View difference between Paste ID: Wy7CRvap and gWDp6QiV
SHOW: | | - or go back to the newest paste.
1
local oldtick = tick()
2
warn("Animation rig - By Mewy23")
3
local plr = game:GetService("Players").LocalPlayer
4
local char, mouse = plr.Character, plr:GetMouse()
5
local hitTab = {}
6
local fadeTab = {}
7
local spd = 0.2 * char:FindFirstChild("Humanoid").WalkSpeed / 16
8
local sound1 = Instance.new("Sound", char.HumanoidRootPart)
9
local sound2 = Instance.new("Sound", char.HumanoidRootPart)
10
local sound3 = Instance.new("Sound")
11
sound1.SoundId = "rbxassetid://130767866"
12
sound1.Volume = 10
13
sound2.SoundId = "rbxassetid://142684400"
14
sound2.Volume = 10
15
sound3.SoundId = "rbxassetid://985132972"
16
sound3.Volume = 10
17
local particle = Instance.new("ParticleEmitter")
18
particle.LightEmission = 0.2
19
particle.Texture = "rbxassetid://50263573"
20
particle.Size = NumberSequence.new({
21
  NumberSequenceKeypoint.new(0, 0),
22
  NumberSequenceKeypoint.new(0.5, 1),
23
  NumberSequenceKeypoint.new(1, 0)
24
})
25
particle.Acceleration = Vector3.new(0, 0, 0)
26
particle.Lifetime = NumberRange.new(0.15, 0.3)
27
particle.Rate = 50
28
particle.Rotation = NumberRange.new(0, 360)
29
particle.RotSpeed = NumberRange.new(0, 0)
30
particle.Speed = NumberRange.new(0, 0)
31
local dfj = {}
32
char:WaitForChild("Animate"):Destroy()
33
char:WaitForChild("Humanoid"):WaitForChild("Animator"):Destroy()
34
for i, v in pairs(char:FindFirstChild("Torso"):GetChildren()) do
35
  if v:IsA("Motor6D") and v.Name ~= "Neck" then
36
    table.insert(dfj, v:Clone())
37
    v:Destroy()
38
char.Humanoid.MaxHealth = math.huge
39
			wait()
40
			char.Humanoid.Health = math.huge
41
  end
42
end
43
local state = "idle"
44
local rootpart = char:FindFirstChild("HumanoidRootPart")
45
local rootjoint = rootpart:FindFirstChild("RootJoint")
46
rootjoint.C1 = CFrame.new(0, 0, 0) * CFrame.Angles(math.rad(-90), math.rad(0), math.rad(180))
47
local rarm = Instance.new("Weld", char:FindFirstChild("Right Arm") or nil)
48
rarm.Part0 = char:FindFirstChild("Torso") or nil
49
rarm.Part1 = char:FindFirstChild("Right Arm") or nil
50
rarm.C0 = CFrame.new(1, 0.5, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0))
51
rarm.C1 = CFrame.new(-0.5, 0.5, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0))
52
local larm = Instance.new("Weld", char:FindFirstChild("Left Arm") or nil)
53
larm.Part0 = char:FindFirstChild("Torso") or nil
54
larm.Part1 = char:FindFirstChild("Left Arm") or nil
55
larm.C0 = CFrame.new(-1, 0.5, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0))
56
larm.C1 = CFrame.new(0.5, 0.5, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0))
57
local rleg = Instance.new("Weld", char:FindFirstChild("Right Leg") or nil)
58
rleg.Part0 = char:FindFirstChild("Torso") or nil
59
rleg.Part1 = char:FindFirstChild("Right Leg") or nil
60
rleg.C0 = CFrame.new(1, -1, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0))
61
rleg.C1 = CFrame.new(0.5, 1, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0))
62
local lleg = Instance.new("Weld", char:FindFirstChild("Left Leg") or nil)
63
lleg.Part0 = char:FindFirstChild("Torso") or nil
64
lleg.Part1 = char:FindFirstChild("Left Leg") or nil
65
lleg.C0 = CFrame.new(-1, -1, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0))
66
lleg.C1 = CFrame.new(-0.5, 1, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0))
67
local neck = char:FindFirstChild("Torso"):FindFirstChild("Neck") or nil
68
neck.Part0 = char:FindFirstChild("Torso") or nil
69
neck.Part1 = char:FindFirstChild("Head") or nil
70
neck.C0 = CFrame.new(0, 1, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0))
71
neck.C1 = CFrame.new(0, -0.5, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0))
72
function hitSphere()
73
  local function recSearch(par)
74
75
CV="Pastel blue"
76
	
77
local txt = Instance.new("BillboardGui", Character)
78
txt.Adornee = Character .Head
79
txt.Name = "_status"
80
txt.Size = UDim2.new(2, 0, 1.2, 0)
81
txt.StudsOffset = Vector3.new(-9, 8, 0)
82
local text = Instance.new("TextLabel", txt)
83
text.Size = UDim2.new(10, 0, 7, 0)
84
text.FontSize = "Size24"
85
text.TextScaled = true
86
text.TextTransparency = 0
87
text.BackgroundTransparency = 1 
88
text.TextTransparency = 0
89
text.TextStrokeTransparency = 0
90
text.Font = "Antique"
91
text.TextStrokeColor3 = Color3.new(255,85,0)
92
93
v=Instance.new("Part")
94
v.Name = "ColorBrick"
95
v.Parent=Player.Character
96
v.FormFactor="Symmetric"
97
v.Anchored=true
98
v.CanCollide=false
99
v.BottomSurface="Smooth"
100
v.TopSurface="Smooth"
101
v.Size=Vector3.new(10,5,3)
102
v.Transparency=1
103
v.CFrame=Character.Torso.CFrame
104
v.BrickColor=BrickColor.new(CV)
105
v.Transparency=1
106
text.TextColor3 = Color3.new(0,0,0)
107
v.Shape="Block"
108
text.Text = "KENSHIRO"
109
110
shirt = Instance.new("Shirt", char)
111
shirt.Name = "Shirt"
112
pants = Instance.new("Pants", char)
113
pants.Name = "Pants"
114
char.Shirt:Remove()
115
char.Pants:Remove()
116
for i,v in pairs(char:GetChildren()) do if v:IsA("Accessory") then v.Handle:Remove() end end
117
char.Shirt.ShirtTemplate = "http://www.roblox.com/asset/?id=667102257"
118
char.Pants.PantsTemplate = "http://www.roblox.com/asset/?id=815144043"
119
char.Head.face.Texture = "rbxassetid://319908966"
120
121
122
123
124
    local tab = {}
125
    local function rec(parent)
126
      if parent:IsA("Humanoid") and parent ~= char:FindFirstChildOfClass("Humanoid") then
127
        table.insert(tab, parent)
128
      end
129
      for i, v in pairs(parent:GetChildren()) do
130
        rec(v)
131
      end
132
    end
133
    rec(par)
134
    return tab
135
  end
136
  local humsFound = {}
137
  for i, v in pairs(recSearch(workspace)) do
138
    table.insert(humsFound, v)
139
  end
140
  return humsFound
141
end
142
mouse.Button1Down:connect(function()
143
  if state ~= "busy" then
144
    state = "busy"
145
    do
146
      local foundHums = {}
147
      local prtcls = {}
148
      local sounds = {}
149
      local parts = {}
150
      sound1:Play()
151
      local hit = false
152
      local toggle = false
153
      local frmcon
154
      local frame = 0
155
      frmcon = game:service("RunService").RenderStepped:connect(function()
156
        frame = frame + 1
157
        if frame / 4 == math.floor(frame / 4) then
158
          if toggle == false then
159
            toggle = true
160
          else
161
            toggle = false
162
          end
163
        end
164
        if toggle == true then
165
          rleg.C0 = rleg.C0:lerp(CFrame.new(1, -1 - math.cos(tick()) / 16, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), spd)
166
          lleg.C0 = lleg.C0:lerp(CFrame.new(-1, -1 - math.cos(tick()) / 16, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), spd)
167
          rarm.C0 = rarm.C0:lerp(CFrame.new(1, 0.5, 0) * CFrame.Angles(math.rad(90), math.rad(0), math.rad(45)), spd * 1.5)
168
          larm.C0 = larm.C0:lerp(CFrame.new(-1, 0.5, 0) * CFrame.Angles(math.rad(90), math.rad(0), math.rad(90)), spd * 1.5)
169
          rootjoint.C0 = rootjoint.C0:lerp(CFrame.new(0, math.cos(tick()) / 16, 0) * CFrame.Angles(math.rad(-90), math.rad(0), math.rad(225)), spd * 1.5)
170
          neck.C0 = neck.C0:lerp(CFrame.new(0, 1, 0) * CFrame.Angles(math.rad(0), math.rad(-45), math.rad(0)), spd * 1.5)
171
        else
172
          rleg.C0 = rleg.C0:lerp(CFrame.new(1, -1 - math.cos(tick()) / 16, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), spd)
173
          lleg.C0 = lleg.C0:lerp(CFrame.new(-1, -1 - math.cos(tick()) / 16, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), spd)
174
          rarm.C0 = rarm.C0:lerp(CFrame.new(1, 0.5, 0) * CFrame.Angles(math.rad(90), math.rad(0), math.rad(-90)), spd * 1.5)
175
          larm.C0 = larm.C0:lerp(CFrame.new(-1, 0.5, 0) * CFrame.Angles(math.rad(90), math.rad(0), math.rad(-45)), spd * 1.5)
176
          rootjoint.C0 = rootjoint.C0:lerp(CFrame.new(0, math.cos(tick()) / 16, 0) * CFrame.Angles(math.rad(-90), math.rad(0), math.rad(135)), spd * 1.5)
177
          neck.C0 = neck.C0:lerp(CFrame.new(0, 1, 0) * CFrame.Angles(math.rad(0), math.rad(45), math.rad(0)), spd * 1.5)
178
        end
179
        if frame % 5 == 0 then
180
          for i, v in pairs(hitSphere()) do
181
            for o, b in pairs(v.Parent:GetChildren()) do
182
              if b:IsA("BasePart") and 4 >= (b.Position - rootjoint.Parent.CFrame * CFrame.new(0, 0, -2.25).p).Magnitude then
183
                hit = true
184
                if foundHums[v] then
185
                  foundHums[v] = foundHums[v] + 1
186
                else
187
                  foundHums[v] = 1
188
                  local ns = sound3:Clone()
189
                  ns.Parent = b
190
                  table.insert(sounds, ns)
191
                end
192
                if not prtcls[b] then
193
                  partClone = particle:Clone()
194
                  partClone.Enabled = false
195
                  partClone.Parent = b
196
                  prtcls[b] = partClone
197
                end
198
                local p = Instance.new("Part")
199
                p.Size = Vector3.new(0.2, 0.2, 0.2)
200
                p.Color = Color3.new(1, 1, 1)
201
                p.TopSurface = "Smooth"
202
                p.BottomSurface = "Smooth"
203
                p.Anchored = true
204
                p.CanCollide = false
205
                p.Shape = "Ball"
206
                p.CFrame = CFrame.new(b.CFrame.p + Vector3.new(math.random(-10, 10) / 10, math.random(-10, 10) / 10, math.random(-10, 10) / 10))
207
                p.Parent = workspace
208
                table.insert(fadeTab, p)
209
                parts[b] = b
210
              end
211
            end
212
          end
213
        end
214
      end)
215
      local bucon
216
      bucon = mouse.Button1Up:connect(function()
217
        frmcon:disconnect()
218
        sound1:Stop()
219
        state = "idle"
220
        if hit == true then
221
          sound2:Play()
222
          wait(2.7)
223
          for i, v in pairs(sounds) do
224
            spawn(function()
225
              wait(math.random(0, 100) / 600)
226
              v.TimePosition = 2.5
227
              v:Play()
228
            end)
229
          end
230
          wait(1.2)
231
          for i, v in pairs(prtcls) do
232
            v.Enabled = true
233
          end
234
          wait(1.3)
235
          spawn(function()
236
            local rcon
237
            local frame = 0
238
            rcon = game:service("RunService").RenderStepped:connect(function()
239
              frame = frame + 1
240
              for i, v in pairs(sounds) do
241
                v.Volume = 10 - frame / 5
242
                if v.Volume <= 0 then
243
                  v.Volume = 0
244
                  v:Destroy()
245
                end
246
              end
247
              if frame >= 200 then
248
                for i, v in pairs(sounds) do
249
                  v:Destroy()
250
                end
251
              end
252
            end)
253
          end)
254
          for i, v in pairs(parts) do
255
            v.RotVelocity = Vector3.new(math.random(-100, 100), math.random(-100, 100), math.random(-100, 100))
256
            v.Velocity = v.Velocity + Vector3.new(0, 20, 0)
257
            local bvel = Instance.new("BodyVelocity", v)
258
            bvel.MaxForce = Vector3.new(1000000, 1000000, 1000000)
259
            bvel.Velocity = Vector3.new(math.random(-50, 50), math.random(-50, 50), math.random(-50, 50))
260
            game:service("Debris"):AddItem(bvel, 0.5)
261
          end
262
          for i, v in pairs(foundHums) do
263
            if i.MaxHealth >= math.huge then
264
              i.MaxHealth = 100
265
            end
266
            i.Health = 0
267
          end
268
          wait(0.7)
269
          for i, v in pairs(prtcls) do
270
            v.Enabled = false
271
          end
272
        end
273
        bucon:disconnect()
274
      end)
275
    end
276
  end
277
end)
278
game:GetService("RunService").Heartbeat:connect(function()
279
  for i, v in pairs(fadeTab) do
280
    v.Transparency = v.Transparency + 0.1
281
    local savecf = v.CFrame
282
    v.Size = v.Size + Vector3.new(0.3, 0.3, 0.3)
283
    v.CFrame = savecf
284
  end
285
  local isub = 0
286
  for i = 1, #fadeTab do
287
    if fadeTab[i - isub].Transparency >= 1 then
288
      fadeTab[i - isub]:Destroy()
289
      table.remove(fadeTab, i - isub)
290
      isub = isub + 1
291
    end
292
  end
293
  char:FindFirstChild("Humanoid").WalkSpeed = 26
294
  spd = 0.2 * char:FindFirstChild("Humanoid").WalkSpeed / 16
295
  if state ~= "busy" then
296
    local ray = Ray.new(rootpart.Position, Vector3.new(0, -4, 0))
297
    local part, pos, normal = workspace:FindPartOnRayWithIgnoreList(ray, char:GetChildren(), false, true)
298
    if rootpart.Velocity.Magnitude > 0.5 and part ~= nil then
299
      state = "running"
300
    elseif rootpart.Velocity.Magnitude <= 0.5 and part ~= nil then
301
      state = "idle"
302
    elseif 0 < rootpart.Velocity.Y and part == nil then
303
      state = "jumping"
304
    elseif 0 >= rootpart.Velocity.Y and part == nil then
305
      state = "falling"
306
    end
307
    if state == "idle" then
308
      rleg.C0 = rleg.C0:lerp(CFrame.new(1, -1 - math.cos(tick()) / 16, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), spd)
309
      lleg.C0 = lleg.C0:lerp(CFrame.new(-1, -1 - math.cos(tick()) / 16, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), spd)
310
      rarm.C0 = rarm.C0:lerp(CFrame.new(1, 0.5 + math.cos(tick() + 0.5) / 16, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad((math.cos(tick()) + 1) / 16) * 20), spd)
311
      larm.C0 = larm.C0:lerp(CFrame.new(-1, 0.5 + math.cos(tick() + 0.5) / 16, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(-(math.cos(tick()) + 1) / 16) * 20), spd)
312
      rootjoint.C0 = rootjoint.C0:lerp(CFrame.new(0, math.cos(tick()) / 16, 0) * CFrame.Angles(math.rad(-90), math.rad(0), math.rad(180)), spd)
313
      neck.C0 = neck.C0:lerp(CFrame.new(0, 1, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), spd)
314
    elseif state == "running" then
315
      rleg.C0 = rleg.C0:lerp(CFrame.new(1, -1 - -math.sin(tick() * 8 + 90) / 8, math.sin(tick() * 8 + 90) / 10) * CFrame.Angles(math.rad(math.sin(tick() * 8) * 60), math.rad(0), math.rad(0)), spd)
316
      lleg.C0 = lleg.C0:lerp(CFrame.new(-1, -1 - math.sin(tick() * 8 + 90) / 8, -math.sin(tick() * 8 + 90) / 10) * CFrame.Angles(-math.rad(math.sin(tick() * 8) * 60), math.rad(0), math.rad(0)), spd)
317
      rarm.C0 = rarm.C0:lerp(CFrame.new(1, 0.5, 0) * CFrame.Angles(math.rad(math.sin(tick() * 8) * 80), math.rad(0), math.rad(0)), spd)
318
      larm.C0 = larm.C0:lerp(CFrame.new(-1, 0.5, 0) * CFrame.Angles(-math.rad(math.sin(tick() * 8) * 80), math.rad(0), math.rad(0)), spd)
319
      rootjoint.C0 = rootjoint.C0:lerp(CFrame.new(0, 0, 0) * CFrame.Angles(math.rad(-110), math.rad(0), math.rad(180)), spd)
320
      neck.C0 = neck.C0:lerp(CFrame.new(0, 1, 0) * CFrame.Angles(math.rad(20), math.rad(0), math.rad(0)), spd)
321
    elseif state == "jumping" then
322
      rleg.C0 = rleg.C0:lerp(CFrame.new(1, -1, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), spd)
323
      lleg.C0 = lleg.C0:lerp(CFrame.new(-1, -1, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), spd)
324
      rarm.C0 = rarm.C0:lerp(CFrame.new(1, 0.5, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), spd)
325
      larm.C0 = larm.C0:lerp(CFrame.new(-1, 0.5, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), spd)
326
      rootjoint.C0 = rootjoint.C0:lerp(CFrame.new(0, 0, 0) * CFrame.Angles(math.rad(-90), math.rad(0), math.rad(180)), spd)
327
      neck.C0 = neck.C0:lerp(CFrame.new(0, 1, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), spd)
328
    elseif state == "falling" then
329
      rleg.C0 = rleg.C0:lerp(CFrame.new(1, -1, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), spd)
330
      lleg.C0 = lleg.C0:lerp(CFrame.new(-1, -1, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), spd)
331
      rarm.C0 = rarm.C0:lerp(CFrame.new(1, 0.5, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), spd)
332
      larm.C0 = larm.C0:lerp(CFrame.new(-1, 0.5, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), spd)
333
      rootjoint.C0 = rootjoint.C0:lerp(CFrame.new(0, 0, 0) * CFrame.Angles(math.rad(-90), math.rad(0), math.rad(180)), spd)
334
      neck.C0 = neck.C0:lerp(CFrame.new(0, 1, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), spd)
335
    end
336
  end
337
end)
338
warn("Loaded! Time elapsed: " .. tick() - oldtick)