View difference between Paste ID: fzajTKX7 and u0NUSJ1P
SHOW: | | - or go back to the newest paste.
1
local player = game.Players.LocalPlayer
2
local function ApplyBaseNames()
3
local playerGui = player.PlayerGui
4
5
local hotbar = playerGui:FindFirstChild("Hotbar")
6
7
local backpack = hotbar:FindFirstChild("Backpack")
8
9
local hotbarFrame = backpack:FindFirstChild("Hotbar")
10
11
local baseButton = hotbarFrame:FindFirstChild("1").Base
12
13
local ToolName = baseButton.ToolName
14
15
16
17
ToolName.Text = "Revenge Strike"
18
19
20
local player = game.Players.LocalPlayer
21
22
local playerGui = player.PlayerGui
23
24
local hotbar = playerGui:FindFirstChild("Hotbar")
25
26
local backpack = hotbar:FindFirstChild("Backpack")
27
28
local hotbarFrame = backpack:FindFirstChild("Hotbar")
29
30
local baseButton = hotbarFrame:FindFirstChild("2").Base
31
32
local ToolName = baseButton.ToolName
33
34
35
ToolName.Text = "Hateful Fury"
36
37
38
local player = game.Players.LocalPlayer
39
40
local playerGui = player.PlayerGui
41
42
local hotbar = playerGui:FindFirstChild("Hotbar")
43
44
local backpack = hotbar:FindFirstChild("Backpack")
45
46
local hotbarFrame = backpack:FindFirstChild("Hotbar")
47
48
local baseButton = hotbarFrame:FindFirstChild("3").Base
49
50
local ToolName = baseButton.ToolName
51
52
53
ToolName.Text = "Clean Strike"
54
55
56
local player = game.Players.LocalPlayer
57
58
local playerGui = player.PlayerGui
59
60
local hotbar = playerGui:FindFirstChild("Hotbar")
61
62
local backpack = hotbar:FindFirstChild("Backpack")
63
64
local hotbarFrame = backpack:FindFirstChild("Hotbar")
65
66
local baseButton = hotbarFrame:FindFirstChild("4").Base
67
68
local ToolName = baseButton.ToolName
69
70
71
ToolName.Text = "Vengeful Smash"
72
end
73
74
local Players = game:GetService("Players")
75
76
local player = Players.LocalPlayer
77
78
local playerGui = player:WaitForChild("PlayerGui")
79
80
81
local function findGuiAndSetText()
82
83
    local screenGui = playerGui:FindFirstChild("ScreenGui")
84
85
    if screenGui then
86
87
        local magicHealthFrame = screenGui:FindFirstChild("MagicHealth")
88
89
        if magicHealthFrame then
90
91
            local textLabel = magicHealthFrame:FindFirstChild("TextLabel")
92
93
            if textLabel then
94
95
                textLabel.Text = "Im done being the dummy."
96
97
            end
98
99
        end
100
101
    end
102
103
end
104
105
106
playerGui.DescendantAdded:Connect(findGuiAndSetText)
107
108
findGuiAndSetText()
109
110
111-
local animationId = 10468665991
111+
local animationId = 15434683426
112
113
114
local player = game.Players.LocalPlayer
115
116
local character = player.Character or player.CharacterAdded:Wait()
117
118
local humanoid = character:WaitForChild("Humanoid")
119
120
121
local function onAnimationPlayed(animationTrack)
122
123
    if animationTrack.Animation.AnimationId == "rbxassetid://" .. animationId then
124
125
126
local p = game.Players.LocalPlayer
127
128
local Humanoid = p.Character:WaitForChild("Humanoid")
129
130
131
for _, animTrack in pairs(Humanoid:GetPlayingAnimationTracks()) do
132
133
    animTrack:Stop()
134
135
end
136
137
-- First move
138
local AnimAnim = Instance.new("Animation")
139
140
AnimAnim.AnimationId = "rbxassetid://103173327148715"
141
142
local Anim = Humanoid:LoadAnimation(AnimAnim)
143
144
145-
local startTime = 1.1
145+
local startTime = 1.59
146
147
148
Anim:Play()
149
150
Anim:AdjustSpeed(0)
151
152
Anim.TimePosition = startTime
153
154
Anim:AdjustSpeed(1.25)
155
156-
task.wait(.88)
156+
task.wait(1.58)
157
Anim:Stop(.75)
158
159
160
    end
161
162
end
163
164
165
humanoid.AnimationPlayed:Connect(onAnimationPlayed)
166
167
168
local animationId = 10466974800
169
170
171
local player = game.Players.LocalPlayer
172
173
local character = player.Character or player.CharacterAdded:Wait()
174
175
local humanoid = character:WaitForChild("Humanoid")
176
177
178
local function onAnimationPlayed(animationTrack)
179
180
    if animationTrack.Animation.AnimationId == "rbxassetid://" .. animationId then
181
182
183
local p = game.Players.LocalPlayer
184
185
local Humanoid = p.Character:WaitForChild("Humanoid")
186
187
188
for _, animTrack in pairs(Humanoid:GetPlayingAnimationTracks()) do
189
190
    animTrack:Stop()
191
192
end
193
194
-- second move
195
local AnimAnim = Instance.new("Animation")
196
197
AnimAnim.AnimationId = "rbxassetid://16945550029"
198
199
local Anim = Humanoid:LoadAnimation(AnimAnim)
200
201
202
local startTime = 1.42
203
204
205
Anim:Play()
206
207
Anim:AdjustSpeed(0)
208
209
Anim.TimePosition = startTime
210
211
Anim:AdjustSpeed(1.4)
212
213
task.wait(1.5)
214
Anim:Stop(.75)
215
216
217
    end
218
219
end
220
221
222
humanoid.AnimationPlayed:Connect(onAnimationPlayed)
223
224
225
local animationId = 10471336737
226
227
228
local player = game.Players.LocalPlayer
229
230
local character = player.Character or player.CharacterAdded:Wait()
231
232
local humanoid = character:WaitForChild("Humanoid")
233
234
235
local function onAnimationPlayed(animationTrack)
236
237
    if animationTrack.Animation.AnimationId == "rbxassetid://" .. animationId then
238
239
240
local p = game.Players.LocalPlayer
241
242
local Humanoid = p.Character:WaitForChild("Humanoid")
243
244
245
for _, animTrack in pairs(Humanoid:GetPlayingAnimationTracks()) do
246
247
    animTrack:Stop()
248
249
end
250
251
-- third move
252
local AnimAnim = Instance.new("Animation")
253
254
AnimAnim.AnimationId = "rbxassetid://15391323441"
255
256
local Anim = Humanoid:LoadAnimation(AnimAnim)
257
258
259
local startTime = 5.3
260
261
262
Anim:Play()
263
264
Anim:AdjustSpeed(0)
265
266
Anim.TimePosition = startTime
267
268
Anim:AdjustSpeed(2.9)
269
270
271
delay(1.8, function()
272
273
    Anim:Stop()
274
275
end)
276
277
278
    end
279
280
end
281
282
283
humanoid.AnimationPlayed:Connect(onAnimationPlayed)
284
285
286
local animationId = 12510170988
287
288
289
local player = game.Players.LocalPlayer
290
291
local character = player.Character or player.CharacterAdded:Wait()
292
293
local humanoid = character:WaitForChild("Humanoid")
294
295
296
local function onAnimationPlayed(animationTrack)
297
298
    if animationTrack.Animation.AnimationId == "rbxassetid://" .. animationId then
299
300
local p = game.Players.LocalPlayer
301
302
local Humanoid = p.Character:WaitForChild("Humanoid")
303
304
305
for _, animTrack in pairs(Humanoid:GetPlayingAnimationTracks()) do
306
307
    animTrack:Stop()
308
309
end
310
311
-- fourth move (last move)
312
local AnimAnim = Instance.new("Animation")
313
314
AnimAnim.AnimationId = "rbxassetid://18179181663"
315
316
local Anim = Humanoid:LoadAnimation(AnimAnim)
317
318
319
local startTime = 0.1
320
321
322
Anim:Play()
323
324
Anim:AdjustSpeed(0)
325
326
Anim.TimePosition = startTime
327
328
Anim:AdjustSpeed(1)
329
330
331
    end
332
333
end
334
335
humanoid.AnimationPlayed:Connect(onAnimationPlayed)
336
337
local animationId = 11343318134
338
339
340
local player = game.Players.LocalPlayer
341
342
local character = player.Character or player.CharacterAdded:Wait()
343
344
local humanoid = character:WaitForChild("Humanoid")
345
346
347
local function onAnimationPlayed(animationTrack)
348
349
    if animationTrack.Animation.AnimationId == "rbxassetid://" .. animationId then
350
351
local p = game.Players.LocalPlayer
352
353
local Humanoid = p.Character:WaitForChild("Humanoid")
354
355
356
for _, animTrack in pairs(Humanoid:GetPlayingAnimationTracks()) do
357
358
    animTrack:Stop()
359
360
end
361
362
-- serious punch
363
364
local AnimAnim = Instance.new("Animation")
365
366
AnimAnim.AnimationId = "rbxassetid://12983333733"
367
368
local Anim = Humanoid:LoadAnimation(AnimAnim)
369
370
371
local startTime = 2
372
373
Anim:Play()
374
ApplyBaseNames()
375
376
Anim:AdjustSpeed(0)
377
378
Anim.TimePosition = startTime
379
380
Anim:AdjustSpeed(0.5)
381
382
383
    end
384
385
end
386
387
humanoid.AnimationPlayed:Connect(onAnimationPlayed)
388
389
local animationId = 15955393872
390
391
392
local player = game.Players.LocalPlayer
393
394
local character = player.Character or player.CharacterAdded:Wait()
395
396
local humanoid = character:WaitForChild("Humanoid")
397
398
399
local function onAnimationPlayed(animationTrack)
400
401
    if animationTrack.Animation.AnimationId == "rbxassetid://" .. animationId then
402
403
local p = game.Players.LocalPlayer
404
405
local Humanoid = p.Character:WaitForChild("Humanoid")
406
407
408
for _, animTrack in pairs(Humanoid:GetPlayingAnimationTracks()) do
409
410
    animTrack:Stop()
411
412
end
413
414
-- Wallcombo
415
local AnimAnim = Instance.new("Animation")
416
417
AnimAnim.AnimationId = "rbxassetid://18440406788"
418
419
local Anim = Humanoid:LoadAnimation(AnimAnim)
420
421
422
local startTime = 2.2
423
424
425
Anim:Play()
426
427
Anim:AdjustSpeed(0)
428
429
Anim.TimePosition = startTime
430
431
Anim:AdjustSpeed(1)
432
433
434
    end
435
436
end
437
438
439
440
humanoid.AnimationPlayed:Connect(onAnimationPlayed)
441
442
local animationId = 12983333733
443
444
445
local player = game.Players.LocalPlayer
446
447
local character = player.Character or player.CharacterAdded:Wait()
448
449
local humanoid = character:WaitForChild("Humanoid")
450
451
452
local function onAnimationPlayed(animationTrack)
453
454
    if animationTrack.Animation.AnimationId == "rbxassetid://" .. animationId then
455
456
local p = game.Players.LocalPlayer
457
458
local Humanoid = p.Character:WaitForChild("Humanoid")
459
460
461
for _, animTrack in pairs(Humanoid:GetPlayingAnimationTracks()) do
462
463
    animTrack:Stop()
464
465
end
466
467
468
-- death counter
469
local AnimAnim = Instance.new("Animation")
470
471
AnimAnim.AnimationId = "rbxassetid://13073745835"
472
473
local Anim = Humanoid:LoadAnimation(AnimAnim)
474
475
476
local startTime = 0.3
477
478
479
Anim:Play()
480
ApplyBaseNames()
481
482
Anim:AdjustSpeed(0)
483
484
Anim.TimePosition = startTime
485
486
Anim:AdjustSpeed(0.2)
487
488
489
    end
490
491
end
492
493
humanoid.AnimationPlayed:Connect(onAnimationPlayed)
494
495
496
local animationId = 12447707844
497
498
499
local player = game.Players.LocalPlayer
500
501
local character = player.Character or player.CharacterAdded:Wait()
502
503
local humanoid = character:WaitForChild("Humanoid")
504
505
506
local function onAnimationPlayed(animationTrack)
507
508
    if animationTrack.Animation.AnimationId == "rbxassetid://" .. animationId then
509
510
local p = game.Players.LocalPlayer
511
512
local Humanoid = p.Character:WaitForChild("Humanoid")
513
514
515
for _, animTrack in pairs(Humanoid:GetPlayingAnimationTracks()) do
516
517
    animTrack:Stop()
518
519
end
520
521
-- ult anim
522
local AnimAnim = Instance.new("Animation")
523
524
AnimAnim.AnimationId = "rbxassetid://17292505729"
525
526
local Anim = Humanoid:LoadAnimation(AnimAnim)
527
528
529
local startTime = 0
530
531
532
533
Anim:Play()
534
535
Anim:AdjustSpeed(0)
536
537
Anim.TimePosition = startTime
538
539
Anim:AdjustSpeed(1)
540
541
    end
542
543
end
544
545
humanoid.AnimationPlayed:Connect(onAnimationPlayed)
546
547
548
local animationId = 10479335397
549
550
551
local player = game.Players.LocalPlayer
552
553
local character = player.Character or player.CharacterAdded:Wait()
554
555
local humanoid = character:WaitForChild("Humanoid")
556
557
558
local function onAnimationPlayed(animationTrack)
559
560
    if animationTrack.Animation.AnimationId == "rbxassetid://" .. animationId then
561
562
local p = game.Players.LocalPlayer
563
564
local Humanoid = p.Character:WaitForChild("Humanoid")
565
566
567
for _, animTrack in pairs(Humanoid:GetPlayingAnimationTracks()) do
568
569
    animTrack:Stop()
570
571
end
572
573
-- Dash anim
574
local AnimAnim = Instance.new("Animation")
575
576
AnimAnim.AnimationId = "rbxassetid://17838006839"
577
578
local Anim = Humanoid:LoadAnimation(AnimAnim)
579
580
581
local startTime = 0.120
582
583
584
Anim:Play()
585
586
Anim:AdjustSpeed(0)
587
588
Anim.TimePosition = startTime
589
590
Anim:AdjustSpeed(0.7)
591
592
593
delay(1.2, function()
594
595
    Anim:Stop()
596
597
end)
598
599
600
    end
601
602
end
603
604
humanoid.AnimationPlayed:Connect(onAnimationPlayed)
605
606
607
local animationId = 10503381238
608
609
610
local player = game.Players.LocalPlayer
611
612
local character = player.Character or player.CharacterAdded:Wait()
613
614
local humanoid = character:WaitForChild("Humanoid")
615
616
617
local function onAnimationPlayed(animationTrack)
618
619
    if animationTrack.Animation.AnimationId == "rbxassetid://" .. animationId then
620
621
local p = game.Players.LocalPlayer
622
623
local Humanoid = p.Character:WaitForChild("Humanoid")
624
625
626
for _, animTrack in pairs(Humanoid:GetPlayingAnimationTracks()) do
627
628
    animTrack:Stop()
629
630
end
631
632
-- Uppercut anim
633
local AnimAnim = Instance.new("Animation")
634
635
AnimAnim.AnimationId = "rbxassetid://14001963401"
636
637
local Anim = Humanoid:LoadAnimation(AnimAnim)
638
639
640
local startTime = 0.2
641
642
643
Anim:Play()
644
645
Anim:AdjustSpeed(0)
646
647
Anim.TimePosition = startTime
648
649
Anim:AdjustSpeed(1)
650
651
652
    end
653
654
end
655
656
humanoid.AnimationPlayed:Connect(onAnimationPlayed)
657
658
659
local animationId = 13813955149
660
661
662
local player = game.Players.LocalPlayer
663
664
local character = player.Character or player.CharacterAdded:Wait()
665
666
local humanoid = character:WaitForChild("Humanoid")
667
668
669
local function onAnimationPlayed(animationTrack)
670
671
    if animationTrack.Animation.AnimationId == "rbxassetid://" .. animationId then
672
673
674
local p = game.Players.LocalPlayer
675
676
local Humanoid = p.Character:WaitForChild("Humanoid")
677
678
679
for _, animTrack in pairs(Humanoid:GetPlayingAnimationTracks()) do
680
681
    animTrack:Stop()
682
683
end
684
685
-- trashcan throw
686
local AnimAnim = Instance.new("Animation")
687
688
AnimAnim.AnimationId = "rbxassetid://13073745835"
689
690
local Anim = Humanoid:LoadAnimation(AnimAnim)
691
692
693
local startTime = 0
694
695
696
Anim:Play()
697
698
Anim:AdjustSpeed(0)
699
700
Anim.TimePosition = startTime
701
702
Anim:AdjustSpeed(1.5)
703
704
705
706
    end
707
708
end
709
710
humanoid.AnimationPlayed:Connect(onAnimationPlayed)
711
712
713
local animationId = 10470104242
714
715
716
local player = game.Players.LocalPlayer
717
718
local character = player.Character or player.CharacterAdded:Wait()
719
720
local humanoid = character:WaitForChild("Humanoid")
721
722
723
local function onAnimationPlayed(animationTrack)
724
725
    if animationTrack.Animation.AnimationId == "rbxassetid://" .. animationId then
726
727
local p = game.Players.LocalPlayer
728
729
local Humanoid = p.Character:WaitForChild("Humanoid")
730
731
732
for _, animTrack in pairs(Humanoid:GetPlayingAnimationTracks()) do
733
734
    animTrack:Stop()
735
736
end
737
738
-- Downslam anim
739
local AnimAnim = Instance.new("Animation")
740
741
AnimAnim.AnimationId = "rbxassetid://17858878027  "
742
743
local Anim = Humanoid:LoadAnimation(AnimAnim)
744
745
746
local startTime = 0.1120
747
748
749
wait(0.2)
750
751
Anim:Play()
752
753
Anim:AdjustSpeed(0.10)
754
755
Anim.TimePosition = startTime
756
757
Anim:AdjustSpeed(1)
758
759
760
    end
761
762
end
763
764
humanoid.AnimationPlayed:Connect(onAnimationPlayed)
765
766
767
local animationId = 17120966975
768
769
770
local player = game.Players.LocalPlayer
771
772
local character = player.Character or player.CharacterAdded:Wait()
773
774
local humanoid = character:WaitForChild("Humanoid")
775
776
777
local function onAnimationPlayed(animationTrack)
778
779
    if animationTrack.Animation.AnimationId == "rbxassetid://" .. animationId then
780
781
782
local p = game.Players.LocalPlayer
783
784
local Humanoid = p.Character:WaitForChild("Humanoid")
785
786
787
for _, animTrack in pairs(Humanoid:GetPlayingAnimationTracks()) do
788
789
    animTrack:Stop()
790
791
end
792
793
-- change emotes change
794
local AnimAnim = Instance.new("Animation")
795
796
AnimAnim.AnimationId = "rbxassetid://100255267749203"
797
798
local Anim = Humanoid:LoadAnimation(AnimAnim)
799
800
801
local startTime = 0
802
803
804
Anim:Play()
805
806
Anim:AdjustSpeed(0)
807
808
Anim.TimePosition = startTime
809
810
Anim:AdjustSpeed(1)
811
812
813
814
    end
815
816
end
817
818
humanoid.AnimationPlayed:Connect(onAnimationPlayed)
819
820
821
local Players = game:GetService("Players")
822
823
local player = Players.LocalPlayer
824
825
local character = player.Character or player.CharacterAdded:Wait()
826
827
local humanoid = character:WaitForChild("Humanoid")
828
829
-- Saitama m1s
830
831
local animationIdsToStop = {
832
833
    [10469493270] = true,
834
835
    [10469630950] = true,
836
837
    [10469639222] = true,
838
839
    [10469643643] = true,
840
841
}
842
843
-- rechange m1s
844
845
local replacementAnimations = {
846
847
    ["10469643643"] = "rbxassetid://13491635433 ",
848
849
    ["10469639222"] = "rbxassetid://13295919399",
850
851
    ["10469630950"] = "rbxassetid://17889461810",
852
853
    ["10469493270"] = "rbxassetid://17889458563",
854
855
}
856
857
858
local queue = {}
859
860
local isAnimating = false
861
862
863
local function playReplacementAnimation(animationId)
864
865
    if isAnimating then
866
867
        table.insert(queue, animationId)
868
869
        return
870
871
    end
872
873
   
874
875
    isAnimating = true
876
877
    local replacementAnimationId = replacementAnimations[tostring(animationId)]
878
879
    if replacementAnimationId then
880
881
        local AnimAnim = Instance.new("Animation")
882
883
        AnimAnim.AnimationId = replacementAnimationId
884
885
        local Anim = humanoid:LoadAnimation(AnimAnim)
886
887
        Anim:Play()
888
889
       
890
891
        Anim.Stopped:Connect(function()
892
893
            isAnimating = false
894
895
            if #queue > 0 then
896
897
                local nextAnimationId = table.remove(queue, 1)
898
899
                playReplacementAnimation(nextAnimationId)
900
901
            end
902
903
        end)
904
905
    else
906
907
        isAnimating = false
908
909
    end
910
911
end
912
913
914
local function stopSpecificAnimations()
915
916
    for _, track in ipairs(humanoid:GetPlayingAnimationTracks()) do
917
918
        local animationId = tonumber(track.Animation.AnimationId:match("%d+"))
919
920
        if animationIdsToStop[animationId] then
921
922
            track:Stop()
923
924
        end
925
926
    end
927
928
end
929
930
931
local function onAnimationPlayed(animationTrack)
932
933
    local animationId = tonumber(animationTrack.Animation.AnimationId:match("%d+"))
934
935
    if animationIdsToStop[animationId] then
936
937
        stopSpecificAnimations()
938
939
        animationTrack:Stop()
940
941
       
942
943
        local replacementAnimationId = replacementAnimations[tostring(animationId)]
944
945
        if replacementAnimationId then
946
947
            playReplacementAnimation(animationId)
948
949
        end
950
951
    end
952
953
end
954
955
956
humanoid.AnimationPlayed:Connect(onAnimationPlayed)
957
958
959
local player = game.Players.LocalPlayer
960
961
local character = player.Character or player.CharacterAdded:Wait()
962
963
local humanoidRootPart = character:WaitForChild("HumanoidRootPart")
964
965
966
local function onBodyVelocityAdded(bodyVelocity)
967
968
    if bodyVelocity:IsA("BodyVelocity") then
969
970
        bodyVelocity.Velocity = Vector3.new(bodyVelocity.Velocity.X, 0, bodyVelocity.Velocity.Z)
971
972
    end
973
974
end
975
976
977
character.DescendantAdded:Connect(onBodyVelocityAdded)
978
979
980
for _, descendant in pairs(character:GetDescendants()) do
981
982
    onBodyVelocityAdded(descendant)
983
984
end
985
986
987
player.CharacterAdded:Connect(function(newCharacter)
988
989
    character = newCharacter
990
991
    humanoidRootPart = character:WaitForChild("HumanoidRootPart")
992
993
    character.DescendantAdded:Connect(onBodyVelocityAdded)
994
995
   
996
997
    for _, descendant in pairs(character:GetDescendants()) do
998
999
        onBodyVelocityAdded(descendant)
1000
1001
    end
1002
1003
end)
1004
1005
1006
local Players = game:GetService("Players")
1007
local TweenService = game:GetService("TweenService")
1008
1009
local player = Players.LocalPlayer
1010
local playerGui = player:WaitForChild("PlayerGui")
1011
1012
local function updateBarColor()
1013
    local screenGui = playerGui:FindFirstChild("Main")
1014
    if not screenGui then return end
1015
1016-
    local magicHealthFrame = screenGui:FindFirstChild("MagicHealth")
1016+
    local magicHealthFrame = screenGui:FindFirstChild("Ultimate")
1017
    if not magicHealthFrame then return end
1018
1019-
    local healthFrame = magicHealthFrame:FindFirstChild("Health")
1019+
    local healthFrame = magicHealthFrame:FindFirstChild("Bar")
1020
    if not healthFrame then return end
1021
1022-
    local barFrame = healthFrame:FindFirstChild("Bar")
1022+
    local barFrame = healthFrame:FindFirstChild("Fill")
1023
    if not barFrame then return end
1024
1025-
    local imageLabel = barFrame:FindFirstChild("Bar")
1025+
 
1026-
    if not imageLabel or not imageLabel:IsA("ImageLabel") then return end
1026+
1027
    barFrame.BackgroundColor3 = Color3.fromRGB(190, 0, 255)
1028-
    imageLabel.ImageColor3 = Color3.fromRGB(1, 1, 1)
1028+
1029
1030
local function onCharacterAdded(character)
1031
    updateBarColor()
1032
end
1033
1034
local function onPlayerAdded()
1035
    local character = player.Character or player.CharacterAdded:Wait()
1036
    onCharacterAdded(character)
1037
1038
    player.CharacterAdded:Connect(onCharacterAdded)
1039
end
1040
function sendMsg(msg)
1041
local textchannel = game:GetService("TextChatService").TextChannels:WaitForChild("RBXGeneral") 
1042
local message = msg 
1043
textchannel:SendAsync(message)
1044
end
1045
1046
Players.PlayerAdded:Connect(onPlayerAdded)
1047
if player then
1048
    onPlayerAdded()
1049
end