SHOW:
|
|
- or go back to the newest paste.
1 | -- This script has been converted to FE by iPxter | |
2 | - | -- [ SANIIIC HES ON DA RAWN ] -- |
2 | + | |
3 | ||
4 | if game:GetService("RunService"):IsClient() then error("Script must be server-side in order to work; use h/ and not hl/") end | |
5 | local Player,Mouse,mouse,UserInputService,ContextActionService = owner | |
6 | do | |
7 | print("FE Compatibility code by Mokiros | Translated to FE by iPxter") | |
8 | script.Parent = Player.Character | |
9 | - | Player = game.Players.LocalPlayer |
9 | + | |
10 | - | c = game.Players.LocalPlayer.Character |
10 | + | --RemoteEvent for communicating |
11 | local Event = Instance.new("RemoteEvent") | |
12 | Event.Name = "UserInput_Event" | |
13 | ||
14 | --Fake event to make stuff like Mouse.KeyDown work | |
15 | - | p = game.Players.LocalPlayer |
15 | + | local function fakeEvent() |
16 | local t = {_fakeEvent=true,Connect=function(self,f)self.Function=f end} | |
17 | t.connect = t.Connect | |
18 | return t | |
19 | end | |
20 | ||
21 | --Creating fake input objects with fake variables | |
22 | local m = {Target=nil,Hit=CFrame.new(),KeyUp=fakeEvent(),KeyDown=fakeEvent(),Button1Up=fakeEvent(),Button1Down=fakeEvent()} | |
23 | local UIS = {InputBegan=fakeEvent(),InputEnded=fakeEvent()} | |
24 | local CAS = {Actions={},BindAction=function(self,name,fun,touch,...) | |
25 | CAS.Actions[name] = fun and {Name=name,Function=fun,Keys={...}} or nil | |
26 | end} | |
27 | --Merged 2 functions into one by checking amount of arguments | |
28 | CAS.UnbindAction = CAS.BindAction | |
29 | - | mouse = Player:GetMouse() |
29 | + | |
30 | --This function will trigger the events that have been :Connect()'ed | |
31 | local function te(self,ev,...) | |
32 | local t = m[ev] | |
33 | if t and t._fakeEvent and t.Function then | |
34 | t.Function(...) | |
35 | end | |
36 | end | |
37 | m.TrigEvent = te | |
38 | UIS.TrigEvent = te | |
39 | ||
40 | Event.OnServerEvent:Connect(function(plr,io) | |
41 | if plr~=Player then return end | |
42 | if io.isMouse then | |
43 | m.Target = io.Target | |
44 | m.Hit = io.Hit | |
45 | else | |
46 | local b = io.UserInputState == Enum.UserInputState.Begin | |
47 | if io.UserInputType == Enum.UserInputType.MouseButton1 then | |
48 | return m:TrigEvent(b and "Button1Down" or "Button1Up") | |
49 | end | |
50 | for _,t in pairs(CAS.Actions) do | |
51 | for _,k in pairs(t.Keys) do | |
52 | if k==io.KeyCode then | |
53 | t.Function(t.Name,io.UserInputState,io) | |
54 | end | |
55 | end | |
56 | end | |
57 | m:TrigEvent(b and "KeyDown" or "KeyUp",io.KeyCode.Name:lower()) | |
58 | UIS:TrigEvent(b and "InputBegan" or "InputEnded",io,false) | |
59 | end | |
60 | end) | |
61 | Event.Parent = NLS([==[ | |
62 | local Player = game:GetService("Players").LocalPlayer | |
63 | local Event = script:WaitForChild("UserInput_Event") | |
64 | ||
65 | local UIS = game:GetService("UserInputService") | |
66 | local input = function(io,a) | |
67 | if a then return end | |
68 | --Since InputObject is a client-side instance, we create and pass table instead | |
69 | Event:FireServer({KeyCode=io.KeyCode,UserInputType=io.UserInputType,UserInputState=io.UserInputState}) | |
70 | end | |
71 | UIS.InputBegan:Connect(input) | |
72 | UIS.InputEnded:Connect(input) | |
73 | ||
74 | local Mouse = Player:GetMouse() | |
75 | local h,t | |
76 | --Give the server mouse data 30 times every second, but only if the values changed | |
77 | --If player is not moving their mouse, client won't fire events | |
78 | while wait(1/30) do | |
79 | if h~=Mouse.Hit or t~=Mouse.Target then | |
80 | h,t=Mouse.Hit,Mouse.Target | |
81 | Event:FireServer({isMouse=true,Target=t,Hit=h}) | |
82 | end | |
83 | end]==],Player.Character) | |
84 | Mouse,mouse,UserInputService,ContextActionService = m,m,UIS,CAS | |
85 | end | |
86 | wait() | |
87 | thing = 0 | |
88 | LoudVolume = false | |
89 | Submerged = false | |
90 | Music = true | |
91 | script.Name = "SANIIIIC" | |
92 | Player = owner | |
93 | c = owner | |
94 | Head = c.Head | |
95 | Humanoid = c.Humanoid | |
96 | anim = c.Humanoid.Animator | |
97 | rage = false | |
98 | p = owner | |
99 | Music = false | |
100 | anim = Humanoid.Animator | |
101 | local Effects = {} | |
102 | attack = false | |
103 | local attacking = false | |
104 | vt = Vector3.new | |
105 | bc = BrickColor.new | |
106 | br = BrickColor.random | |
107 | it = Instance.new | |
108 | cf = CFrame.new | |
109 | euler = CFrame.fromEulerAnglesXYZ | |
110 | angles = CFrame.Angles | |
111 | matr = math.random | |
112 | ||
113 | ||
114 | RSC0 = CFrame.new(1, 0.5, 0, 0, 0, 1, 0, 1, 0, -1, 0, 0) | |
115 | RSC1 = CFrame.new(-0.5, 0.5, 0, 0, 0, 1, 0, 1, 0, -1, 0, 0) | |
116 | LSC0 = CFrame.new(-1, 0.5, 0, 0, 0, -1, 0, 1, 0, 1, 0, 0) | |
117 | LSC1 = CFrame.new(0.5, 0.5, 0, 0, 0, -1, 0, 1, 0, 1, 0, 0) | |
118 | RHC0 = CFrame.new(1, -1, 0, 0, 0, 1, 0, 1, 0, -1, 0, 0) | |
119 | RHC1 = CFrame.new(0.5, 1, 0, 0, 0, 1, 0, 1, 0, -1, 0, 0) | |
120 | LHC0 = CFrame.new(-1, -1, 0, 0, 0, -1, 0, 1, 0, 1, 0, 0) | |
121 | LHC1 = CFrame.new(-0.5, 1, 0, 0, 0, -1, 0, 1, 0, 1, 0, 0) | |
122 | NC0 = CFrame.new(0, 1, 0, -1, 0, 0, 0, 0, 1, 0, 1, 0) | |
123 | NC1 = CFrame.new(0, -0.5, 0, -1, 0, 0, 0, 0, 1, 0, 1, 0) | |
124 | RJC0 = CFrame.new(0, 0, 0, -1, 0, 0, 0, 0, 1, 0, 1, 0) | |
125 | RJC1 = CFrame.new(0, 0, 0, -1, 0, 0, 0, 0, 1, 0, 1, 0) | |
126 | RS = c.Torso:FindFirstChild("Right Shoulder") | |
127 | LS = c.Torso:FindFirstChild("Left Shoulder") | |
128 | RH = c.Torso:FindFirstChild("Right Hip") | |
129 | LH = c.Torso:FindFirstChild("Left Hip") | |
130 | RJ = c.HumanoidRootPart:FindFirstChild("RootJoint") | |
131 | N = c.Torso:FindFirstChild("Neck") | |
132 | cf = CFrame.new | |
133 | ang = CFrame.Angles | |
134 | rd = math.rad | |
135 | rd2 = math.random | |
136 | ||
137 | --[[mainShirt = c.Shirt | |
138 | mainPants = c.Pants | |
139 | mainBColors = c["Body Colors"] | |
140 | mainShirt.ShirtTemplate = "rbxassetid://769869277" | |
141 | mainPants.PantsTemplate = "rbxassetid://805486769" | |
142 | mainBColors.HeadColor = BrickColor.new("Pastel brown") | |
143 | mainBColors.LeftArmColor = BrickColor.new("Pastel brown") | |
144 | mainBColors.LeftLegColor = BrickColor.new("Pastel brown") | |
145 | mainBColors.RightArmColor = BrickColor.new("Pastel brown") | |
146 | mainBColors.RightLegColor = BrickColor.new("Pastel brown") | |
147 | mainBColors.TorsoColor = BrickColor.new("Pastel brown")]] | |
148 | function swait(num) | |
149 | if num==0 or num==nil then | |
150 | game:service'RunService'.Heartbeat:wait(0) | |
151 | else | |
152 | for i=0,num do | |
153 | game:service'RunService'.Heartbeat:wait(0) | |
154 | end | |
155 | end | |
156 | end | |
157 | ||
158 | function lerpz(joint, prop, cfrmz, alp) | |
159 | joint[prop] = joint[prop]:lerp(cfrmz, alp) | |
160 | end | |
161 | function resetlerp() | |
162 | RJ.C0 = RJC0 | |
163 | RJ.C1 = RJC1 | |
164 | N.C0 = NC0 | |
165 | N.C1 = NC1 | |
166 | RS.C0 = RSC0 | |
167 | RS.C1 = RSC1 | |
168 | LS.C0 = LSC0 | |
169 | LS.C1 = LSC1 | |
170 | RH.C0 = RHC0 | |
171 | RH.C1 = RHC1 | |
172 | LH.C0 = LHC0 | |
173 | LH.C1 = LHC1 | |
174 | end | |
175 | ||
176 | local S2 = Instance.new("Sound",c.HumanoidRootPart)S2.SoundId = "rbxassetid://1246460167" S2.Volume = 0 S2.PlaybackSpeed = 0 S2.Looped = true S2:Play() | |
177 | c.Head.face:remove() | |
178 | ||
179 | local ColorArray = {ColorSequenceKeypoint.new(0, Color3.new(0/255,170/255,255/255)),ColorSequenceKeypoint.new(1, Color3.new(0/255,170/255,255/255))} | |
180 | local att1 = Instance.new("Attachment", c["Right Leg"]) | |
181 | att1.Name = "att1" | |
182 | att1.Position = Vector3.new(0.5, 1, 0.5) | |
183 | local att2 = Instance.new("Attachment", c["Right Leg"]) | |
184 | att2.Name = "att2" | |
185 | att2.Position = Vector3.new(-0.5, 1, 0.5) | |
186 | local att3 = Instance.new("Attachment", c["Right Leg"]) | |
187 | att3.Name = "att3" | |
188 | att3.Position = Vector3.new(0.5, -1, 0.5) | |
189 | local att4 = Instance.new("Attachment", c["Right Leg"]) | |
190 | att4.Name = "att4" | |
191 | att4.Position = Vector3.new(-0.5, -1, 0.5) | |
192 | ||
193 | local attt1 = Instance.new("Attachment", c["Left Leg"]) | |
194 | attt1.Name = "att1" | |
195 | attt1.Position = Vector3.new(0.5, 1, 0.5) | |
196 | local attt2 = Instance.new("Attachment", c["Left Leg"]) | |
197 | attt2.Name = "att2" | |
198 | attt2.Position = Vector3.new(-0.5, 1, 0.5) | |
199 | local attt3 = Instance.new("Attachment", c["Left Leg"]) | |
200 | attt3.Name = "att3" | |
201 | attt3.Position = Vector3.new(0.5, -1, 0.5) | |
202 | local attt4 = Instance.new("Attachment", c["Left Leg"]) | |
203 | attt4.Name = "att4" | |
204 | attt4.Position = Vector3.new(-0.5, -1, 0.5) | |
205 | ||
206 | local trailtop1 = Instance.new("Trail", c["Right Leg"]) | |
207 | trailtop1.Enabled = true | |
208 | trailtop1.Texture = "rbxassetid://16607923" | |
209 | trailtop1.Name = "toptrail" | |
210 | trailtop1.MinLength = 0 | |
211 | trailtop1.Lifetime = 0.1 | |
212 | ||
213 | trailtop1.Color = ColorSequence.new(ColorArray) | |
214 | ||
215 | trailtop1.Attachment0 = att1 | |
216 | trailtop1.Attachment1 = att2 | |
217 | trailtop1.Transparency = NumberSequence.new({ | |
218 | NumberSequenceKeypoint.new(0, 0.5, 0), | |
219 | NumberSequenceKeypoint.new(1, 1, 0) | |
220 | }) | |
221 | ||
222 | local trailbot1 = Instance.new("Trail", c["Right Leg"]) | |
223 | trailbot1.Enabled = true | |
224 | trailbot1.Texture = "rbxassetid://16607923" | |
225 | trailbot1.Name = "bottrail" | |
226 | trailbot1.MinLength = 0 | |
227 | trailbot1.Lifetime = 0.1 | |
228 | ||
229 | trailbot1.Color = ColorSequence.new(ColorArray) | |
230 | ||
231 | trailbot1.Attachment0 = att3 | |
232 | trailbot1.Attachment1 = att4 | |
233 | trailbot1.Transparency = NumberSequence.new({ | |
234 | NumberSequenceKeypoint.new(0, 0.5, 0), | |
235 | NumberSequenceKeypoint.new(1, 1, 0) | |
236 | }) | |
237 | ||
238 | local trailside1 = Instance.new("Trail", c["Right Leg"]) | |
239 | trailside1.Enabled = true | |
240 | trailside1.Texture = "rbxassetid://16607923" | |
241 | trailside1.Name = "sidetrail1" | |
242 | trailside1.MinLength = 0 | |
243 | trailside1.Lifetime = 0.1 | |
244 | ||
245 | trailside1.Color = ColorSequence.new(ColorArray) | |
246 | ||
247 | trailside1.Attachment0 = att1 | |
248 | trailside1.Attachment1 = att3 | |
249 | trailside1.Transparency = NumberSequence.new({ | |
250 | NumberSequenceKeypoint.new(0, 0.5, 0), | |
251 | NumberSequenceKeypoint.new(1, 1, 0) | |
252 | }) | |
253 | ||
254 | local trailside2 = Instance.new("Trail", c["Right Leg"]) | |
255 | trailside2.Enabled = true | |
256 | trailside2.Texture = "rbxassetid://16607923" | |
257 | trailside2.Name = "sidetrail2" | |
258 | trailside2.MinLength = 0 | |
259 | trailside2.Lifetime = 0.1 | |
260 | spawn(function() | |
261 | while true do wait() | |
262 | trailside2.Color = ColorSequence.new(ColorArray) | |
263 | end | |
264 | end) | |
265 | trailside2.Attachment0 = att2 | |
266 | trailside2.Attachment1 = att4 | |
267 | trailside2.Transparency = NumberSequence.new({ | |
268 | NumberSequenceKeypoint.new(0, 0.5, 0), | |
269 | NumberSequenceKeypoint.new(1, 1, 0) | |
270 | }) | |
271 | ||
272 | ||
273 | local trailtop12 = Instance.new("Trail", c["Left Leg"]) | |
274 | trailtop12.Enabled = true | |
275 | trailtop12.Texture = "rbxassetid://16607923" | |
276 | trailtop12.Name = "toptrail" | |
277 | trailtop12.MinLength = 0 | |
278 | trailtop12.Lifetime = 0.1 | |
279 | spawn(function() | |
280 | while true do wait() | |
281 | trailtop12.Color = ColorSequence.new(ColorArray) | |
282 | end | |
283 | end) | |
284 | trailtop12.Attachment0 = attt1 | |
285 | trailtop12.Attachment1 = attt2 | |
286 | trailtop12.Transparency = NumberSequence.new({ | |
287 | NumberSequenceKeypoint.new(0, 0.5, 0), | |
288 | NumberSequenceKeypoint.new(1, 1, 0) | |
289 | }) | |
290 | ||
291 | local trailbot2 = Instance.new("Trail", c["Left Leg"]) | |
292 | trailbot2.Enabled = true | |
293 | trailbot2.Texture = "rbxassetid://16607923" | |
294 | trailbot2.Name = "bottrail" | |
295 | trailbot2.MinLength = 0 | |
296 | trailbot2.Lifetime = 0.1 | |
297 | ||
298 | trailbot2.Color = ColorSequence.new(ColorArray) | |
299 | ||
300 | trailbot2.Attachment0 = attt3 | |
301 | trailbot2.Attachment1 = attt4 | |
302 | trailbot2.Transparency = NumberSequence.new({ | |
303 | NumberSequenceKeypoint.new(0, 0.5, 0), | |
304 | NumberSequenceKeypoint.new(1, 1, 0) | |
305 | }) | |
306 | ||
307 | local trailside12 = Instance.new("Trail", c["Left Leg"]) | |
308 | trailside12.Enabled = true | |
309 | trailside12.Texture = "rbxassetid://16607923" | |
310 | trailside12.Name = "sidetrail1" | |
311 | trailside12.MinLength = 0 | |
312 | trailside12.Lifetime = 0.1 | |
313 | ||
314 | trailside12.Color = ColorSequence.new(ColorArray) | |
315 | ||
316 | trailside12.Attachment0 = attt1 | |
317 | trailside12.Attachment1 = attt3 | |
318 | trailside12.Transparency = NumberSequence.new({ | |
319 | NumberSequenceKeypoint.new(0, 0.5, 0), | |
320 | NumberSequenceKeypoint.new(1, 1, 0) | |
321 | }) | |
322 | ||
323 | local trailside22 = Instance.new("Trail", c["Left Leg"]) | |
324 | trailside22.Enabled = true | |
325 | trailside22.Texture = "rbxassetid://16607923" | |
326 | trailside22.Name = "sidetrail2" | |
327 | trailside22.MinLength = 0 | |
328 | trailside22.Lifetime = 0.1 | |
329 | ||
330 | trailside22.Color = ColorSequence.new(ColorArray) | |
331 | ||
332 | trailside22.Attachment0 = attt2 | |
333 | trailside22.Attachment1 = attt4 | |
334 | trailside22.Transparency = NumberSequence.new({ | |
335 | NumberSequenceKeypoint.new(0, 0.5, 0), | |
336 | NumberSequenceKeypoint.new(1, 1, 0) | |
337 | }) | |
338 | ||
339 | ||
340 | local att1 = Instance.new("Attachment", c["Right Arm"]) | |
341 | att1.Name = "att1" | |
342 | att1.Position = Vector3.new(0.5, 1, 0.5) | |
343 | local att2 = Instance.new("Attachment", c["Right Arm"]) | |
344 | att2.Name = "att2" | |
345 | att2.Position = Vector3.new(-0.5, 1, 0.5) | |
346 | local att3 = Instance.new("Attachment", c["Right Arm"]) | |
347 | att3.Name = "att3" | |
348 | att3.Position = Vector3.new(0.5, -1, 0.5) | |
349 | local att4 = Instance.new("Attachment", c["Right Arm"]) | |
350 | att4.Name = "att4" | |
351 | att4.Position = Vector3.new(-0.5, -1, 0.5) | |
352 | ||
353 | local attt1 = Instance.new("Attachment", c["Left Arm"]) | |
354 | attt1.Name = "att1" | |
355 | attt1.Position = Vector3.new(0.5, 1, 0.5) | |
356 | local attt2 = Instance.new("Attachment", c["Left Arm"]) | |
357 | attt2.Name = "att2" | |
358 | attt2.Position = Vector3.new(-0.5, 1, 0.5) | |
359 | local attt3 = Instance.new("Attachment", c["Left Arm"]) | |
360 | attt3.Name = "att3" | |
361 | attt3.Position = Vector3.new(0.5, -1, 0.5) | |
362 | local attt4 = Instance.new("Attachment", c["Left Arm"]) | |
363 | attt4.Name = "att4" | |
364 | attt4.Position = Vector3.new(-0.5, -1, 0.5) | |
365 | ||
366 | local trailtop1 = Instance.new("Trail", c["Right Arm"]) | |
367 | trailtop1.Enabled = true | |
368 | trailtop1.Texture = "rbxassetid://16607923" | |
369 | trailtop1.Name = "toptrail" | |
370 | trailtop1.MinLength = 0 | |
371 | trailtop1.Lifetime = 0.1 | |
372 | ||
373 | trailtop1.Color = ColorSequence.new(ColorArray) | |
374 | ||
375 | trailtop1.Attachment0 = att1 | |
376 | trailtop1.Attachment1 = att2 | |
377 | trailtop1.Transparency = NumberSequence.new({ | |
378 | NumberSequenceKeypoint.new(0, 0.5, 0), | |
379 | NumberSequenceKeypoint.new(1, 1, 0) | |
380 | }) | |
381 | ||
382 | local trailbot1 = Instance.new("Trail", c["Right Arm"]) | |
383 | trailbot1.Enabled = true | |
384 | trailbot1.Texture = "rbxassetid://16607923" | |
385 | trailbot1.Name = "bottrail" | |
386 | trailbot1.MinLength = 0 | |
387 | trailbot1.Lifetime = 0.1 | |
388 | spawn(function() | |
389 | while true do wait() | |
390 | trailbot1.Color = ColorSequence.new(ColorArray) | |
391 | end | |
392 | end) | |
393 | trailbot1.Attachment0 = att3 | |
394 | trailbot1.Attachment1 = att4 | |
395 | trailbot1.Transparency = NumberSequence.new({ | |
396 | NumberSequenceKeypoint.new(0, 0.5, 0), | |
397 | NumberSequenceKeypoint.new(1, 1, 0) | |
398 | }) | |
399 | ||
400 | local trailside1 = Instance.new("Trail", c["Right Arm"]) | |
401 | trailside1.Enabled = true | |
402 | trailside1.Texture = "rbxassetid://16607923" | |
403 | trailside1.Name = "sidetrail1" | |
404 | trailside1.MinLength = 0 | |
405 | trailside1.Lifetime = 0.1 | |
406 | ||
407 | trailside1.Color = ColorSequence.new(ColorArray) | |
408 | ||
409 | trailside1.Attachment0 = att1 | |
410 | trailside1.Attachment1 = att3 | |
411 | trailside1.Transparency = NumberSequence.new({ | |
412 | NumberSequenceKeypoint.new(0, 0.5, 0), | |
413 | NumberSequenceKeypoint.new(1, 1, 0) | |
414 | }) | |
415 | ||
416 | local trailside2 = Instance.new("Trail", c["Right Arm"]) | |
417 | trailside2.Enabled = true | |
418 | trailside2.Texture = "rbxassetid://16607923" | |
419 | trailside2.Name = "sidetrail2" | |
420 | trailside2.MinLength = 0 | |
421 | trailside2.Lifetime = 0.1 | |
422 | ||
423 | trailside2.Color = ColorSequence.new(ColorArray) | |
424 | ||
425 | trailside2.Attachment0 = att2 | |
426 | trailside2.Attachment1 = att4 | |
427 | trailside2.Transparency = NumberSequence.new({ | |
428 | NumberSequenceKeypoint.new(0, 0.5, 0), | |
429 | NumberSequenceKeypoint.new(1, 1, 0) | |
430 | }) | |
431 | ||
432 | ||
433 | local trailtop12 = Instance.new("Trail", c["Left Arm"]) | |
434 | trailtop12.Enabled = true | |
435 | trailtop12.Texture = "rbxassetid://16607923" | |
436 | trailtop12.Name = "toptrail" | |
437 | trailtop12.MinLength = 0 | |
438 | trailtop12.Lifetime = 0.1 | |
439 | ||
440 | trailtop12.Color = ColorSequence.new(ColorArray) | |
441 | ||
442 | trailtop12.Attachment0 = attt1 | |
443 | trailtop12.Attachment1 = attt2 | |
444 | trailtop12.Transparency = NumberSequence.new({ | |
445 | NumberSequenceKeypoint.new(0, 0.5, 0), | |
446 | NumberSequenceKeypoint.new(1, 1, 0) | |
447 | }) | |
448 | ||
449 | local trailbot2 = Instance.new("Trail", c["Left Arm"]) | |
450 | trailbot2.Enabled = true | |
451 | trailbot2.Texture = "rbxassetid://16607923" | |
452 | trailbot2.Name = "bottrail" | |
453 | trailbot2.MinLength = 0 | |
454 | trailbot2.Lifetime = 0.1 | |
455 | ||
456 | trailbot2.Color = ColorSequence.new(ColorArray) | |
457 | ||
458 | trailbot2.Attachment0 = attt3 | |
459 | trailbot2.Attachment1 = attt4 | |
460 | trailbot2.Transparency = NumberSequence.new({ | |
461 | NumberSequenceKeypoint.new(0, 0.5, 0), | |
462 | NumberSequenceKeypoint.new(1, 1, 0) | |
463 | }) | |
464 | ||
465 | local trailside12 = Instance.new("Trail", c["Left Arm"]) | |
466 | trailside12.Enabled = true | |
467 | trailside12.Texture = "rbxassetid://16607923" | |
468 | trailside12.Name = "sidetrail1" | |
469 | trailside12.MinLength = 0 | |
470 | trailside12.Lifetime = 0.1 | |
471 | ||
472 | trailside12.Color = ColorSequence.new(ColorArray) | |
473 | ||
474 | trailside12.Attachment0 = attt1 | |
475 | trailside12.Attachment1 = attt3 | |
476 | trailside12.Transparency = NumberSequence.new({ | |
477 | NumberSequenceKeypoint.new(0, 0.5, 0), | |
478 | NumberSequenceKeypoint.new(1, 1, 0) | |
479 | }) | |
480 | ||
481 | local trailside22 = Instance.new("Trail", c["Left Arm"]) | |
482 | trailside22.Enabled = true | |
483 | trailside22.Texture = "rbxassetid://16607923" | |
484 | trailside22.Name = "sidetrail2" | |
485 | trailside22.MinLength = 0 | |
486 | trailside22.Lifetime = 0.1 | |
487 | ||
488 | trailside22.Color = ColorSequence.new(ColorArray) | |
489 | ||
490 | trailside22.Attachment0 = attt2 | |
491 | trailside22.Attachment1 = attt4 | |
492 | trailside22.Transparency = NumberSequence.new({ | |
493 | NumberSequenceKeypoint.new(0, 0.5, 0), | |
494 | NumberSequenceKeypoint.new(1, 1, 0) | |
495 | }) | |
496 | ||
497 | local att1 = Instance.new("Attachment", c["Torso"]) | |
498 | att1.Name = "att1" | |
499 | att1.Position = Vector3.new(1, 1, 0.5) | |
500 | local att2 = Instance.new("Attachment", c["Torso"]) | |
501 | att2.Name = "att2" | |
502 | att2.Position = Vector3.new(-1, 1, 0.5) | |
503 | local att3 = Instance.new("Attachment", c["Torso"]) | |
504 | att3.Name = "att3" | |
505 | att3.Position = Vector3.new(1, -1, 0.5) | |
506 | local att4 = Instance.new("Attachment", c["Torso"]) | |
507 | att4.Name = "att4" | |
508 | att4.Position = Vector3.new(-1, -1, 0.5) | |
509 | ||
510 | local attt1 = Instance.new("Attachment", c["Head"]) | |
511 | attt1.Name = "att1" | |
512 | attt1.Position = Vector3.new(.55, .55, 0.025) | |
513 | local attt2 = Instance.new("Attachment", c["Head"]) | |
514 | attt2.Name = "att2" | |
515 | attt2.Position = Vector3.new(-.55, .55, 0.025) | |
516 | local attt3 = Instance.new("Attachment", c["Head"]) | |
517 | attt3.Name = "att3" | |
518 | attt3.Position = Vector3.new(.55, -.5, 0.025) | |
519 | local attt4 = Instance.new("Attachment", c["Head"]) | |
520 | attt4.Name = "att4" | |
521 | attt4.Position = Vector3.new(-.55, -.5, 0.025) | |
522 | local trailtop1 = Instance.new("Trail", c["Torso"]) | |
523 | trailtop1.Enabled = true | |
524 | trailtop1.Texture = "rbxassetid://16607923" | |
525 | trailtop1.Name = "toptrail" | |
526 | trailtop1.MinLength = 0 | |
527 | trailtop1.Lifetime = 0.1 | |
528 | ||
529 | trailtop1.Color = ColorSequence.new(ColorArray) | |
530 | ||
531 | trailtop1.Attachment0 = att1 | |
532 | trailtop1.Attachment1 = att2 | |
533 | trailtop1.Transparency = NumberSequence.new({ | |
534 | NumberSequenceKeypoint.new(0, 0.5, 0), | |
535 | NumberSequenceKeypoint.new(1, 1, 0) | |
536 | }) | |
537 | local trailbot1 = Instance.new("Trail", c["Torso"]) | |
538 | trailbot1.Enabled = true | |
539 | trailbot1.Texture = "rbxassetid://16607923" | |
540 | trailbot1.Name = "bottrail" | |
541 | trailbot1.MinLength = 0 | |
542 | trailbot1.Lifetime = 0.1 | |
543 | ||
544 | trailbot1.Color = ColorSequence.new(ColorArray) | |
545 | ||
546 | trailbot1.Attachment0 = att3 | |
547 | trailbot1.Attachment1 = att4 | |
548 | trailbot1.Transparency = NumberSequence.new({ | |
549 | NumberSequenceKeypoint.new(0, 0.5, 0), | |
550 | NumberSequenceKeypoint.new(1, 1, 0) | |
551 | }) | |
552 | local trailside1 = Instance.new("Trail", c["Torso"]) | |
553 | trailside1.Enabled = true | |
554 | trailside1.Texture = "rbxassetid://16607923" | |
555 | trailside1.Name = "sidetrail1" | |
556 | trailside1.MinLength = 0 | |
557 | trailside1.Lifetime = 0.1 | |
558 | ||
559 | trailside1.Color = ColorSequence.new(ColorArray) | |
560 | ||
561 | trailside1.Attachment0 = att1 | |
562 | trailside1.Attachment1 = att3 | |
563 | trailside1.Transparency = NumberSequence.new({ | |
564 | NumberSequenceKeypoint.new(0, 0.5, 0), | |
565 | NumberSequenceKeypoint.new(1, 1, 0) | |
566 | }) | |
567 | local trailside2 = Instance.new("Trail", c["Torso"]) | |
568 | trailside2.Enabled = true | |
569 | trailside2.Texture = "rbxassetid://16607923" | |
570 | trailside2.Name = "sidetrail2" | |
571 | trailside2.MinLength = 0 | |
572 | trailside2.Lifetime = 0.1 | |
573 | ||
574 | trailside2.Color = ColorSequence.new(ColorArray) | |
575 | ||
576 | trailside2.Attachment0 = att2 | |
577 | trailside2.Attachment1 = att4 | |
578 | trailside2.Transparency = NumberSequence.new({ | |
579 | NumberSequenceKeypoint.new(0, 0.5, 0), | |
580 | NumberSequenceKeypoint.new(1, 1, 0) | |
581 | }) | |
582 | local trailtop12 = Instance.new("Trail", c["Head"]) | |
583 | trailtop12.Enabled = true | |
584 | trailtop12.Texture = "rbxassetid://16607923" | |
585 | trailtop12.Name = "toptrail" | |
586 | trailtop12.MinLength = 0 | |
587 | trailtop12.Lifetime = 0.1 | |
588 | ||
589 | trailtop12.Color = ColorSequence.new(ColorArray) | |
590 | ||
591 | trailtop12.Attachment0 = attt1 | |
592 | trailtop12.Attachment1 = attt2 | |
593 | trailtop12.Transparency = NumberSequence.new({ | |
594 | NumberSequenceKeypoint.new(0, 0.5, 0), | |
595 | NumberSequenceKeypoint.new(1, 1, 0) | |
596 | }) | |
597 | local trailbot2 = Instance.new("Trail", c["Head"]) | |
598 | trailbot2.Enabled = true | |
599 | trailbot2.Texture = "rbxassetid://16607923" | |
600 | trailbot2.Name = "bottrail" | |
601 | trailbot2.MinLength = 0 | |
602 | trailbot2.Lifetime = 0.1 | |
603 | ||
604 | trailbot2.Color = ColorSequence.new(ColorArray) | |
605 | ||
606 | trailbot2.Attachment0 = attt3 | |
607 | trailbot2.Attachment1 = attt4 | |
608 | trailbot2.Transparency = NumberSequence.new({ | |
609 | NumberSequenceKeypoint.new(0, 0.5, 0), | |
610 | NumberSequenceKeypoint.new(1, 1, 0) | |
611 | }) | |
612 | local trailside12 = Instance.new("Trail", c["Head"]) | |
613 | trailside12.Enabled = true | |
614 | trailside12.Texture = "rbxassetid://16607923" | |
615 | trailside12.Name = "sidetrail1" | |
616 | trailside12.MinLength = 0 | |
617 | trailside12.Lifetime = 0.1 | |
618 | ||
619 | trailside12.Color = ColorSequence.new(ColorArray) | |
620 | ||
621 | trailside12.Attachment0 = attt1 | |
622 | trailside12.Attachment1 = attt3 | |
623 | trailside12.Transparency = NumberSequence.new({ | |
624 | NumberSequenceKeypoint.new(0, 0.5, 0), | |
625 | NumberSequenceKeypoint.new(1, 1, 0) | |
626 | }) | |
627 | local trailside22 = Instance.new("Trail", c["Head"]) | |
628 | trailside22.Enabled = true | |
629 | trailside22.Texture = "rbxassetid://16607923" | |
630 | trailside22.Name = "sidetrail2" | |
631 | trailside22.MinLength = 0 | |
632 | trailside22.Lifetime = 0.1 | |
633 | ||
634 | trailside22.Color = ColorSequence.new(ColorArray) | |
635 | ||
636 | trailside22.Attachment0 = attt2 trailside22.Attachment1 = attt4 | |
637 | trailside22.Transparency = NumberSequence.new({NumberSequenceKeypoint.new(0, 0.5, 0),NumberSequenceKeypoint.new(1, 1, 0)}) | |
638 | ||
639 | Sped = 0 | |
640 | ||
641 | function ragplayer(cactus) | |
642 | local S = Instance.new("Sound",c.HumanoidRootPart)S.SoundId = "rbxassetid://131026421" S.Volume = 2 S:Play() | |
643 | cactus.Humanoid.PlatformStand = true cactus:findFirstChild("Humanoid").Health = 0.01 | |
644 | if cactus["Right Arm"]~=nil and cactus.Torso:FindFirstChild("Right Shoulder") then | |
645 | cactus.Torso:FindFirstChild("Right Shoulder"):Destroy() | |
646 | makegloo(cactus.Torso, RSC0, RSC1, cactus.Torso, cactus["Right Arm"], "Right Shoulder") | |
647 | maketouchy(cactus["Right Arm"], cactus["Right Arm"], CFrame.new(0, 0.5, 0)) | |
648 | end | |
649 | if cactus["Left Arm"]~=nil and cactus.Torso:FindFirstChild("Left Shoulder") then | |
650 | cactus.Torso:FindFirstChild("Left Shoulder"):Destroy() | |
651 | makegloo(cactus.Torso, LSC0, LSC1, cactus.Torso, cactus["Left Arm"], "Left Shoulder") | |
652 | maketouchy(cactus["Left Arm"], cactus["Left Arm"], CFrame.new(0, 0.5, 0)) | |
653 | end | |
654 | if cactus["Right Leg"]~=nil and cactus.Torso:FindFirstChild("Right Hip") then | |
655 | cactus.Torso:FindFirstChild("Right Hip"):Destroy() | |
656 | makegloo(cactus.Torso, RHC0, RHC1, cactus.Torso, cactus["Right Leg"], "Right Hip") | |
657 | maketouchy(cactus["Right Leg"], cactus["Right Leg"], CFrame.new(0, 0.5, 0)) | |
658 | end | |
659 | if cactus["Left Leg"]~=nil and cactus.Torso:FindFirstChild("Left Hip") then | |
660 | cactus.Torso:FindFirstChild("Left Hip"):Destroy() | |
661 | makegloo(cactus.Torso, LHC0, LHC1, cactus.Torso, cactus["Left Leg"], "Left Hip") | |
662 | maketouchy(cactus["Left Leg"], cactus["Left Leg"], CFrame.new(0, 0.5, 0)) | |
663 | end | |
664 | cactus.Parent = game.Workspace game.Debris:AddItem(cactus,15) | |
665 | end | |
666 | function makegloo(paren, co, ci, parto, parti, nam) local gloo = Instance.new("Glue") gloo.Name = nam gloo.C0 = co gloo.C1 = ci gloo.Part0 = parto gloo.Part1 = parti gloo.Parent = paren end | |
667 | ||
668 | function maketouchy(parent, limb, cframe) local pr = Instance.new("Part") pr.Name = "touchy" pr.Size = Vector3.new(1, 1, 1) pr.Transparency = 1 pr.CustomPhysicalProperties = PhysicalProperties.new(0.55, 0.3, 0.5) pr.CanCollide = true pr.Anchored = false pr.Parent = parent local w = Instance.new("Weld") w.Part0 = pr w.Part1 = limb w.C0 = cframe w.Parent = pr end | |
669 | ||
670 | local hitz = false | |
671 | c.HumanoidRootPart.Touched:connect(function(Hit) | |
672 | if thing >= 100 then | |
673 | if hitz == false then hitz = true | |
674 | ragplayer(c) local S = Instance.new("Sound",c.HumanoidRootPart)S.SoundId = "rbxassetid://386946017" S.Volume = 6 S:Play() | |
675 | wait(15) | |
676 | end | |
677 | end | |
678 | end) | |
679 | ||
680 | function Spin() | |
681 | attack = true | |
682 | while attack == true do Sped = Sped + 0.25 | |
683 | lerpz(RJ, "C0", RJC0 * cf(0, 0, 0) * ang(rd(Sped*Sped*5), rd(0), rd(0)), 1) | |
684 | lerpz(N, "C0", NC0 * cf(0, 0, 0) * ang(rd(60), rd(0), rd(0)), 1) | |
685 | lerpz(RS, "C0", RSC0 * cf(0, 0, 0) * ang(rd(15), rd(25), rd(25)), 1) | |
686 | lerpz(RS, "C1", RSC1 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 1) | |
687 | lerpz(LS, "C0", LSC0 * cf(0, 0, 0) * ang(rd(15), rd(-25), rd(-25)), 1) | |
688 | lerpz(LS, "C1", LSC1 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 1) | |
689 | lerpz(RH, "C0", RHC0 * cf(0.5, 1.5, 0) * ang(rd(0), rd(0), rd(0)), 1) | |
690 | lerpz(RH, "C1", RHC1 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 1) | |
691 | lerpz(LH, "C0", LHC0 * cf(-0.5, 1.5, 0) * ang(rd(0), rd(0), rd(0)), 1) | |
692 | lerpz(LH, "C1", LHC1 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 1) | |
693 | swait() | |
694 | end | |
695 | end | |
696 | ||
697 | SanicScreams = {585370931,202427593} | |
698 | ||
699 | mouse.KeyDown:connect(function(key) | |
700 | if attack == true then return end | |
701 | if key == "q" then | |
702 | Spin() | |
703 | end | |
704 | if key == "e" then | |
705 | local S = Instance.new("Sound",c.HumanoidRootPart)S.SoundId = "rbxassetid://537371462" S.Volume = 10 S:Play() | |
706 | wait(1.25) | |
707 | local Sanic = SanicScreams[math.random(1,#SanicScreams)] | |
708 | local S = Instance.new("Sound",c.HumanoidRootPart)S.SoundId = "rbxassetid://"..Sanic S.Volume = 10 S:Play() | |
709 | spawn(function() | |
710 | local Sp = Instance.new("Part",game.Workspace)Sp.BrickColor = BrickColor.new("Cyan")Sp.Material = "Neon" Sp.Size = Vector3.new(1,1,1) Sp.Anchored = true Sp.CanCollide = false | |
711 | local SPM = Instance.new("SpecialMesh",Sp)SPM.MeshType = "Sphere" Sp.CFrame = c.HumanoidRootPart.CFrame | |
712 | for i = 1,25 do | |
713 | SPM.Scale = SPM.Scale + Vector3.new(4,4,4) | |
714 | Sp.Transparency = Sp.Transparency + 1/25 | |
715 | swait() | |
716 | end | |
717 | end) | |
718 | local S = Instance.new("Sound",c.HumanoidRootPart)S.SoundId = "rbxassetid://214444596" S.Volume = 10 S:Play() | |
719 | Sped = 10000000000 | |
720 | end | |
721 | end) | |
722 | ||
723 | mouse.KeyUp:connect(function(key) | |
724 | if key == "q" then | |
725 | attack = false | |
726 | end | |
727 | end) | |
728 | ||
729 | local P = Instance.new("Part",game.Workspace.CurrentCamera)P.CanCollide = true P.Anchored = true P.Size = Vector3.new(15,1,15) | |
730 | P.CFrame = CFrame.new(c.HumanoidRootPart.Position)*CFrame.new(0,-3.5,0)P.Transparency = 0 P.Name = "FlightPart" | |
731 | P.BrickColor = BrickColor.new("Dark green") P.TopSurface = "Smooth" P.Material = "Grass" | |
732 | spawn(function() | |
733 | while true do | |
734 | P.CFrame = CFrame.new(c.HumanoidRootPart.Position.X,-0.6,c.HumanoidRootPart.Position.Z) | |
735 | swait() | |
736 | end | |
737 | end) | |
738 | ||
739 | anim.Parent = nil | |
740 | sine = 0 | |
741 | ||
742 | game:GetService("RunService").RenderStepped:connect(function() | |
743 | if attack == false then | |
744 | thing = (c.HumanoidRootPart.Velocity * Vector3.new(1, 0, 1)).magnitude | |
745 | game.Workspace.CurrentCamera.FieldOfView = 70+thing/100 | |
746 | if c.HumanoidRootPart.Velocity.Y > 1 then sine = sine + 1 | |
747 | lerpz(RJ, "C0", RJC0 * cf(0, 0, 0) * ang(rd(sine*thing*0.75), rd(0), rd(0)), 1) | |
748 | lerpz(N, "C0", NC0 * cf(0, 0, 0) * ang(rd(60), rd(0), rd(0)), 1) | |
749 | lerpz(RS, "C0", RSC0 * cf(0, 0, 0) * ang(rd(15), rd(25), rd(25)), 1) | |
750 | lerpz(RS, "C1", RSC1 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 1) | |
751 | lerpz(LS, "C0", LSC0 * cf(0, 0, 0) * ang(rd(15), rd(-25), rd(-25)), 1) | |
752 | lerpz(LS, "C1", LSC1 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 1) | |
753 | lerpz(RH, "C0", RHC0 * cf(0.5, 1.5, 0) * ang(rd(0), rd(0), rd(0)), 1) | |
754 | lerpz(RH, "C1", RHC1 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 1) | |
755 | lerpz(LH, "C0", LHC0 * cf(-0.5, 1.5, 0) * ang(rd(0), rd(0), rd(0)), 1) | |
756 | lerpz(LH, "C1", LHC1 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 1) | |
757 | elseif (c.HumanoidRootPart.Velocity * Vector3.new(1, 0, 1)).magnitude > 2 then | |
758 | sine = sine + 1 Sped = Sped + 0.1 | |
759 | if thing <= 200 then | |
760 | if S2.PlaybackSpeed >= 1 then | |
761 | S2.PlaybackSpeed = 1 | |
762 | else | |
763 | S2.PlaybackSpeed = thing/80 | |
764 | end | |
765 | c.Humanoid.WalkSpeed = 16+(thing/1.5)+Sped | |
766 | S2.Volume = thing/20 | |
767 | end | |
768 | if thing <= 200 then | |
769 | c.Humanoid.WalkSpeed = 16+(thing/1.5)+Sped | |
770 | S2.Volume = thing/20 | |
771 | else | |
772 | c.Humanoid.WalkSpeed = 16+(thing/1.5)+Sped | |
773 | end | |
774 | if thing <= 100 then | |
775 | for i,v in pairs(c:children()) do | |
776 | if v.ClassName == "Part" then | |
777 | for i,v2 in pairs(v:children()) do | |
778 | if v2.ClassName == "Trail" then | |
779 | v2.Enabled = false | |
780 | v2.LightEmission = 1 | |
781 | end | |
782 | end | |
783 | end | |
784 | end | |
785 | else | |
786 | for i,v in pairs(c:children()) do | |
787 | if v.ClassName == "Part" then | |
788 | for i,v2 in pairs(v:children()) do | |
789 | if v2.ClassName == "Trail" then | |
790 | v2.Lifetime = 2 | |
791 | v2.Enabled = true | |
792 | end | |
793 | end | |
794 | end | |
795 | end | |
796 | end | |
797 | lerpz(RJ, "C0", RJC0 * cf(0, 0, 0) * ang(rd(thing/7), rd(0), rd(0)), 1) | |
798 | lerpz(N, "C0", NC0 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 1) | |
799 | lerpz(RS, "C0", RSC0 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(-thing/1.5)), 1) | |
800 | lerpz(RS, "C1", RSC1 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 1) | |
801 | lerpz(LS, "C0", LSC0 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(thing/1.5)), 1) | |
802 | lerpz(LS, "C1", LSC1 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 1) | |
803 | lerpz(RH, "C0", RHC0 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(math.cos(sine/2))*thing/1.25), 1) | |
804 | lerpz(RH, "C1", RHC1 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 1) | |
805 | lerpz(LH, "C0", LHC0 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(math.cos(sine/2))*thing/1.25), 1) | |
806 | lerpz(LH, "C1", LHC1 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 1) | |
807 | else c.Humanoid.WalkSpeed = 16 Sped = 0 sine = sine + 1 S2.Volume = 0 S2.PlaybackSpeed = 0 | |
808 | lerpz(RJ, "C0", RJC0 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.5) | |
809 | lerpz(N, "C0", NC0 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.5) | |
810 | lerpz(RS, "C0", RSC0 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(math.cos(sine/24)*4)), 0.5) | |
811 | lerpz(RS, "C1", RSC1 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.5) | |
812 | lerpz(LS, "C0", LSC0 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(math.cos(sine/24)*4)), 0.5) | |
813 | lerpz(LS, "C1", LSC1 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.5) | |
814 | lerpz(RH, "C0", RHC0 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.5) | |
815 | lerpz(RH, "C1", RHC1 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.5) | |
816 | lerpz(LH, "C0", LHC0 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.5) | |
817 | lerpz(LH, "C1", LHC1 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.5) | |
818 | end | |
819 | for i,v in pairs (c:children()) do | |
820 | if v.ClassName == "Accessory" then | |
821 | for i,v2 in pairs (v:children()) do | |
822 | if v2.ClassName == "Part" then | |
823 | v2.Anchored = false | |
824 | end | |
825 | end | |
826 | end | |
827 | for i,v in pairs (c:children()) do | |
828 | if v.ClassName == "Part" then | |
829 | v.Anchored = false | |
830 | end | |
831 | end | |
832 | end | |
833 | end | |
834 | end) |