SHOW:
|
|
- or go back to the newest paste.
1 | --Converted with ttyyuu12345's model to script plugin v4 | |
2 | function sandbox(var,func) | |
3 | local env = getfenv(func) | |
4 | local newenv = setmetatable({},{ | |
5 | __index = function(self,k) | |
6 | if k=="script" then | |
7 | return var | |
8 | else | |
9 | return env[k] | |
10 | end | |
11 | end, | |
12 | }) | |
13 | setfenv(func,newenv) | |
14 | return func | |
15 | end | |
16 | cors = {} | |
17 | mas = Instance.new("Model",game:GetService("Lighting")) | |
18 | Tool0 = Instance.new("Tool") | |
19 | Part1 = Instance.new("Part") | |
20 | Decal2 = Instance.new("Decal") | |
21 | Decal3 = Instance.new("Decal") | |
22 | Decal4 = Instance.new("Decal") | |
23 | Decal5 = Instance.new("Decal") | |
24 | Decal6 = Instance.new("Decal") | |
25 | Decal7 = Instance.new("Decal") | |
26 | SpecialMesh8 = Instance.new("SpecialMesh") | |
27 | Sound9 = Instance.new("Sound") | |
28 | LocalScript10 = Instance.new("LocalScript") | |
29 | LocalScript11 = Instance.new("LocalScript") | |
30 | HopperBin12 = Instance.new("HopperBin") | |
31 | LocalScript13 = Instance.new("LocalScript") | |
32 | BlockMesh14 = Instance.new("BlockMesh") | |
33 | Script15 = Instance.new("Script") | |
34 | Script16 = Instance.new("Script") | |
35 | HopperBin17 = Instance.new("HopperBin") | |
36 | LocalScript18 = Instance.new("LocalScript") | |
37 | HopperBin19 = Instance.new("HopperBin") | |
38 | LocalScript20 = Instance.new("LocalScript") | |
39 | BlockMesh21 = Instance.new("BlockMesh") | |
40 | Script22 = Instance.new("Script") | |
41 | Script23 = Instance.new("Script") | |
42 | Script24 = Instance.new("Script") | |
43 | StringValue25 = Instance.new("StringValue") | |
44 | Part26 = Instance.new("Part") | |
45 | SpecialMesh27 = Instance.new("SpecialMesh") | |
46 | Part28 = Instance.new("Part") | |
47 | SpecialMesh29 = Instance.new("SpecialMesh") | |
48 | Part30 = Instance.new("Part") | |
49 | SpecialMesh31 = Instance.new("SpecialMesh") | |
50 | Tool0.Name = "(Click to eat) Gomu Gomu no mi" | |
51 | Tool0.Parent = mas | |
52 | Tool0.Grip = CFrame.new(0, 0, 0, 0, 0, -1, 0, 1, 0, 1, 0, 0) | |
53 | Tool0.GripForward = Vector3.new(1, -0, -0) | |
54 | Tool0.GripRight = Vector3.new(0, 0, 1) | |
55 | Part1.Name = "Handle" | |
56 | Part1.Parent = Tool0 | |
57 | Part1.CFrame = CFrame.new(48.749485, 0.503547013, 19.1430969, -0.999999523, -0.000978620723, 1.05401614e-05, -0.000978537253, 0.999980748, 0.00612961594, -1.66846348e-05, 0.0061296029, -0.999981225) | |
58 | Part1.Orientation = Vector3.new(-0.349999994, 180, -0.0599999987) | |
59 | Part1.Position = Vector3.new(48.749485, 0.503547013, 19.1430969) | |
60 | Part1.Rotation = Vector3.new(-179.649994, 0, 179.940002) | |
61 | Part1.Color = Color3.new(0.972549, 0.85098, 0.427451) | |
62 | Part1.Size = Vector3.new(1, 1, 1) | |
63 | Part1.BottomSurface = Enum.SurfaceType.Smooth | |
64 | Part1.BrickColor = BrickColor.new("Daisy orange") | |
65 | Part1.Material = Enum.Material.SmoothPlastic | |
66 | Part1.TopSurface = Enum.SurfaceType.Smooth | |
67 | Part1.brickColor = BrickColor.new("Daisy orange") | |
68 | Part1.FormFactor = Enum.FormFactor.Symmetric | |
69 | Part1.formFactor = Enum.FormFactor.Symmetric | |
70 | Decal2.Parent = Part1 | |
71 | Decal2.Texture = "rbxassetid://114369508" | |
72 | Decal2.Transparency = 0.5 | |
73 | Decal3.Parent = Part1 | |
74 | Decal3.Texture = "rbxassetid://114369508" | |
75 | Decal3.Transparency = 0.5 | |
76 | Decal3.Face = Enum.NormalId.Left | |
77 | Decal4.Parent = Part1 | |
78 | Decal4.Texture = "rbxassetid://114369508" | |
79 | Decal4.Transparency = 0.5 | |
80 | Decal4.Face = Enum.NormalId.Back | |
81 | Decal5.Parent = Part1 | |
82 | Decal5.Texture = "rbxassetid://114369508" | |
83 | Decal5.Transparency = 0.5 | |
84 | Decal5.Face = Enum.NormalId.Right | |
85 | Decal6.Parent = Part1 | |
86 | Decal6.Texture = "rbxassetid://114369508" | |
87 | Decal6.Transparency = 0.5 | |
88 | Decal6.Face = Enum.NormalId.Top | |
89 | Decal7.Parent = Part1 | |
90 | Decal7.Texture = "rbxassetid://114369508" | |
91 | Decal7.Transparency = 0.5 | |
92 | Decal7.Face = Enum.NormalId.Bottom | |
93 | SpecialMesh8.Parent = Part1 | |
94 | SpecialMesh8.Scale = Vector3.new(1.29999995, 1.29999995, 1.29999995) | |
95 | SpecialMesh8.MeshType = Enum.MeshType.Sphere | |
96 | Sound9.Name = "Eat" | |
97 | Sound9.Parent = Part1 | |
98 | Sound9.Looped = true | |
99 | Sound9.Pitch = 1.1000000238419 | |
100 | Sound9.PlaybackSpeed = 1.1000000238419 | |
101 | Sound9.SoundId = "rbxassetid://161190414" | |
102 | LocalScript10.Name = "InstaWeld" | |
103 | LocalScript10.Parent = Tool0 | |
104 | table.insert(cors,sandbox(LocalScript10,function() | |
105 | local currentwelds = {} | |
106 | ||
107 | function Weld(x,y) | |
108 | local W = Instance.new("Weld") | |
109 | W.Part0 = x | |
110 | W.Part1 = y | |
111 | local CJ = CFrame.new(x.Position) | |
112 | local C0 = x.CFrame:inverse()*CJ | |
113 | local C1 = y.CFrame:inverse()*CJ | |
114 | W.C0 = C0 | |
115 | W.C1 = C1 | |
116 | W.Parent = x | |
117 | currentwelds[#currentwelds+1] = W | |
118 | end | |
119 | ||
120 | function Get(A) | |
121 | if A:IsA("BasePart") then | |
122 | Weld(script.Parent.Handle, A) | |
123 | A.Anchored = false | |
124 | else | |
125 | local C = A:GetChildren() | |
126 | for i=1, #C do | |
127 | Get(C[i]) | |
128 | end | |
129 | end | |
130 | end | |
131 | ||
132 | function Finale() | |
133 | currentwelds = {} | |
134 | Get(script.Parent) | |
135 | coroutine.resume(coroutine.create(function() | |
136 | wait(0.1) | |
137 | local toolparts = script.Parent:GetChildren() | |
138 | for h = 1, #toolparts do | |
139 | local c = toolparts[h]:GetChildren() | |
140 | for j = 1, #c do | |
141 | if c[j]:IsA("Weld") then | |
142 | local stop = false | |
143 | for k = 1, #currentwelds do | |
144 | if c[j] == currentwelds[k] then | |
145 | stop = true | |
146 | end | |
147 | end | |
148 | if not stop then | |
149 | c[j]:Destroy() | |
150 | end | |
151 | end | |
152 | end | |
153 | end | |
154 | end)) | |
155 | end | |
156 | ||
157 | script.Parent.Equipped:connect(Finale) | |
158 | script.Parent.Unequipped:connect(Finale) | |
159 | Finale() | |
160 | end)) | |
161 | LocalScript11.Name = "EatScript" | |
162 | LocalScript11.Parent = Tool0 | |
163 | table.insert(cors,sandbox(LocalScript11,function() | |
164 | wait() | |
165 | ||
166 | local tool = script.Parent | |
167 | local player = owner | |
168 | ||
169 | defaultholdingpos = tool.GripPos | |
170 | eaten = false | |
171 | equipped = false | |
172 | cancelled = false | |
173 | tool.Equipped:connect(function() | |
174 | equipped = true | |
175 | script.Parent.Activated:connect(function() | |
176 | if not eaten then | |
177 | cancelled = false | |
178 | tool.GripPos = Vector3.new(0.8, -0.5, 1.5) | |
179 | tool.Handle.Eat:Play() | |
180 | wait(1.4) | |
181 | tool.Handle.Eat:Stop() | |
182 | if equipped and not cancelled then | |
183 | local currentsavedgear = player:FindFirstChild("StarterGear"):GetChildren() | |
184 | local hasdf = false | |
185 | if #currentsavedgear > 0 then | |
186 | for i = 1, #currentsavedgear do | |
187 | if currentsavedgear[i]:FindFirstChild("DevilFruitAbility") then | |
188 | currentsavedgear[i]:Destroy() | |
189 | hasdf = true | |
190 | end | |
191 | end | |
192 | end | |
193 | if not hasdf then | |
194 | local dftools = script:GetChildren() | |
195 | for i = 1, #dftools do | |
196 | local df_tag = Instance.new("StringValue") | |
197 | df_tag.Name = "DevilFruitAbility" | |
198 | df_tag.Value = tool.DevilFruitType.Value | |
199 | df_tag.Parent = dftools[i] | |
200 | dftools[i]:clone().Parent = player:FindFirstChild("Backpack") | |
201 | dftools[i]:clone().Parent = player:FindFirstChild("StarterGear") | |
202 | end | |
203 | tool:Destroy() | |
204 | elseif hasdf then | |
205 | if player.Character then | |
206 | if player.Character:FindFirstChild("Humanoid") then | |
207 | player.Character:BreakJoints() | |
208 | player.Character:FindFirstChild("Humanoid").Health = 0 | |
209 | end | |
210 | end | |
211 | tool:Destroy() | |
212 | end | |
213 | end | |
214 | end | |
215 | end) | |
216 | end) | |
217 | ||
218 | tool.Unequipped:connect(function() | |
219 | tool.Handle.Eat:Stop() | |
220 | cancelled = true | |
221 | equipped = false | |
222 | if not eaten then | |
223 | tool.GripPos = defaultholdingpos | |
224 | end | |
225 | end) | |
226 | end)) | |
227 | HopperBin12.Name = "Pistol" | |
228 | HopperBin12.Parent = LocalScript11 | |
229 | LocalScript13.Name = "Normal" | |
230 | LocalScript13.Parent = HopperBin12 | |
231 | table.insert(cors,sandbox(LocalScript13,function() | |
232 | COOLDOWN = 1 | |
233 | ||
234 | MAX_VELOCITY = 475 | |
235 | MIN_VELOCITY = 400 | |
236 | ||
237 | AUTOFIRE = false | |
238 | ||
239 | SPREAD = 2 | |
240 | ORIGIN_SPREAD = 0 | |
241 | LOCK_FORWARD = false | |
242 | ||
243 | ANTI_GRAVITY = 1 | |
244 | ||
245 | FIRE_SOUND = "http://www.roblox.com/asset/?id=93011731" | |
246 | ||
247 | DESPAWN_TIME = 1 | |
248 | ||
249 | ||
250 | wait(1) | |
251 | ------------------------------ | |
252 | missile = Instance.new("Part") | |
253 | missile.Name = "Gomu" | |
254 | missile.Transparency = 0 | |
255 | missile.Reflectance = 0 | |
256 | missile.CanCollide = false | |
257 | missile.Shape = "Block" | |
258 | missile.FormFactor = "Custom" | |
259 | missile.Size = Vector3.new(2, 2, 2) | |
260 | missile.Elasticity = 0 | |
261 | missile.TopSurface = 0 | |
262 | missile.BottomSurface = 0 | |
263 | ||
264 | while script:FindFirstChild("Mesh") == nil do wait() end | |
265 | script.Mesh:clone().Parent = missile | |
266 | ||
267 | force = Instance.new("BodyForce") | |
268 | force.force = Vector3.new(0,missile:GetMass() * 196.2 * ANTI_GRAVITY) | |
269 | force.Parent = missile | |
270 | ||
271 | scriptName = "ArrowScript" | |
272 | while script:FindFirstChild(scriptName) == nil do wait() end | |
273 | script:FindFirstChild(scriptName):clone().Parent = missile | |
274 | ||
275 | ------------------------------ | |
276 | ||
277 | wait() | |
278 | Tool = script.Parent | |
279 | player = owner | |
280 | while player.Character == nil do wait() end | |
281 | char = player.Character | |
282 | ||
283 | function hidePart(part) | |
284 | if part:FindFirstChild("AttackHide") == nil then | |
285 | local hide = Instance.new("SpecialMesh") | |
286 | hide.Name = "AttackHide" | |
287 | hide.MeshType = "FileMesh" | |
288 | hide.Scale = Vector3.new(0, 0, 0) | |
289 | hide.Parent = part | |
290 | game.Debris:AddItem(hide, DESPAWN_TIME/2) | |
291 | end | |
292 | end | |
293 | ||
294 | shooting = false | |
295 | function fire(v) | |
296 | if choosehand == 1 then | |
297 | choosehand = 2 | |
298 | arm = char:FindFirstChild("Right Arm") | |
299 | else | |
300 | choosehand = 1 | |
301 | arm = char:FindFirstChild("Left Arm") | |
302 | end | |
303 | if arm == nil then return end | |
304 | hidePart(arm) | |
305 | ||
306 | if not LOCK_FORWARD then | |
307 | v_spreadx = math.random(-SPREAD, SPREAD) | |
308 | v_spready = math.random(-SPREAD, SPREAD) | |
309 | v_spreadz = math.random(-SPREAD, SPREAD) | |
310 | v = v + Vector3.new(v_spreadx, v_spready, v_spreadz) | |
311 | v = (v - arm.Position).unit | |
312 | else | |
313 | v = char:FindFirstChild("Torso").CFrame.lookVector | |
314 | end | |
315 | ||
316 | o_spreadx = math.random(-ORIGIN_SPREAD, ORIGIN_SPREAD) | |
317 | o_spready = math.random(-ORIGIN_SPREAD, ORIGIN_SPREAD) | |
318 | o_spreadz = math.random(-ORIGIN_SPREAD, ORIGIN_SPREAD) | |
319 | local spawnPos = arm.Position + Vector3.new(o_spreadx, o_spready, o_spreadz) | |
320 | spawnPos = spawnPos + (v * 1) | |
321 | ||
322 | shot = missile:clone() | |
323 | shot.BrickColor = arm.BrickColor | |
324 | shot.Velocity = v * math.random(MIN_VELOCITY, MAX_VELOCITY) | |
325 | local launch = spawnPos + 2 * v | |
326 | shot.CFrame = CFrame.new(launch, launch + v) | |
327 | ||
328 | local creator_tag = Instance.new("ObjectValue") | |
329 | creator_tag.Value = player | |
330 | creator_tag.Name = "creator" | |
331 | creator_tag.Parent = shot | |
332 | ||
333 | local firesound = Instance.new("Sound") | |
334 | firesound.Name = "FiredSound" | |
335 | firesound.SoundId = FIRE_SOUND | |
336 | firesound.Volume = 1 | |
337 | firesound.Pitch = math.random(8, 14)/10 | |
338 | firesound.Parent = shot | |
339 | ||
340 | shot.Parent = game.Workspace | |
341 | game.Debris:AddItem(shot, DESPAWN_TIME) | |
342 | shot:FindFirstChild(scriptName).Disabled = false | |
343 | end | |
344 | ||
345 | ||
346 | enabled = true | |
347 | gatlingmode = false | |
348 | ||
349 | function onButtonUp() | |
350 | shooting = false | |
351 | end | |
352 | ||
353 | function onDeselect() | |
354 | stopped = true | |
355 | end | |
356 | ||
357 | function gatlingOFF() | |
358 | gatlingmode = false -- its not gatling ya know | |
359 | COOLDOWN = 2 | |
360 | MAX_VELOCITY = 250 | |
361 | MIN_VELOCITY = 200 | |
362 | AUTOFIRE = false | |
363 | SPREAD = 3 | |
364 | ORIGIN_SPREAD = 3 | |
365 | DESPAWN_TIME = 0.9 | |
366 | missile.Transparency = 0.4 | |
367 | LOCK_FORWARD = true | |
368 | end | |
369 | ||
370 | function gatlingON() | |
371 | gatlingmode = true -- its one shot | |
372 | COOLDOWN = 2 | |
373 | MAX_VELOCITY = 475 | |
374 | MIN_VELOCITY = 400 | |
375 | AUTOFIRE = false | |
376 | SPREAD = 2 | |
377 | ORIGIN_SPREAD = 0 | |
378 | DESPAWN_TIME = 1 | |
379 | missile.Transparency = 0 | |
380 | LOCK_FORWARD = false | |
381 | end | |
382 | ||
383 | function onSelected(mouse) | |
384 | gatlingmode = false | |
385 | gatlingOFF() | |
386 | mouse.Icon = "rbxasset://textures\\GunCursor.png" | |
387 | mouse.Button1Down:connect(function() | |
388 | ||
389 | if not enabled then return end | |
390 | mouse.Icon = "rbxasset://textures\\GunWaitCursor.png" | |
391 | enabled = false | |
392 | shooting = true | |
393 | stopped = false | |
394 | while shooting do | |
395 | hum = char:FindFirstChild("Humanoid") | |
396 | if hum == nil then else | |
397 | if hum.Health <= 0 then shooting = false end | |
398 | fire(mouse.Hit.p) | |
399 | ||
400 | wait(COOLDOWN) | |
401 | if not AUTOFIRE then | |
402 | shooting = false | |
403 | end | |
404 | end | |
405 | if AUTOFIRE then | |
406 | wait(COOLDOWN) | |
407 | end | |
408 | if mouse then | |
409 | mouse.Icon = "rbxasset://textures\\GunCursor.png" | |
410 | end | |
411 | enabled = true | |
412 | end | |
413 | end) | |
414 | mouse.Button1Up:connect(function() onButtonUp() end) | |
415 | mouse.KeyDown:connect(function(key2) | |
416 | local key=string.byte(key2) | |
417 | if key==string.byte("g") then | |
418 | if gatlingmode == false then | |
419 | gatlingON() | |
420 | else | |
421 | gatlingOFF() | |
422 | end | |
423 | end | |
424 | end) | |
425 | end | |
426 | ||
427 | script.Parent.Selected:connect(onSelected) | |
428 | script.Parent.Deselected:connect(onDeselected) | |
429 | ||
430 | ||
431 | ||
432 | ||
433 | end)) | |
434 | BlockMesh14.Parent = LocalScript13 | |
435 | Script15.Name = "Stretch" | |
436 | Script15.Parent = BlockMesh14 | |
437 | table.insert(cors,sandbox(Script15,function() | |
438 | local missile = script.Parent.Parent | |
439 | if missile:IsA("Part") then | |
440 | origPos = missile.Position | |
441 | m = script.Parent | |
442 | for i = 1, 10 do | |
443 | script.Parent.Parent.Velocity = script.Parent.Parent.Velocity * 0.8 | |
444 | dist = (origPos - missile.Position).magnitude | |
445 | m.Scale = Vector3.new(0.5, 0.5, dist/2) | |
446 | m.Offset = Vector3.new(0.5, 0.5, dist/2) | |
447 | wait() | |
448 | end | |
449 | wait(0.1) | |
450 | script.Parent.Parent.Velocity = script.Parent.Parent.Velocity * -0.6 | |
451 | while true do | |
452 | script.Parent.Parent.Velocity = script.Parent.Parent.Velocity * 1.15 | |
453 | dist = (origPos - missile.Position).magnitude | |
454 | m.Scale = Vector3.new(0.5, 0.5, dist/2) | |
455 | m.Offset = Vector3.new(0.5, 0.5, dist/2) | |
456 | wait() | |
457 | end | |
458 | end | |
459 | end)) | |
460 | Script16.Name = "ArrowScript" | |
461 | Script16.Parent = LocalScript13 | |
462 | table.insert(cors,sandbox(Script16,function() | |
463 | arrow = script.Parent | |
464 | ||
465 | local hitsound = Instance.new("Sound") | |
466 | hitsound.SoundId = "http://www.roblox.com/asset/?id=137579113" | |
467 | hitsound.Volume = 0.3 | |
468 | hitsound.Pitch = math.random(11, 17)/10 | |
469 | hitsound.Parent = arrow | |
470 | ||
471 | if arrow:FindFirstChild("creator") == nil then | |
472 | arrow:WaitForChild("creator") | |
473 | end | |
474 | ||
475 | damage = 25 | |
476 | if arrow.Transparency ~= 0 then | |
477 | damage = 25 | |
478 | end | |
479 | ||
480 | local tag = arrow:FindFirstChild("creator") | |
481 | local ourguy = tag.Value.Character:FindFirstChild("Humanoid") | |
482 | ||
483 | ||
484 | function onTouched(hit) | |
485 | humanoid = nil | |
486 | if tag ~= nil and ourguy ~= nil then | |
487 | if hit.Parent == nil then return end | |
488 | if hit.Parent:findFirstChild("Humanoid") then | |
489 | humanoid = hit.Parent:findFirstChild("Humanoid") | |
490 | elseif hit.Parent.Parent:findFirstChild("Humanoid") then | |
491 | humanoid = hit.Parent.Parent:findFirstChild("Humanoid") | |
492 | end | |
493 | if humanoid ~= nil then | |
494 | if humanoid ~= ourguy then | |
495 | stop = false | |
496 | local ph = hit.Parent:FindFirstChild("PunchHurt") | |
497 | if (ph ~= nil) then | |
498 | if ph.Value == false then | |
499 | stop = true | |
500 | end | |
501 | end | |
502 | if stop == false then | |
503 | hitsound:Play() | |
504 | tagHumanoid(humanoid, vPlayer) | |
505 | humanoid:TakeDamage(damage) | |
506 | arrow:Destroy() | |
507 | end | |
508 | end | |
509 | elseif hit.Anchored == true and hit.CanCollide == true then | |
510 | arrow:Destroy() | |
511 | end | |
512 | end | |
513 | end | |
514 | ||
515 | function tagHumanoid(humanoid) | |
516 | local tag = arrow:findFirstChild("creator") | |
517 | if tag ~= nil then | |
518 | local new_tag = tag:clone() | |
519 | new_tag.Parent = humanoid | |
520 | game.Debris:AddItem(new_tag, 1) | |
521 | end | |
522 | end | |
523 | ||
524 | arrow.Touched:connect(onTouched) | |
525 | ||
526 | wait() | |
527 | if arrow:FindFirstChild("FiredSound") then | |
528 | arrow:FindFirstChild("FiredSound"):Play() | |
529 | end | |
530 | ||
531 | wait(10) | |
532 | arrow:Destroy() | |
533 | end)) | |
534 | Script16.Disabled = true | |
535 | HopperBin17.Name = "Gear Second" | |
536 | HopperBin17.Parent = LocalScript11 | |
537 | LocalScript18.Parent = HopperBin17 | |
538 | table.insert(cors,sandbox(LocalScript18,function() | |
539 | bin = script.Parent | |
540 | player = script.Parent.Parent.Parent | |
541 | me = script.Parent.Parent.Parent | |
542 | ||
543 | enabled = true | |
544 | ||
545 | function Talk(msg) | |
546 | game:GetService("Chat"):Chat(player.Character.Head, msg, Enum.ChatColor.Blue) | |
547 | end | |
548 | ||
549 | function onButton1Down(mouse) | |
550 | if not enabled then | |
551 | return | |
552 | end | |
553 | ||
554 | local player = owner | |
555 | if player == nil then return end | |
556 | ||
557 | enabled = false | |
558 | RightShoulder = me.Character.Torso["Right Shoulder"] | |
559 | LeftShoulder = me.Character.Torso["Left Shoulder"] | |
560 | Run = game:GetService("RunService") | |
561 | for i = 1, 3 do | |
562 | LeftShoulder.C0 = LeftShoulder.C0 *CFrame.Angles(0, 0, 1) | |
563 | RightShoulder.C0 = RightShoulder.C0 *CFrame.Angles(0, 0, -1) | |
564 | RightShoulder.C0 = RightShoulder.C0 *CFrame.Angles(0, 1.1, 0) | |
565 | LeftShoulder.C0 = LeftShoulder.C0 *CFrame.Angles(0, -1.1, 0) | |
566 | Run.Stepped:wait(0.005) | |
567 | end | |
568 | ------------------------------------------------------------------------------- | |
569 | ||
570 | --EDIT HERE-- | |
571 | Talk("Gear Second!")-- you can change Gear Second or Gear 2nd | |
572 | gg = Instance.new("Part") | |
573 | gg.Anchored = true | |
574 | gg.Shape = "Ball" --THIS ball will appear when transforming | |
575 | gg.TopSurface = "Smooth" | |
576 | gg.BottomSurface = "Smooth" | |
577 | gg.BrickColor = BrickColor.new("Persimmon")--color of the bode when transforming | |
578 | gg.CanCollide = false | |
579 | gg.Parent = Workspace | |
580 | gg.Size = Vector3.new(6, 6, 6) | |
581 | p = Instance.new("PointLight", gg) | |
582 | p.Brightness = 10 | |
583 | p.Range = 10 | |
584 | p.Color = Color3.new(255, 0, 0) | |
585 | gg.CFrame = me.Character.Torso.CFrame*CFrame.new(0, 0, 0) | |
586 | qq = Instance.new("SpecialMesh") | |
587 | qq.Parent = gg | |
588 | qq.Scale = Vector3.new(6, 6, 6) | |
589 | qq.MeshType = ("Sphere") | |
590 | for i = 1,6 do | |
591 | qq.Scale = qq.Scale -Vector3.new(1 ,1 ,1) | |
592 | wait(0.01) | |
593 | end | |
594 | gg:remove() | |
595 | Hardening = me.Character["Body Colors"] | |
596 | Hardening.LeftArmColor = BrickColor.new("Persimmon") --color | |
597 | Hardening.RightArmColor = BrickColor.new("Persimmon")--of | |
598 | Hardening.RightLegColor = BrickColor.new("Persimmon")--the | |
599 | Hardening.LeftLegColor = BrickColor.new("Persimmon")--body | |
600 | Hardening.TorsoColor = BrickColor.new("Persimmon")--when | |
601 | Hardening. HeadColor = BrickColor.new("Persimmon")--transforming | |
602 | j = me.Character.Head | |
603 | k = me.Character.Torso | |
604 | q = me.Character["Left Arm"] | |
605 | w = me.Character["Left Leg"] | |
606 | e = me.Character["Right Arm"] | |
607 | r = me.Character["Right Leg"] | |
608 | ||
609 | me.Character.Humanoid.MaxHealth = 500-- 500 - 550 Health of human when transformed | |
610 | me.Character.Humanoid.Health = 500----- SAME ONE | |
611 | me.Character.Humanoid.WalkSpeed = 0 | |
612 | wait(1.5) | |
613 | me.Character.Humanoid.WalkSpeed = 20 --edit 17 - 100 it will increase speed | |
614 | ||
615 | ||
616 | ||
617 | ||
618 | for i = 1, 3 do | |
619 | LeftShoulder.C0 = LeftShoulder.C0 *CFrame.Angles(0, 1.1, 0) | |
620 | RightShoulder.C0 = RightShoulder.C0 *CFrame.Angles(0, -1.1, 0) | |
621 | LeftShoulder.C0 = LeftShoulder.C0 *CFrame.Angles(0, 0, -1) | |
622 | RightShoulder.C0 = RightShoulder.C0 *CFrame.Angles(0, 0, 1) | |
623 | Run.Stepped:wait(0.01) | |
624 | end | |
625 | wait(20) | |
626 | enabled = true | |
627 | end | |
628 | ||
629 | ||
630 | enabled = true | |
631 | function onS(mouse) | |
632 | mouse.Button1Down:connect(function() onButton1Down(mouse) end) | |
633 | end | |
634 | bin.Selected:connect(onS) | |
635 | ||
636 | ||
637 | end)) | |
638 | HopperBin19.Name = "Gatling Gun" | |
639 | HopperBin19.Parent = LocalScript11 | |
640 | LocalScript20.Name = "Gatling" | |
641 | LocalScript20.Parent = HopperBin19 | |
642 | table.insert(cors,sandbox(LocalScript20,function() | |
643 | COOLDOWN = 2 | |
644 | ||
645 | MAX_VELOCITY = 475 | |
646 | MIN_VELOCITY = 400 | |
647 | ||
648 | AUTOFIRE = false | |
649 | ||
650 | SPREAD = 2 | |
651 | ORIGIN_SPREAD = 0 | |
652 | LOCK_FORWARD = false | |
653 | ||
654 | ANTI_GRAVITY = 1 | |
655 | ||
656 | FIRE_SOUND = "http://www.roblox.com/asset/?id=93011731" | |
657 | ||
658 | DESPAWN_TIME = 1 | |
659 | ||
660 | ||
661 | wait(1) | |
662 | ------------------------------ | |
663 | missile = Instance.new("Part") | |
664 | missile.Name = "Gomu" | |
665 | missile.Transparency = 0 | |
666 | missile.Reflectance = 0 | |
667 | missile.CanCollide = false | |
668 | missile.Shape = "Block" | |
669 | missile.FormFactor = "Custom" | |
670 | missile.Size = Vector3.new(2, 2, 2) | |
671 | missile.Elasticity = 0 | |
672 | missile.TopSurface = 0 | |
673 | missile.BottomSurface = 0 | |
674 | ||
675 | while script:FindFirstChild("Mesh") == nil do wait() end | |
676 | script.Mesh:clone().Parent = missile | |
677 | ||
678 | force = Instance.new("BodyForce") | |
679 | force.force = Vector3.new(0,missile:GetMass() * 196.2 * ANTI_GRAVITY) | |
680 | force.Parent = missile | |
681 | ||
682 | scriptName = "ArrowScript" | |
683 | while script:FindFirstChild(scriptName) == nil do wait() end | |
684 | script:FindFirstChild(scriptName):clone().Parent = missile | |
685 | ||
686 | ------------------------------ | |
687 | ||
688 | wait() | |
689 | Tool = script.Parent | |
690 | player = owner | |
691 | while player.Character == nil do wait() end | |
692 | char = player.Character | |
693 | ||
694 | function hidePart(part) | |
695 | if part:FindFirstChild("AttackHide") == nil then | |
696 | local hide = Instance.new("SpecialMesh") | |
697 | hide.Name = "AttackHide" | |
698 | hide.MeshType = "FileMesh" | |
699 | hide.Scale = Vector3.new(0, 0, 0) | |
700 | hide.Parent = part | |
701 | game.Debris:AddItem(hide, DESPAWN_TIME/2) | |
702 | end | |
703 | end | |
704 | ||
705 | shooting = false | |
706 | function fire(v) | |
707 | if choosehand == 1 then | |
708 | choosehand = 2 | |
709 | arm = char:FindFirstChild("Right Arm") | |
710 | else | |
711 | choosehand = 1 | |
712 | arm = char:FindFirstChild("Left Arm") | |
713 | end | |
714 | if arm == nil then return end | |
715 | hidePart(arm) | |
716 | ||
717 | if not LOCK_FORWARD then | |
718 | v_spreadx = math.random(-SPREAD, SPREAD) | |
719 | v_spready = math.random(-SPREAD, SPREAD) | |
720 | v_spreadz = math.random(-SPREAD, SPREAD) | |
721 | v = v + Vector3.new(v_spreadx, v_spready, v_spreadz) | |
722 | v = (v - arm.Position).unit | |
723 | else | |
724 | v = char:FindFirstChild("Torso").CFrame.lookVector | |
725 | end | |
726 | ||
727 | o_spreadx = math.random(-ORIGIN_SPREAD, ORIGIN_SPREAD) | |
728 | o_spready = math.random(-ORIGIN_SPREAD, ORIGIN_SPREAD) | |
729 | o_spreadz = math.random(-ORIGIN_SPREAD, ORIGIN_SPREAD) | |
730 | local spawnPos = arm.Position + Vector3.new(o_spreadx, o_spready, o_spreadz) | |
731 | spawnPos = spawnPos + (v * 1) | |
732 | ||
733 | shot = missile:clone() | |
734 | shot.BrickColor = arm.BrickColor | |
735 | shot.Velocity = v * math.random(MIN_VELOCITY, MAX_VELOCITY) | |
736 | local launch = spawnPos + 2 * v | |
737 | shot.CFrame = CFrame.new(launch, launch + v) | |
738 | ||
739 | local creator_tag = Instance.new("ObjectValue") | |
740 | creator_tag.Value = player | |
741 | creator_tag.Name = "creator" | |
742 | creator_tag.Parent = shot | |
743 | ||
744 | local firesound = Instance.new("Sound") | |
745 | firesound.Name = "FiredSound" | |
746 | firesound.SoundId = FIRE_SOUND | |
747 | firesound.Volume = 1 | |
748 | firesound.Pitch = math.random(8, 14)/10 | |
749 | firesound.Parent = shot | |
750 | ||
751 | shot.Parent = game.Workspace | |
752 | game.Debris:AddItem(shot, DESPAWN_TIME) | |
753 | shot:FindFirstChild(scriptName).Disabled = false | |
754 | end | |
755 | ||
756 | ||
757 | enabled = true | |
758 | gatlingmode = false | |
759 | ||
760 | function onButtonUp() | |
761 | shooting = false | |
762 | end | |
763 | ||
764 | function onDeselect() | |
765 | stopped = true | |
766 | end | |
767 | ||
768 | function gatlingON() | |
769 | gatlingmode = true --if gatling mode | |
770 | COOLDOWN = 0 | |
771 | MAX_VELOCITY = 250 | |
772 | MIN_VELOCITY = 200 | |
773 | AUTOFIRE = true --it means if you click one time it will repeat | |
774 | SPREAD = 3 | |
775 | ORIGIN_SPREAD = 3 | |
776 | DESPAWN_TIME = 0.9 | |
777 | missile.Transparency = 0.4 | |
778 | LOCK_FORWARD = true --change it to false if you want to back attack | |
779 | end | |
780 | ||
781 | function gatlingOFF() | |
782 | gatlingmode = false -- if one shot mode | |
783 | COOLDOWN = 0.4 | |
784 | MAX_VELOCITY = 475 | |
785 | MIN_VELOCITY = 400 | |
786 | AUTOFIRE = true --it means if you click one time it will repeat | |
787 | SPREAD = 2 | |
788 | ORIGIN_SPREAD = 0 | |
789 | DESPAWN_TIME = 1 | |
790 | missile.Transparency = 0 | |
791 | LOCK_FORWARD = false | |
792 | end | |
793 | ||
794 | function onSelected(mouse) | |
795 | gatlingmode = true | |
796 | gatlingON() | |
797 | mouse.Icon = "rbxasset://textures\\GunCursor.png" | |
798 | mouse.Button1Down:connect(function() | |
799 | ||
800 | if not enabled then return end | |
801 | mouse.Icon = "rbxasset://textures\\GunWaitCursor.png" | |
802 | enabled = false | |
803 | shooting = true | |
804 | stopped = false | |
805 | while shooting do | |
806 | hum = char:FindFirstChild("Humanoid") | |
807 | if hum == nil then else | |
808 | if hum.Health <= 0 then shooting = false end | |
809 | fire(mouse.Hit.p) | |
810 | ||
811 | wait(COOLDOWN) | |
812 | if not AUTOFIRE then | |
813 | shooting = false | |
814 | end | |
815 | end | |
816 | if AUTOFIRE then | |
817 | wait(COOLDOWN) | |
818 | end | |
819 | if mouse then | |
820 | mouse.Icon = "rbxasset://textures\\GunCursor.png" | |
821 | end | |
822 | enabled = true | |
823 | end | |
824 | end) | |
825 | mouse.Button1Up:connect(function() onButtonUp() end) | |
826 | mouse.KeyDown:connect(function(key2) | |
827 | local key=string.byte(key2) | |
828 | if key==string.byte("g") then | |
829 | if gatlingmode == false then | |
830 | gatlingON() | |
831 | else | |
832 | gatlingOFF() | |
833 | end | |
834 | end | |
835 | end) | |
836 | end | |
837 | ||
838 | script.Parent.Selected:connect(onSelected) | |
839 | script.Parent.Deselected:connect(onDeselected) | |
840 | ||
841 | ||
842 | ||
843 | ||
844 | ||
845 | ||
846 | end)) | |
847 | BlockMesh21.Parent = LocalScript20 | |
848 | Script22.Name = "Stretch" | |
849 | Script22.Parent = BlockMesh21 | |
850 | table.insert(cors,sandbox(Script22,function() | |
851 | local missile = script.Parent.Parent | |
852 | if missile:IsA("Part") then | |
853 | origPos = missile.Position | |
854 | m = script.Parent | |
855 | for i = 1, 10 do | |
856 | script.Parent.Parent.Velocity = script.Parent.Parent.Velocity * 0.8 | |
857 | dist = (origPos - missile.Position).magnitude | |
858 | m.Scale = Vector3.new(0.5, 0.5, dist/2) | |
859 | m.Offset = Vector3.new(0.5, 0.5, dist/2) | |
860 | wait() | |
861 | end | |
862 | wait(0.1) | |
863 | script.Parent.Parent.Velocity = script.Parent.Parent.Velocity * -0.6 | |
864 | while true do | |
865 | script.Parent.Parent.Velocity = script.Parent.Parent.Velocity * 1.15 | |
866 | dist = (origPos - missile.Position).magnitude | |
867 | m.Scale = Vector3.new(0.5, 0.5, dist/2) | |
868 | m.Offset = Vector3.new(0.5, 0.5, dist/2) | |
869 | wait() | |
870 | end | |
871 | end | |
872 | end)) | |
873 | Script23.Name = "ArrowScript" | |
874 | Script23.Parent = LocalScript20 | |
875 | table.insert(cors,sandbox(Script23,function() | |
876 | arrow = script.Parent | |
877 | ||
878 | local hitsound = Instance.new("Sound") | |
879 | hitsound.SoundId = "http://www.roblox.com/asset/?id=137579113" | |
880 | hitsound.Volume = 0.3 | |
881 | hitsound.Pitch = math.random(11, 17)/10 | |
882 | hitsound.Parent = arrow | |
883 | ||
884 | if arrow:FindFirstChild("creator") == nil then | |
885 | arrow:WaitForChild("creator") | |
886 | end | |
887 | ||
888 | damage = 40 | |
889 | if arrow.Transparency ~= 0 then | |
890 | damage = 40 | |
891 | end | |
892 | ||
893 | local tag = arrow:FindFirstChild("creator") | |
894 | local ourguy = tag.Value.Character:FindFirstChild("Humanoid") | |
895 | ||
896 | ||
897 | function onTouched(hit) | |
898 | humanoid = nil | |
899 | if tag ~= nil and ourguy ~= nil then | |
900 | if hit.Parent == nil then return end | |
901 | if hit.Parent:findFirstChild("Humanoid") then | |
902 | humanoid = hit.Parent:findFirstChild("Humanoid") | |
903 | elseif hit.Parent.Parent:findFirstChild("Humanoid") then | |
904 | humanoid = hit.Parent.Parent:findFirstChild("Humanoid") | |
905 | end | |
906 | if humanoid ~= nil then | |
907 | if humanoid ~= ourguy then | |
908 | stop = false | |
909 | local ph = hit.Parent:FindFirstChild("PunchHurt") | |
910 | if (ph ~= nil) then | |
911 | if ph.Value == false then | |
912 | stop = true | |
913 | end | |
914 | end | |
915 | if stop == false then | |
916 | hitsound:Play() | |
917 | tagHumanoid(humanoid, vPlayer) | |
918 | humanoid:TakeDamage(damage) | |
919 | arrow:Destroy() | |
920 | end | |
921 | end | |
922 | elseif hit.Anchored == true and hit.CanCollide == true then | |
923 | arrow:Destroy() | |
924 | end | |
925 | end | |
926 | end | |
927 | ||
928 | function tagHumanoid(humanoid) | |
929 | local tag = arrow:findFirstChild("creator") | |
930 | if tag ~= nil then | |
931 | local new_tag = tag:clone() | |
932 | new_tag.Parent = humanoid | |
933 | game.Debris:AddItem(new_tag, 1) | |
934 | end | |
935 | end | |
936 | ||
937 | arrow.Touched:connect(onTouched) | |
938 | ||
939 | wait() | |
940 | if arrow:FindFirstChild("FiredSound") then | |
941 | arrow:FindFirstChild("FiredSound"):Play() | |
942 | end | |
943 | ||
944 | wait(10) | |
945 | arrow:Destroy() | |
946 | end)) | |
947 | Script23.Disabled = true | |
948 | Script24.Name = "DevilFruitAttributes" | |
949 | Script24.Parent = LocalScript11 | |
950 | table.insert(cors,sandbox(Script24,function() | |
951 | wait() | |
952 | if script.Parent then | |
953 | if not script.Parent:IsA("Script") or not script.Parent.Name == "StarterGear" then | |
954 | local debris = game:GetService("Debris") | |
955 | local backpack = script.Parent | |
956 | local player = backpack.Parent | |
957 | while player.Character == nil do wait() end | |
958 | local character = player.Character | |
959 | if character then | |
960 | while character:FindFirstChild("Humanoid") == nil do wait() end | |
961 | local hum = character:FindFirstChild("Humanoid") | |
962 | ||
963 | -- Logia | |
964 | local charparts = character:GetChildren() | |
965 | for i = 1, #charparts do | |
966 | local charpart = charparts[i] | |
967 | if charpart:IsA("BasePart") then | |
968 | charpart.Touched:connect(function(hit) | |
969 | if charpart:FindFirstChild("Hide") then return end | |
970 | local stop = true | |
971 | if hit ~= nil then | |
972 | if hit.Parent ~= nil then | |
973 | if hit:FindFirstChild("creator") or hit.Parent:FindFirstChild("creator") then | |
974 | stop = false | |
975 | elseif hit.Parent:FindFirstChild("Humanoid") then | |
976 | if hit.Parent:FindFirstChild("Humanoid") ~= hum then | |
977 | stop = false | |
978 | end | |
979 | end | |
980 | end | |
981 | end | |
982 | if stop then return end | |
983 | local hidemesh = Instance.new("SpecialMesh") | |
984 | hidemesh.Name = "Hide" | |
985 | hidemesh.MeshType = "FileMesh" | |
986 | hidemesh.MeshId = "" | |
987 | hidemesh.Scale = Vector3.new(0, 0, 0) | |
988 | hidemesh.Parent = charpart | |
989 | debris:AddItem(hidemesh, 1.5) | |
990 | ||
991 | local bodyeffect = Instance.new("Part") | |
992 | bodyeffect.Name = "BodyEffect" | |
993 | bodyeffect.Transparency = 0.3 | |
994 | bodyeffect.CanCollide = false | |
995 | bodyeffect.FormFactor = "Custom" | |
996 | bodyeffect.Size = Vector3.new(0.2, 0.2, 0.2) | |
997 | bodyeffect.TopSurface = "Smooth" | |
998 | bodyeffect.BottomSurface = "Smooth" | |
999 | bodyeffect.CFrame = charpart.CFrame | |
1000 | ||
1001 | local mesh = Instance.new("SpecialMesh") | |
1002 | mesh.MeshId = "http://www.roblox.com/asset?id=165709404" | |
1003 | mesh.TextureId = "http://www.roblox.com/asset?id=165709478" | |
1004 | mesh.Scale = Vector3.new(3, 3, 3) | |
1005 | mesh.Parent = bodyeffect | |
1006 | ||
1007 | local sound = Instance.new("Sound") | |
1008 | sound.SoundId = "http://www.roblox.com/asset/?id=31759626" | |
1009 | sound.Volume = 0.3 | |
1010 | sound.Pitch = math.random(9, 11)/10 | |
1011 | sound.Parent = bodyeffect | |
1012 | ||
1013 | local light = Instance.new("PointLight") | |
1014 | light.Range = 5 | |
1015 | light.Color = Color3.new(1, 1, 0) | |
1016 | light.Parent = bodyeffect | |
1017 | ||
1018 | bodyeffect.Parent = charpart.Parent | |
1019 | ||
1020 | sound:Play() | |
1021 | ||
1022 | local weld = Instance.new("ManualWeld") | |
1023 | weld.Part0 = bodyeffect | |
1024 | weld.Part1 = charpart | |
1025 | weld.C1 = charpart.CFrame:inverse() * bodyeffect.CFrame | |
1026 | weld.Parent = bodyeffect | |
1027 | ||
1028 | debris:AddItem(bodyeffect, 1.5) | |
1029 | end) | |
1030 | end | |
1031 | end | |
1032 | end | |
1033 | end | |
1034 | end | |
1035 | end)) | |
1036 | StringValue25.Name = "DevilFruitType" | |
1037 | StringValue25.Parent = Tool0 | |
1038 | StringValue25.Value = "Rubber" | |
1039 | Part26.Name = "Leafs" | |
1040 | Part26.Parent = Tool0 | |
1041 | Part26.CFrame = CFrame.new(48.6795959, 1.326491, 19.1532822, -4.4091145e-08, -7.30506144e-08, -1, 1, -4.51691449e-08, -4.36030163e-08, -4.23751771e-08, -1, -7.30506144e-08) | |
1042 | Part26.Orientation = Vector3.new(0, -90, 90) | |
1043 | Part26.Position = Vector3.new(48.6795959, 1.326491, 19.1532822) | |
1044 | Part26.Rotation = Vector3.new(-90, -90, 0) | |
1045 | Part26.Color = Color3.new(1, 0.34902, 0.34902) | |
1046 | Part26.Size = Vector3.new(0.410000086, 0.329999983, 0.200000048) | |
1047 | Part26.Anchored = true | |
1048 | Part26.BrickColor = BrickColor.new("Persimmon") | |
1049 | Part26.Material = Enum.Material.SmoothPlastic | |
1050 | Part26.brickColor = BrickColor.new("Persimmon") | |
1051 | Part26.FormFactor = Enum.FormFactor.Custom | |
1052 | Part26.formFactor = Enum.FormFactor.Custom | |
1053 | SpecialMesh27.Parent = Part26 | |
1054 | SpecialMesh27.Scale = Vector3.new(1, 0.200000003, 0.200000003) | |
1055 | SpecialMesh27.MeshType = Enum.MeshType.Cylinder | |
1056 | Part28.Name = "Leafs" | |
1057 | Part28.Parent = Tool0 | |
1058 | Part28.CFrame = CFrame.new(48.6795998, 1.51648796, 19.1482849, -1.16759111e-07, 4.34269509e-10, -1, -1.52271241e-07, -1, 1.92770244e-11, -1, 1.49477273e-07, -2.93402991e-08) | |
1059 | Part28.Orientation = Vector3.new(0, -90, -180) | |
1060 | Part28.Position = Vector3.new(48.6795998, 1.51648796, 19.1482849) | |
1061 | Part28.Rotation = Vector3.new(180, -90, 0) | |
1062 | Part28.Color = Color3.new(0.411765, 0.25098, 0.156863) | |
1063 | Part28.Size = Vector3.new(0.640000045, 0.329999983, 0.200000048) | |
1064 | Part28.Anchored = true | |
1065 | Part28.BrickColor = BrickColor.new("Reddish brown") | |
1066 | Part28.Material = Enum.Material.SmoothPlastic | |
1067 | Part28.brickColor = BrickColor.new("Reddish brown") | |
1068 | Part28.FormFactor = Enum.FormFactor.Custom | |
1069 | Part28.formFactor = Enum.FormFactor.Custom | |
1070 | SpecialMesh29.Parent = Part28 | |
1071 | SpecialMesh29.Scale = Vector3.new(1, 0.200000003, 0.200000003) | |
1072 | SpecialMesh29.MeshType = Enum.MeshType.Cylinder | |
1073 | Part30.Name = "Leafs" | |
1074 | Part30.Parent = Tool0 | |
1075 | Part30.CFrame = CFrame.new(48.6795998, 1.543787, 18.7326698, -1.14498107e-07, -1.83335942e-08, -1, 0.258818775, -0.965925932, -1.1264305e-08, -0.965925932, -0.258818686, -3.08291419e-08) | |
1076 | Part30.Orientation = Vector3.new(0, -90, 165) | |
1077 | Part30.Position = Vector3.new(48.6795998, 1.543787, 18.7326698) | |
1078 | Part30.Rotation = Vector3.new(-165, -90, 0) | |
1079 | Part30.Color = Color3.new(0.411765, 0.25098, 0.156863) | |
1080 | Part30.Size = Vector3.new(0.200000077, 0.329999983, 0.200000048) | |
1081 | Part30.Anchored = true | |
1082 | Part30.BrickColor = BrickColor.new("Reddish brown") | |
1083 | Part30.Material = Enum.Material.SmoothPlastic | |
1084 | Part30.brickColor = BrickColor.new("Reddish brown") | |
1085 | Part30.FormFactor = Enum.FormFactor.Custom | |
1086 | Part30.formFactor = Enum.FormFactor.Custom | |
1087 | SpecialMesh31.Parent = Part30 | |
1088 | SpecialMesh31.Scale = Vector3.new(1, 0.200000003, 0.200000003) | |
1089 | SpecialMesh31.MeshType = Enum.MeshType.Cylinder | |
1090 | for i,v in pairs(mas:GetChildren()) do | |
1091 | v.Parent = workspace | |
1092 | pcall(function() v:MakeJoints() end) | |
1093 | end | |
1094 | mas:Destroy() | |
1095 | for i,v in pairs(cors) do | |
1096 | spawn(function() | |
1097 | pcall(v) | |
1098 | end) | |
1099 | end | |
1100 | ||
1101 | --Converted with ttyyuu12345's model to script plugin v4 | |
1102 | function sandbox(var,func) | |
1103 | local env = getfenv(func) | |
1104 | local newenv = setmetatable({},{ | |
1105 | __index = function(self,k) | |
1106 | if k=="script" then | |
1107 | return var | |
1108 | else | |
1109 | return env[k] | |
1110 | end | |
1111 | end, | |
1112 | }) | |
1113 | setfenv(func,newenv) | |
1114 | return func | |
1115 | end | |
1116 | cors = {} | |
1117 | mas = Instance.new("Model",game:GetService("Lighting")) | |
1118 | Tool0 = Instance.new("Tool") | |
1119 | Part1 = Instance.new("Part") | |
1120 | Decal2 = Instance.new("Decal") | |
1121 | Decal3 = Instance.new("Decal") | |
1122 | Decal4 = Instance.new("Decal") | |
1123 | Decal5 = Instance.new("Decal") | |
1124 | Decal6 = Instance.new("Decal") | |
1125 | Decal7 = Instance.new("Decal") | |
1126 | SpecialMesh8 = Instance.new("SpecialMesh") | |
1127 | Sound9 = Instance.new("Sound") | |
1128 | LocalScript10 = Instance.new("LocalScript") | |
1129 | LocalScript11 = Instance.new("LocalScript") | |
1130 | HopperBin12 = Instance.new("HopperBin") | |
1131 | LocalScript13 = Instance.new("LocalScript") | |
1132 | BlockMesh14 = Instance.new("BlockMesh") | |
1133 | Script15 = Instance.new("Script") | |
1134 | Script16 = Instance.new("Script") | |
1135 | HopperBin17 = Instance.new("HopperBin") | |
1136 | LocalScript18 = Instance.new("LocalScript") | |
1137 | HopperBin19 = Instance.new("HopperBin") | |
1138 | LocalScript20 = Instance.new("LocalScript") | |
1139 | BlockMesh21 = Instance.new("BlockMesh") | |
1140 | Script22 = Instance.new("Script") | |
1141 | Script23 = Instance.new("Script") | |
1142 | Script24 = Instance.new("Script") | |
1143 | StringValue25 = Instance.new("StringValue") | |
1144 | Part26 = Instance.new("Part") | |
1145 | SpecialMesh27 = Instance.new("SpecialMesh") | |
1146 | Part28 = Instance.new("Part") | |
1147 | SpecialMesh29 = Instance.new("SpecialMesh") | |
1148 | Part30 = Instance.new("Part") | |
1149 | SpecialMesh31 = Instance.new("SpecialMesh") | |
1150 | Tool0.Name = "(Click to eat) Gomu Gomu no mi" | |
1151 | Tool0.Parent = mas | |
1152 | Tool0.Grip = CFrame.new(0, 0, 0, 0, 0, -1, 0, 1, 0, 1, 0, 0) | |
1153 | Tool0.GripForward = Vector3.new(1, -0, -0) | |
1154 | Tool0.GripRight = Vector3.new(0, 0, 1) | |
1155 | Part1.Name = "Handle" | |
1156 | Part1.Parent = Tool0 | |
1157 | Part1.CFrame = CFrame.new(48.749485, 0.503547013, 19.1430969, -0.999999523, -0.000978620723, 1.05401614e-05, -0.000978537253, 0.999980748, 0.00612961594, -1.66846348e-05, 0.0061296029, -0.999981225) | |
1158 | Part1.Orientation = Vector3.new(-0.349999994, 180, -0.0599999987) | |
1159 | Part1.Position = Vector3.new(48.749485, 0.503547013, 19.1430969) | |
1160 | Part1.Rotation = Vector3.new(-179.649994, 0, 179.940002) | |
1161 | Part1.Color = Color3.new(0.972549, 0.85098, 0.427451) | |
1162 | Part1.Size = Vector3.new(1, 1, 1) | |
1163 | Part1.BottomSurface = Enum.SurfaceType.Smooth | |
1164 | Part1.BrickColor = BrickColor.new("Daisy orange") | |
1165 | Part1.Material = Enum.Material.SmoothPlastic | |
1166 | Part1.TopSurface = Enum.SurfaceType.Smooth | |
1167 | Part1.brickColor = BrickColor.new("Daisy orange") | |
1168 | Part1.FormFactor = Enum.FormFactor.Symmetric | |
1169 | Part1.formFactor = Enum.FormFactor.Symmetric | |
1170 | Decal2.Parent = Part1 | |
1171 | Decal2.Texture = "rbxassetid://114369508" | |
1172 | Decal2.Transparency = 0.5 | |
1173 | Decal3.Parent = Part1 | |
1174 | Decal3.Texture = "rbxassetid://114369508" | |
1175 | Decal3.Transparency = 0.5 | |
1176 | Decal3.Face = Enum.NormalId.Left | |
1177 | Decal4.Parent = Part1 | |
1178 | Decal4.Texture = "rbxassetid://114369508" | |
1179 | Decal4.Transparency = 0.5 | |
1180 | Decal4.Face = Enum.NormalId.Back | |
1181 | Decal5.Parent = Part1 | |
1182 | Decal5.Texture = "rbxassetid://114369508" | |
1183 | Decal5.Transparency = 0.5 | |
1184 | Decal5.Face = Enum.NormalId.Right | |
1185 | Decal6.Parent = Part1 | |
1186 | Decal6.Texture = "rbxassetid://114369508" | |
1187 | Decal6.Transparency = 0.5 | |
1188 | Decal6.Face = Enum.NormalId.Top | |
1189 | Decal7.Parent = Part1 | |
1190 | Decal7.Texture = "rbxassetid://114369508" | |
1191 | Decal7.Transparency = 0.5 | |
1192 | Decal7.Face = Enum.NormalId.Bottom | |
1193 | SpecialMesh8.Parent = Part1 | |
1194 | SpecialMesh8.Scale = Vector3.new(1.29999995, 1.29999995, 1.29999995) | |
1195 | SpecialMesh8.MeshType = Enum.MeshType.Sphere | |
1196 | Sound9.Name = "Eat" | |
1197 | Sound9.Parent = Part1 | |
1198 | Sound9.Looped = true | |
1199 | Sound9.Pitch = 1.1000000238419 | |
1200 | Sound9.PlaybackSpeed = 1.1000000238419 | |
1201 | Sound9.SoundId = "rbxassetid://161190414" | |
1202 | LocalScript10.Name = "InstaWeld" | |
1203 | LocalScript10.Parent = Tool0 | |
1204 | table.insert(cors,sandbox(LocalScript10,function() | |
1205 | local currentwelds = {} | |
1206 | ||
1207 | function Weld(x,y) | |
1208 | local W = Instance.new("Weld") | |
1209 | W.Part0 = x | |
1210 | W.Part1 = y | |
1211 | local CJ = CFrame.new(x.Position) | |
1212 | local C0 = x.CFrame:inverse()*CJ | |
1213 | local C1 = y.CFrame:inverse()*CJ | |
1214 | W.C0 = C0 | |
1215 | W.C1 = C1 | |
1216 | W.Parent = x | |
1217 | currentwelds[#currentwelds+1] = W | |
1218 | end | |
1219 | ||
1220 | function Get(A) | |
1221 | if A:IsA("BasePart") then | |
1222 | Weld(script.Parent.Handle, A) | |
1223 | A.Anchored = false | |
1224 | else | |
1225 | local C = A:GetChildren() | |
1226 | for i=1, #C do | |
1227 | Get(C[i]) | |
1228 | end | |
1229 | end | |
1230 | end | |
1231 | ||
1232 | function Finale() | |
1233 | currentwelds = {} | |
1234 | Get(script.Parent) | |
1235 | coroutine.resume(coroutine.create(function() | |
1236 | wait(0.1) | |
1237 | local toolparts = script.Parent:GetChildren() | |
1238 | for h = 1, #toolparts do | |
1239 | local c = toolparts[h]:GetChildren() | |
1240 | for j = 1, #c do | |
1241 | if c[j]:IsA("Weld") then | |
1242 | local stop = false | |
1243 | for k = 1, #currentwelds do | |
1244 | if c[j] == currentwelds[k] then | |
1245 | stop = true | |
1246 | end | |
1247 | end | |
1248 | if not stop then | |
1249 | c[j]:Destroy() | |
1250 | end | |
1251 | end | |
1252 | end | |
1253 | end | |
1254 | end)) | |
1255 | end | |
1256 | ||
1257 | script.Parent.Equipped:connect(Finale) | |
1258 | script.Parent.Unequipped:connect(Finale) | |
1259 | Finale() | |
1260 | end)) | |
1261 | LocalScript11.Name = "EatScript" | |
1262 | LocalScript11.Parent = Tool0 | |
1263 | table.insert(cors,sandbox(LocalScript11,function() | |
1264 | wait() | |
1265 | ||
1266 | local tool = script.Parent | |
1267 | local player = owner | |
1268 | ||
1269 | defaultholdingpos = tool.GripPos | |
1270 | eaten = false | |
1271 | equipped = false | |
1272 | cancelled = false | |
1273 | tool.Equipped:connect(function() | |
1274 | equipped = true | |
1275 | script.Parent.Activated:connect(function() | |
1276 | if not eaten then | |
1277 | cancelled = false | |
1278 | tool.GripPos = Vector3.new(0.8, -0.5, 1.5) | |
1279 | tool.Handle.Eat:Play() | |
1280 | wait(1.4) | |
1281 | tool.Handle.Eat:Stop() | |
1282 | if equipped and not cancelled then | |
1283 | local currentsavedgear = player:FindFirstChild("StarterGear"):GetChildren() | |
1284 | local hasdf = false | |
1285 | if #currentsavedgear > 0 then | |
1286 | for i = 1, #currentsavedgear do | |
1287 | if currentsavedgear[i]:FindFirstChild("DevilFruitAbility") then | |
1288 | currentsavedgear[i]:Destroy() | |
1289 | hasdf = true | |
1290 | end | |
1291 | end | |
1292 | end | |
1293 | if not hasdf then | |
1294 | local dftools = script:GetChildren() | |
1295 | for i = 1, #dftools do | |
1296 | local df_tag = Instance.new("StringValue") | |
1297 | df_tag.Name = "DevilFruitAbility" | |
1298 | df_tag.Value = tool.DevilFruitType.Value | |
1299 | df_tag.Parent = dftools[i] | |
1300 | dftools[i]:clone().Parent = player:FindFirstChild("Backpack") | |
1301 | dftools[i]:clone().Parent = player:FindFirstChild("StarterGear") | |
1302 | end | |
1303 | tool:Destroy() | |
1304 | elseif hasdf then | |
1305 | if player.Character then | |
1306 | if player.Character:FindFirstChild("Humanoid") then | |
1307 | player.Character:BreakJoints() | |
1308 | player.Character:FindFirstChild("Humanoid").Health = 0 | |
1309 | end | |
1310 | end | |
1311 | tool:Destroy() | |
1312 | end | |
1313 | end | |
1314 | end | |
1315 | end) | |
1316 | end) | |
1317 | ||
1318 | tool.Unequipped:connect(function() | |
1319 | tool.Handle.Eat:Stop() | |
1320 | cancelled = true | |
1321 | equipped = false | |
1322 | if not eaten then | |
1323 | tool.GripPos = defaultholdingpos | |
1324 | end | |
1325 | end) | |
1326 | end)) | |
1327 | HopperBin12.Name = "Pistol" | |
1328 | HopperBin12.Parent = LocalScript11 | |
1329 | LocalScript13.Name = "Normal" | |
1330 | LocalScript13.Parent = HopperBin12 | |
1331 | table.insert(cors,sandbox(LocalScript13,function() | |
1332 | COOLDOWN = 1 | |
1333 | ||
1334 | MAX_VELOCITY = 475 | |
1335 | MIN_VELOCITY = 400 | |
1336 | ||
1337 | AUTOFIRE = false | |
1338 | ||
1339 | SPREAD = 2 | |
1340 | ORIGIN_SPREAD = 0 | |
1341 | LOCK_FORWARD = false | |
1342 | ||
1343 | ANTI_GRAVITY = 1 | |
1344 | ||
1345 | FIRE_SOUND = "http://www.roblox.com/asset/?id=93011731" | |
1346 | ||
1347 | DESPAWN_TIME = 1 | |
1348 | ||
1349 | ||
1350 | wait(1) | |
1351 | ------------------------------ | |
1352 | missile = Instance.new("Part") | |
1353 | missile.Name = "Gomu" | |
1354 | missile.Transparency = 0 | |
1355 | missile.Reflectance = 0 | |
1356 | missile.CanCollide = false | |
1357 | missile.Shape = "Block" | |
1358 | missile.FormFactor = "Custom" | |
1359 | missile.Size = Vector3.new(2, 2, 2) | |
1360 | missile.Elasticity = 0 | |
1361 | missile.TopSurface = 0 | |
1362 | missile.BottomSurface = 0 | |
1363 | ||
1364 | while script:FindFirstChild("Mesh") == nil do wait() end | |
1365 | script.Mesh:clone().Parent = missile | |
1366 | ||
1367 | force = Instance.new("BodyForce") | |
1368 | force.force = Vector3.new(0,missile:GetMass() * 196.2 * ANTI_GRAVITY) | |
1369 | force.Parent = missile | |
1370 | ||
1371 | scriptName = "ArrowScript" | |
1372 | while script:FindFirstChild(scriptName) == nil do wait() end | |
1373 | script:FindFirstChild(scriptName):clone().Parent = missile | |
1374 | ||
1375 | ------------------------------ | |
1376 | ||
1377 | wait() | |
1378 | Tool = script.Parent | |
1379 | player = owner | |
1380 | while player.Character == nil do wait() end | |
1381 | char = player.Character | |
1382 | ||
1383 | function hidePart(part) | |
1384 | if part:FindFirstChild("AttackHide") == nil then | |
1385 | local hide = Instance.new("SpecialMesh") | |
1386 | hide.Name = "AttackHide" | |
1387 | hide.MeshType = "FileMesh" | |
1388 | hide.Scale = Vector3.new(0, 0, 0) | |
1389 | hide.Parent = part | |
1390 | game.Debris:AddItem(hide, DESPAWN_TIME/2) | |
1391 | end | |
1392 | end | |
1393 | ||
1394 | shooting = false | |
1395 | function fire(v) | |
1396 | if choosehand == 1 then | |
1397 | choosehand = 2 | |
1398 | arm = char:FindFirstChild("Right Arm") | |
1399 | else | |
1400 | choosehand = 1 | |
1401 | arm = char:FindFirstChild("Left Arm") | |
1402 | end | |
1403 | if arm == nil then return end | |
1404 | hidePart(arm) | |
1405 | ||
1406 | if not LOCK_FORWARD then | |
1407 | v_spreadx = math.random(-SPREAD, SPREAD) | |
1408 | v_spready = math.random(-SPREAD, SPREAD) | |
1409 | v_spreadz = math.random(-SPREAD, SPREAD) | |
1410 | v = v + Vector3.new(v_spreadx, v_spready, v_spreadz) | |
1411 | v = (v - arm.Position).unit | |
1412 | else | |
1413 | v = char:FindFirstChild("Torso").CFrame.lookVector | |
1414 | end | |
1415 | ||
1416 | o_spreadx = math.random(-ORIGIN_SPREAD, ORIGIN_SPREAD) | |
1417 | o_spready = math.random(-ORIGIN_SPREAD, ORIGIN_SPREAD) | |
1418 | o_spreadz = math.random(-ORIGIN_SPREAD, ORIGIN_SPREAD) | |
1419 | local spawnPos = arm.Position + Vector3.new(o_spreadx, o_spready, o_spreadz) | |
1420 | spawnPos = spawnPos + (v * 1) | |
1421 | ||
1422 | shot = missile:clone() | |
1423 | shot.BrickColor = arm.BrickColor | |
1424 | shot.Velocity = v * math.random(MIN_VELOCITY, MAX_VELOCITY) | |
1425 | local launch = spawnPos + 2 * v | |
1426 | shot.CFrame = CFrame.new(launch, launch + v) | |
1427 | ||
1428 | local creator_tag = Instance.new("ObjectValue") | |
1429 | creator_tag.Value = player | |
1430 | creator_tag.Name = "creator" | |
1431 | creator_tag.Parent = shot | |
1432 | ||
1433 | local firesound = Instance.new("Sound") | |
1434 | firesound.Name = "FiredSound" | |
1435 | firesound.SoundId = FIRE_SOUND | |
1436 | firesound.Volume = 1 | |
1437 | firesound.Pitch = math.random(8, 14)/10 | |
1438 | firesound.Parent = shot | |
1439 | ||
1440 | shot.Parent = game.Workspace | |
1441 | game.Debris:AddItem(shot, DESPAWN_TIME) | |
1442 | shot:FindFirstChild(scriptName).Disabled = false | |
1443 | end | |
1444 | ||
1445 | ||
1446 | enabled = true | |
1447 | gatlingmode = false | |
1448 | ||
1449 | function onButtonUp() | |
1450 | shooting = false | |
1451 | end | |
1452 | ||
1453 | function onDeselect() | |
1454 | stopped = true | |
1455 | end | |
1456 | ||
1457 | function gatlingOFF() | |
1458 | gatlingmode = false -- its not gatling ya know | |
1459 | COOLDOWN = 2 | |
1460 | MAX_VELOCITY = 250 | |
1461 | MIN_VELOCITY = 200 | |
1462 | AUTOFIRE = false | |
1463 | SPREAD = 3 | |
1464 | ORIGIN_SPREAD = 3 | |
1465 | DESPAWN_TIME = 0.9 | |
1466 | missile.Transparency = 0.4 | |
1467 | LOCK_FORWARD = true | |
1468 | end | |
1469 | ||
1470 | function gatlingON() | |
1471 | gatlingmode = true -- its one shot | |
1472 | COOLDOWN = 2 | |
1473 | MAX_VELOCITY = 475 | |
1474 | MIN_VELOCITY = 400 | |
1475 | AUTOFIRE = false | |
1476 | SPREAD = 2 | |
1477 | ORIGIN_SPREAD = 0 | |
1478 | DESPAWN_TIME = 1 | |
1479 | missile.Transparency = 0 | |
1480 | LOCK_FORWARD = false | |
1481 | end | |
1482 | ||
1483 | function onSelected(mouse) | |
1484 | gatlingmode = false | |
1485 | gatlingOFF() | |
1486 | mouse.Icon = "rbxasset://textures\\GunCursor.png" | |
1487 | mouse.Button1Down:connect(function() | |
1488 | ||
1489 | if not enabled then return end | |
1490 | mouse.Icon = "rbxasset://textures\\GunWaitCursor.png" | |
1491 | enabled = false | |
1492 | shooting = true | |
1493 | stopped = false | |
1494 | while shooting do | |
1495 | hum = char:FindFirstChild("Humanoid") | |
1496 | if hum == nil then else | |
1497 | if hum.Health <= 0 then shooting = false end | |
1498 | fire(mouse.Hit.p) | |
1499 | ||
1500 | wait(COOLDOWN) | |
1501 | if not AUTOFIRE then | |
1502 | shooting = false | |
1503 | end | |
1504 | end | |
1505 | if AUTOFIRE then | |
1506 | wait(COOLDOWN) | |
1507 | end | |
1508 | if mouse then | |
1509 | mouse.Icon = "rbxasset://textures\\GunCursor.png" | |
1510 | end | |
1511 | enabled = true | |
1512 | end | |
1513 | end) | |
1514 | mouse.Button1Up:connect(function() onButtonUp() end) | |
1515 | mouse.KeyDown:connect(function(key2) | |
1516 | local key=string.byte(key2) | |
1517 | if key==string.byte("g") then | |
1518 | if gatlingmode == false then | |
1519 | gatlingON() | |
1520 | else | |
1521 | gatlingOFF() | |
1522 | end | |
1523 | end | |
1524 | end) | |
1525 | end | |
1526 | ||
1527 | script.Parent.Selected:connect(onSelected) | |
1528 | script.Parent.Deselected:connect(onDeselected) | |
1529 | ||
1530 | ||
1531 | ||
1532 | ||
1533 | end)) | |
1534 | BlockMesh14.Parent = LocalScript13 | |
1535 | Script15.Name = "Stretch" | |
1536 | Script15.Parent = BlockMesh14 | |
1537 | table.insert(cors,sandbox(Script15,function() | |
1538 | local missile = script.Parent.Parent | |
1539 | if missile:IsA("Part") then | |
1540 | origPos = missile.Position | |
1541 | m = script.Parent | |
1542 | for i = 1, 10 do | |
1543 | script.Parent.Parent.Velocity = script.Parent.Parent.Velocity * 0.8 | |
1544 | dist = (origPos - missile.Position).magnitude | |
1545 | m.Scale = Vector3.new(0.5, 0.5, dist/2) | |
1546 | m.Offset = Vector3.new(0.5, 0.5, dist/2) | |
1547 | wait() | |
1548 | end | |
1549 | wait(0.1) | |
1550 | script.Parent.Parent.Velocity = script.Parent.Parent.Velocity * -0.6 | |
1551 | while true do | |
1552 | script.Parent.Parent.Velocity = script.Parent.Parent.Velocity * 1.15 | |
1553 | dist = (origPos - missile.Position).magnitude | |
1554 | m.Scale = Vector3.new(0.5, 0.5, dist/2) | |
1555 | m.Offset = Vector3.new(0.5, 0.5, dist/2) | |
1556 | wait() | |
1557 | end | |
1558 | end | |
1559 | end)) | |
1560 | Script16.Name = "ArrowScript" | |
1561 | Script16.Parent = LocalScript13 | |
1562 | table.insert(cors,sandbox(Script16,function() | |
1563 | arrow = script.Parent | |
1564 | ||
1565 | local hitsound = Instance.new("Sound") | |
1566 | hitsound.SoundId = "http://www.roblox.com/asset/?id=137579113" | |
1567 | hitsound.Volume = 0.3 | |
1568 | hitsound.Pitch = math.random(11, 17)/10 | |
1569 | hitsound.Parent = arrow | |
1570 | ||
1571 | if arrow:FindFirstChild("creator") == nil then | |
1572 | arrow:WaitForChild("creator") | |
1573 | end | |
1574 | ||
1575 | damage = 25 | |
1576 | if arrow.Transparency ~= 0 then | |
1577 | damage = 25 | |
1578 | end | |
1579 | ||
1580 | local tag = arrow:FindFirstChild("creator") | |
1581 | local ourguy = tag.Value.Character:FindFirstChild("Humanoid") | |
1582 | ||
1583 | ||
1584 | function onTouched(hit) | |
1585 | humanoid = nil | |
1586 | if tag ~= nil and ourguy ~= nil then | |
1587 | if hit.Parent == nil then return end | |
1588 | if hit.Parent:findFirstChild("Humanoid") then | |
1589 | humanoid = hit.Parent:findFirstChild("Humanoid") | |
1590 | elseif hit.Parent.Parent:findFirstChild("Humanoid") then | |
1591 | humanoid = hit.Parent.Parent:findFirstChild("Humanoid") | |
1592 | end | |
1593 | if humanoid ~= nil then | |
1594 | if humanoid ~= ourguy then | |
1595 | stop = false | |
1596 | local ph = hit.Parent:FindFirstChild("PunchHurt") | |
1597 | if (ph ~= nil) then | |
1598 | if ph.Value == false then | |
1599 | stop = true | |
1600 | end | |
1601 | end | |
1602 | if stop == false then | |
1603 | hitsound:Play() | |
1604 | tagHumanoid(humanoid, vPlayer) | |
1605 | humanoid:TakeDamage(damage) | |
1606 | arrow:Destroy() | |
1607 | end | |
1608 | end | |
1609 | elseif hit.Anchored == true and hit.CanCollide == true then | |
1610 | arrow:Destroy() | |
1611 | end | |
1612 | end | |
1613 | end | |
1614 | ||
1615 | function tagHumanoid(humanoid) | |
1616 | local tag = arrow:findFirstChild("creator") | |
1617 | if tag ~= nil then | |
1618 | local new_tag = tag:clone() | |
1619 | new_tag.Parent = humanoid | |
1620 | game.Debris:AddItem(new_tag, 1) | |
1621 | end | |
1622 | end | |
1623 | ||
1624 | arrow.Touched:connect(onTouched) | |
1625 | ||
1626 | wait() | |
1627 | if arrow:FindFirstChild("FiredSound") then | |
1628 | arrow:FindFirstChild("FiredSound"):Play() | |
1629 | end | |
1630 | ||
1631 | wait(10) | |
1632 | arrow:Destroy() | |
1633 | end)) | |
1634 | Script16.Disabled = true | |
1635 | HopperBin17.Name = "Gear Second" | |
1636 | HopperBin17.Parent = LocalScript11 | |
1637 | LocalScript18.Parent = HopperBin17 | |
1638 | table.insert(cors,sandbox(LocalScript18,function() | |
1639 | bin = script.Parent | |
1640 | player = script.Parent.Parent.Parent | |
1641 | me = script.Parent.Parent.Parent | |
1642 | ||
1643 | enabled = true | |
1644 | ||
1645 | function Talk(msg) | |
1646 | game:GetService("Chat"):Chat(player.Character.Head, msg, Enum.ChatColor.Blue) | |
1647 | end | |
1648 | ||
1649 | function onButton1Down(mouse) | |
1650 | if not enabled then | |
1651 | return | |
1652 | end | |
1653 | ||
1654 | local player = owner | |
1655 | if player == nil then return end | |
1656 | ||
1657 | enabled = false | |
1658 | RightShoulder = me.Character.Torso["Right Shoulder"] | |
1659 | LeftShoulder = me.Character.Torso["Left Shoulder"] | |
1660 | Run = game:GetService("RunService") | |
1661 | for i = 1, 3 do | |
1662 | LeftShoulder.C0 = LeftShoulder.C0 *CFrame.Angles(0, 0, 1) | |
1663 | RightShoulder.C0 = RightShoulder.C0 *CFrame.Angles(0, 0, -1) | |
1664 | RightShoulder.C0 = RightShoulder.C0 *CFrame.Angles(0, 1.1, 0) | |
1665 | LeftShoulder.C0 = LeftShoulder.C0 *CFrame.Angles(0, -1.1, 0) | |
1666 | Run.Stepped:wait(0.005) | |
1667 | end | |
1668 | ------------------------------------------------------------------------------- | |
1669 | ||
1670 | --EDIT HERE-- | |
1671 | Talk("Gear Second!")-- you can change Gear Second or Gear 2nd | |
1672 | gg = Instance.new("Part") | |
1673 | gg.Anchored = true | |
1674 | gg.Shape = "Ball" --THIS ball will appear when transforming | |
1675 | gg.TopSurface = "Smooth" | |
1676 | gg.BottomSurface = "Smooth" | |
1677 | gg.BrickColor = BrickColor.new("Persimmon")--color of the bode when transforming | |
1678 | gg.CanCollide = false | |
1679 | gg.Parent = Workspace | |
1680 | gg.Size = Vector3.new(6, 6, 6) | |
1681 | p = Instance.new("PointLight", gg) | |
1682 | p.Brightness = 10 | |
1683 | p.Range = 10 | |
1684 | p.Color = Color3.new(255, 0, 0) | |
1685 | gg.CFrame = me.Character.Torso.CFrame*CFrame.new(0, 0, 0) | |
1686 | qq = Instance.new("SpecialMesh") | |
1687 | qq.Parent = gg | |
1688 | qq.Scale = Vector3.new(6, 6, 6) | |
1689 | qq.MeshType = ("Sphere") | |
1690 | for i = 1,6 do | |
1691 | qq.Scale = qq.Scale -Vector3.new(1 ,1 ,1) | |
1692 | wait(0.01) | |
1693 | end | |
1694 | gg:remove() | |
1695 | Hardening = me.Character["Body Colors"] | |
1696 | Hardening.LeftArmColor = BrickColor.new("Persimmon") --color | |
1697 | Hardening.RightArmColor = BrickColor.new("Persimmon")--of | |
1698 | Hardening.RightLegColor = BrickColor.new("Persimmon")--the | |
1699 | Hardening.LeftLegColor = BrickColor.new("Persimmon")--body | |
1700 | Hardening.TorsoColor = BrickColor.new("Persimmon")--when | |
1701 | Hardening. HeadColor = BrickColor.new("Persimmon")--transforming | |
1702 | j = me.Character.Head | |
1703 | k = me.Character.Torso | |
1704 | q = me.Character["Left Arm"] | |
1705 | w = me.Character["Left Leg"] | |
1706 | e = me.Character["Right Arm"] | |
1707 | r = me.Character["Right Leg"] | |
1708 | ||
1709 | me.Character.Humanoid.MaxHealth = 500-- 500 - 550 Health of human when transformed | |
1710 | me.Character.Humanoid.Health = 500----- SAME ONE | |
1711 | me.Character.Humanoid.WalkSpeed = 0 | |
1712 | wait(1.5) | |
1713 | me.Character.Humanoid.WalkSpeed = 20 --edit 17 - 100 it will increase speed | |
1714 | ||
1715 | ||
1716 | ||
1717 | ||
1718 | for i = 1, 3 do | |
1719 | LeftShoulder.C0 = LeftShoulder.C0 *CFrame.Angles(0, 1.1, 0) | |
1720 | RightShoulder.C0 = RightShoulder.C0 *CFrame.Angles(0, -1.1, 0) | |
1721 | LeftShoulder.C0 = LeftShoulder.C0 *CFrame.Angles(0, 0, -1) | |
1722 | RightShoulder.C0 = RightShoulder.C0 *CFrame.Angles(0, 0, 1) | |
1723 | Run.Stepped:wait(0.01) | |
1724 | end | |
1725 | wait(20) | |
1726 | enabled = true | |
1727 | end | |
1728 | ||
1729 | ||
1730 | enabled = true | |
1731 | function onS(mouse) | |
1732 | mouse.Button1Down:connect(function() onButton1Down(mouse) end) | |
1733 | end | |
1734 | bin.Selected:connect(onS) | |
1735 | ||
1736 | ||
1737 | end)) | |
1738 | HopperBin19.Name = "Gatling Gun" | |
1739 | HopperBin19.Parent = LocalScript11 | |
1740 | LocalScript20.Name = "Gatling" | |
1741 | LocalScript20.Parent = HopperBin19 | |
1742 | table.insert(cors,sandbox(LocalScript20,function() | |
1743 | COOLDOWN = 2 | |
1744 | ||
1745 | MAX_VELOCITY = 475 | |
1746 | MIN_VELOCITY = 400 | |
1747 | ||
1748 | AUTOFIRE = false | |
1749 | ||
1750 | SPREAD = 2 | |
1751 | ORIGIN_SPREAD = 0 | |
1752 | LOCK_FORWARD = false | |
1753 | ||
1754 | ANTI_GRAVITY = 1 | |
1755 | ||
1756 | FIRE_SOUND = "http://www.roblox.com/asset/?id=93011731" | |
1757 | ||
1758 | DESPAWN_TIME = 1 | |
1759 | ||
1760 | ||
1761 | wait(1) | |
1762 | ------------------------------ | |
1763 | missile = Instance.new("Part") | |
1764 | missile.Name = "Gomu" | |
1765 | missile.Transparency = 0 | |
1766 | missile.Reflectance = 0 | |
1767 | missile.CanCollide = false | |
1768 | missile.Shape = "Block" | |
1769 | missile.FormFactor = "Custom" | |
1770 | missile.Size = Vector3.new(2, 2, 2) | |
1771 | missile.Elasticity = 0 | |
1772 | missile.TopSurface = 0 | |
1773 | missile.BottomSurface = 0 | |
1774 | ||
1775 | while script:FindFirstChild("Mesh") == nil do wait() end | |
1776 | script.Mesh:clone().Parent = missile | |
1777 | ||
1778 | force = Instance.new("BodyForce") | |
1779 | force.force = Vector3.new(0,missile:GetMass() * 196.2 * ANTI_GRAVITY) | |
1780 | force.Parent = missile | |
1781 | ||
1782 | scriptName = "ArrowScript" | |
1783 | while script:FindFirstChild(scriptName) == nil do wait() end | |
1784 | script:FindFirstChild(scriptName):clone().Parent = missile | |
1785 | ||
1786 | ------------------------------ | |
1787 | ||
1788 | wait() | |
1789 | Tool = script.Parent | |
1790 | player = owner | |
1791 | while player.Character == nil do wait() end | |
1792 | char = player.Character | |
1793 | ||
1794 | function hidePart(part) | |
1795 | if part:FindFirstChild("AttackHide") == nil then | |
1796 | local hide = Instance.new("SpecialMesh") | |
1797 | hide.Name = "AttackHide" | |
1798 | hide.MeshType = "FileMesh" | |
1799 | hide.Scale = Vector3.new(0, 0, 0) | |
1800 | hide.Parent = part | |
1801 | game.Debris:AddItem(hide, DESPAWN_TIME/2) | |
1802 | end | |
1803 | end | |
1804 | ||
1805 | shooting = false | |
1806 | function fire(v) | |
1807 | if choosehand == 1 then | |
1808 | choosehand = 2 | |
1809 | arm = char:FindFirstChild("Right Arm") | |
1810 | else | |
1811 | choosehand = 1 | |
1812 | arm = char:FindFirstChild("Left Arm") | |
1813 | end | |
1814 | if arm == nil then return end | |
1815 | hidePart(arm) | |
1816 | ||
1817 | if not LOCK_FORWARD then | |
1818 | v_spreadx = math.random(-SPREAD, SPREAD) | |
1819 | v_spready = math.random(-SPREAD, SPREAD) | |
1820 | v_spreadz = math.random(-SPREAD, SPREAD) | |
1821 | v = v + Vector3.new(v_spreadx, v_spready, v_spreadz) | |
1822 | v = (v - arm.Position).unit | |
1823 | else | |
1824 | v = char:FindFirstChild("Torso").CFrame.lookVector | |
1825 | end | |
1826 | ||
1827 | o_spreadx = math.random(-ORIGIN_SPREAD, ORIGIN_SPREAD) | |
1828 | o_spready = math.random(-ORIGIN_SPREAD, ORIGIN_SPREAD) | |
1829 | o_spreadz = math.random(-ORIGIN_SPREAD, ORIGIN_SPREAD) | |
1830 | local spawnPos = arm.Position + Vector3.new(o_spreadx, o_spready, o_spreadz) | |
1831 | spawnPos = spawnPos + (v * 1) | |
1832 | ||
1833 | shot = missile:clone() | |
1834 | shot.BrickColor = arm.BrickColor | |
1835 | shot.Velocity = v * math.random(MIN_VELOCITY, MAX_VELOCITY) | |
1836 | local launch = spawnPos + 2 * v | |
1837 | shot.CFrame = CFrame.new(launch, launch + v) | |
1838 | ||
1839 | local creator_tag = Instance.new("ObjectValue") | |
1840 | creator_tag.Value = player | |
1841 | creator_tag.Name = "creator" | |
1842 | creator_tag.Parent = shot | |
1843 | ||
1844 | local firesound = Instance.new("Sound") | |
1845 | firesound.Name = "FiredSound" | |
1846 | firesound.SoundId = FIRE_SOUND | |
1847 | firesound.Volume = 1 | |
1848 | firesound.Pitch = math.random(8, 14)/10 | |
1849 | firesound.Parent = shot | |
1850 | ||
1851 | shot.Parent = game.Workspace | |
1852 | game.Debris:AddItem(shot, DESPAWN_TIME) | |
1853 | shot:FindFirstChild(scriptName).Disabled = false | |
1854 | end | |
1855 | ||
1856 | ||
1857 | enabled = true | |
1858 | gatlingmode = false | |
1859 | ||
1860 | function onButtonUp() | |
1861 | shooting = false | |
1862 | end | |
1863 | ||
1864 | function onDeselect() | |
1865 | stopped = true | |
1866 | end | |
1867 | ||
1868 | function gatlingON() | |
1869 | gatlingmode = true --if gatling mode | |
1870 | COOLDOWN = 0 | |
1871 | MAX_VELOCITY = 250 | |
1872 | MIN_VELOCITY = 200 | |
1873 | AUTOFIRE = true --it means if you click one time it will repeat | |
1874 | SPREAD = 3 | |
1875 | ORIGIN_SPREAD = 3 | |
1876 | DESPAWN_TIME = 0.9 | |
1877 | missile.Transparency = 0.4 | |
1878 | LOCK_FORWARD = true --change it to false if you want to back attack | |
1879 | end | |
1880 | ||
1881 | function gatlingOFF() | |
1882 | gatlingmode = false -- if one shot mode | |
1883 | COOLDOWN = 0.4 | |
1884 | MAX_VELOCITY = 475 | |
1885 | MIN_VELOCITY = 400 | |
1886 | AUTOFIRE = true --it means if you click one time it will repeat | |
1887 | SPREAD = 2 | |
1888 | ORIGIN_SPREAD = 0 | |
1889 | DESPAWN_TIME = 1 | |
1890 | missile.Transparency = 0 | |
1891 | LOCK_FORWARD = false | |
1892 | end | |
1893 | ||
1894 | function onSelected(mouse) | |
1895 | gatlingmode = true | |
1896 | gatlingON() | |
1897 | mouse.Icon = "rbxasset://textures\\GunCursor.png" | |
1898 | mouse.Button1Down:connect(function() | |
1899 | ||
1900 | if not enabled then return end | |
1901 | mouse.Icon = "rbxasset://textures\\GunWaitCursor.png" | |
1902 | enabled = false | |
1903 | shooting = true | |
1904 | stopped = false | |
1905 | while shooting do | |
1906 | hum = char:FindFirstChild("Humanoid") | |
1907 | if hum == nil then else | |
1908 | if hum.Health <= 0 then shooting = false end | |
1909 | fire(mouse.Hit.p) | |
1910 | ||
1911 | wait(COOLDOWN) | |
1912 | if not AUTOFIRE then | |
1913 | shooting = false | |
1914 | end | |
1915 | end | |
1916 | if AUTOFIRE then | |
1917 | wait(COOLDOWN) | |
1918 | end | |
1919 | if mouse then | |
1920 | mouse.Icon = "rbxasset://textures\\GunCursor.png" | |
1921 | end | |
1922 | enabled = true | |
1923 | end | |
1924 | end) | |
1925 | mouse.Button1Up:connect(function() onButtonUp() end) | |
1926 | mouse.KeyDown:connect(function(key2) | |
1927 | local key=string.byte(key2) | |
1928 | if key==string.byte("g") then | |
1929 | if gatlingmode == false then | |
1930 | gatlingON() | |
1931 | else | |
1932 | gatlingOFF() | |
1933 | end | |
1934 | end | |
1935 | end) | |
1936 | end | |
1937 | ||
1938 | script.Parent.Selected:connect(onSelected) | |
1939 | script.Parent.Deselected:connect(onDeselected) | |
1940 | ||
1941 | ||
1942 | ||
1943 | ||
1944 | ||
1945 | ||
1946 | end)) | |
1947 | BlockMesh21.Parent = LocalScript20 | |
1948 | Script22.Name = "Stretch" | |
1949 | Script22.Parent = BlockMesh21 | |
1950 | table.insert(cors,sandbox(Script22,function() | |
1951 | local missile = script.Parent.Parent | |
1952 | if missile:IsA("Part") then | |
1953 | origPos = missile.Position | |
1954 | m = script.Parent | |
1955 | for i = 1, 10 do | |
1956 | script.Parent.Parent.Velocity = script.Parent.Parent.Velocity * 0.8 | |
1957 | dist = (origPos - missile.Position).magnitude | |
1958 | m.Scale = Vector3.new(0.5, 0.5, dist/2) | |
1959 | m.Offset = Vector3.new(0.5, 0.5, dist/2) | |
1960 | wait() | |
1961 | end | |
1962 | wait(0.1) | |
1963 | script.Parent.Parent.Velocity = script.Parent.Parent.Velocity * -0.6 | |
1964 | while true do | |
1965 | script.Parent.Parent.Velocity = script.Parent.Parent.Velocity * 1.15 | |
1966 | dist = (origPos - missile.Position).magnitude | |
1967 | m.Scale = Vector3.new(0.5, 0.5, dist/2) | |
1968 | m.Offset = Vector3.new(0.5, 0.5, dist/2) | |
1969 | wait() | |
1970 | end | |
1971 | end | |
1972 | end)) | |
1973 | Script23.Name = "ArrowScript" | |
1974 | Script23.Parent = LocalScript20 | |
1975 | table.insert(cors,sandbox(Script23,function() | |
1976 | arrow = script.Parent | |
1977 | ||
1978 | local hitsound = Instance.new("Sound") | |
1979 | hitsound.SoundId = "http://www.roblox.com/asset/?id=137579113" | |
1980 | hitsound.Volume = 0.3 | |
1981 | hitsound.Pitch = math.random(11, 17)/10 | |
1982 | hitsound.Parent = arrow | |
1983 | ||
1984 | if arrow:FindFirstChild("creator") == nil then | |
1985 | arrow:WaitForChild("creator") | |
1986 | end | |
1987 | ||
1988 | damage = 40 | |
1989 | if arrow.Transparency ~= 0 then | |
1990 | damage = 40 | |
1991 | end | |
1992 | ||
1993 | local tag = arrow:FindFirstChild("creator") | |
1994 | local ourguy = tag.Value.Character:FindFirstChild("Humanoid") | |
1995 | ||
1996 | ||
1997 | function onTouched(hit) | |
1998 | humanoid = nil | |
1999 | if tag ~= nil and ourguy ~= nil then | |
2000 | if hit.Parent == nil then return end | |
2001 | if hit.Parent:findFirstChild("Humanoid") then | |
2002 | humanoid = hit.Parent:findFirstChild("Humanoid") | |
2003 | elseif hit.Parent.Parent:findFirstChild("Humanoid") then | |
2004 | humanoid = hit.Parent.Parent:findFirstChild("Humanoid") | |
2005 | end | |
2006 | if humanoid ~= nil then | |
2007 | if humanoid ~= ourguy then | |
2008 | stop = false | |
2009 | local ph = hit.Parent:FindFirstChild("PunchHurt") | |
2010 | if (ph ~= nil) then | |
2011 | if ph.Value == false then | |
2012 | stop = true | |
2013 | end | |
2014 | end | |
2015 | if stop == false then | |
2016 | hitsound:Play() | |
2017 | tagHumanoid(humanoid, vPlayer) | |
2018 | humanoid:TakeDamage(damage) | |
2019 | arrow:Destroy() | |
2020 | end | |
2021 | end | |
2022 | elseif hit.Anchored == true and hit.CanCollide == true then | |
2023 | arrow:Destroy() | |
2024 | end | |
2025 | end | |
2026 | end | |
2027 | ||
2028 | function tagHumanoid(humanoid) | |
2029 | local tag = arrow:findFirstChild("creator") | |
2030 | if tag ~= nil then | |
2031 | local new_tag = tag:clone() | |
2032 | new_tag.Parent = humanoid | |
2033 | game.Debris:AddItem(new_tag, 1) | |
2034 | end | |
2035 | end | |
2036 | ||
2037 | arrow.Touched:connect(onTouched) | |
2038 | ||
2039 | wait() | |
2040 | if arrow:FindFirstChild("FiredSound") then | |
2041 | arrow:FindFirstChild("FiredSound"):Play() | |
2042 | end | |
2043 | ||
2044 | wait(10) | |
2045 | arrow:Destroy() | |
2046 | end)) | |
2047 | Script23.Disabled = true | |
2048 | Script24.Name = "DevilFruitAttributes" | |
2049 | Script24.Parent = LocalScript11 | |
2050 | table.insert(cors,sandbox(Script24,function() | |
2051 | wait() | |
2052 | if script.Parent then | |
2053 | if not script.Parent:IsA("Script") or not script.Parent.Name == "StarterGear" then | |
2054 | local debris = game:GetService("Debris") | |
2055 | local backpack = script.Parent | |
2056 | local player = backpack.Parent | |
2057 | while player.Character == nil do wait() end | |
2058 | local character = player.Character | |
2059 | if character then | |
2060 | while character:FindFirstChild("Humanoid") == nil do wait() end | |
2061 | local hum = character:FindFirstChild("Humanoid") | |
2062 | ||
2063 | -- Logia | |
2064 | local charparts = character:GetChildren() | |
2065 | for i = 1, #charparts do | |
2066 | local charpart = charparts[i] | |
2067 | if charpart:IsA("BasePart") then | |
2068 | charpart.Touched:connect(function(hit) | |
2069 | if charpart:FindFirstChild("Hide") then return end | |
2070 | local stop = true | |
2071 | if hit ~= nil then | |
2072 | if hit.Parent ~= nil then | |
2073 | if hit:FindFirstChild("creator") or hit.Parent:FindFirstChild("creator") then | |
2074 | stop = false | |
2075 | elseif hit.Parent:FindFirstChild("Humanoid") then | |
2076 | if hit.Parent:FindFirstChild("Humanoid") ~= hum then | |
2077 | stop = false | |
2078 | end | |
2079 | end | |
2080 | end | |
2081 | end | |
2082 | if stop then return end | |
2083 | local hidemesh = Instance.new("SpecialMesh") | |
2084 | hidemesh.Name = "Hide" | |
2085 | hidemesh.MeshType = "FileMesh" | |
2086 | hidemesh.MeshId = "" | |
2087 | hidemesh.Scale = Vector3.new(0, 0, 0) | |
2088 | hidemesh.Parent = charpart | |
2089 | debris:AddItem(hidemesh, 1.5) | |
2090 | ||
2091 | local bodyeffect = Instance.new("Part") | |
2092 | bodyeffect.Name = "BodyEffect" | |
2093 | bodyeffect.Transparency = 0.3 | |
2094 | bodyeffect.CanCollide = false | |
2095 | bodyeffect.FormFactor = "Custom" | |
2096 | bodyeffect.Size = Vector3.new(0.2, 0.2, 0.2) | |
2097 | bodyeffect.TopSurface = "Smooth" | |
2098 | bodyeffect.BottomSurface = "Smooth" | |
2099 | bodyeffect.CFrame = charpart.CFrame | |
2100 | ||
2101 | local mesh = Instance.new("SpecialMesh") | |
2102 | mesh.MeshId = "http://www.roblox.com/asset?id=165709404" | |
2103 | mesh.TextureId = "http://www.roblox.com/asset?id=165709478" | |
2104 | mesh.Scale = Vector3.new(3, 3, 3) | |
2105 | mesh.Parent = bodyeffect | |
2106 | ||
2107 | local sound = Instance.new("Sound") | |
2108 | sound.SoundId = "http://www.roblox.com/asset/?id=31759626" | |
2109 | sound.Volume = 0.3 | |
2110 | sound.Pitch = math.random(9, 11)/10 | |
2111 | sound.Parent = bodyeffect | |
2112 | ||
2113 | local light = Instance.new("PointLight") | |
2114 | light.Range = 5 | |
2115 | light.Color = Color3.new(1, 1, 0) | |
2116 | light.Parent = bodyeffect | |
2117 | ||
2118 | bodyeffect.Parent = charpart.Parent | |
2119 | ||
2120 | sound:Play() | |
2121 | ||
2122 | local weld = Instance.new("ManualWeld") | |
2123 | weld.Part0 = bodyeffect | |
2124 | weld.Part1 = charpart | |
2125 | weld.C1 = charpart.CFrame:inverse() * bodyeffect.CFrame | |
2126 | weld.Parent = bodyeffect | |
2127 | ||
2128 | debris:AddItem(bodyeffect, 1.5) | |
2129 | end) | |
2130 | end | |
2131 | end | |
2132 | end | |
2133 | end | |
2134 | end | |
2135 | end)) | |
2136 | StringValue25.Name = "DevilFruitType" | |
2137 | StringValue25.Parent = Tool0 | |
2138 | StringValue25.Value = "Rubber" | |
2139 | Part26.Name = "Leafs" | |
2140 | Part26.Parent = Tool0 | |
2141 | Part26.CFrame = CFrame.new(48.6795959, 1.326491, 19.1532822, -4.4091145e-08, -7.30506144e-08, -1, 1, -4.51691449e-08, -4.36030163e-08, -4.23751771e-08, -1, -7.30506144e-08) | |
2142 | Part26.Orientation = Vector3.new(0, -90, 90) | |
2143 | Part26.Position = Vector3.new(48.6795959, 1.326491, 19.1532822) | |
2144 | Part26.Rotation = Vector3.new(-90, -90, 0) | |
2145 | Part26.Color = Color3.new(1, 0.34902, 0.34902) | |
2146 | Part26.Size = Vector3.new(0.410000086, 0.329999983, 0.200000048) | |
2147 | Part26.Anchored = true | |
2148 | Part26.BrickColor = BrickColor.new("Persimmon") | |
2149 | Part26.Material = Enum.Material.SmoothPlastic | |
2150 | Part26.brickColor = BrickColor.new("Persimmon") | |
2151 | Part26.FormFactor = Enum.FormFactor.Custom | |
2152 | Part26.formFactor = Enum.FormFactor.Custom | |
2153 | SpecialMesh27.Parent = Part26 | |
2154 | SpecialMesh27.Scale = Vector3.new(1, 0.200000003, 0.200000003) | |
2155 | SpecialMesh27.MeshType = Enum.MeshType.Cylinder | |
2156 | Part28.Name = "Leafs" | |
2157 | Part28.Parent = Tool0 | |
2158 | Part28.CFrame = CFrame.new(48.6795998, 1.51648796, 19.1482849, -1.16759111e-07, 4.34269509e-10, -1, -1.52271241e-07, -1, 1.92770244e-11, -1, 1.49477273e-07, -2.93402991e-08) | |
2159 | Part28.Orientation = Vector3.new(0, -90, -180) | |
2160 | Part28.Position = Vector3.new(48.6795998, 1.51648796, 19.1482849) | |
2161 | Part28.Rotation = Vector3.new(180, -90, 0) | |
2162 | Part28.Color = Color3.new(0.411765, 0.25098, 0.156863) | |
2163 | Part28.Size = Vector3.new(0.640000045, 0.329999983, 0.200000048) | |
2164 | Part28.Anchored = true | |
2165 | Part28.BrickColor = BrickColor.new("Reddish brown") | |
2166 | Part28.Material = Enum.Material.SmoothPlastic | |
2167 | Part28.brickColor = BrickColor.new("Reddish brown") | |
2168 | Part28.FormFactor = Enum.FormFactor.Custom | |
2169 | Part28.formFactor = Enum.FormFactor.Custom | |
2170 | SpecialMesh29.Parent = Part28 | |
2171 | SpecialMesh29.Scale = Vector3.new(1, 0.200000003, 0.200000003) | |
2172 | SpecialMesh29.MeshType = Enum.MeshType.Cylinder | |
2173 | Part30.Name = "Leafs" | |
2174 | Part30.Parent = Tool0 | |
2175 | Part30.CFrame = CFrame.new(48.6795998, 1.543787, 18.7326698, -1.14498107e-07, -1.83335942e-08, -1, 0.258818775, -0.965925932, -1.1264305e-08, -0.965925932, -0.258818686, -3.08291419e-08) | |
2176 | Part30.Orientation = Vector3.new(0, -90, 165) | |
2177 | Part30.Position = Vector3.new(48.6795998, 1.543787, 18.7326698) | |
2178 | Part30.Rotation = Vector3.new(-165, -90, 0) | |
2179 | Part30.Color = Color3.new(0.411765, 0.25098, 0.156863) | |
2180 | Part30.Size = Vector3.new(0.200000077, 0.329999983, 0.200000048) | |
2181 | Part30.Anchored = true | |
2182 | Part30.BrickColor = BrickColor.new("Reddish brown") | |
2183 | Part30.Material = Enum.Material.SmoothPlastic | |
2184 | Part30.brickColor = BrickColor.new("Reddish brown") | |
2185 | Part30.FormFactor = Enum.FormFactor.Custom | |
2186 | Part30.formFactor = Enum.FormFactor.Custom | |
2187 | SpecialMesh31.Parent = Part30 | |
2188 | SpecialMesh31.Scale = Vector3.new(1, 0.200000003, 0.200000003) | |
2189 | SpecialMesh31.MeshType = Enum.MeshType.Cylinder | |
2190 | for i,v in pairs(mas:GetChildren()) do | |
2191 | v.Parent = workspace | |
2192 | pcall(function() v:MakeJoints() end) | |
2193 | end | |
2194 | mas:Destroy() | |
2195 | for i,v in pairs(cors) do | |
2196 | spawn(function() | |
2197 | pcall(v) | |
2198 | end) | |
2199 | end | |
2200 | ||
2201 | ---------------------------------------------------------------- | |
2202 | --//Budha-Budha no mi\\-- | |
2203 | ---------------------------------------------------------------- | |
2204 | ||
2205 | if game:GetService("RunService"):IsClient() then error("Script must be server-side in order to work; use h/ and not hl/") end | |
2206 | local Player,game,owner = owner,game | |
2207 | local RealPlayer = Player | |
2208 | do | |
2209 | local rp = RealPlayer | |
2210 | script.Parent = rp.Character | |
2211 | ||
2212 | --RemoteEvent for communicating | |
2213 | local Event = Instance.new("RemoteEvent") | |
2214 | Event.Name = "UserInput_Event" | |
2215 | ||
2216 | --Fake event to make stuff like Mouse.KeyDown work | |
2217 | local function fakeEvent() | |
2218 | local t = {_fakeEvent=true,Functions={},Connect=function(self,f)table.insert(self.Functions,f) end} | |
2219 | t.connect = t.Connect | |
2220 | return t | |
2221 | end | |
2222 | ||
2223 | --Creating fake input objects with fake variables | |
2224 | local m = {Target=nil,Hit=CFrame.new(),KeyUp=fakeEvent(),KeyDown=fakeEvent(),Button1Up=fakeEvent(),Button1Down=fakeEvent()} | |
2225 | local UIS = {InputBegan=fakeEvent(),InputEnded=fakeEvent()} | |
2226 | local CAS = {Actions={},BindAction=function(self,name,fun,touch,...) | |
2227 | CAS.Actions[name] = fun and {Name=name,Function=fun,Keys={...}} or nil | |
2228 | end} | |
2229 | --Merged 2 functions into one by checking amount of arguments | |
2230 | CAS.UnbindAction = CAS.BindAction | |
2231 | ||
2232 | --This function will trigger the events that have been :Connect()'ed | |
2233 | local function te(self,ev,...) | |
2234 | local t = m[ev] | |
2235 | if t and t._fakeEvent then | |
2236 | for _,f in pairs(t.Functions) do | |
2237 | f(...) | |
2238 | end | |
2239 | end | |
2240 | end | |
2241 | m.TrigEvent = te | |
2242 | UIS.TrigEvent = te | |
2243 | ||
2244 | Event.OnServerEvent:Connect(function(plr,io) | |
2245 | if plr~=rp then return end | |
2246 | m.Target = io.Target | |
2247 | m.Hit = io.Hit | |
2248 | if not io.isMouse then | |
2249 | local b = io.UserInputState == Enum.UserInputState.Begin | |
2250 | if io.UserInputType == Enum.UserInputType.MouseButton1 then | |
2251 | return m:TrigEvent(b and "Button1Down" or "Button1Up") | |
2252 | end | |
2253 | for _,t in pairs(CAS.Actions) do | |
2254 | for _,k in pairs(t.Keys) do | |
2255 | if k==io.KeyCode then | |
2256 | t.Function(t.Name,io.UserInputState,io) | |
2257 | end | |
2258 | end | |
2259 | end | |
2260 | m:TrigEvent(b and "KeyDown" or "KeyUp",io.KeyCode.Name:lower()) | |
2261 | UIS:TrigEvent(b and "InputBegan" or "InputEnded",io,false) | |
2262 | end | |
2263 | end) | |
2264 | Event.Parent = NLS([==[ | |
2265 | local Player = game:GetService("Players").LocalPlayer | |
2266 | local Event = script:WaitForChild("UserInput_Event") | |
2267 | ||
2268 | local Mouse = Player:GetMouse() | |
2269 | local UIS = game:GetService("UserInputService") | |
2270 | local input = function(io,a) | |
2271 | if a then return end | |
2272 | --Since InputObject is a client-side instance, we create and pass table instead | |
2273 | Event:FireServer({KeyCode=io.KeyCode,UserInputType=io.UserInputType,UserInputState=io.UserInputState,Hit=Mouse.Hit,Target=Mouse.Target}) | |
2274 | end | |
2275 | UIS.InputBegan:Connect(input) | |
2276 | UIS.InputEnded:Connect(input) | |
2277 | ||
2278 | local h,t | |
2279 | --Give the server mouse data 30 times every second, but only if the values changed | |
2280 | --If player is not moving their mouse, client won't fire events | |
2281 | while wait(1/30) do | |
2282 | if h~=Mouse.Hit or t~=Mouse.Target then | |
2283 | h,t=Mouse.Hit,Mouse.Target | |
2284 | Event:FireServer({isMouse=true,Target=t,Hit=h}) | |
2285 | end | |
2286 | end]==],Player.Character) | |
2287 | ||
2288 | ----Sandboxed game object that allows the usage of client-side methods and services | |
2289 | --Real game object | |
2290 | local _rg = game | |
2291 | ||
2292 | --Metatable for fake service | |
2293 | local fsmt = { | |
2294 | __index = function(self,k) | |
2295 | local s = rawget(self,"_RealService") | |
2296 | if s then return s[k] end | |
2297 | end, | |
2298 | __newindex = function(self,k,v) | |
2299 | local s = rawget(self,"_RealService") | |
2300 | if s then s[k]=v end | |
2301 | end, | |
2302 | __call = function(self,...) | |
2303 | local s = rawget(self,"_RealService") | |
2304 | if s then return s(...) end | |
2305 | end | |
2306 | } | |
2307 | local function FakeService(t,RealService) | |
2308 | t._RealService = typeof(RealService)=="string" and _rg:GetService(RealService) or RealService | |
2309 | return setmetatable(t,fsmt) | |
2310 | end | |
2311 | ||
2312 | --Fake game object | |
2313 | local g = { | |
2314 | GetService = function(self,s) | |
2315 | return self[s] | |
2316 | end, | |
2317 | Players = FakeService({ | |
2318 | LocalPlayer = FakeService({GetMouse=function(self)return m end},Player) | |
2319 | },"Players"), | |
2320 | UserInputService = FakeService(UIS,"UserInputService"), | |
2321 | ContextActionService = FakeService(CAS,"ContextActionService"), | |
2322 | } | |
2323 | rawset(g.Players,"localPlayer",g.Players.LocalPlayer) | |
2324 | g.service = g.GetService | |
2325 | ||
2326 | g.RunService = FakeService({ | |
2327 | RenderStepped = _rg:GetService("RunService").Heartbeat, | |
2328 | BindToRenderStep = function(self,name,_,fun) | |
2329 | self._btrs[name] = self.Heartbeat:Connect(fun) | |
2330 | end, | |
2331 | UnbindFromRenderStep = function(self,name) | |
2332 | self._btrs[name]:Disconnect() | |
2333 | end, | |
2334 | },"RunService") | |
2335 | ||
2336 | setmetatable(g,{ | |
2337 | __index=function(self,s) | |
2338 | return _rg:GetService(s) or typeof(_rg[s])=="function" | |
2339 | and function(_,...)return _rg[s](_rg,...)end or _rg[s] | |
2340 | end, | |
2341 | __newindex = fsmt.__newindex, | |
2342 | __call = fsmt.__call | |
2343 | }) | |
2344 | --Changing owner to fake player object to support owner:GetMouse() | |
2345 | game,owner = g,g.Players.LocalPlayer | |
2346 | end | |
2347 | ||
2348 | Player = owner | |
2349 | PlayerGui = Player.PlayerGui | |
2350 | Cam = workspace.CurrentCamera | |
2351 | Backpack = Player.Backpack | |
2352 | Character = Player.Character | |
2353 | Humanoid = Character.Humanoid | |
2354 | Mouse = Player:GetMouse() | |
2355 | RootPart = Character["HumanoidRootPart"] | |
2356 | Torso = Character["Torso"] | |
2357 | Head = Character["Head"] | |
2358 | RightArm = Character["Right Arm"] | |
2359 | LeftArm = Character["Left Arm"] | |
2360 | RightLeg = Character["Right Leg"] | |
2361 | LeftLeg = Character["Left Leg"] | |
2362 | RootJoint = RootPart["RootJoint"] | |
2363 | Neck = Torso["Neck"] | |
2364 | RightShoulder = Torso["Right Shoulder"] | |
2365 | LeftShoulder = Torso["Left Shoulder"] | |
2366 | RightHip = Torso["Right Hip"] | |
2367 | LeftHip = Torso["Left Hip"] | |
2368 | ||
2369 | removeuseless = game:GetService("Debris") | |
2370 | laff = Instance.new("Sound",Head) | |
2371 | tauntdebounce = false | |
2372 | Character = Player.Character | |
2373 | Humanoid = Character.Humanoid | |
2374 | --------- | |
2375 | plr = game.Players.LocalPlayer | |
2376 | chara = plr.Character | |
2377 | mouse = plr:GetMouse() | |
2378 | Create = Instance.new | |
2379 | Huge = math.huge | |
2380 | ||
2381 | Player = game:GetService("Players").LocalPlayer | |
2382 | PlayerGui = Player.PlayerGui | |
2383 | Cam = workspace.CurrentCamera | |
2384 | Backpack = Player.Backpack | |
2385 | Character = Player.Character | |
2386 | char = Player.Character | |
2387 | Humanoid = Character.Humanoid | |
2388 | Mouse = Player:GetMouse() | |
2389 | RootPart = Character["HumanoidRootPart"] | |
2390 | Torso = Character["Torso"] | |
2391 | Head = Character["Head"] | |
2392 | RightArm = Character["Right Arm"] | |
2393 | LeftArm = Character["Left Arm"] | |
2394 | RightLeg = Character["Right Leg"] | |
2395 | LeftLeg = Character["Left Leg"] | |
2396 | RootJoint = RootPart["RootJoint"] | |
2397 | Neck = Torso["Neck"] | |
2398 | RightShoulder = Torso["Right Shoulder"] | |
2399 | LeftShoulder = Torso["Left Shoulder"] | |
2400 | RightHip = Torso["Right Hip"] | |
2401 | LeftHip = Torso["Left Hip"] | |
2402 | ||
2403 | local Orin = "http://www.roblox.com/asset/?id=1065951398" | |
2404 | Head.face.Texture = Orin | |
2405 | function weld(a, b, acf) | |
2406 | local w = Instance.new("Weld", a) | |
2407 | w.Part0 = a | |
2408 | w.Part1 = b | |
2409 | w.C0 = acf | |
2410 | end | |
2411 | -------------------------------- | |
2412 | char.Head.face.Texture = "rbxassetid://0" | |
2413 | -------------------------------- | |
2414 | ||
2415 | ------------------------------------------------------- | |
2416 | wait(0.2) | |
2417 | local plr = game:service'Players'.LocalPlayer | |
2418 | local char = plr.Character | |
2419 | local hum = char.Humanoid | |
2420 | local hed = char.Head | |
2421 | local root = char.HumanoidRootPart | |
2422 | local rootj = root.RootJoint | |
2423 | local tors = char.Torso | |
2424 | local ra = char["Right Arm"] | |
2425 | local la = char["Left Arm"] | |
2426 | local rl = char["Right Leg"] | |
2427 | local ll = char["Left Leg"] | |
2428 | local neck = tors["Neck"] | |
2429 | local mouse = plr:GetMouse() | |
2430 | local RootCF = CFrame.fromEulerAnglesXYZ(-1.57, 0, 3.14) | |
2431 | local RHCF = CFrame.fromEulerAnglesXYZ(0, 1.6, 0) | |
2432 | local LHCF = CFrame.fromEulerAnglesXYZ(0, -1.6, 0) | |
2433 | local maincolor = BrickColor.new("Plum") | |
2434 | ||
2435 | ------------------------------------------------------- | |
2436 | --Start Good Stuff-- | |
2437 | ------------------------------------------------------- | |
2438 | cam = game.Workspace.CurrentCamera | |
2439 | CF = CFrame.new | |
2440 | angles = CFrame.Angles | |
2441 | attack = false | |
2442 | Euler = CFrame.fromEulerAnglesXYZ | |
2443 | Rad = math.rad | |
2444 | IT = Instance.new | |
2445 | BrickC = BrickColor.new | |
2446 | Cos = math.cos | |
2447 | Acos = math.acos | |
2448 | Sin = math.sin | |
2449 | Asin = math.asin | |
2450 | Abs = math.abs | |
2451 | Mrandom = math.random | |
2452 | Floor = math.floor | |
2453 | ------------------------------------------------------- | |
2454 | --End Good Stuff-- | |
2455 | ------------------------------------------------------- | |
2456 | ------------------------------------------------------- | |
2457 | --Start HeartBeat-- | |
2458 | ------------------------------------------------------- | |
2459 | ArtificialHB = Instance.new("BindableEvent", script) | |
2460 | ArtificialHB.Name = "Heartbeat" | |
2461 | script:WaitForChild("Heartbeat") | |
2462 | ||
2463 | frame = 1 / 60 | |
2464 | tf = 0 | |
2465 | allowframeloss = false | |
2466 | tossremainder = false | |
2467 | ||
2468 | ||
2469 | lastframe = tick() | |
2470 | script.Heartbeat:Fire() | |
2471 | ||
2472 | ||
2473 | game:GetService("RunService").Heartbeat:connect(function(s, p) | |
2474 | tf = tf + s | |
2475 | if tf >= frame then | |
2476 | if allowframeloss then | |
2477 | script.Heartbeat:Fire() | |
2478 | lastframe = tick() | |
2479 | else | |
2480 | for i = 1, math.floor(tf / frame) do | |
2481 | script.Heartbeat:Fire() | |
2482 | end | |
2483 | lastframe = tick() | |
2484 | end | |
2485 | if tossremainder then | |
2486 | tf = 0 | |
2487 | else | |
2488 | tf = tf - frame * math.floor(tf / frame) | |
2489 | end | |
2490 | end | |
2491 | end) | |
2492 | ------------------------------------------------------- | |
2493 | --End HeartBeat-- | |
2494 | ------------------------------------------------------- | |
2495 | ||
2496 | ------------------------------------------------------- | |
2497 | --Start Important Functions-- | |
2498 | ------------------------------------------------------- | |
2499 | function swait(num) | |
2500 | if num == 0 or num == nil then | |
2501 | game:service("RunService").Stepped:wait(0) | |
2502 | else | |
2503 | for i = 0, num do | |
2504 | game:service("RunService").Stepped:wait(0) | |
2505 | end | |
2506 | end | |
2507 | end | |
2508 | function thread(f) | |
2509 | coroutine.resume(coroutine.create(f)) | |
2510 | end | |
2511 | function clerp(a, b, t) | |
2512 | local qa = { | |
2513 | QuaternionFromCFrame(a) | |
2514 | } | |
2515 | local qb = { | |
2516 | QuaternionFromCFrame(b) | |
2517 | } | |
2518 | local ax, ay, az = a.x, a.y, a.z | |
2519 | local bx, by, bz = b.x, b.y, b.z | |
2520 | local _t = 1 - t | |
2521 | return QuaternionToCFrame(_t * ax + t * bx, _t * ay + t * by, _t * az + t * bz, QuaternionSlerp(qa, qb, t)) | |
2522 | end | |
2523 | function QuaternionFromCFrame(cf) | |
2524 | local mx, my, mz, m00, m01, m02, m10, m11, m12, m20, m21, m22 = cf:components() | |
2525 | local trace = m00 + m11 + m22 | |
2526 | if trace > 0 then | |
2527 | local s = math.sqrt(1 + trace) | |
2528 | local recip = 0.5 / s | |
2529 | return (m21 - m12) * recip, (m02 - m20) * recip, (m10 - m01) * recip, s * 0.5 | |
2530 | else | |
2531 | local i = 0 | |
2532 | if m00 < m11 then | |
2533 | i = 1 | |
2534 | end | |
2535 | if m22 > (i == 0 and m00 or m11) then | |
2536 | i = 2 | |
2537 | end | |
2538 | if i == 0 then | |
2539 | local s = math.sqrt(m00 - m11 - m22 + 1) | |
2540 | local recip = 0.5 / s | |
2541 | return 0.5 * s, (m10 + m01) * recip, (m20 + m02) * recip, (m21 - m12) * recip | |
2542 | elseif i == 1 then | |
2543 | local s = math.sqrt(m11 - m22 - m00 + 1) | |
2544 | local recip = 0.5 / s | |
2545 | return (m01 + m10) * recip, 0.5 * s, (m21 + m12) * recip, (m02 - m20) * recip | |
2546 | elseif i == 2 then | |
2547 | local s = math.sqrt(m22 - m00 - m11 + 1) | |
2548 | local recip = 0.5 / s | |
2549 | return (m02 + m20) * recip, (m12 + m21) * recip, 0.5 * s, (m10 - m01) * recip | |
2550 | end | |
2551 | end | |
2552 | end | |
2553 | function QuaternionToCFrame(px, py, pz, x, y, z, w) | |
2554 | local xs, ys, zs = x + x, y + y, z + z | |
2555 | local wx, wy, wz = w * xs, w * ys, w * zs | |
2556 | local xx = x * xs | |
2557 | local xy = x * ys | |
2558 | local xz = x * zs | |
2559 | local yy = y * ys | |
2560 | local yz = y * zs | |
2561 | local zz = z * zs | |
2562 | return CFrame.new(px, py, pz, 1 - (yy + zz), xy - wz, xz + wy, xy + wz, 1 - (xx + zz), yz - wx, xz - wy, yz + wx, 1 - (xx + yy)) | |
2563 | end | |
2564 | function QuaternionSlerp(a, b, t) | |
2565 | local cosTheta = a[1] * b[1] + a[2] * b[2] + a[3] * b[3] + a[4] * b[4] | |
2566 | local startInterp, finishInterp | |
2567 | if cosTheta >= 1.0E-4 then | |
2568 | if 1 - cosTheta > 1.0E-4 then | |
2569 | local theta = math.acos(cosTheta) | |
2570 | local invSinTheta = 1 / Sin(theta) | |
2571 | startInterp = Sin((1 - t) * theta) * invSinTheta | |
2572 | finishInterp = Sin(t * theta) * invSinTheta | |
2573 | else | |
2574 | startInterp = 1 - t | |
2575 | finishInterp = t | |
2576 | end | |
2577 | elseif 1 + cosTheta > 1.0E-4 then | |
2578 | local theta = math.acos(-cosTheta) | |
2579 | local invSinTheta = 1 / Sin(theta) | |
2580 | startInterp = Sin((t - 1) * theta) * invSinTheta | |
2581 | finishInterp = Sin(t * theta) * invSinTheta | |
2582 | else | |
2583 | startInterp = t - 1 | |
2584 | finishInterp = t | |
2585 | end | |
2586 | return a[1] * startInterp + b[1] * finishInterp, a[2] * startInterp + b[2] * finishInterp, a[3] * startInterp + b[3] * finishInterp, a[4] * startInterp + b[4] * finishInterp | |
2587 | end | |
2588 | function rayCast(Position, Direction, Range, Ignore) | |
2589 | return game:service("Workspace"):FindPartOnRay(Ray.new(Position, Direction.unit * (Range or 999.999)), Ignore) | |
2590 | end | |
2591 | local RbxUtility = LoadLibrary("RbxUtility") | |
2592 | local Create = RbxUtility.Create | |
2593 | ||
2594 | ------------------------------------------------------- | |
2595 | --Start Damage Function-- | |
2596 | ------------------------------------------------------- | |
2597 | function Damage(Part, hit, minim, maxim, knockback, Type, Property, Delay, HitSound, HitPitch) | |
2598 | if hit.Parent == nil then | |
2599 | return | |
2600 | end | |
2601 | local h = hit.Parent:FindFirstChildOfClass("Humanoid") | |
2602 | for _, v in pairs(hit.Parent:children()) do | |
2603 | if v:IsA("Humanoid") then | |
2604 | h = v | |
2605 | end | |
2606 | end | |
2607 | if h ~= nil and hit.Parent.Name ~= char.Name and hit.Parent:FindFirstChild("UpperTorso") ~= nil then | |
2608 | ||
2609 | hit.Parent:FindFirstChild("Head"):BreakJoints() | |
2610 | end | |
2611 | ||
2612 | if h ~= nil and hit.Parent.Name ~= char.Name and hit.Parent:FindFirstChild("Torso") ~= nil then | |
2613 | if hit.Parent:findFirstChild("DebounceHit") ~= nil then | |
2614 | if hit.Parent.DebounceHit.Value == true then | |
2615 | return | |
2616 | end | |
2617 | end | |
2618 | if insta == true then | |
2619 | hit.Parent:FindFirstChild("Head"):BreakJoints() | |
2620 | end | |
2621 | local c = Create("ObjectValue"){ | |
2622 | Name = "creator", | |
2623 | Value = game:service("Players").LocalPlayer, | |
2624 | Parent = h, | |
2625 | } | |
2626 | game:GetService("Debris"):AddItem(c, .5) | |
2627 | if HitSound ~= nil and HitPitch ~= nil then | |
2628 | CFuncs.Sound.Create(HitSound, hit, 1, HitPitch) | |
2629 | end | |
2630 | local Damage = math.random(minim, maxim) | |
2631 | local blocked = false | |
2632 | local block = hit.Parent:findFirstChild("Block") | |
2633 | if block ~= nil then | |
2634 | if block.className == "IntValue" then | |
2635 | if block.Value > 0 then | |
2636 | blocked = true | |
2637 | block.Value = block.Value - 1 | |
2638 | print(block.Value) | |
2639 | end | |
2640 | end | |
2641 | end | |
2642 | if blocked == false then | |
2643 | h.Health = h.Health - Damage | |
2644 | ShowDamage((Part.CFrame * CFrame.new(0, 0, (Part.Size.Z / 2)).p + Vector3.new(0, 1.5, 0)), -Damage, 1.5, tors.BrickColor.Color) | |
2645 | else | |
2646 | h.Health = h.Health - (Damage / 2) | |
2647 | ShowDamage((Part.CFrame * CFrame.new(0, 0, (Part.Size.Z / 2)).p + Vector3.new(0, 1.5, 0)), -Damage, 1.5, tors.BrickColor.Color) | |
2648 | end | |
2649 | if Type == "Knockdown" then | |
2650 | local hum = hit.Parent.Humanoid | |
2651 | hum.PlatformStand = true | |
2652 | coroutine.resume(coroutine.create(function(HHumanoid) | |
2653 | swait(1) | |
2654 | HHumanoid.PlatformStand = false | |
2655 | end), hum) | |
2656 | local angle = (hit.Position - (Property.Position + Vector3.new(0, 0, 0))).unit | |
2657 | local bodvol = Create("BodyVelocity"){ | |
2658 | velocity = angle * knockback, | |
2659 | P = 5000, | |
2660 | maxForce = Vector3.new(8e+003, 8e+003, 8e+003), | |
2661 | Parent = hit, | |
2662 | } | |
2663 | local rl = Create("BodyAngularVelocity"){ | |
2664 | P = 3000, | |
2665 | maxTorque = Vector3.new(500000, 500000, 500000) * 50000000000000, | |
2666 | angularvelocity = Vector3.new(math.random(-10, 10), math.random(-10, 10), math.random(-10, 10)), | |
2667 | Parent = hit, | |
2668 | } | |
2669 | game:GetService("Debris"):AddItem(bodvol, .5) | |
2670 | game:GetService("Debris"):AddItem(rl, .5) | |
2671 | elseif Type == "Normal" then | |
2672 | local vp = Create("BodyVelocity"){ | |
2673 | P = 500, | |
2674 | maxForce = Vector3.new(math.huge, 0, math.huge), | |
2675 | velocity = Property.CFrame.lookVector * knockback + Property.Velocity / 1.05, | |
2676 | } | |
2677 | if knockback > 0 then | |
2678 | vp.Parent = hit.Parent.Torso | |
2679 | end | |
2680 | game:GetService("Debris"):AddItem(vp, .5) | |
2681 | elseif Type == "Up" then | |
2682 | local bodyVelocity = Create("BodyVelocity"){ | |
2683 | velocity = Vector3.new(0, 20, 0), | |
2684 | P = 5000, | |
2685 | maxForce = Vector3.new(8e+003, 8e+003, 8e+003), | |
2686 | Parent = hit, | |
2687 | } | |
2688 | game:GetService("Debris"):AddItem(bodyVelocity, .5) | |
2689 | elseif Type == "DarkUp" then | |
2690 | coroutine.resume(coroutine.create(function() | |
2691 | for i = 0, 1, 0.1 do | |
2692 | swait() | |
2693 | Effects.Block.Create(BrickColor.new("Really red"), hit.Parent.Torso.CFrame, 5, 5, 5, 1, 1, 1, .08, 1) | |
2694 | end | |
2695 | end)) | |
2696 | local bodyVelocity = Create("BodyVelocity"){ | |
2697 | velocity = Vector3.new(0, 20, 0), | |
2698 | P = 5000, | |
2699 | maxForce = Vector3.new(8e+003, 8e+003, 8e+003), | |
2700 | Parent = hit, | |
2701 | } | |
2702 | game:GetService("Debris"):AddItem(bodyVelocity, 1) | |
2703 | elseif Type == "Snare" then | |
2704 | local bp = Create("BodyPosition"){ | |
2705 | P = 2000, | |
2706 | D = 100, | |
2707 | maxForce = Vector3.new(math.huge, math.huge, math.huge), | |
2708 | position = hit.Parent.Torso.Position, | |
2709 | Parent = hit.Parent.Torso, | |
2710 | } | |
2711 | game:GetService("Debris"):AddItem(bp, 1) | |
2712 | elseif Type == "Freeze" then | |
2713 | local BodPos = Create("BodyPosition"){ | |
2714 | P = 50000, | |
2715 | D = 1000, | |
2716 | maxForce = Vector3.new(math.huge, math.huge, math.huge), | |
2717 | position = hit.Parent.Torso.Position, | |
2718 | Parent = hit.Parent.Torso, | |
2719 | } | |
2720 | local BodGy = Create("BodyGyro") { | |
2721 | maxTorque = Vector3.new(4e+005, 4e+005, 4e+005) * math.huge , | |
2722 | P = 20e+003, | |
2723 | Parent = hit.Parent.Torso, | |
2724 | cframe = hit.Parent.Torso.CFrame, | |
2725 | } | |
2726 | hit.Parent.Torso.Anchored = true | |
2727 | coroutine.resume(coroutine.create(function(Part) | |
2728 | swait(1.5) | |
2729 | Part.Anchored = false | |
2730 | end), hit.Parent.Torso) | |
2731 | game:GetService("Debris"):AddItem(BodPos, 3) | |
2732 | game:GetService("Debris"):AddItem(BodGy, 3) | |
2733 | end | |
2734 | local debounce = Create("BoolValue"){ | |
2735 | Name = "DebounceHit", | |
2736 | Parent = hit.Parent, | |
2737 | Value = true, | |
2738 | } | |
2739 | game:GetService("Debris"):AddItem(debounce, Delay) | |
2740 | c = Create("ObjectValue"){ | |
2741 | Name = "creator", | |
2742 | Value = Player, | |
2743 | Parent = h, | |
2744 | } | |
2745 | game:GetService("Debris"):AddItem(c, .5) | |
2746 | end | |
2747 | end | |
2748 | ------------------------------------------------------- | |
2749 | --End Damage Function-- | |
2750 | ------------------------------------------------------- | |
2751 | ||
2752 | ------------------------------------------------------- | |
2753 | --Start Damage Function Customization-- | |
2754 | ------------------------------------------------------- | |
2755 | function ShowDamage(Pos, Text, Time, Color) | |
2756 | local Rate = (1 / 30) | |
2757 | local Pos = (Pos or Vector3.new(0, 0, 0)) | |
2758 | local Text = (Text or "") | |
2759 | local Time = (Time or 2) | |
2760 | local Color = (Color or Color3.new(255, 255, 1)) | |
2761 | local EffectPart = CFuncs.Part.Create(workspace, "SmoothPlastic", 0, 1, BrickColor.new(Color), "Effect", Vector3.new(0, 0, 0)) | |
2762 | EffectPart.Anchored = true | |
2763 | local BillboardGui = Create("BillboardGui"){ | |
2764 | Size = UDim2.new(3, 0, 3, 0), | |
2765 | Adornee = EffectPart, | |
2766 | Parent = EffectPart, | |
2767 | } | |
2768 | local TextLabel = Create("TextLabel"){ | |
2769 | BackgroundTransparency = 1, | |
2770 | Size = UDim2.new(1, 0, 1, 0), | |
2771 | Text = Text, | |
2772 | Font = "Bodoni", | |
2773 | TextColor3 = Color, | |
2774 | TextScaled = true, | |
2775 | TextStrokeColor3 = Color3.fromRGB(220, 188, 129), | |
2776 | Parent = BillboardGui, | |
2777 | } | |
2778 | game.Debris:AddItem(EffectPart, (Time)) | |
2779 | EffectPart.Parent = game:GetService("Workspace") | |
2780 | delay(0, function() | |
2781 | local Frames = (Time / Rate) | |
2782 | for Frame = 1, Frames do | |
2783 | wait(Rate) | |
2784 | local Percent = (Frame / Frames) | |
2785 | EffectPart.CFrame = CFrame.new(Pos) + Vector3.new(0, Percent, 0) | |
2786 | TextLabel.TextTransparency = Percent | |
2787 | end | |
2788 | if EffectPart and EffectPart.Parent then | |
2789 | EffectPart:Destroy() | |
2790 | end | |
2791 | end) | |
2792 | end | |
2793 | ------------------------------------------------------- | |
2794 | --End Damage Function Customization-- | |
2795 | ------------------------------------------------------- | |
2796 | ||
2797 | function MagniDamage(Part, magni, mindam, maxdam, knock, Type) | |
2798 | for _, c in pairs(workspace:children()) do | |
2799 | local hum = c:findFirstChild("Humanoid") | |
2800 | if hum ~= nil then | |
2801 | local head = c:findFirstChild("Head") | |
2802 | if head ~= nil then | |
2803 | local targ = head.Position - Part.Position | |
2804 | local mag = targ.magnitude | |
2805 | if magni >= mag and c.Name ~= plr.Name then | |
2806 | Damage(head, head, mindam, maxdam, knock, Type, root, 0.1, "http://www.roblox.com/asset/?id=0", 1.2) | |
2807 | end | |
2808 | end | |
2809 | end | |
2810 | end | |
2811 | end | |
2812 | ||
2813 | ||
2814 | CFuncs = { | |
2815 | Part = { | |
2816 | Create = function(Parent, Material, Reflectance, Transparency, BColor, Name, Size) | |
2817 | local Part = Create("Part")({ | |
2818 | Parent = Parent, | |
2819 | Reflectance = Reflectance, | |
2820 | Transparency = Transparency, | |
2821 | CanCollide = false, | |
2822 | Locked = true, | |
2823 | BrickColor = BrickColor.new(tostring(BColor)), | |
2824 | Name = Name, | |
2825 | Size = Size, | |
2826 | Material = Material | |
2827 | }) | |
2828 | RemoveOutlines(Part) | |
2829 | return Part | |
2830 | end | |
2831 | }, | |
2832 | Mesh = { | |
2833 | Create = function(Mesh, Part, MeshType, MeshId, OffSet, Scale) | |
2834 | local Msh = Create(Mesh)({ | |
2835 | Parent = Part, | |
2836 | Offset = OffSet, | |
2837 | Scale = Scale | |
2838 | }) | |
2839 | if Mesh == "SpecialMesh" then | |
2840 | Msh.MeshType = MeshType | |
2841 | Msh.MeshId = MeshId | |
2842 | end | |
2843 | return Msh | |
2844 | end | |
2845 | }, | |
2846 | Mesh = { | |
2847 | Create = function(Mesh, Part, MeshType, MeshId, OffSet, Scale) | |
2848 | local Msh = Create(Mesh)({ | |
2849 | Parent = Part, | |
2850 | Offset = OffSet, | |
2851 | Scale = Scale | |
2852 | }) | |
2853 | if Mesh == "SpecialMesh" then | |
2854 | Msh.MeshType = MeshType | |
2855 | Msh.MeshId = MeshId | |
2856 | end | |
2857 | return Msh | |
2858 | end | |
2859 | }, | |
2860 | Weld = { | |
2861 | Create = function(Parent, Part0, Part1, C0, C1) | |
2862 | local Weld = Create("Weld")({ | |
2863 | Parent = Parent, | |
2864 | Part0 = Part0, | |
2865 | Part1 = Part1, | |
2866 | C0 = C0, | |
2867 | C1 = C1 | |
2868 | }) | |
2869 | return Weld | |
2870 | end | |
2871 | }, | |
2872 | Sound = { | |
2873 | Create = function(id, par, vol, pit) | |
2874 | coroutine.resume(coroutine.create(function() | |
2875 | local S = Create("Sound")({ | |
2876 | Volume = vol, | |
2877 | Pitch = pit or 1, | |
2878 | SoundId = id, | |
2879 | Parent = par or workspace | |
2880 | }) | |
2881 | wait() | |
2882 | S:play() | |
2883 | game:GetService("Debris"):AddItem(S, 6) | |
2884 | end)) | |
2885 | end | |
2886 | }, | |
2887 | ParticleEmitter = { | |
2888 | Create = function(Parent, Color1, Color2, LightEmission, Size, Texture, Transparency, ZOffset, Accel, Drag, LockedToPart, VelocityInheritance, EmissionDirection, Enabled, LifeTime, Rate, Rotation, RotSpeed, Speed, VelocitySpread) | |
2889 | local fp = Create("ParticleEmitter")({ | |
2890 | Parent = Parent, | |
2891 | Color = ColorSequence.new(Color1, Color2), | |
2892 | LightEmission = LightEmission, | |
2893 | Size = Size, | |
2894 | Texture = Texture, | |
2895 | Transparency = Transparency, | |
2896 | ZOffset = ZOffset, | |
2897 | Acceleration = Accel, | |
2898 | Drag = Drag, | |
2899 | LockedToPart = LockedToPart, | |
2900 | VelocityInheritance = VelocityInheritance, | |
2901 | EmissionDirection = EmissionDirection, | |
2902 | Enabled = Enabled, | |
2903 | Lifetime = LifeTime, | |
2904 | Rate = Rate, | |
2905 | Rotation = Rotation, | |
2906 | RotSpeed = RotSpeed, | |
2907 | Speed = Speed, | |
2908 | VelocitySpread = VelocitySpread | |
2909 | }) | |
2910 | return fp | |
2911 | end | |
2912 | } | |
2913 | } | |
2914 | function RemoveOutlines(part) | |
2915 | part.TopSurface, part.BottomSurface, part.LeftSurface, part.RightSurface, part.FrontSurface, part.BackSurface = 10, 10, 10, 10, 10, 10 | |
2916 | end | |
2917 | function CreatePart(FormFactor, Parent, Material, Reflectance, Transparency, BColor, Name, Size) | |
2918 | local Part = Create("Part")({ | |
2919 | formFactor = FormFactor, | |
2920 | Parent = Parent, | |
2921 | Reflectance = Reflectance, | |
2922 | Transparency = Transparency, | |
2923 | CanCollide = false, | |
2924 | Locked = true, | |
2925 | BrickColor = BrickColor.new(tostring(BColor)), | |
2926 | Name = Name, | |
2927 | Size = Size, | |
2928 | Material = Material | |
2929 | }) | |
2930 | RemoveOutlines(Part) | |
2931 | return Part | |
2932 | end | |
2933 | function CreateMesh(Mesh, Part, MeshType, MeshId, OffSet, Scale) | |
2934 | local Msh = Create(Mesh)({ | |
2935 | Parent = Part, | |
2936 | Offset = OffSet, | |
2937 | Scale = Scale | |
2938 | }) | |
2939 | if Mesh == "SpecialMesh" then | |
2940 | Msh.MeshType = MeshType | |
2941 | Msh.MeshId = MeshId | |
2942 | end | |
2943 | return Msh | |
2944 | end | |
2945 | function CreateWeld(Parent, Part0, Part1, C0, C1) | |
2946 | local Weld = Create("Weld")({ | |
2947 | Parent = Parent, | |
2948 | Part0 = Part0, | |
2949 | Part1 = Part1, | |
2950 | C0 = C0, | |
2951 | C1 = C1 | |
2952 | }) | |
2953 | return Weld | |
2954 | end | |
2955 | ||
2956 | ||
2957 | ||
2958 | ------------------------------------------------------- | |
2959 | --End Effect Function-- | |
2960 | ------------------------------------------------------- | |
2961 | function Cso(ID, PARENT, VOLUME, PITCH) | |
2962 | local NSound = nil | |
2963 | coroutine.resume(coroutine.create(function() | |
2964 | NSound = IT("Sound", PARENT) | |
2965 | NSound.Volume = VOLUME | |
2966 | NSound.Pitch = PITCH | |
2967 | NSound.SoundId = "http://www.roblox.com/asset/?id="..ID | |
2968 | swait() | |
2969 | NSound:play() | |
2970 | game:GetService("Debris"):AddItem(NSound, 50) | |
2971 | end)) | |
2972 | return NSound | |
2973 | end | |
2974 | function CameraEnshaking(Length, Intensity) | |
2975 | coroutine.resume(coroutine.create(function() | |
2976 | local intensity = 1 * Intensity | |
2977 | local rotM = 0.01 * Intensity | |
2978 | for i = 0, Length, 0.1 do | |
2979 | swait() | |
2980 | intensity = intensity - 0.05 * Intensity / Length | |
2981 | rotM = rotM - 5.0E-4 * Intensity / Length | |
2982 | hum.CameraOffset = Vector3.new(Rad(Mrandom(-intensity, intensity)), Rad(Mrandom(-intensity, intensity)), Rad(Mrandom(-intensity, intensity))) | |
2983 | cam.CFrame = cam.CFrame * CF(Rad(Mrandom(-intensity, intensity)), Rad(Mrandom(-intensity, intensity)), Rad(Mrandom(-intensity, intensity))) * Euler(Rad(Mrandom(-intensity, intensity)) * rotM, Rad(Mrandom(-intensity, intensity)) * rotM, Rad(Mrandom(-intensity, intensity)) * rotM) | |
2984 | end | |
2985 | hum.CameraOffset = Vector3.new(0, 0, 0) | |
2986 | end)) | |
2987 | end | |
2988 | ------------------------------------------------------- | |
2989 | --End Important Functions-- | |
2990 | ------------------------------------------------------- | |
2991 | ||
2992 | ---------------------------------------------------------------------------------- | |
2993 | hum.WalkSpeed = 20 | |
2994 | hum.JumpPower = 60 | |
2995 | ---------------------------------------------------------------------------------- | |
2996 | local AddInstance = function(Object, ...) | |
2997 | local Obj = Instance.new(Object) | |
2998 | for i,v in next,(...) do | |
2999 | Obj[i] = v | |
3000 | end | |
3001 | return Obj | |
3002 | end | |
3003 | ---------------------------------------------------- | |
3004 | ||
3005 | ||
3006 | local Reaper = AddInstance("Part",{ | |
3007 | Parent = hed, | |
3008 | CFrame = hed.CFrame, | |
3009 | formFactor = "Symmetric", | |
3010 | Size = Vector3.new(1, 1, 1), | |
3011 | CanCollide = false, | |
3012 | TopSurface = "Smooth", | |
3013 | BottomSurface = "Smooth", | |
3014 | Locked = true, | |
3015 | }) | |
3016 | local Weld = AddInstance("Weld",{ | |
3017 | Parent = Reaper, | |
3018 | Part0 = hed, | |
3019 | C0 = CFrame.new(0, 1.45, 0)*CFrame.Angles(0, 0, 0), | |
3020 | Part1 = Reaper, | |
3021 | }) | |
3022 | local Mesh = AddInstance("SpecialMesh",{ | |
3023 | Parent = Reaper, | |
3024 | MeshId = "rbxassetid://0", | |
3025 | TextureId = "rbxassetid://0", | |
3026 | Scale = Vector3.new(0.85,0.85,0.85), | |
3027 | VertexColor = Vector3.new(1, 1, 1), | |
3028 | }) | |
3029 | ||
3030 | ------------------------------------------------------- | |
3031 | IT = Instance.new | |
3032 | CF = CFrame.new | |
3033 | VT = Vector3.new | |
3034 | RAD = math.rad | |
3035 | C3 = Color3.new | |
3036 | UD2 = UDim2.new | |
3037 | BRICKC = BrickColor.new | |
3038 | ANGLES = CFrame.Angles | |
3039 | EULER = CFrame.fromEulerAnglesXYZ | |
3040 | COS = math.cos | |
3041 | ACOS = math.acos | |
3042 | SIN = math.sin | |
3043 | ASIN = math.asin | |
3044 | ABS = math.abs | |
3045 | MRANDOM = math.random | |
3046 | FLOOR = math.floor | |
3047 | ||
3048 | function CreateLabel(PARENT, TEXT, TEXTCOLOR, TEXTFONTSIZE, TEXTFONT, TRANSPARENCY, BORDERSIZEPIXEL, STROKETRANSPARENCY, NAME) | |
3049 | local label = IT("TextLabel") | |
3050 | label.BackgroundTransparency = 1 | |
3051 | label.Size = UD2(1, 0, 1, 0) | |
3052 | label.Position = UD2(0, 0, 0, 0) | |
3053 | label.TextColor3 = TEXTCOLOR | |
3054 | label.TextStrokeTransparency = STROKETRANSPARENCY | |
3055 | label.TextTransparency = TRANSPARENCY | |
3056 | label.FontSize = TEXTFONTSIZE | |
3057 | label.Font = TEXTFONT | |
3058 | label.BorderSizePixel = BORDERSIZEPIXEL | |
3059 | label.TextScaled = false | |
3060 | label.Text = TEXT | |
3061 | label.Name = NAME | |
3062 | label.Parent = PARENT | |
3063 | return label | |
3064 | end | |
3065 | ||
3066 | function chatfunc(text) | |
3067 | local chat = coroutine.wrap(function() | |
3068 | if Character:FindFirstChild("TalkingBillBoard")~= nil then | |
3069 | Character:FindFirstChild("TalkingBillBoard"):destroy() | |
3070 | end | |
3071 | local Bill = Instance.new("BillboardGui",Character) | |
3072 | Bill.Size = UDim2.new(0,100,0,40) | |
3073 | Bill.StudsOffset = Vector3.new(0,3,0) | |
3074 | Bill.Adornee = Character.Head | |
3075 | Bill.Name = "TalkingBillBoard" | |
3076 | local Hehe = Instance.new("TextLabel",Bill) | |
3077 | Hehe.BackgroundTransparency = 1 | |
3078 | Hehe.BorderSizePixel = 0 | |
3079 | Hehe.Text = "" | |
3080 | Hehe.Font = "Bodoni" | |
3081 | Hehe.TextSize = 40 | |
3082 | Hehe.TextStrokeTransparency = 0 | |
3083 | Hehe.Size = UDim2.new(1,0,0.5,0) | |
3084 | coroutine.resume(coroutine.create(function() | |
3085 | while Hehe ~= nil do | |
3086 | swait() | |
3087 | Hehe.Position = UDim2.new(math.random(-.4,.4),math.random(-5,5),.05,math.random(-5,5)) | |
3088 | Hehe.Rotation = math.random(-5,5) | |
3089 | Hehe.TextColor3 = Color3.new(220, 188, 129) | |
3090 | Hehe.TextStrokeColor3 = Color3.new(220, 188, 129) | |
3091 | end | |
3092 | end)) | |
3093 | for i = 1,string.len(text),1 do | |
3094 | swait() | |
3095 | Hehe.Text = string.sub(text,1,i) | |
3096 | end | |
3097 | swait(90)--Re[math.random(1, 93)] | |
3098 | for i = 0, 1, .025 do | |
3099 | swait() | |
3100 | Bill.ExtentsOffset = Vector3.new(math.random(-i, i), math.random(-i, i), math.random(-i, i)) | |
3101 | Hehe.TextStrokeTransparency = i | |
3102 | Hehe.TextTransparency = i | |
3103 | end | |
3104 | Bill:Destroy() | |
3105 | end) | |
3106 | chat() | |
3107 | end | |
3108 | ||
3109 | function onChatted(msg) | |
3110 | chatfunc(msg) | |
3111 | end | |
3112 | ||
3113 | Player.Chatted:connect(onChatted) | |
3114 | ||
3115 | function Ban() | |
3116 | wait(1.5) | |
3117 | local Hair = AddInstance("Part",{ | |
3118 | Parent = hed, | |
3119 | CFrame = hed.CFrame, | |
3120 | formFactor = "Symmetric", | |
3121 | Size = Vector3.new(1, 1, 1), | |
3122 | CanCollide = false, | |
3123 | TopSurface = "Smooth", | |
3124 | BottomSurface = "Smooth", | |
3125 | Locked = true, | |
3126 | }) | |
3127 | local Weld = AddInstance("Weld",{ | |
3128 | Parent = Hair, | |
3129 | Part0 = hed, | |
3130 | C0 = CFrame.new(-0.02, 0.3, 0)*CFrame.Angles(0, 480.5, 0), | |
3131 | Part1 = Hair, | |
3132 | }) | |
3133 | local Mesh = AddInstance("SpecialMesh",{ | |
3134 | Parent = Hair, | |
3135 | MeshId = "rbxassetid://488906775", | |
3136 | TextureId = "rbxassetid://869796655", | |
3137 | Scale = Vector3.new(1,1,1), | |
3138 | VertexColor = Vector3.new(1, 1, 1), | |
3139 | }) | |
3140 | local Cape = AddInstance("Part",{ | |
3141 | Parent = Torso, | |
3142 | CFrame = Torso.CFrame, | |
3143 | formFactor = "Symmetric", | |
3144 | Size = Vector3.new(1, 1, 1), | |
3145 | CanCollide = false, | |
3146 | TopSurface = "Smooth", | |
3147 | BottomSurface = "Smooth", | |
3148 | Locked = true, | |
3149 | }) | |
3150 | local Weld = AddInstance("Weld",{ | |
3151 | Parent = Cape, | |
3152 | Part0 = Torso, | |
3153 | C0 = CFrame.new(0, -1.2, 0.65)*CFrame.Angles(0, 0, 0), | |
3154 | Part1 = Cape, | |
3155 | }) | |
3156 | local Mesh = AddInstance("SpecialMesh",{ | |
3157 | Parent = Cape, | |
3158 | MeshId = "rbxassetid://2774049768", | |
3159 | TextureId = "rbxassetid://2774049797", | |
3160 | Scale = Vector3.new(5, 4, 5), | |
3161 | VertexColor = Vector3.new(1, 1, 1), | |
3162 | }) | |
3163 | local har3 = Instance.new("Part", char.Head) | |
3164 | har3.BrickColor = BrickColor.new("Black") | |
3165 | har3.Name = "Hair" | |
3166 | har3.formFactor = 0 | |
3167 | har3.Size = Vector3.new(0,-0.25,0) | |
3168 | har3.BottomSurface = 0 | |
3169 | har3.TopSurface = 0 | |
3170 | har3.CanCollide = false | |
3171 | Mesh3 = Instance.new("SpecialMesh",har3) | |
3172 | Mesh3.MeshId = "rbxassetid://1018860047" | |
3173 | Mesh3.Scale=Vector3.new(1.01, .99, 1.01) | |
3174 | local bWeld = Instance.new("Weld", char.Head) | |
3175 | bWeld.Part0 = char.Head | |
3176 | bWeld.Part1 = har3 | |
3177 | bWeld.C1 = CFrame.new(0,-.1,.3) | |
3178 | ||
3179 | swait() | |
3180 | plr = game.Players.LocalPlayer | |
3181 | char = plr.Character | |
3182 | mouse = plr:GetMouse() | |
3183 | whitecolor = Color3.new(220, 188, 129) | |
3184 | epicmode = false | |
3185 | normal = true | |
3186 | for i,v in pairs(char:GetChildren()) do | |
3187 | if v.ClassName == "Shirt" or v.ClassName == "Pants" or v.ClassName == "ShirtGraphic" then | |
3188 | v:Destroy() | |
3189 | end | |
3190 | end | |
3191 | local shirt = Instance.new("Shirt",char) | |
3192 | shirt.ShirtTemplate = "rbxassetid://0" | |
3193 | local pants = Instance.new("Pants",char) | |
3194 | pants.PantsTemplate = "rbxassetid://0" | |
3195 | local bdycolors = char["Body Colors"] | |
3196 | bdycolors.HeadColor3 = whitecolor | |
3197 | bdycolors.LeftArmColor3 = whitecolor | |
3198 | bdycolors.LeftLegColor3 = whitecolor | |
3199 | bdycolors.RightArmColor3 = whitecolor | |
3200 | bdycolors.RightLegColor3 = whitecolor | |
3201 | bdycolors.TorsoColor3 = whitecolor | |
3202 | for i,v in pairs(char:GetChildren()) do | |
3203 | if v.ClassName == "Hat" or v.ClassName == "Accessory" then | |
3204 | v:Destroy() | |
3205 | end | |
3206 | end | |
3207 | ||
3208 | ||
3209 | ||
3210 | local BC = Character["Body Colors"] | |
3211 | BC.HeadColor = BrickColor.new("Flame yellowish orange") | |
3212 | BC.LeftArmColor = BrickColor.new("Flame yellowish orange") | |
3213 | BC.LeftLegColor = BrickColor.new("Flame yellowish orange") | |
3214 | BC.RightArmColor = BrickColor.new("Flame yellowish orange") | |
3215 | BC.RightLegColor = BrickColor.new("Flame yellowish orange") | |
3216 | BC.TorsoColor = BrickColor.new("Curry") | |
3217 | end | |
3218 | if game:GetService("RunService"):IsClient() then error("Script must be server-side in order to work; use h/ and not hl/") end | |
3219 | local Player,game,owner = owner,game | |
3220 | local RealPlayer = Player | |
3221 | do | |
3222 | local rp = RealPlayer | |
3223 | script.Parent = rp.Character | |
3224 | ||
3225 | --RemoteEvent for communicating | |
3226 | local Event = Instance.new("RemoteEvent") | |
3227 | Event.Name = "UserInput_Event" | |
3228 | ||
3229 | --Fake event to make stuff like Mouse.KeyDown work | |
3230 | local function fakeEvent() | |
3231 | local t = {_fakeEvent=true,Functions={},Connect=function(self,f)table.insert(self.Functions,f) end} | |
3232 | t.connect = t.Connect | |
3233 | return t | |
3234 | end | |
3235 | ||
3236 | --Creating fake input objects with fake variables | |
3237 | local m = {Target=nil,Hit=CFrame.new(),KeyUp=fakeEvent(),KeyDown=fakeEvent(),Button1Up=fakeEvent(),Button1Down=fakeEvent()} | |
3238 | local UIS = {InputBegan=fakeEvent(),InputEnded=fakeEvent()} | |
3239 | local CAS = {Actions={},BindAction=function(self,name,fun,touch,...) | |
3240 | CAS.Actions[name] = fun and {Name=name,Function=fun,Keys={...}} or nil | |
3241 | end} | |
3242 | --Merged 2 functions into one by checking amount of arguments | |
3243 | CAS.UnbindAction = CAS.BindAction | |
3244 | ||
3245 | --This function will trigger the events that have been :Connect()'ed | |
3246 | local function te(self,ev,...) | |
3247 | local t = m[ev] | |
3248 | if t and t._fakeEvent then | |
3249 | for _,f in pairs(t.Functions) do | |
3250 | f(...) | |
3251 | end | |
3252 | end | |
3253 | end | |
3254 | m.TrigEvent = te | |
3255 | UIS.TrigEvent = te | |
3256 | ||
3257 | Event.OnServerEvent:Connect(function(plr,io) | |
3258 | if plr~=rp then return end | |
3259 | m.Target = io.Target | |
3260 | m.Hit = io.Hit | |
3261 | if not io.isMouse then | |
3262 | local b = io.UserInputState == Enum.UserInputState.Begin | |
3263 | if io.UserInputType == Enum.UserInputType.MouseButton1 then | |
3264 | return m:TrigEvent(b and "Button1Down" or "Button1Up") | |
3265 | end | |
3266 | for _,t in pairs(CAS.Actions) do | |
3267 | for _,k in pairs(t.Keys) do | |
3268 | if k==io.KeyCode then | |
3269 | t.Function(t.Name,io.UserInputState,io) | |
3270 | end | |
3271 | end | |
3272 | end | |
3273 | m:TrigEvent(b and "KeyDown" or "KeyUp",io.KeyCode.Name:lower()) | |
3274 | UIS:TrigEvent(b and "InputBegan" or "InputEnded",io,false) | |
3275 | end | |
3276 | end) | |
3277 | Event.Parent = NLS([==[ | |
3278 | local Player = game:GetService("Players").LocalPlayer | |
3279 | local Event = script:WaitForChild("UserInput_Event") | |
3280 | ||
3281 | local Mouse = Player:GetMouse() | |
3282 | local UIS = game:GetService("UserInputService") | |
3283 | local input = function(io,a) | |
3284 | if a then return end | |
3285 | --Since InputObject is a client-side instance, we create and pass table instead | |
3286 | Event:FireServer({KeyCode=io.KeyCode,UserInputType=io.UserInputType,UserInputState=io.UserInputState,Hit=Mouse.Hit,Target=Mouse.Target}) | |
3287 | end | |
3288 | UIS.InputBegan:Connect(input) | |
3289 | UIS.InputEnded:Connect(input) | |
3290 | ||
3291 | local h,t | |
3292 | --Give the server mouse data 30 times every second, but only if the values changed | |
3293 | --If player is not moving their mouse, client won't fire events | |
3294 | while wait(1/30) do | |
3295 | if h~=Mouse.Hit or t~=Mouse.Target then | |
3296 | h,t=Mouse.Hit,Mouse.Target | |
3297 | Event:FireServer({isMouse=true,Target=t,Hit=h}) | |
3298 | end | |
3299 | end]==],Player.Character) | |
3300 | ||
3301 | ----Sandboxed game object that allows the usage of client-side methods and services | |
3302 | --Real game object | |
3303 | local _rg = game | |
3304 | ||
3305 | --Metatable for fake service | |
3306 | local fsmt = { | |
3307 | __index = function(self,k) | |
3308 | local s = rawget(self,"_RealService") | |
3309 | if s then return s[k] end | |
3310 | end, | |
3311 | __newindex = function(self,k,v) | |
3312 | local s = rawget(self,"_RealService") | |
3313 | if s then s[k]=v end | |
3314 | end, | |
3315 | __call = function(self,...) | |
3316 | local s = rawget(self,"_RealService") | |
3317 | if s then return s(...) end | |
3318 | end | |
3319 | } | |
3320 | local function FakeService(t,RealService) | |
3321 | t._RealService = typeof(RealService)=="string" and _rg:GetService(RealService) or RealService | |
3322 | return setmetatable(t,fsmt) | |
3323 | end | |
3324 | ||
3325 | --Fake game object | |
3326 | local g = { | |
3327 | GetService = function(self,s) | |
3328 | return self[s] | |
3329 | end, | |
3330 | Players = FakeService({ | |
3331 | LocalPlayer = FakeService({GetMouse=function(self)return m end},Player) | |
3332 | },"Players"), | |
3333 | UserInputService = FakeService(UIS,"UserInputService"), | |
3334 | ContextActionService = FakeService(CAS,"ContextActionService"), | |
3335 | } | |
3336 | rawset(g.Players,"localPlayer",g.Players.LocalPlayer) | |
3337 | g.service = g.GetService | |
3338 | ||
3339 | g.RunService = FakeService({ | |
3340 | RenderStepped = _rg:GetService("RunService").Heartbeat, | |
3341 | BindToRenderStep = function(self,name,_,fun) | |
3342 | self._btrs[name] = self.Heartbeat:Connect(fun) | |
3343 | end, | |
3344 | UnbindFromRenderStep = function(self,name) | |
3345 | self._btrs[name]:Disconnect() | |
3346 | end, | |
3347 | },"RunService") | |
3348 | ||
3349 | setmetatable(g,{ | |
3350 | __index=function(self,s) | |
3351 | return _rg:GetService(s) or typeof(_rg[s])=="function" | |
3352 | and function(_,...)return _rg[s](_rg,...)end or _rg[s] | |
3353 | end, | |
3354 | __newindex = fsmt.__newindex, | |
3355 | __call = fsmt.__call | |
3356 | }) | |
3357 | --Changing owner to fake player object to support owner:GetMouse() | |
3358 | game,owner = g,g.Players.LocalPlayer | |
3359 | end | |
3360 | ||
3361 | Player = owner | |
3362 | PlayerGui = Player.PlayerGui | |
3363 | Cam = workspace.CurrentCamera | |
3364 | Backpack = Player.Backpack | |
3365 | Character = Player.Character | |
3366 | Humanoid = Character.Humanoid | |
3367 | Mouse = Player:GetMouse() | |
3368 | RootPart = Character["HumanoidRootPart"] | |
3369 | Torso = Character["Torso"] | |
3370 | Head = Character["Head"] | |
3371 | RightArm = Character["Right Arm"] | |
3372 | LeftArm = Character["Left Arm"] | |
3373 | RightLeg = Character["Right Leg"] | |
3374 | LeftLeg = Character["Left Leg"] | |
3375 | RootJoint = RootPart["RootJoint"] | |
3376 | Neck = Torso["Neck"] | |
3377 | RightShoulder = Torso["Right Shoulder"] | |
3378 | LeftShoulder = Torso["Left Shoulder"] | |
3379 | RightHip = Torso["Right Hip"] | |
3380 | LeftHip = Torso["Left Hip"] | |
3381 | ||
3382 | Character = Player.Character | |
3383 | Humanoid = Character.Humanoid | |
3384 | ||
3385 | ------------------------------------------------------- | |
3386 | ||
3387 | local FavIDs = { | |
3388 | 340106355, --Nefl Crystals | |
3389 | 927529620, --Dimension | |
3390 | 876981900, --Fantasy | |
3391 | 398987889, --Ordinary Days | |
3392 | 1117396305, --Oh wait, it's you. | |
3393 | 885996042, --Action Winter Journey | |
3394 | 919231299, --Sprawling Idiot Effigy | |
3395 | 743466274, --Good Day Sunshine | |
3396 | 727411183, --Knife Fight | |
3397 | 1402748531, --The Earth Is Counting On You! | |
3398 | 595230126 --Robot Language | |
3399 | } | |
3400 | ||
3401 | ||
3402 | ||
3403 | wait(0.2) | |
3404 | local plr = game:service'Players'.LocalPlayer | |
3405 | local char = plr.Character | |
3406 | local hum = char.Humanoid | |
3407 | local hed = char.Head | |
3408 | local root = char.HumanoidRootPart | |
3409 | local rootj = root.RootJoint | |
3410 | local tors = char.Torso | |
3411 | local ra = char["Right Arm"] | |
3412 | local la = char["Left Arm"] | |
3413 | local rl = char["Right Leg"] | |
3414 | local ll = char["Left Leg"] | |
3415 | local neck = tors["Neck"] | |
3416 | local mouse = plr:GetMouse() | |
3417 | local RootCF = CFrame.fromEulerAnglesXYZ(-1.57, 0, 3.14) | |
3418 | local RHCF = CFrame.fromEulerAnglesXYZ(0, 1.6, 0) | |
3419 | local LHCF = CFrame.fromEulerAnglesXYZ(0, -1.6, 0) | |
3420 | local maincolor = BrickColor.new("Really grey") | |
3421 | ||
3422 | ------------------------------------------------------- | |
3423 | --Start Good Stuff-- | |
3424 | ------------------------------------------------------- | |
3425 | cam = game.Workspace.CurrentCamera | |
3426 | CF = CFrame.new | |
3427 | angles = CFrame.Angles | |
3428 | attack = false | |
3429 | Euler = CFrame.fromEulerAnglesXYZ | |
3430 | Rad = math.rad | |
3431 | IT = Instance.new | |
3432 | BrickC = BrickColor.new | |
3433 | Cos = math.cos | |
3434 | Acos = math.acos | |
3435 | Sin = math.sin | |
3436 | Asin = math.asin | |
3437 | Abs = math.abs | |
3438 | Mrandom = math.random | |
3439 | Floor = math.floor | |
3440 | ------------------------------------------------------- | |
3441 | --End Good Stuff-- | |
3442 | ------------------------------------------------------- | |
3443 | necko = CF(0, 1, 0, -1, -0, -0, 0, 0, 1, 0, 1, 0) | |
3444 | RSH, LSH = nil, nil | |
3445 | RW = Instance.new("Weld") | |
3446 | LW = Instance.new("Weld") | |
3447 | RH = tors["Right Hip"] | |
3448 | LH = tors["Left Hip"] | |
3449 | RSH = tors["Right Shoulder"] | |
3450 | LSH = tors["Left Shoulder"] | |
3451 | RSH.Parent = nil | |
3452 | LSH.Parent = nil | |
3453 | RW.Name = "RW" | |
3454 | RW.Part0 = tors | |
3455 | RW.C0 = CF(1.5, 0.5, 0) | |
3456 | RW.C1 = CF(0, 0.5, 0) | |
3457 | RW.Part1 = ra | |
3458 | RW.Parent = tors | |
3459 | LW.Name = "LW" | |
3460 | LW.Part0 = tors | |
3461 | LW.C0 = CF(-1.5, 0.5, 0) | |
3462 | LW.C1 = CF(0, 0.5, 0) | |
3463 | LW.Part1 = la | |
3464 | LW.Parent = tors | |
3465 | Effects = {} | |
3466 | ------------------------------------------------------- | |
3467 | --Start HeartBeat-- | |
3468 | ------------------------------------------------------- | |
3469 | ArtificialHB = Instance.new("BindableEvent", script) | |
3470 | ArtificialHB.Name = "Heartbeat" | |
3471 | script:WaitForChild("Heartbeat") | |
3472 | ||
3473 | frame = 1 / 60 | |
3474 | tf = 0 | |
3475 | allowframeloss = false | |
3476 | tossremainder = false | |
3477 | ||
3478 | ||
3479 | lastframe = tick() | |
3480 | script.Heartbeat:Fire() | |
3481 | ||
3482 | ||
3483 | game:GetService("RunService").Heartbeat:connect(function(s, p) | |
3484 | tf = tf + s | |
3485 | if tf >= frame then | |
3486 | if allowframeloss then | |
3487 | script.Heartbeat:Fire() | |
3488 | lastframe = tick() | |
3489 | else | |
3490 | for i = 1, math.floor(tf / frame) do | |
3491 | script.Heartbeat:Fire() | |
3492 | end | |
3493 | lastframe = tick() | |
3494 | end | |
3495 | if tossremainder then | |
3496 | tf = 0 | |
3497 | else | |
3498 | tf = tf - frame * math.floor(tf / frame) | |
3499 | end | |
3500 | end | |
3501 | end) | |
3502 | ------------------------------------------------------- | |
3503 | --End HeartBeat-- | |
3504 | ------------------------------------------------------- | |
3505 | ||
3506 | ------------------------------------------------------- | |
3507 | --Start Important Functions-- | |
3508 | ------------------------------------------------------- | |
3509 | function swait(num) | |
3510 | if num == 0 or num == nil then | |
3511 | game:service("RunService").Stepped:wait(0) | |
3512 | else | |
3513 | for i = 0, num do | |
3514 | game:service("RunService").Stepped:wait(0) | |
3515 | end | |
3516 | end | |
3517 | end | |
3518 | function thread(f) | |
3519 | coroutine.resume(coroutine.create(f)) | |
3520 | end | |
3521 | function clerp(a, b, t) | |
3522 | local qa = { | |
3523 | QuaternionFromCFrame(a) | |
3524 | } | |
3525 | local qb = { | |
3526 | QuaternionFromCFrame(b) | |
3527 | } | |
3528 | local ax, ay, az = a.x, a.y, a.z | |
3529 | local bx, by, bz = b.x, b.y, b.z | |
3530 | local _t = 1 - t | |
3531 | return QuaternionToCFrame(_t * ax + t * bx, _t * ay + t * by, _t * az + t * bz, QuaternionSlerp(qa, qb, t)) | |
3532 | end | |
3533 | function QuaternionFromCFrame(cf) | |
3534 | local mx, my, mz, m00, m01, m02, m10, m11, m12, m20, m21, m22 = cf:components() | |
3535 | local trace = m00 + m11 + m22 | |
3536 | if trace > 0 then | |
3537 | local s = math.sqrt(1 + trace) | |
3538 | local recip = 0.5 / s | |
3539 | return (m21 - m12) * recip, (m02 - m20) * recip, (m10 - m01) * recip, s * 0.5 | |
3540 | else | |
3541 | local i = 0 | |
3542 | if m00 < m11 then | |
3543 | i = 1 | |
3544 | end | |
3545 | if m22 > (i == 0 and m00 or m11) then | |
3546 | i = 2 | |
3547 | end | |
3548 | if i == 0 then | |
3549 | local s = math.sqrt(m00 - m11 - m22 + 1) | |
3550 | local recip = 0.5 / s | |
3551 | return 0.5 * s, (m10 + m01) * recip, (m20 + m02) * recip, (m21 - m12) * recip | |
3552 | elseif i == 1 then | |
3553 | local s = math.sqrt(m11 - m22 - m00 + 1) | |
3554 | local recip = 0.5 / s | |
3555 | return (m01 + m10) * recip, 0.5 * s, (m21 + m12) * recip, (m02 - m20) * recip | |
3556 | elseif i == 2 then | |
3557 | local s = math.sqrt(m22 - m00 - m11 + 1) | |
3558 | local recip = 0.5 / s | |
3559 | return (m02 + m20) * recip, (m12 + m21) * recip, 0.5 * s, (m10 - m01) * recip | |
3560 | end | |
3561 | end | |
3562 | end | |
3563 | function QuaternionToCFrame(px, py, pz, x, y, z, w) | |
3564 | local xs, ys, zs = x + x, y + y, z + z | |
3565 | local wx, wy, wz = w * xs, w * ys, w * zs | |
3566 | local xx = x * xs | |
3567 | local xy = x * ys | |
3568 | local xz = x * zs | |
3569 | local yy = y * ys | |
3570 | local yz = y * zs | |
3571 | local zz = z * zs | |
3572 | return CFrame.new(px, py, pz, 1 - (yy + zz), xy - wz, xz + wy, xy + wz, 1 - (xx + zz), yz - wx, xz - wy, yz + wx, 1 - (xx + yy)) | |
3573 | end | |
3574 | function QuaternionSlerp(a, b, t) | |
3575 | local cosTheta = a[1] * b[1] + a[2] * b[2] + a[3] * b[3] + a[4] * b[4] | |
3576 | local startInterp, finishInterp | |
3577 | if cosTheta >= 1.0E-4 then | |
3578 | if 1 - cosTheta > 1.0E-4 then | |
3579 | local theta = math.acos(cosTheta) | |
3580 | local invSinTheta = 1 / Sin(theta) | |
3581 | startInterp = Sin((1 - t) * theta) * invSinTheta | |
3582 | finishInterp = Sin(t * theta) * invSinTheta | |
3583 | else | |
3584 | startInterp = 1 - t | |
3585 | finishInterp = t | |
3586 | end | |
3587 | elseif 1 + cosTheta > 1.0E-4 then | |
3588 | local theta = math.acos(-cosTheta) | |
3589 | local invSinTheta = 1 / Sin(theta) | |
3590 | startInterp = Sin((t - 1) * theta) * invSinTheta | |
3591 | finishInterp = Sin(t * theta) * invSinTheta | |
3592 | else | |
3593 | startInterp = t - 1 | |
3594 | finishInterp = t | |
3595 | end | |
3596 | return a[1] * startInterp + b[1] * finishInterp, a[2] * startInterp + b[2] * finishInterp, a[3] * startInterp + b[3] * finishInterp, a[4] * startInterp + b[4] * finishInterp | |
3597 | end | |
3598 | function rayCast(Position, Direction, Range, Ignore) | |
3599 | return game:service("Workspace"):FindPartOnRay(Ray.new(Position, Direction.unit * (Range or 999.999)), Ignore) | |
3600 | end | |
3601 | local RbxUtility = LoadLibrary("RbxUtility") | |
3602 | local Create = RbxUtility.Create | |
3603 | ||
3604 | ------------------------------------------------------- | |
3605 | --Start Damage Function-- | |
3606 | ------------------------------------------------------- | |
3607 | function Damage(Part, hit, minim, maxim, knockback, Type, Property, Delay, HitSound, HitPitch) | |
3608 | if hit.Parent == nil then | |
3609 | return | |
3610 | end | |
3611 | local h = hit.Parent:FindFirstChildOfClass("Humanoid") | |
3612 | for _, v in pairs(hit.Parent:children()) do | |
3613 | if v:IsA("Humanoid") then | |
3614 | h = v | |
3615 | end | |
3616 | end | |
3617 | if h ~= nil and hit.Parent.Name ~= char.Name and hit.Parent:FindFirstChild("UpperTorso") ~= nil then | |
3618 | ||
3619 | hit.Parent:FindFirstChild("Head"):BreakJoints() | |
3620 | end | |
3621 | ||
3622 | if h ~= nil and hit.Parent.Name ~= char.Name and hit.Parent:FindFirstChild("Torso") ~= nil then | |
3623 | if hit.Parent:findFirstChild("DebounceHit") ~= nil then | |
3624 | if hit.Parent.DebounceHit.Value == true then | |
3625 | return | |
3626 | end | |
3627 | end | |
3628 | if insta == true then | |
3629 | hit.Parent:FindFirstChild("Head"):BreakJoints() | |
3630 | end | |
3631 | local c = Create("ObjectValue"){ | |
3632 | Name = "creator", | |
3633 | Value = game:service("Players").LocalPlayer, | |
3634 | Parent = h, | |
3635 | } | |
3636 | game:GetService("Debris"):AddItem(c, .5) | |
3637 | if HitSound ~= nil and HitPitch ~= nil then | |
3638 | CFuncs.Sound.Create(HitSound, hit, 1, HitPitch) | |
3639 | end | |
3640 | local Damage = math.random(minim, maxim) | |
3641 | local blocked = false | |
3642 | local block = hit.Parent:findFirstChild("Block") | |
3643 | if block ~= nil then | |
3644 | if block.className == "IntValue" then | |
3645 | if block.Value > 0 then | |
3646 | blocked = true | |
3647 | block.Value = block.Value - 1 | |
3648 | print(block.Value) | |
3649 | end | |
3650 | end | |
3651 | end | |
3652 | if blocked == false then | |
3653 | h.Health = h.Health - Damage | |
3654 | ShowDamage((Part.CFrame * CFrame.new(0, 0, (Part.Size.Z / 2)).p + Vector3.new(0, 1.5, 0)), -Damage, 1.5, tors.BrickColor.Color) | |
3655 | else | |
3656 | h.Health = h.Health - (Damage / 2) | |
3657 | ShowDamage((Part.CFrame * CFrame.new(0, 0, (Part.Size.Z / 2)).p + Vector3.new(0, 1.5, 0)), -Damage, 1.5, tors.BrickColor.Color) | |
3658 | end | |
3659 | if Type == "Knockdown" then | |
3660 | local hum = hit.Parent.Humanoid | |
3661 | hum.PlatformStand = true | |
3662 | coroutine.resume(coroutine.create(function(HHumanoid) | |
3663 | swait(1) | |
3664 | HHumanoid.PlatformStand = false | |
3665 | end), hum) | |
3666 | local angle = (hit.Position - (Property.Position + Vector3.new(0, 0, 0))).unit | |
3667 | local bodvol = Create("BodyVelocity"){ | |
3668 | velocity = angle * knockback, | |
3669 | P = 5000, | |
3670 | maxForce = Vector3.new(8e+003, 8e+003, 8e+003), | |
3671 | Parent = hit, | |
3672 | } | |
3673 | local rl = Create("BodyAngularVelocity"){ | |
3674 | P = 3000, | |
3675 | maxTorque = Vector3.new(500000, 500000, 500000) * 50000000000000, | |
3676 | angularvelocity = Vector3.new(math.random(-10, 10), math.random(-10, 10), math.random(-10, 10)), | |
3677 | Parent = hit, | |
3678 | } | |
3679 | game:GetService("Debris"):AddItem(bodvol, .5) | |
3680 | game:GetService("Debris"):AddItem(rl, .5) | |
3681 | elseif Type == "Normal" then | |
3682 | local vp = Create("BodyVelocity"){ | |
3683 | P = 500, | |
3684 | maxForce = Vector3.new(math.huge, 0, math.huge), | |
3685 | velocity = Property.CFrame.lookVector * knockback + Property.Velocity / 1.05, | |
3686 | } | |
3687 | if knockback > 0 then | |
3688 | vp.Parent = hit.Parent.Torso | |
3689 | end | |
3690 | game:GetService("Debris"):AddItem(vp, .5) | |
3691 | elseif Type == "Up" then | |
3692 | local bodyVelocity = Create("BodyVelocity"){ | |
3693 | velocity = Vector3.new(0, 20, 0), | |
3694 | P = 5000, | |
3695 | maxForce = Vector3.new(8e+003, 8e+003, 8e+003), | |
3696 | Parent = hit, | |
3697 | } | |
3698 | game:GetService("Debris"):AddItem(bodyVelocity, .5) | |
3699 | elseif Type == "DarkUp" then | |
3700 | coroutine.resume(coroutine.create(function() | |
3701 | for i = 0, 1, 0.1 do | |
3702 | swait() | |
3703 | Effects.Block.Create(BrickColor.new("Black"), hit.Parent.Torso.CFrame, 5, 5, 5, 1, 1, 1, .08, 1) | |
3704 | end | |
3705 | end)) | |
3706 | local bodyVelocity = Create("BodyVelocity"){ | |
3707 | velocity = Vector3.new(0, 20, 0), | |
3708 | P = 5000, | |
3709 | maxForce = Vector3.new(8e+003, 8e+003, 8e+003), | |
3710 | Parent = hit, | |
3711 | } | |
3712 | game:GetService("Debris"):AddItem(bodyVelocity, 1) | |
3713 | elseif Type == "Snare" then | |
3714 | local bp = Create("BodyPosition"){ | |
3715 | P = 2000, | |
3716 | D = 100, | |
3717 | maxForce = Vector3.new(math.huge, math.huge, math.huge), | |
3718 | position = hit.Parent.Torso.Position, | |
3719 | Parent = hit.Parent.Torso, | |
3720 | } | |
3721 | game:GetService("Debris"):AddItem(bp, 1) | |
3722 | elseif Type == "Freeze" then | |
3723 | local BodPos = Create("BodyPosition"){ | |
3724 | P = 50000, | |
3725 | D = 1000, | |
3726 | maxForce = Vector3.new(math.huge, math.huge, math.huge), | |
3727 | position = hit.Parent.Torso.Position, | |
3728 | Parent = hit.Parent.Torso, | |
3729 | } | |
3730 | local BodGy = Create("BodyGyro") { | |
3731 | maxTorque = Vector3.new(4e+005, 4e+005, 4e+005) * math.huge , | |
3732 | P = 20e+003, | |
3733 | Parent = hit.Parent.Torso, | |
3734 | cframe = hit.Parent.Torso.CFrame, | |
3735 | } | |
3736 | hit.Parent.Torso.Anchored = true | |
3737 | coroutine.resume(coroutine.create(function(Part) | |
3738 | swait(1.5) | |
3739 | Part.Anchored = false | |
3740 | end), hit.Parent.Torso) | |
3741 | game:GetService("Debris"):AddItem(BodPos, 3) | |
3742 | game:GetService("Debris"):AddItem(BodGy, 3) | |
3743 | end | |
3744 | local debounce = Create("BoolValue"){ | |
3745 | Name = "DebounceHit", | |
3746 | Parent = hit.Parent, | |
3747 | Value = true, | |
3748 | } | |
3749 | game:GetService("Debris"):AddItem(debounce, Delay) | |
3750 | c = Create("ObjectValue"){ | |
3751 | Name = "creator", | |
3752 | Value = Player, | |
3753 | Parent = h, | |
3754 | } | |
3755 | game:GetService("Debris"):AddItem(c, .5) | |
3756 | end | |
3757 | end | |
3758 | ------------------------------------------------------- | |
3759 | --End Damage Function-- | |
3760 | ------------------------------------------------------- | |
3761 | ||
3762 | ------------------------------------------------------- | |
3763 | --Start Damage Function Customization-- | |
3764 | ------------------------------------------------------- | |
3765 | function ShowDamage(Pos, Text, Time, Color) | |
3766 | local Rate = (1 / 30) | |
3767 | local Pos = (Pos or Vector3.new(0, 0, 0)) | |
3768 | local Text = (Text or "") | |
3769 | local Time = (Time or 2) | |
3770 | local Color = (Color or Color3.new(17, 17, 17)) | |
3771 | local EffectPart = CFuncs.Part.Create(workspace, "SmoothPlastic", 0, 1, BrickColor.new(Color), "Effect", Vector3.new(0, 0, 0)) | |
3772 | EffectPart.Anchored = true | |
3773 | local BillboardGui = Create("BillboardGui"){ | |
3774 | Size = UDim2.new(3, 0, 3, 0), | |
3775 | Adornee = EffectPart, | |
3776 | Parent = EffectPart, | |
3777 | } | |
3778 | local TextLabel = Create("TextLabel"){ | |
3779 | BackgroundTransparency = 1, | |
3780 | Size = UDim2.new(1, 0, 1, 0), | |
3781 | Text = Text, | |
3782 | Font = "Bodoni", | |
3783 | TextColor3 = Color, | |
3784 | TextScaled = true, | |
3785 | TextStrokeColor3 = Color3.fromRGB(0,0,0), | |
3786 | Parent = BillboardGui, | |
3787 | } | |
3788 | game.Debris:AddItem(EffectPart, (Time)) | |
3789 | EffectPart.Parent = game:GetService("Workspace") | |
3790 | delay(0, function() | |
3791 | local Frames = (Time / Rate) | |
3792 | for Frame = 1, Frames do | |
3793 | wait(Rate) | |
3794 | local Percent = (Frame / Frames) | |
3795 | EffectPart.CFrame = CFrame.new(Pos) + Vector3.new(0, Percent, 0) | |
3796 | TextLabel.TextTransparency = Percent | |
3797 | end | |
3798 | if EffectPart and EffectPart.Parent then | |
3799 | EffectPart:Destroy() | |
3800 | end | |
3801 | end) | |
3802 | end | |
3803 | ------------------------------------------------------- | |
3804 | --End Damage Function Customization-- | |
3805 | ------------------------------------------------------- | |
3806 | ||
3807 | function MagniDamage(Part, magni, mindam, maxdam, knock, Type) | |
3808 | for _, c in pairs(workspace:children()) do | |
3809 | local hum = c:findFirstChild("Humanoid") | |
3810 | if hum ~= nil then | |
3811 | local head = c:findFirstChild("Head") | |
3812 | if head ~= nil then | |
3813 | local targ = head.Position - Part.Position | |
3814 | local mag = targ.magnitude | |
3815 | if magni >= mag and c.Name ~= plr.Name then | |
3816 | Damage(head, head, mindam, maxdam, knock, Type, root, 0.1, "http://www.roblox.com/asset/?id=0", 1.2) | |
3817 | end | |
3818 | end | |
3819 | end | |
3820 | end | |
3821 | end | |
3822 | ||
3823 | ||
3824 | CFuncs = { | |
3825 | Part = { | |
3826 | Create = function(Parent, Material, Reflectance, Transparency, BColor, Name, Size) | |
3827 | local Part = Create("Part")({ | |
3828 | Parent = Parent, | |
3829 | Reflectance = Reflectance, | |
3830 | Transparency = Transparency, | |
3831 | CanCollide = false, | |
3832 | Locked = true, | |
3833 | BrickColor = BrickColor.new(tostring(BColor)), | |
3834 | Name = Name, | |
3835 | Size = Size, | |
3836 | Material = Material | |
3837 | }) | |
3838 | RemoveOutlines(Part) | |
3839 | return Part | |
3840 | end | |
3841 | }, | |
3842 | Mesh = { | |
3843 | Create = function(Mesh, Part, MeshType, MeshId, OffSet, Scale) | |
3844 | local Msh = Create(Mesh)({ | |
3845 | Parent = Part, | |
3846 | Offset = OffSet, | |
3847 | Scale = Scale | |
3848 | }) | |
3849 | if Mesh == "SpecialMesh" then | |
3850 | Msh.MeshType = MeshType | |
3851 | Msh.MeshId = MeshId | |
3852 | end | |
3853 | return Msh | |
3854 | end | |
3855 | }, | |
3856 | Mesh = { | |
3857 | Create = function(Mesh, Part, MeshType, MeshId, OffSet, Scale) | |
3858 | local Msh = Create(Mesh)({ | |
3859 | Parent = Part, | |
3860 | Offset = OffSet, | |
3861 | Scale = Scale | |
3862 | }) | |
3863 | if Mesh == "SpecialMesh" then | |
3864 | Msh.MeshType = MeshType | |
3865 | Msh.MeshId = MeshId | |
3866 | end | |
3867 | return Msh | |
3868 | end | |
3869 | }, | |
3870 | Weld = { | |
3871 | Create = function(Parent, Part0, Part1, C0, C1) | |
3872 | local Weld = Create("Weld")({ | |
3873 | Parent = Parent, | |
3874 | Part0 = Part0, | |
3875 | Part1 = Part1, | |
3876 | C0 = C0, | |
3877 | C1 = C1 | |
3878 | }) | |
3879 | return Weld | |
3880 | end | |
3881 | }, | |
3882 | Sound = { | |
3883 | Create = function(id, par, vol, pit) | |
3884 | coroutine.resume(coroutine.create(function() | |
3885 | local S = Create("Sound")({ | |
3886 | Volume = vol, | |
3887 | Pitch = pit or 1, | |
3888 | SoundId = id, | |
3889 | Parent = par or workspace | |
3890 | }) | |
3891 | wait() | |
3892 | S:play() | |
3893 | game:GetService("Debris"):AddItem(S, 6) | |
3894 | end)) | |
3895 | end | |
3896 | }, | |
3897 | ParticleEmitter = { | |
3898 | Create = function(Parent, Color1, Color2, LightEmission, Size, Texture, Transparency, ZOffset, Accel, Drag, LockedToPart, VelocityInheritance, EmissionDirection, Enabled, LifeTime, Rate, Rotation, RotSpeed, Speed, VelocitySpread) | |
3899 | local fp = Create("ParticleEmitter")({ | |
3900 | Parent = Parent, | |
3901 | Color = ColorSequence.new(Color1, Color2), | |
3902 | LightEmission = LightEmission, | |
3903 | Size = Size, | |
3904 | Texture = Texture, | |
3905 | Transparency = Transparency, | |
3906 | ZOffset = ZOffset, | |
3907 | Acceleration = Accel, | |
3908 | Drag = Drag, | |
3909 | LockedToPart = LockedToPart, | |
3910 | VelocityInheritance = VelocityInheritance, | |
3911 | EmissionDirection = EmissionDirection, | |
3912 | Enabled = Enabled, | |
3913 | Lifetime = LifeTime, | |
3914 | Rate = Rate, | |
3915 | Rotation = Rotation, | |
3916 | RotSpeed = RotSpeed, | |
3917 | Speed = Speed, | |
3918 | VelocitySpread = VelocitySpread | |
3919 | }) | |
3920 | return fp | |
3921 | end | |
3922 | } | |
3923 | } | |
3924 | function RemoveOutlines(part) | |
3925 | part.TopSurface, part.BottomSurface, part.LeftSurface, part.RightSurface, part.FrontSurface, part.BackSurface = 10, 10, 10, 10, 10, 10 | |
3926 | end | |
3927 | function CreatePart(FormFactor, Parent, Material, Reflectance, Transparency, BColor, Name, Size) | |
3928 | local Part = Create("Part")({ | |
3929 | formFactor = FormFactor, | |
3930 | Parent = Parent, | |
3931 | Reflectance = Reflectance, | |
3932 | Transparency = Transparency, | |
3933 | CanCollide = false, | |
3934 | Locked = true, | |
3935 | BrickColor = BrickColor.new(tostring(BColor)), | |
3936 | Name = Name, | |
3937 | Size = Size, | |
3938 | Material = Material | |
3939 | }) | |
3940 | RemoveOutlines(Part) | |
3941 | return Part | |
3942 | end | |
3943 | function CreateMesh(Mesh, Part, MeshType, MeshId, OffSet, Scale) | |
3944 | local Msh = Create(Mesh)({ | |
3945 | Parent = Part, | |
3946 | Offset = OffSet, | |
3947 | Scale = Scale | |
3948 | }) | |
3949 | if Mesh == "SpecialMesh" then | |
3950 | Msh.MeshType = MeshType | |
3951 | Msh.MeshId = MeshId | |
3952 | end | |
3953 | return Msh | |
3954 | end | |
3955 | function CreateWeld(Parent, Part0, Part1, C0, C1) | |
3956 | local Weld = Create("Weld")({ | |
3957 | Parent = Parent, | |
3958 | Part0 = Part0, | |
3959 | Part1 = Part1, | |
3960 | C0 = C0, | |
3961 | C1 = C1 | |
3962 | }) | |
3963 | return Weld | |
3964 | end | |
3965 | ||
3966 | ||
3967 | ------------------------------------------------------- | |
3968 | --Start Effect Function-- | |
3969 | ------------------------------------------------------- | |
3970 | function CreateWeldOrSnapOrMotor(TYPE, PARENT, PART0, PART1, C0, C1) | |
3971 | local NEWWELD = IT(TYPE) | |
3972 | NEWWELD.Part0 = PART0 | |
3973 | NEWWELD.Part1 = PART1 | |
3974 | NEWWELD.C0 = C0 | |
3975 | NEWWELD.C1 = C1 | |
3976 | NEWWELD.Parent = PARENT | |
3977 | return NEWWELD | |
3978 | end | |
3979 | function CreateMesh(MESH, PARENT, MESHTYPE, MESHID, TEXTUREID, SCALE, OFFSET) | |
3980 | local NEWMESH = IT(MESH) | |
3981 | if MESH == "SpecialMesh" then | |
3982 | NEWMESH.MeshType = MESHTYPE | |
3983 | if MESHID ~= "nil" and MESHID ~= "" then | |
3984 | NEWMESH.MeshId = "http://www.roblox.com/asset/?id="..MESHID | |
3985 | end | |
3986 | if TEXTUREID ~= "nil" and TEXTUREID ~= "" then | |
3987 | NEWMESH.TextureId = "http://www.roblox.com/asset/?id="..TEXTUREID | |
3988 | end | |
3989 | end | |
3990 | NEWMESH.Offset = OFFSET or VT(0, 0, 0) | |
3991 | NEWMESH.Scale = SCALE | |
3992 | NEWMESH.Parent = PARENT | |
3993 | return NEWMESH | |
3994 | end | |
3995 | ||
3996 | EffectModel = Instance.new("Model", char) | |
3997 | Effects = { | |
3998 | Block = { | |
3999 | Create = function(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay, Type) | |
4000 | local prt = CFuncs.Part.Create(EffectModel, "SmoothPlastic", 0, 0, brickcolor, "Effect", Vector3.new()) | |
4001 | prt.Anchored = true | |
4002 | prt.CFrame = cframe | |
4003 | local msh = CFuncs.Mesh.Create("BlockMesh", prt, "", "", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1)) | |
4004 | game:GetService("Debris"):AddItem(prt, 10) | |
4005 | if Type == 1 or Type == nil then | |
4006 | table.insert(Effects, { | |
4007 | prt, | |
4008 | "Block1", | |
4009 | delay, | |
4010 | x3, | |
4011 | y3, | |
4012 | z3, | |
4013 | msh | |
4014 | }) | |
4015 | elseif Type == 2 then | |
4016 | table.insert(Effects, { | |
4017 | prt, | |
4018 | "Block2", | |
4019 | delay, | |
4020 | x3, | |
4021 | y3, | |
4022 | z3, | |
4023 | msh | |
4024 | }) | |
4025 | else | |
4026 | table.insert(Effects, { | |
4027 | prt, | |
4028 | "Block3", | |
4029 | delay, | |
4030 | x3, | |
4031 | y3, | |
4032 | z3, | |
4033 | msh | |
4034 | }) | |
4035 | end | |
4036 | end | |
4037 | }, | |
4038 | Sphere = { | |
4039 | Create = function(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay) | |
4040 | local prt = CFuncs.Part.Create(EffectModel, "Neon", 0, 0, brickcolor, "Effect", Vector3.new()) | |
4041 | prt.Anchored = true | |
4042 | prt.CFrame = cframe | |
4043 | local msh = CFuncs.Mesh.Create("SpecialMesh", prt, "Sphere", "", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1)) | |
4044 | game:GetService("Debris"):AddItem(prt, 10) | |
4045 | table.insert(Effects, { | |
4046 | prt, | |
4047 | "Cylinder", | |
4048 | delay, | |
4049 | x3, | |
4050 | y3, | |
4051 | z3, | |
4052 | msh | |
4053 | }) | |
4054 | end | |
4055 | }, | |
4056 | Cylinder = { | |
4057 | Create = function(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay) | |
4058 | local prt = CFuncs.Part.Create(EffectModel, "SmoothPlastic", 0, 0, brickcolor, "Effect", Vector3.new()) | |
4059 | prt.Anchored = true | |
4060 | prt.CFrame = cframe | |
4061 | local msh = CFuncs.Mesh.Create("CylinderMesh", prt, "", "", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1)) | |
4062 | game:GetService("Debris"):AddItem(prt, 10) | |
4063 | table.insert(Effects, { | |
4064 | prt, | |
4065 | "Cylinder", | |
4066 | delay, | |
4067 | x3, | |
4068 | y3, | |
4069 | z3, | |
4070 | msh | |
4071 | }) | |
4072 | end | |
4073 | }, | |
4074 | Wave = { | |
4075 | Create = function(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay) | |
4076 | local prt = CFuncs.Part.Create(EffectModel, "Neon", 0, 0, brickcolor, "Effect", Vector3.new()) | |
4077 | prt.Anchored = true | |
4078 | prt.CFrame = cframe | |
4079 | local msh = CFuncs.Mesh.Create("SpecialMesh", prt, "FileMesh", "rbxassetid://0", Vector3.new(0, 0, 0), Vector3.new(x1 / 60, y1 / 60, z1 / 60)) | |
4080 | Cso("2755928629", tors, 10, 1) | |
4081 | chatfunc("print (''you got that'')", BrickColor.new("Really red").Color) | |
4082 | wait(0,35) | |
4083 | game:GetService("Debris"):AddItem(prt, 10) | |
4084 | table.insert(Effects, { | |
4085 | prt, | |
4086 | "Cylinder", | |
4087 | delay, | |
4088 | x3 / 60, | |
4089 | y3 / 60, | |
4090 | z3 / 60, | |
4091 | msh | |
4092 | }) | |
4093 | end | |
4094 | }, | |
4095 | Ring = { | |
4096 | Create = function(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay) | |
4097 | local prt = CFuncs.Part.Create(EffectModel, "SmoothPlastic", 0, 0, brickcolor, "Effect", Vector3.new()) | |
4098 | prt.Anchored = true | |
4099 | prt.CFrame = cframe | |
4100 | local msh = CFuncs.Mesh.Create("SpecialMesh", prt, "FileMesh", "rbxassetid://3270017", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1)) | |
4101 | game:GetService("Debris"):AddItem(prt, 10) | |
4102 | table.insert(Effects, { | |
4103 | prt, | |
4104 | "Cylinder", | |
4105 | delay, | |
4106 | x3, | |
4107 | y3, | |
4108 | z3, | |
4109 | msh | |
4110 | }) | |
4111 | end | |
4112 | }, | |
4113 | Break = { | |
4114 | Create = function(brickcolor, cframe, x1, y1, z1) | |
4115 | local prt = CFuncs.Part.Create(EffectModel, "Neon", 0, 0, brickcolor, "Effect", Vector3.new(0.5, 0.5, 0.5)) | |
4116 | prt.Anchored = true | |
4117 | prt.CFrame = cframe * CFrame.fromEulerAnglesXYZ(math.random(-50, 50), math.random(-50, 50), math.random(-50, 50)) | |
4118 | local msh = CFuncs.Mesh.Create("SpecialMesh", prt, "Sphere", "", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1)) | |
4119 | local num = math.random(10, 50) / 1000 | |
4120 | game:GetService("Debris"):AddItem(prt, 10) | |
4121 | table.insert(Effects, { | |
4122 | prt, | |
4123 | "Shatter", | |
4124 | num, | |
4125 | prt.CFrame, | |
4126 | math.random() - math.random(), | |
4127 | 0, | |
4128 | math.random(50, 100) / 100 | |
4129 | }) | |
4130 | end | |
4131 | }, | |
4132 | Spiral = { | |
4133 | Create = function(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay) | |
4134 | local prt = CFuncs.Part.Create(EffectModel, "SmoothPlastic", 0, 0, brickcolor, "Effect", Vector3.new()) | |
4135 | prt.Anchored = true | |
4136 | prt.CFrame = cframe | |
4137 | local msh = CFuncs.Mesh.Create("SpecialMesh", prt, "FileMesh", "rbxassetid://1051557", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1)) | |
4138 | game:GetService("Debris"):AddItem(prt, 10) | |
4139 | table.insert(Effects, { | |
4140 | prt, | |
4141 | "Cylinder", | |
4142 | delay, | |
4143 | x3, | |
4144 | y3, | |
4145 | z3, | |
4146 | msh | |
4147 | }) | |
4148 | end | |
4149 | }, | |
4150 | Push = { | |
4151 | Create = function(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay) | |
4152 | local prt = CFuncs.Part.Create(EffectModel, "SmoothPlastic", 0, 0, brickcolor, "Effect", Vector3.new()) | |
4153 | prt.Anchored = true | |
4154 | prt.CFrame = cframe | |
4155 | local msh = CFuncs.Mesh.Create("SpecialMesh", prt, "FileMesh", "rbxassetid://437347603", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1)) | |
4156 | game:GetService("Debris"):AddItem(prt, 10) | |
4157 | table.insert(Effects, { | |
4158 | prt, | |
4159 | "Cylinder", | |
4160 | delay, | |
4161 | x3, | |
4162 | y3, | |
4163 | z3, | |
4164 | msh | |
4165 | }) | |
4166 | end | |
4167 | } | |
4168 | } | |
4169 | function part(formfactor ,parent, reflectance, transparency, brickcolor, name, size) | |
4170 | local fp = IT("Part") | |
4171 | fp.formFactor = formfactor | |
4172 | fp.Parent = parent | |
4173 | fp.Reflectance = reflectance | |
4174 | fp.Transparency = transparency | |
4175 | fp.CanCollide = false | |
4176 | fp.Locked = true | |
4177 | fp.BrickColor = brickcolor | |
4178 | fp.Name = name | |
4179 | fp.Size = size | |
4180 | fp.Position = tors.Position | |
4181 | RemoveOutlines(fp) | |
4182 | fp.Material = "SmoothPlastic" | |
4183 | fp:BreakJoints() | |
4184 | return fp | |
4185 | end | |
4186 | ||
4187 | function mesh(Mesh,part,meshtype,meshid,offset,scale) | |
4188 | local mesh = IT(Mesh) | |
4189 | mesh.Parent = part | |
4190 | if Mesh == "SpecialMesh" then | |
4191 | mesh.MeshType = meshtype | |
4192 | if meshid ~= "nil" then | |
4193 | mesh.MeshId = "http://www.roblox.com/asset/?id="..meshid | |
4194 | end | |
4195 | end | |
4196 | mesh.Offset = offset | |
4197 | mesh.Scale = scale | |
4198 | return mesh | |
4199 | end | |
4200 | ||
4201 | function Magic(bonuspeed, type, pos, scale, value, color, MType) | |
4202 | local type = type | |
4203 | local rng = Instance.new("Part", char) | |
4204 | rng.Anchored = true | |
4205 | rng.BrickColor = color | |
4206 | rng.CanCollide = false | |
4207 | rng.FormFactor = 3 | |
4208 | rng.Name = "Ring" | |
4209 | rng.Material = "Neon" | |
4210 | rng.Size = Vector3.new(1, 1, 1) | |
4211 | rng.Transparency = 0 | |
4212 | rng.TopSurface = 0 | |
4213 | rng.BottomSurface = 0 | |
4214 | rng.CFrame = pos | |
4215 | local rngm = Instance.new("SpecialMesh", rng) | |
4216 | rngm.MeshType = MType | |
4217 | rngm.Scale = scale | |
4218 | local scaler2 = 1 | |
4219 | if type == "Add" then | |
4220 | scaler2 = 1 * value | |
4221 | elseif type == "Divide" then | |
4222 | scaler2 = 1 / value | |
4223 | end | |
4224 | coroutine.resume(coroutine.create(function() | |
4225 | for i = 0, 10 / bonuspeed, 0.1 do | |
4226 | swait() | |
4227 | if type == "Add" then | |
4228 | scaler2 = scaler2 - 0.01 * value / bonuspeed | |
4229 | elseif type == "Divide" then | |
4230 | scaler2 = scaler2 - 0.01 / value * bonuspeed | |
4231 | end | |
4232 | rng.Transparency = rng.Transparency + 0.01 * bonuspeed | |
4233 | rngm.Scale = rngm.Scale + Vector3.new(scaler2 * bonuspeed, scaler2 * bonuspeed, scaler2 * bonuspeed) | |
4234 | end | |
4235 | rng:Destroy() | |
4236 | end)) | |
4237 | end | |
4238 | ||
4239 | function Eviscerate(dude) | |
4240 | if dude.Name ~= char then | |
4241 | local bgf = IT("BodyGyro", dude.Head) | |
4242 | bgf.CFrame = bgf.CFrame * CFrame.fromEulerAnglesXYZ(Rad(-90), 0, 0) | |
4243 | local val = IT("BoolValue", dude) | |
4244 | val.Name = "IsHit" | |
4245 | local ds = coroutine.wrap(function() | |
4246 | dude:WaitForChild("Head"):BreakJoints() | |
4247 | wait(0.5) | |
4248 | target = nil | |
4249 | coroutine.resume(coroutine.create(function() | |
4250 | for i, v in pairs(dude:GetChildren()) do | |
4251 | if v:IsA("Accessory") then | |
4252 | v:Destroy() | |
4253 | end | |
4254 | if v:IsA("Humanoid") then | |
4255 | v:Destroy() | |
4256 | end | |
4257 | if v:IsA("CharacterMesh") then | |
4258 | v:Destroy() | |
4259 | end | |
4260 | if v:IsA("Model") then | |
4261 | v:Destroy() | |
4262 | end | |
4263 | if v:IsA("Part") or v:IsA("MeshPart") then | |
4264 | for x, o in pairs(v:GetChildren()) do | |
4265 | if o:IsA("Decal") then | |
4266 | o:Destroy() | |
4267 | end | |
4268 | end | |
4269 | coroutine.resume(coroutine.create(function() | |
4270 | v.Material = "Neon" | |
4271 | v.CanCollide = false | |
4272 | local PartEmmit1 = IT("ParticleEmitter", v) | |
4273 | PartEmmit1.LightEmission = 1 | |
4274 | PartEmmit1.Texture = "rbxassetid://284205403" | |
4275 | PartEmmit1.Color = ColorSequence.new(maincolor.Color) | |
4276 | PartEmmit1.Rate = 150 | |
4277 | PartEmmit1.Lifetime = NumberRange.new(1) | |
4278 | PartEmmit1.Size = NumberSequence.new({ | |
4279 | NumberSequenceKeypoint.new(0, 0.75, 0), | |
4280 | NumberSequenceKeypoint.new(1, 0, 0) | |
4281 | }) | |
4282 | PartEmmit1.Transparency = NumberSequence.new({ | |
4283 | NumberSequenceKeypoint.new(0, 0, 0), | |
4284 | NumberSequenceKeypoint.new(1, 1, 0) | |
4285 | }) | |
4286 | PartEmmit1.Speed = NumberRange.new(0, 0) | |
4287 | PartEmmit1.VelocitySpread = 30000 | |
4288 | PartEmmit1.Rotation = NumberRange.new(-500, 500) | |
4289 | PartEmmit1.RotSpeed = NumberRange.new(-500, 500) | |
4290 | local BodPoss = IT("BodyPosition", v) | |
4291 | BodPoss.P = 3000 | |
4292 | BodPoss.D = 1000 | |
4293 | BodPoss.maxForce = Vector3.new(50000000000, 50000000000, 50000000000) | |
4294 | BodPoss.position = v.Position + Vector3.new(Mrandom(-15, 15), Mrandom(-15, 15), Mrandom(-15, 15)) | |
4295 | v.Color = maincolor.Color | |
4296 | coroutine.resume(coroutine.create(function() | |
4297 | for i = 0, 49 do | |
4298 | swait(1) | |
4299 | v.Transparency = v.Transparency + 0.08 | |
4300 | end | |
4301 | wait(0.5) | |
4302 | PartEmmit1.Enabled = false | |
4303 | wait(3) | |
4304 | v:Destroy() | |
4305 | dude:Destroy() | |
4306 | end)) | |
4307 | end)) | |
4308 | end | |
4309 | end | |
4310 | end)) | |
4311 | end) | |
4312 | ds() | |
4313 | end | |
4314 | end | |
4315 | ||
4316 | function FindNearestHead(Position, Distance, SinglePlayer) | |
4317 | if SinglePlayer then | |
4318 | return Distance > (SinglePlayer.Torso.CFrame.p - Position).magnitude | |
4319 | end | |
4320 | local List = {} | |
4321 | for i, v in pairs(workspace:GetChildren()) do | |
4322 | if v:IsA("Model") and v:findFirstChild("Head") and v ~= char and Distance >= (v.Head.Position - Position).magnitude then | |
4323 | table.insert(List, v) | |
4324 | end | |
4325 | end | |
4326 | return List | |
4327 | end | |
4328 | ||
4329 | function Aura(bonuspeed, FastSpeed, type, pos, x1, y1, z1, value, color, outerpos, MType) | |
4330 | local type = type | |
4331 | local rng = Instance.new("Part", char) | |
4332 | rng.Anchored = true | |
4333 | rng.BrickColor = color | |
4334 | rng.CanCollide = false | |
4335 | rng.FormFactor = 3 | |
4336 | rng.Name = "Ring" | |
4337 | rng.Material = "Neon" | |
4338 | rng.Size = Vector3.new(1, 1, 1) | |
4339 | rng.Transparency = 0 | |
4340 | rng.TopSurface = 0 | |
4341 | rng.BottomSurface = 0 | |
4342 | rng.CFrame = pos | |
4343 | rng.CFrame = rng.CFrame + rng.CFrame.lookVector * outerpos | |
4344 | local rngm = Instance.new("SpecialMesh", rng) | |
4345 | rngm.MeshType = MType | |
4346 | rngm.Scale = Vector3.new(x1, y1, z1) | |
4347 | local scaler2 = 1 | |
4348 | local speeder = FastSpeed | |
4349 | if type == "Add" then | |
4350 | scaler2 = 1 * value | |
4351 | elseif type == "Divide" then | |
4352 | scaler2 = 1 / value | |
4353 | end | |
4354 | coroutine.resume(coroutine.create(function() | |
4355 | for i = 0, 10 / bonuspeed, 0.1 do | |
4356 | swait() | |
4357 | if type == "Add" then | |
4358 | scaler2 = scaler2 - 0.01 * value / bonuspeed | |
4359 | elseif type == "Divide" then | |
4360 | scaler2 = scaler2 - 0.01 / value * bonuspeed | |
4361 | end | |
4362 | speeder = speeder - 0.01 * FastSpeed * bonuspeed | |
4363 | rng.CFrame = rng.CFrame + rng.CFrame.lookVector * speeder * bonuspeed | |
4364 | rng.Transparency = rng.Transparency + 0.01 * bonuspeed | |
4365 | rngm.Scale = rngm.Scale + Vector3.new(scaler2 * bonuspeed, scaler2 * bonuspeed, 0) | |
4366 | end | |
4367 | rng:Destroy() | |
4368 | end)) | |
4369 | end | |
4370 | ||
4371 | function SoulSteal(dude) | |
4372 | if dude.Name ~= char then | |
4373 | local bgf = IT("BodyGyro", dude.Head) | |
4374 | bgf.CFrame = bgf.CFrame * CFrame.fromEulerAnglesXYZ(Rad(-90), 0, 0) | |
4375 | local val = IT("BoolValue", dude) | |
4376 | val.Name = "IsHit" | |
4377 | local torso = (dude:FindFirstChild'Head' or dude:FindFirstChild'Torso' or dude:FindFirstChild'UpperTorso' or dude:FindFirstChild'LowerTorso' or dude:FindFirstChild'HumanoidRootPart') | |
4378 | local soulst = coroutine.wrap(function() | |
4379 | local soul = Instance.new("Part",dude) | |
4380 | soul.Size = Vector3.new(1,1,1) | |
4381 | soul.CanCollide = false | |
4382 | soul.Anchored = false | |
4383 | soul.Position = torso.Position | |
4384 | soul.Transparency = 1 | |
4385 | local PartEmmit1 = IT("ParticleEmitter", soul) | |
4386 | PartEmmit1.LightEmission = 1 | |
4387 | PartEmmit1.Texture = "rbxassetid://569507414" | |
4388 | PartEmmit1.Color = ColorSequence.new(maincolor.Color) | |
4389 | PartEmmit1.Rate = 250 | |
4390 | PartEmmit1.Lifetime = NumberRange.new(1.6) | |
4391 | PartEmmit1.Size = NumberSequence.new({ | |
4392 | NumberSequenceKeypoint.new(0, 1, 0), | |
4393 | NumberSequenceKeypoint.new(1, 0, 0) | |
4394 | }) | |
4395 | PartEmmit1.Transparency = NumberSequence.new({ | |
4396 | NumberSequenceKeypoint.new(0, 0, 0), | |
4397 | NumberSequenceKeypoint.new(1, 1, 0) | |
4398 | }) | |
4399 | PartEmmit1.Speed = NumberRange.new(0, 0) | |
4400 | PartEmmit1.VelocitySpread = 30000 | |
4401 | PartEmmit1.Rotation = NumberRange.new(-360, 360) | |
4402 | PartEmmit1.RotSpeed = NumberRange.new(-360, 360) | |
4403 | local BodPoss = IT("BodyPosition", soul) | |
4404 | BodPoss.P = 3000 | |
4405 | BodPoss.D = 1000 | |
4406 | BodPoss.maxForce = Vector3.new(50000000000, 50000000000, 50000000000) | |
4407 | BodPoss.position = torso.Position + Vector3.new(Mrandom(-15, 15), Mrandom(-15, 15), Mrandom(-15, 15)) | |
4408 | wait(1.6) | |
4409 | soul.Touched:connect(function(hit) | |
4410 | if hit.Parent == char then | |
4411 | soul:Destroy() | |
4412 | end | |
4413 | end) | |
4414 | wait(1.2) | |
4415 | while soul do | |
4416 | swait() | |
4417 | PartEmmit1.Color = ColorSequence.new(maincolor.Color) | |
4418 | BodPoss.Position = tors.Position | |
4419 | end | |
4420 | end) | |
4421 | soulst() | |
4422 | end | |
4423 | end | |
4424 | function FaceMouse() | |
4425 | local Cam = workspace.CurrentCamera | |
4426 | return { | |
4427 | CFrame.new(char.Torso.Position, Vector3.new(mouse.Hit.p.x, char.Torso.Position.y, mouse.Hit.p.z)), | |
4428 | Vector3.new(mouse.Hit.p.x, mouse.Hit.p.y, mouse.Hit.p.z) | |
4429 | } | |
4430 | end | |
4431 | ||
4432 | ------------------------------------------------------ | |
4433 | --End Effect Function-- | |
4434 | ------------------------------------------------------- | |
4435 | function Cso(ID, PARENT, VOLUME, PITCH) | |
4436 | local NSound = nil | |
4437 | coroutine.resume(coroutine.create(function() | |
4438 | NSound = IT("Sound", PARENT) | |
4439 | NSound.Volume = VOLUME | |
4440 | NSound.Pitch = PITCH | |
4441 | NSound.SoundId = "http://www.roblox.com/asset/?id="..ID | |
4442 | swait() | |
4443 | NSound:play() | |
4444 | game:GetService("Debris"):AddItem(NSound, 50) | |
4445 | end)) | |
4446 | return NSound | |
4447 | end | |
4448 | function CameraEnshaking(Length, Intensity) | |
4449 | coroutine.resume(coroutine.create(function() | |
4450 | local intensity = 1 * Intensity | |
4451 | local rotM = 0.01 * Intensity | |
4452 | for i = 0, Length, 0.1 do | |
4453 | swait() | |
4454 | intensity = intensity - 0.05 * Intensity / Length | |
4455 | rotM = rotM - 5.0E-4 * Intensity / Length | |
4456 | hum.CameraOffset = Vector3.new(Rad(Mrandom(-intensity, intensity)), Rad(Mrandom(-intensity, intensity)), Rad(Mrandom(-intensity, intensity))) | |
4457 | cam.CFrame = cam.CFrame * CF(Rad(Mrandom(-intensity, intensity)), Rad(Mrandom(-intensity, intensity)), Rad(Mrandom(-intensity, intensity))) * Euler(Rad(Mrandom(-intensity, intensity)) * rotM, Rad(Mrandom(-intensity, intensity)) * rotM, Rad(Mrandom(-intensity, intensity)) * rotM) | |
4458 | end | |
4459 | hum.CameraOffset = Vector3.new(0, 0, 0) | |
4460 | end)) | |
4461 | end | |
4462 | ------------------------------------------------------- | |
4463 | --End Important Functions-- | |
4464 | ------------------------------------------------------- | |
4465 | ||
4466 | ||
4467 | ------------------------------------------------------- | |
4468 | --Start Customization-- | |
4469 | ------------------------------------------------------- | |
4470 | local Player_Size = 1 | |
4471 | if Player_Size ~= 1 then | |
4472 | root.Size = root.Size * Player_Size | |
4473 | tors.Size = tors.Size * Player_Size | |
4474 | hed.Size = hed.Size * Player_Size | |
4475 | ra.Size = ra.Size * Player_Size | |
4476 | la.Size = la.Size * Player_Size | |
4477 | rl.Size = rl.Size * Player_Size | |
4478 | ll.Size = ll.Size * Player_Size | |
4479 | ---------------------------------------------------------------------------------- | |
4480 | rootj.Parent = root | |
4481 | neck.Parent = tors | |
4482 | RW.Parent = tors | |
4483 | LW.Parent = tors | |
4484 | RH.Parent = tors | |
4485 | LH.Parent = tors | |
4486 | ---------------------------------------------------------------------------------- | |
4487 | rootj.C0 = RootCF * CF(5 * Player_Size, 5 * Player_Size, 5 * Player_Size) * angles(Rad(0), Rad(0), Rad(0)) | |
4488 | rootj.C1 = RootCF * CF(0 * Player_Size, 0 * Player_Size, 0 * Player_Size) * angles(Rad(0), Rad(0), Rad(0)) | |
4489 | neck.C0 = necko * CF(0 * Player_Size, 0 * Player_Size, 0 + ((5 * Player_Size) - 5)) * angles(Rad(0), Rad(0), Rad(0)) | |
4490 | neck.C1 = CF(0 * Player_Size, -0.5 * Player_Size, 0 * Player_Size) * angles(Rad(-90), Rad(0), Rad(180)) | |
4491 | RW.C0 = CF(1.5 * Player_Size, 0.5 * Player_Size, 0 * Player_Size) * angles(Rad(0), Rad(0), Rad(0)) --* RIGHTSHOULDERC0 | |
4492 | LW.C0 = CF(-1.5 * Player_Size, 0.5 * Player_Size, 0 * Player_Size) * angles(Rad(0), Rad(0), Rad(0)) --* LEFTSHOULDERC0 | |
4493 | ---------------------------------------------------------------------------------- | |
4494 | RH.C0 = CF(5 * Player_Size, -5 * Player_Size, 5 * Player_Size) * angles(Rad(0), Rad(90), Rad(0)) * angles(Rad(0), Rad(0), Rad(0)) | |
4495 | LH.C0 = CF(-5 * Player_Size, -5 * Player_Size, 5 * Player_Size) * angles(Rad(0), Rad(-90), Rad(0)) * angles(Rad(0), Rad(0), Rad(0)) | |
4496 | RH.C1 = CF(5 * Player_Size, 5 * Player_Size, 5 * Player_Size) * angles(Rad(0), Rad(90), Rad(0)) * angles(Rad(0), Rad(0), Rad(0)) | |
4497 | LH.C1 = CF(-5 * Player_Size, 5 * Player_Size, 5 * Player_Size) * angles(Rad(0), Rad(-90), Rad(0)) * angles(Rad(0), Rad(0), Rad(0)) | |
4498 | --hat.Parent = Character | |
4499 | end | |
4500 | ---------------------------------------------------------------------------------- | |
4501 | ---------------------------------------------------------------------------------- | |
4502 | local equipped = false | |
4503 | local idle = 0 | |
4504 | local change = 1 | |
4505 | local val = 0 | |
4506 | local toim = 0 | |
4507 | local idleanim = 0.4 | |
4508 | local sine = 0 | |
4509 | local Sit = 1 | |
4510 | ---------------------------------------------------------------------------------- | |
4511 | hum.WalkSpeed = 8 | |
4512 | hum.JumpPower = 57 | |
4513 | hum.Animator.Parent = nil | |
4514 | ---------------------------------------------------------------------------------- | |
4515 | local Blob = Instance.new("Part", char) | |
4516 | Blob.Name = "Bloby" | |
4517 | Blob.CanCollide = false | |
4518 | Blob.BrickColor = BrickColor.new("Really black") | |
4519 | Blob.Transparency = 0 | |
4520 | Blob.Material = "Plastic" | |
4521 | Blob.Size = Vector3.new(1, 1, 2) | |
4522 | Blob.TopSurface = Enum.SurfaceType.Smooth | |
4523 | Blob.BottomSurface = Enum.SurfaceType.Smooth | |
4524 | ||
4525 | local Weld = Instance.new("Weld", Blob) | |
4526 | Weld.Part0 = ra | |
4527 | Weld.Part1 = Blob | |
4528 | Weld.C1 = CFrame.new(0, -2, 1.1) | |
4529 | Weld.C0 = CFrame.Angles(Rad(-86),0,0) | |
4530 | ||
4531 | local M2 = Instance.new("SpecialMesh") | |
4532 | M2.Parent = Blob | |
4533 | M2.MeshId = "http://www.roblox.com/asset/?id=432791411" | |
4534 | M2.TextureId = "http://www.roblox.com/asset/?id=160810181" | |
4535 | M2.Scale = Vector3.new(2, 2, 2) | |
4536 | ||
4537 | --[[local naeeym2 = Instance.new("BillboardGui",char) | |
4538 | naeeym2.AlwaysOnTop = true | |
4539 | naeeym2.Size = UDim2.new(5,35,2,15) | |
4540 | naeeym2.StudsOffset = Vector3.new(0, 3.5, 0) | |
4541 | naeeym2.Adornee = hed | |
4542 | naeeym2.Name = "Name" | |
4543 | --naeeym2.PlayerToHideFrom = Player | |
4544 | local tecks2 = Instance.new("TextLabel",naeeym2) | |
4545 | tecks2.BackgroundTransparency = 1 | |
4546 | tecks2.TextScaled = true | |
4547 | tecks2.BorderSizePixel = 0 | |
4548 | tecks2.Text = "Fight Me" | |
4549 | tecks2.Font = Enum.Font.Bodoni | |
4550 | tecks2.TextSize = 30 | |
4551 | tecks2.TextStrokeTransparency = 0 | |
4552 | tecks2.TextColor3 = Color3.new(0, 0, 0) | |
4553 | tecks2.TextStrokeColor3 = Color3.new(205, 84, 75) | |
4554 | tecks2.Size = UDim2.new(1,0,0.5,0) | |
4555 | tecks2.Parent = naeeym2]] | |
4556 | ------------------------------------------------------- | |
4557 | --End Customization-- | |
4558 | ------------------------------------------------------- | |
4559 | ||
4560 | ------------------------------------------------------- | |
4561 | --Start Attacks N Stuff-- | |
4562 | ------------------------------------------------------- | |
4563 | local naeeym2 = Instance.new("BillboardGui",char) | |
4564 | naeeym2.AlwaysOnTop = true | |
4565 | naeeym2.Size = UDim2.new(5,35,2,35) | |
4566 | naeeym2.StudsOffset = Vector3.new(0,2,0) | |
4567 | naeeym2.Adornee = hed | |
4568 | naeeym2.Name = "Name" | |
4569 | ||
4570 | local tecks2 = Instance.new("TextLabel",naeeym2) | |
4571 | CFuncs.Sound.Create("rbxassetid://0", root, 1.85, 1) | |
4572 | tecks2.BackgroundTransparency = 1 | |
4573 | tecks2.TextScaled = true | |
4574 | tecks2.BorderSizePixel = 0 | |
4575 | tecks2.Text = "" | |
4576 | tecks2.Font = "Fantasy" | |
4577 | tecks2.TextSize = 30 | |
4578 | tecks2.TextStrokeTransparency = 0 | |
4579 | tecks2.TextColor3 = BrickColor.new('Really red').Color | |
4580 | tecks2.TextStrokeColor3 = BrickColor.new('Really black').Color | |
4581 | tecks2.Size = UDim2.new(1,0,0.5,0) | |
4582 | tecks2.Parent = naeeym2 | |
4583 | textfag = tecks2 | |
4584 | CFuncs.Sound.Create("rbxassetid://0", root, 1.85, 1) | |
4585 | tecks2.Text = "" | |
4586 | CFuncs.Sound.Create("rbxassetid://2755928629", root, 1.85, 1) | |
4587 | tecks2.Text = "script by xdielivex" | |
4588 | wait(2) | |
4589 | CFuncs.Sound.Create("rbxassetid://0", root, 1.85, 1) | |
4590 | tecks2.Text = "" | |
4591 | coroutine.resume(coroutine.create(function() | |
4592 | while textfag ~= nil do | |
4593 | swait() | |
4594 | textfag.Position = UDim2.new(math.random(-.2,.2),math.random(-3,3),.05,math.random(-3,3)) | |
4595 | textfag.Rotation = math.random(-3,3) | |
4596 | end | |
4597 | end)) | |
4598 | ||
4599 | hed.face.Texture = "http://www.roblox.com/asset/?id=0" | |
4600 | for i,v in pairs(char:children()) do | |
4601 | if v:IsA("Shirt") and v:IsA("Pants") and v:IsA("Hat") and v:IsA("Accessory") then | |
4602 | v:Remove() | |
4603 | end | |
4604 | end | |
4605 | shirt = Instance.new("Shirt", char) | |
4606 | shirt.Name = "Shirt" | |
4607 | pants = Instance.new("Pants", char) | |
4608 | pants.Name = "Pants" | |
4609 | char.Shirt.ShirtTemplate = "rbxassetid://2018917293" | |
4610 | char.Pants.PantsTemplate = "rbxassetid://398633812" | |
4611 | local Hair2 = Instance.new("Part", char) | |
4612 | Hair2.Name = "Hair2" | |
4613 | Hair2.CanCollide = false | |
4614 | Hair2.BrickColor = BrickColor.new("CGA brown") | |
4615 | Hair2.Transparency = 0 | |
4616 | Hair2.Material = "Plastic" | |
4617 | Hair2.Size = Vector3.new(1, 1, 2) | |
4618 | Hair2.TopSurface = Enum.SurfaceType.Smooth | |
4619 | Hair2.BottomSurface = Enum.SurfaceType.Smooth | |
4620 | ||
4621 | local Weld = Instance.new("Weld", Hair2) | |
4622 | Weld.Part0 = hed | |
4623 | Weld.Part1 = Hair2 | |
4624 | Weld.C1 = CFrame.new(0,-0.1,0.60) | |
4625 | Weld.C0 = CFrame.Angles(math.rad(0),math.rad(0),0) | |
4626 | ||
4627 | local M2 = Instance.new("SpecialMesh") | |
4628 | M2.Parent = Hair2 | |
4629 | M2.MeshId = "http://www.roblox.com/asset/?id=1703946602" | |
4630 | M2.TextureId = "http://www.roblox.com/asset/?id=916236071" | |
4631 | M2.Scale = Vector3.new(1, 1, 1) | |
4632 | local AddInstance = function(Object, ...) | |
4633 | local Obj = Instance.new(Object) | |
4634 | for i,v in next,(...) do | |
4635 | Obj[i] = v | |
4636 | end | |
4637 | return Obj | |
4638 | end | |
4639 | ||
4640 | ||
4641 | ---------------------------------------------------- | |
4642 | local Reaper = AddInstance("Part",{ | |
4643 | Parent = hed, | |
4644 | CFrame = hed.CFrame, | |
4645 | formFactor = "Symmetric", | |
4646 | Size = Vector3.new(1, 1, 1), | |
4647 | CanCollide = false, | |
4648 | TopSurface = "Smooth", | |
4649 | BottomSurface = "Smooth", | |
4650 | Locked = true, | |
4651 | }) | |
4652 | local Weld = AddInstance("Weld",{ | |
4653 | Parent = Reaper, | |
4654 | Part0 = hed, | |
4655 | C0 = CFrame.new(0, 0, 0)*CFrame.Angles(0, 0, 0), | |
4656 | Part1 = Reaper, | |
4657 | }) | |
4658 | local Mesh = AddInstance("SpecialMesh",{ | |
4659 | Parent = Reaper, | |
4660 | MeshId = "rbxassetid://0", | |
4661 | TextureId = "rbxassetid://0", | |
4662 | Scale = Vector3.new(1.1, 1.1, 1.1), | |
4663 | VertexColor = Vector3.new(0.3, 0.3, 0.3), | |
4664 | }) | |
4665 | ||
4666 | function dash() | |
4667 | dashing = true | |
4668 | attack = true | |
4669 | local bv = Instance.new("BodyVelocity") | |
4670 | bv.maxForce = Vector3.new(1e9, 1e9, 1e9) | |
4671 | bv.velocity = root.CFrame.lookVector*200 | |
4672 | bv.Parent = root | |
4673 | for i = 0,1,0.1 do | |
4674 | swait() | |
4675 | bv.velocity = root.CFrame.lookVector*200 | |
4676 | RootJoint.C0 = clerp(RootJoint.C0,RootCF*CF(0,0,0)* angles(math.rad(50),math.rad(0),math.rad(0)),0.5) | |
4677 | Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(5),math.rad(0),math.rad(0)),.5) | |
4678 | RW.C0 = clerp(RW.C0, CFrame.new(1.45, 0.5, 0) * angles(math.rad(-80), math.rad(0), math.rad(50)), 0.5) | |
4679 | LW.C0 = clerp(LW.C0, CFrame.new(-1.45, 0.5, 0) * angles(math.rad(-80), math.rad(0), math.rad(-50)), 0.5) | |
4680 | RH.C0=clerp(RH.C0,CF(1,-1 - 0.05 * math.cos(sine / 25),0)*angles(math.rad(0),math.rad(90),math.rad(0))*angles(math.rad(-5),math.rad(0),math.rad(-20)),.1) | |
4681 | LH.C0=clerp(LH.C0,CF(-1,-1 - 0.05 * math.cos(sine / 25),0)*angles(math.rad(0),math.rad(-90),math.rad(0))*angles(math.rad(-5),math.rad(0),math.rad(20)),.1) | |
4682 | end | |
4683 | bv:Destroy() | |
4684 | attack = false | |
4685 | dashing = false | |
4686 | end | |
4687 | ------------------------------------------------------- | |
4688 | wait() | |
4689 | plr = game.Players.LocalPlayer | |
4690 | char = plr.Character | |
4691 | mouse = plr:GetMouse() | |
4692 | epicmode = false | |
4693 | normal = true | |
4694 | for i,v in pairs(char:GetChildren()) do | |
4695 | if v.ClassName == "Shirt" or v.ClassName == "Pants" or v.ClassName == "ShirtGraphic" then | |
4696 | v:Destroy() | |
4697 | end | |
4698 | end | |
4699 | for i,v in pairs(char:GetChildren()) do | |
4700 | if v.ClassName == "Hat" or v.ClassName == "Accessory" then | |
4701 | v:Destroy() | |
4702 | end | |
4703 | end | |
4704 | ---------------------------------------------------------------------- | |
4705 | Circle = nil | |
4706 | CircleParts = {} | |
4707 | Equipped = false | |
4708 | ||
4709 | function RayCast(Position, Direction, MaxDistance, IgnoreList) | |
4710 | return game:GetService("Workspace"):FindPartOnRayWithIgnoreList(Ray.new(Position, Direction.unit * (MaxDistance or 999.999)), IgnoreList) | |
4711 | end | |
4712 | Equipped = true | |
4713 | Circle = Instance.new("Model") | |
4714 | Circle.Name = "Circle" | |
4715 | Angle = 0 | |
4716 | for i = 1, 1 do | |
4717 | local CirclePart = Instance.new("Part") | |
4718 | CirclePart.Name = "CirclePart" | |
4719 | CirclePart.Transparency = 1 | |
4720 | CirclePart.BrickColor = BrickColor.new("Really black") | |
4721 | CirclePart.Material = Enum.Material.Plastic | |
4722 | CirclePart.Shape = Enum.PartType.Block | |
4723 | CirclePart.FormFactor = Enum.FormFactor.Custom | |
4724 | CirclePart.TopSurface = Enum.SurfaceType.Smooth | |
4725 | CirclePart.BottomSurface = Enum.SurfaceType.Smooth | |
4726 | CirclePart.Anchored = true | |
4727 | CirclePart.CanCollide = false | |
4728 | CirclePart.Locked = true | |
4729 | CirclePart.Size = Vector3.new(10, 0.2, 10) | |
4730 | local Aura = Instance.new('ParticleEmitter') | |
4731 | Aura.Name = "Aura" | |
4732 | Aura.Texture = "rbxassetid://0" | |
4733 | Aura.Parent = CirclePart | |
4734 | Aura.LightEmission = 0 | |
4735 | Aura.Transparency = NumberSequence.new(0.2,0.4,1) | |
4736 | Aura.Color = ColorSequence.new(Color3.new(255/255, 255/255, 0/255),Color3.new(255/200, 200/200, 200/200)) | |
4737 | Aura.Size = NumberSequence.new(0.9,0.5,0.3) | |
4738 | Aura.LockedToPart = false | |
4739 | Aura.Lifetime = NumberRange.new(1) | |
4740 | Aura.Rate = 50 | |
4741 | Aura.Speed = NumberRange.new(2.5) | |
4742 | Aura.SpreadAngle = Vector2.new(80,80) | |
4743 | local BlockMesh = Instance.new("BlockMesh") | |
4744 | BlockMesh.Scale = Vector3.new(1, (1 + (0.005 * i)), 1) | |
4745 | BlockMesh.Parent = CirclePart | |
4746 | CirclePart.Parent = Circle | |
4747 | local Star = Instance.new("Decal", CirclePart) | |
4748 | Star.Texture = "http://www.roblox.com/asset/?id=124339739" | |
4749 | Star.Face = "Top" | |
4750 | local Light = Instance.new("PointLight", CirclePart) | |
4751 | Light.Color = Color3.new(.20,0,0) | |
4752 | Light.Brightness = 100 | |
4753 | Light.Range = 15 | |
4754 | table.insert(CircleParts, CirclePart) | |
4755 | end | |
4756 | Spawn(function() | |
4757 | while Equipped and Humanoid.Parent and Torso.Parent do | |
4758 | if Angle == 360 then | |
4759 | Angle = 0 | |
4760 | end | |
4761 | Angle = Angle + 0.05 | |
4762 | local Hit, EndPosition = RayCast(Torso.Position, Vector3.new(0, -1, 0), (Torso.Size.Y * 6.5), {Character}) | |
4763 | if Hit then | |
4764 | if not Circle.Parent then | |
4765 | Circle.Parent = Character | |
4766 | end | |
4767 | for i, v in pairs(CircleParts) do | |
4768 | v.CFrame = CFrame.new(Torso.Position.X, EndPosition.Y, Torso.Position.Z) * CFrame.Angles(0, (Angle + i), 0) | |
4769 | end | |
4770 | else | |
4771 | Circle.Parent = nil | |
4772 | end | |
4773 | wait() | |
4774 | end | |
4775 | end) | |
4776 | ||
4777 | function chatfunc(text, color) | |
4778 | local chat = coroutine.wrap(function() | |
4779 | if char:FindFirstChild("TalkingBillBoard") ~= nil then | |
4780 | char:FindFirstChild("TalkingBillBoard"):destroy() | |
4781 | end | |
4782 | local naeeym2 = Instance.new("BillboardGui", char) | |
4783 | naeeym2.Size = UDim2.new(0, 100, 0, 40) | |
4784 | naeeym2.StudsOffset = Vector3.new(0, 3, 0) | |
4785 | naeeym2.Adornee = hed | |
4786 | naeeym2.Name = "TalkingBillBoard" | |
4787 | local tecks2 = Instance.new("TextLabel", naeeym2) | |
4788 | tecks2.BackgroundTransparency = 1 | |
4789 | tecks2.BorderSizePixel = 0 | |
4790 | tecks2.Text = "" | |
4791 | tecks2.Font = "Fantasy" | |
4792 | tecks2.TextSize = 30 | |
4793 | tecks2.TextStrokeTransparency = 0 | |
4794 | tecks2.TextColor3 = color | |
4795 | tecks2.TextStrokeColor3 = Color3.new(0, 0, 0) | |
4796 | tecks2.Size = UDim2.new(1, 0, 0.5, 0) | |
4797 | local tecks3 = Instance.new("TextLabel", naeeym2) | |
4798 | tecks3.BackgroundTransparency = 1 | |
4799 | tecks3.BorderSizePixel = 0 | |
4800 | tecks3.Text = "" | |
4801 | tecks3.Font = "Fantasy" | |
4802 | tecks3.TextSize = 30 | |
4803 | tecks3.TextStrokeTransparency = 0 | |
4804 | tecks3.TextColor3 = Color3.new(0, 0, 0) | |
4805 | tecks3.TextStrokeColor3 = color | |
4806 | tecks3.Size = UDim2.new(1, 0, 0.5, 0) | |
4807 | coroutine.resume(coroutine.create(function() | |
4808 | while true do | |
4809 | swait(1) | |
4810 | tecks2.Position = UDim2.new(0, math.random(-5, 5), 0, math.random(-5, 5)) | |
4811 | tecks3.Position = UDim2.new(0, math.random(-5, 5), 0, math.random(-5, 5)) | |
4812 | tecks2.Rotation = math.random(-5, 5) | |
4813 | tecks3.Rotation = math.random(-5, 5) | |
4814 | end | |
4815 | end)) | |
4816 | for i = 1, string.len(text) do | |
4817 | CFuncs.Sound.Create("rbxassetid://274118116", char, 0.25, 0.115) | |
4818 | tecks2.Text = string.sub(text, 1, i) | |
4819 | tecks3.Text = string.sub(text, 1, i) | |
4820 | swait(1) | |
4821 | end | |
4822 | wait(1) | |
4823 | local randomrot = math.random(1, 2) | |
4824 | if randomrot == 1 then | |
4825 | for i = 1, 50 do | |
4826 | swait() | |
4827 | tecks2.Rotation = tecks2.Rotation - 0.75 | |
4828 | tecks2.TextStrokeTransparency = tecks2.TextStrokeTransparency + 0.04 | |
4829 | tecks2.TextTransparency = tecks2.TextTransparency + 0.04 | |
4830 | tecks3.Rotation = tecks2.Rotation + 0.75 | |
4831 | tecks3.TextStrokeTransparency = tecks2.TextStrokeTransparency + 0.04 | |
4832 | tecks3.TextTransparency = tecks2.TextTransparency + 0.04 | |
4833 | end | |
4834 | elseif randomrot == 2 then | |
4835 | for i = 1, 50 do | |
4836 | swait() | |
4837 | tecks2.Rotation = tecks2.Rotation + 0.75 | |
4838 | tecks2.TextStrokeTransparency = tecks2.TextStrokeTransparency + 0.04 | |
4839 | tecks2.TextTransparency = tecks2.TextTransparency + 0.04 | |
4840 | tecks3.Rotation = tecks2.Rotation - 0.75 | |
4841 | tecks3.TextStrokeTransparency = tecks2.TextStrokeTransparency + 0.04 | |
4842 | tecks3.TextTransparency = tecks2.TextTransparency + 0.04 | |
4843 | end | |
4844 | end | |
4845 | naeeym2:Destroy() | |
4846 | end) | |
4847 | chat() | |
4848 | end | |
4849 | --------------------------------------------------------- | |
4850 | ||
4851 | ||
4852 | ||
4853 | mouse.KeyDown:connect(function(key) | |
4854 | ||
4855 | attack = false | |
4856 | if key == "e" then | |
4857 | dash() | |
4858 | Cso("158037267", tors, 10, 1) | |
4859 | end | |
4860 | end) | |
4861 | mouse.Button1Down:connect(function(key) | |
4862 | if attack == false then | |
4863 | end | |
4864 | end) | |
4865 | ||
4866 | ||
4867 | ||
4868 | --------------------------------------------------------- | |
4869 | ||
4870 | ------------------------------------------------------- | |
4871 | --Start Animations-- | |
4872 | ------------------------------------------------------- | |
4873 | while true do | |
4874 | swait() | |
4875 | sine = sine + change | |
4876 | local torvel = (root.Velocity * Vector3.new(1, 0, 1)).magnitude | |
4877 | local velderp = root.Velocity.y | |
4878 | hitfloor, posfloor = rayCast(root.Position, CFrame.new(root.Position, root.Position - Vector3.new(0, 1, 0)).lookVector, 4* Player_Size, char) | |
4879 | if equipped == true or equipped == false then | |
4880 | if attack == false then | |
4881 | idle = idle + 1 | |
4882 | else | |
4883 | idle = 0 | |
4884 | end | |
4885 | if 1 < root.Velocity.y and hitfloor == nil then | |
4886 | Anim = "Jump" | |
4887 | if attack == false then | |
4888 | rootj.C0 = clerp(rootj.C0, RootCF * CF(0* Player_Size, 0* Player_Size, -0.1 + 0.1 * Cos(sine / 20)* Player_Size) * angles(Rad(-16), Rad(0), Rad(0)), 0.15) | |
4889 | neck.C0 = clerp(neck.C0, necko* CF(0, 0, 0 + ((1* Player_Size) - 1)) * angles(Rad(10 - 2.5 * Sin(sine / 30)), Rad(0), Rad(0)), 0.3) | |
4890 | RH.C0 = clerp(RH.C0, CF(1* Player_Size, -.2 - 0.1 * Cos(sine / 20)* Player_Size, -.3* Player_Size) * RHCF * angles(Rad(-2.5), Rad(0), Rad(0)), 0.15) | |
4891 | LH.C0 = clerp(LH.C0, CF(-1* Player_Size, -.9 - 0.1 * Cos(sine / 20), -.5* Player_Size) * LHCF * angles(Rad(-2.5), Rad(0), Rad(0)), 0.15) | |
4892 | RW.C0 = clerp(RW.C0, CF(1.5* Player_Size, 0.5 + 0.02 * Sin(sine / 20)* Player_Size, 0* Player_Size) * angles(Rad(25), Rad(-.6), Rad(13 + 4.5 * Sin(sine / 20))), 0.1) | |
4893 | LW.C0 = clerp(LW.C0, CF(-1.5* Player_Size, 0.5 + 0.02 * Sin(sine / 20)* Player_Size, 0* Player_Size) * angles(Rad(25), Rad(-.6), Rad(-13 - 4.5 * Sin(sine / 20))), 0.1) | |
4894 | end | |
4895 | elseif -1 > root.Velocity.y and hitfloor == nil then | |
4896 | Anim = "Fall" | |
4897 | if attack == false then | |
4898 | rootj.C0 = clerp(rootj.C0, RootCF * CF(0* Player_Size, 0* Player_Size, -0.1 + 0.1 * Cos(sine / 20)* Player_Size) * angles(Rad(24), Rad(0), Rad(0)), 0.15) | |
4899 | neck.C0 = clerp(neck.C0, necko* CF(0, 0, 0 + ((1* Player_Size) - 1)) * angles(Rad(10 - 2.5 * Sin(sine / 30)), Rad(0), Rad(0)), 0.3) | |
4900 | RH.C0 = clerp(RH.C0, CF(1 * Player_Size, -1 * Player_Size - 0.06 - 0.05 * Player_Size * Cos(sine / 12), -0.01 * Player_Size) * angles(Rad(0 - 2.5 * Sin(sine / 12)), Rad(79), Rad(0)) * angles(Rad(-6 - 2.5 * Sin(sine / 24)), Rad(0), Rad(0)), 0.15) | |
4901 | LH.C0 = clerp(LH.C0, CF(-1 * Player_Size, -1 * Player_Size - 0.06 - 0.05 * Player_Size * Cos(sine / 12), -0.01 * Player_Size) * angles(Rad(0 - 2.5 * Sin(sine / 12)), Rad(-79), Rad(0)) * angles(Rad(-6 + 2.5 * Sin(sine / 24)), Rad(0), Rad(0)), 0.15) | |
4902 | RW.C0 = clerp(RW.C0, CF(1.5* Player_Size, 0.5 + 0.02 * Sin(sine / 20)* Player_Size, 0* Player_Size) * angles(Rad(65), Rad(-.6), Rad(45 + 4.5 * Sin(sine / 20))), 0.1) | |
4903 | LW.C0 = clerp(LW.C0, CF(-1.5* Player_Size, 0.5 + 0.02 * Sin(sine / 20)* Player_Size, 0* Player_Size) * angles(Rad(55), Rad(-.6), Rad(-45 - 4.5 * Sin(sine / 20))), 0.1) | |
4904 | end | |
4905 | elseif torvel < 1 and hitfloor ~= nil then | |
4906 | Anim = "Idle" | |
4907 | change = 1 | |
4908 | if attack == false then | |
4909 | rootj.C0 = clerp(rootj.C0, RootCF * CF(0* Player_Size, 0* Player_Size, -0.1 + 0.1* Player_Size * Cos(sine / 20)) * angles(Rad(0), Rad(0), Rad(0)), 0.08) | |
4910 | tors.Neck.C0 = clerp(tors.Neck.C0, necko * angles(Rad(20), Rad(-10 - 2.5 * Sin(sine/ 20)), Rad(20 * Cos(sine / 20))), 0.3) | |
4911 | RH.C0 = clerp(RH.C0, CF(1* Player_Size, -0.9 - 0.1 * Cos(sine / 20)* Player_Size, 0* Player_Size) * angles(Rad(0), Rad(80), Rad(0)) * angles(Rad(-6.5), Rad(0), Rad(0)), 0.08) | |
4912 | LH.C0 = clerp(LH.C0, CF(-1* Player_Size, -0.9 - 0.1 * Cos(sine / 20)* Player_Size, 0* Player_Size) * angles(Rad(0), Rad(-80), Rad(0)) * angles(Rad(-6.5), Rad(0), Rad(0)), 0.08) | |
4913 | RW.C0 = clerp(RW.C0, CF(1 * Player_Size, 0.5 + 0.02 * Sin(sine / 12)* Player_Size, .6* Player_Size) * angles(Rad(-20), Rad(-.6), Rad(-43)), 0.08) | |
4914 | LW.C0 = clerp(LW.C0, CF(-1 * Player_Size, 0.5 + 0.02 * Sin(sine / 12)* Player_Size, .6* Player_Size) * angles(Rad(-20), Rad(-.6), Rad(43)), 0.08) | |
4915 | end | |
4916 | elseif torvel > 2 and torvel < 25 and hitfloor ~= nil then | |
4917 | Anim = "Walk" | |
4918 | change = 1 | |
4919 | if attack == false then | |
4920 | rootj.C0 = clerp(rootj.C0, RootCF * CF(0, 0, -0.175 + 0.025 * Cos(sine / 3.5) + -Sin(sine / 3.5) / 7) * angles(Rad(4-2.5 * Cos(sine / 3.5)), Rad(0) - root.RotVelocity.Y / 75, Rad(5 * Cos(sine / 7))), 0.15) | |
4921 | tors.Neck.C0 = clerp(tors.Neck.C0, necko * angles(Rad(-2.5 * Sin(sine / 20)), Rad(0), Rad(0) - hed.RotVelocity.Y / 15), 0.3) | |
4922 | RH.C0 = clerp(RH.C0, CF(1, -0.925 - 0.5 * Cos(sine / 7) / 2, 0.5 * Cos(sine / 7) / 2) * angles(Rad(-15 - 5 * Cos(sine / 7)) - rl.RotVelocity.Y / 75 + -Sin(sine / 7) / 2.5, Rad(90 - 0.1 * Cos(sine / 7)), Rad(0)) * angles(Rad(0 + 0.1 * Cos(sine / 7)), Rad(0), Rad(0)), 0.3) | |
4923 | LH.C0 = clerp(LH.C0, CF(-1, -0.925 + 0.5 * Cos(sine / 7) / 2, -0.5 * Cos(sine / 7) / 2) * angles(Rad(-15 + 5 * Cos(sine / 7)) + ll.RotVelocity.Y / 75 + Sin(sine / 7) / 2.5, Rad(-90 - 0.1 * Cos(sine / 7)), Rad(0)) * angles(Rad(0 - 0.1 * Cos(sine / 7)), Rad(0), Rad(0)), 0.3) | |
4924 | RW.C0 = clerp(RW.C0, CF(1.5, 0.5 + 0.05 * Sin(sine / 7), 0.15 * Cos(sine / 7)) * angles(Rad(45) * Cos(sine / 7) , Rad(0), Rad(5) - ra.RotVelocity.Y / 75), 0.1) | |
4925 | LW.C0 = clerp(LW.C0, CF(-1.5, 0.5 + 0.05 * Sin(sine / 7), -0.15 * Cos(sine / 7)) * angles(Rad(-45) * Cos(sine / 7) , Rad(0) , Rad(-5) + la.RotVelocity.Y / 75), 0.1) | |
4926 | end | |
4927 | elseif torvel >= 25 and hitfloor ~= nil then | |
4928 | Anim = "Sprint" | |
4929 | change = 1.35 | |
4930 | if attack == false then | |
4931 | rootj.C0 = clerp(rootj.C0, RootCF * CF(0* Player_Size, 0* Player_Size, -0.175 + 0.025 * Cos(sine / 3.5) + -Sin(sine / 3.5) / 7* Player_Size) * angles(Rad(26 - 4.5 * Cos(sine / 3.5)), Rad(0) - root.RotVelocity.Y / 75, Rad(15 * Cos(sine / 7))), 0.15) | |
4932 | tors.Neck.C0 = clerp(tors.Neck.C0, necko* CF(0, 0, 0 + ((1* Player_Size) - 1)) * angles(Rad(-2.5 * Sin(sine / 20)), Rad(0), Rad(0) - hed.RotVelocity.Y / 15), 0.3) | |
4933 | RH.C0 = clerp(RH.C0, CF(1* Player_Size, -0.925 - 0.5 * Cos(sine / 7) / 2* Player_Size, 0.7 * Cos(sine / 7) / 2* Player_Size) * angles(Rad(-15 - 55 * Cos(sine / 7)) - rl.RotVelocity.Y / 75 + -Sin(sine / 7) / 2.5, Rad(90 - 0.1 * Cos(sine / 7)), Rad(0)) * angles(Rad(0 + 0.1 * Cos(sine / 7)), Rad(0), Rad(0)), 0.3) | |
4934 | LH.C0 = clerp(LH.C0, CF(-1* Player_Size, -0.925 + 0.5 * Cos(sine / 7) / 2* Player_Size, -0.7 * Cos(sine / 7) / 2* Player_Size) * angles(Rad(-15 + 55 * Cos(sine / 7)) + ll.RotVelocity.Y / 75 + Sin(sine / 7) / 2.5, Rad(-90 - 0.1 * Cos(sine / 7)), Rad(0)) * angles(Rad(0 - 0.1 * Cos(sine / 7)), Rad(0), Rad(0)), 0.3) | |
4935 | RW.C0 = clerp(RW.C0, CF(1.5* Player_Size, 0.5 + 0.05 * Sin(sine / 30)* Player_Size, 0.34 * Cos(sine / 7* Player_Size)) * angles(Rad(110) * Cos(sine / 7) , Rad(0), Rad(13) - ra.RotVelocity.Y / 75), 0.15) | |
4936 | LW.C0 = clerp(LW.C0, CF(-1.5* Player_Size, 0.5 + 0.05 * Sin(sine / 30)* Player_Size, -0.34 * Cos(sine / 7* Player_Size)) * angles(Rad(-110) * Cos(sine / 7) , Rad(0) , Rad(-13) + la.RotVelocity.Y / 75), 0.15) | |
4937 | end | |
4938 | end | |
4939 | end | |
4940 | if 0 < #Effects then | |
4941 | for e = 1, #Effects do | |
4942 | if Effects[e] ~= nil then | |
4943 | local Thing = Effects[e] | |
4944 | if Thing ~= nil then | |
4945 | local Part = Thing[1] | |
4946 | local Mode = Thing[2] | |
4947 | local Delay = Thing[3] | |
4948 | local IncX = Thing[4] | |
4949 | local IncY = Thing[5] | |
4950 | local IncZ = Thing[6] | |
4951 | if 1 >= Thing[1].Transparency then | |
4952 | if Thing[2] == "Block1" then | |
4953 | Thing[1].CFrame = Thing[1].CFrame * CFrame.fromEulerAnglesXYZ(math.random(-50, 50), math.random(-50, 50), math.random(-50, 50)) | |
4954 | local Mesh = Thing[1].Mesh | |
4955 | Mesh.Scale = Mesh.Scale + Vector3.new(Thing[4], Thing[5], Thing[6]) | |
4956 | Thing[1].Transparency = Thing[1].Transparency + Thing[3] | |
4957 | elseif Thing[2] == "Block2" then | |
4958 | Thing[1].CFrame = Thing[1].CFrame + Vector3.new(0, 0, 0) | |
4959 | local Mesh = Thing[7] | |
4960 | Mesh.Scale = Mesh.Scale + Vector3.new(Thing[4], Thing[5], Thing[6]) | |
4961 | Thing[1].Transparency = Thing[1].Transparency + Thing[3] | |
4962 | elseif Thing[2] == "Block3" then | |
4963 | Thing[1].CFrame = Thing[1].CFrame * CFrame.fromEulerAnglesXYZ(math.random(-50, 50), math.random(-50, 50), math.random(-50, 50)) + Vector3.new(0, 0.15, 0) | |
4964 | local Mesh = Thing[7] | |
4965 | Mesh.Scale = Mesh.Scale + Vector3.new(Thing[4], Thing[5], Thing[6]) | |
4966 | Thing[1].Transparency = Thing[1].Transparency + Thing[3] | |
4967 | elseif Thing[2] == "Cylinder" then | |
4968 | local Mesh = Thing[1].Mesh | |
4969 | Mesh.Scale = Mesh.Scale + Vector3.new(Thing[4], Thing[5], Thing[6]) | |
4970 | Thing[1].Transparency = Thing[1].Transparency + Thing[3] | |
4971 | elseif Thing[2] == "Blood" then | |
4972 | local Mesh = Thing[7] | |
4973 | Thing[1].CFrame = Thing[1].CFrame * Vector3.new(0, 0.5, 0) | |
4974 | Mesh.Scale = Mesh.Scale + Vector3.new(Thing[4], Thing[5], Thing[6]) | |
4975 | Thing[1].Transparency = Thing[1].Transparency + Thing[3] | |
4976 | elseif Thing[2] == "Elec" then | |
4977 | local Mesh = Thing[1].Mesh | |
4978 | Mesh.Scale = Mesh.Scale + Vector3.new(Thing[7], Thing[8], Thing[9]) | |
4979 | Thing[1].Transparency = Thing[1].Transparency + Thing[3] | |
4980 | elseif Thing[2] == "Disappear" then | |
4981 | Thing[1].Transparency = Thing[1].Transparency + Thing[3] | |
4982 | elseif Thing[2] == "Shatter" then | |
4983 | Thing[1].Transparency = Thing[1].Transparency + Thing[3] | |
4984 | Thing[4] = Thing[4] * CFrame.new(0, Thing[7], 0) | |
4985 | Thing[1].CFrame = Thing[4] * CFrame.fromEulerAnglesXYZ(Thing[6], 0, 0) | |
4986 | Thing[6] = Thing[6] + Thing[5] | |
4987 | end | |
4988 | else | |
4989 | Part.Parent = nil | |
4990 | table.remove(Effects, e) | |
4991 | end | |
4992 | end | |
4993 | end | |
4994 | end | |
4995 | end | |
4996 | end | |
4997 | ------------------------------------------------------- | |
4998 | --End Animations And Script-- | |
4999 | ------------------------------------------------------- | |
5000 | ||
5001 | mouse.Button1Down:connect(function(key) | |
5002 | if attack == false then | |
5003 | Ban() | |
5004 | end | |
5005 | end) | |
5006 | ----------------------------------------------- | |
5007 | ||
5008 | theme = Instance.new("Sound", Head) | |
5009 | theme.Volume = 0.7 | |
5010 | theme.Name = "theme" | |
5011 | theme.Looped = true | |
5012 | ||
5013 | mouse.KeyDown:connect(function(Press) | |
5014 | Press=Press:lower() | |
5015 | if Press=='z' then | |
5016 | id = 0 | |
5017 | theme.SoundId = "rbxassetid://"..id | |
5018 | theme:Play() | |
5019 | end | |
5020 | end) | |
5021 | ||
5022 | mouse.KeyDown:connect(function(Press) | |
5023 | Press=Press:lower() | |
5024 | if Press=='c' then | |
5025 | id = 143809158 | |
5026 | theme.SoundId = "rbxassetid://"..id | |
5027 | theme:Play() | |
5028 | end | |
5029 | end) | |
5030 | ||
5031 | mouse.KeyDown:connect(function(Press) | |
5032 | Press=Press:lower() | |
5033 | if Press=='v' then | |
5034 | id = 136343853 | |
5035 | theme.SoundId = "rbxassetid://"..id | |
5036 | theme:Play() | |
5037 | end | |
5038 | end) | |
5039 | ||
5040 | mouse.KeyDown:connect(function(Press) | |
5041 | Press=Press:lower() | |
5042 | if Press=='b' then | |
5043 | id = 317697384 | |
5044 | theme.SoundId = "rbxassetid://"..id | |
5045 | theme:Play() | |
5046 | end | |
5047 | end) | |
5048 | ||
5049 | mouse.KeyDown:connect(function(Press) | |
5050 | Press=Press:lower() | |
5051 | if Press=='x' then | |
5052 | id = 235751894 | |
5053 | theme.SoundId = "rbxassetid://"..id | |
5054 | theme:Play() | |
5055 | end | |
5056 | end) |