SHOW:
|
|
- or go back to the newest paste.
1 | if game:GetService("RunService"):IsClient() then error("Script must be server-side in order to work; use h/ and not hl/") end | |
2 | local Player,game,owner = owner,game | |
3 | local RealPlayer = Player | |
4 | do | |
5 | print("FE Compatibility code by Mokiros") | |
6 | local rp = RealPlayer | |
7 | script.Parent = rp.Character | |
8 | ||
9 | --RemoteEvent for communicating | |
10 | local Event = Instance.new("RemoteEvent") | |
11 | Event.Name = "UserInput_Event" | |
12 | ||
13 | --Fake event to make stuff like Mouse.KeyDown work | |
14 | local function fakeEvent() | |
15 | local t = {_fakeEvent=true,Functions={},Connect=function(self,f)table.insert(self.Functions,f) end} | |
16 | t.connect = t.Connect | |
17 | return t | |
18 | end | |
19 | ||
20 | --Creating fake input objects with fake variables | |
21 | local m = {Target=nil,Hit=CFrame.new(),KeyUp=fakeEvent(),KeyDown=fakeEvent(),Button1Up=fakeEvent(),Button1Down=fakeEvent()} | |
22 | local UIS = {InputBegan=fakeEvent(),InputEnded=fakeEvent()} | |
23 | local CAS = {Actions={},BindAction=function(self,name,fun,touch,...) | |
24 | CAS.Actions[name] = fun and {Name=name,Function=fun,Keys={...}} or nil | |
25 | end} | |
26 | --Merged 2 functions into one by checking amount of arguments | |
27 | CAS.UnbindAction = CAS.BindAction | |
28 | ||
29 | --This function will trigger the events that have been :Connect()'ed | |
30 | local function te(self,ev,...) | |
31 | local t = m[ev] | |
32 | if t and t._fakeEvent then | |
33 | for _,f in pairs(t.Functions) do | |
34 | f(...) | |
35 | end | |
36 | end | |
37 | end | |
38 | m.TrigEvent = te | |
39 | UIS.TrigEvent = te | |
40 | ||
41 | Event.OnServerEvent:Connect(function(plr,io) | |
42 | if plr~=rp then return end | |
43 | m.Target = io.Target | |
44 | m.Hit = io.Hit | |
45 | if not io.isMouse then | |
46 | local b = io.UserInputState == Enum.UserInputState.Begin | |
47 | if io.UserInputType == Enum.UserInputType.MouseButton1 then | |
48 | return m:TrigEvent(b and "Button1Down" or "Button1Up") | |
49 | end | |
50 | for _,t in pairs(CAS.Actions) do | |
51 | for _,k in pairs(t.Keys) do | |
52 | if k==io.KeyCode then | |
53 | t.Function(t.Name,io.UserInputState,io) | |
54 | end | |
55 | end | |
56 | end | |
57 | m:TrigEvent(b and "KeyDown" or "KeyUp",io.KeyCode.Name:lower()) | |
58 | UIS:TrigEvent(b and "InputBegan" or "InputEnded",io,false) | |
59 | end | |
60 | end) | |
61 | Event.Parent = NLS([==[ | |
62 | local Player = game:GetService("Players").LocalPlayer | |
63 | local Event = script:WaitForChild("UserInput_Event") | |
64 | ||
65 | local Mouse = Player:GetMouse() | |
66 | local UIS = game:GetService("UserInputService") | |
67 | local input = function(io,a) | |
68 | if a then return end | |
69 | --Since InputObject is a client-side instance, we create and pass table instead | |
70 | Event:FireServer({KeyCode=io.KeyCode,UserInputType=io.UserInputType,UserInputState=io.UserInputState,Hit=Mouse.Hit,Target=Mouse.Target}) | |
71 | end | |
72 | UIS.InputBegan:Connect(input) | |
73 | UIS.InputEnded:Connect(input) | |
74 | ||
75 | local h,t | |
76 | --Give the server mouse data 30 times every second, but only if the values changed | |
77 | --If player is not moving their mouse, client won't fire events | |
78 | while wait(1/30) do | |
79 | if h~=Mouse.Hit or t~=Mouse.Target then | |
80 | h,t=Mouse.Hit,Mouse.Target | |
81 | Event:FireServer({isMouse=true,Target=t,Hit=h}) | |
82 | end | |
83 | end]==],Player.Character) | |
84 | ||
85 | ----Sandboxed game object that allows the usage of client-side methods and services | |
86 | --Real game object | |
87 | local _rg = game | |
88 | ||
89 | --Metatable for fake service | |
90 | local fsmt = { | |
91 | __index = function(self,k) | |
92 | local s = rawget(self,"_RealService") | |
93 | if s then return s[k] end | |
94 | end, | |
95 | __newindex = function(self,k,v) | |
96 | local s = rawget(self,"_RealService") | |
97 | if s then s[k]=v end | |
98 | end, | |
99 | __call = function(self,...) | |
100 | local s = rawget(self,"_RealService") | |
101 | if s then return s(...) end | |
102 | end | |
103 | } | |
104 | local function FakeService(t,RealService) | |
105 | t._RealService = typeof(RealService)=="string" and _rg:GetService(RealService) or RealService | |
106 | return setmetatable(t,fsmt) | |
107 | end | |
108 | ||
109 | --Fake game object | |
110 | local g = { | |
111 | GetService = function(self,s) | |
112 | return self[s] | |
113 | end, | |
114 | Players = FakeService({ | |
115 | LocalPlayer = FakeService({GetMouse=function(self)return m end},Player) | |
116 | },"Players"), | |
117 | UserInputService = FakeService(UIS,"UserInputService"), | |
118 | ContextActionService = FakeService(CAS,"ContextActionService"), | |
119 | } | |
120 | rawset(g.Players,"localPlayer",g.Players.LocalPlayer) | |
121 | g.service = g.GetService | |
122 | ||
123 | g.RunService = FakeService({ | |
124 | RenderStepped = _rg:GetService("RunService").Heartbeat, | |
125 | BindToRenderStep = function(self,name,_,fun) | |
126 | self._btrs[name] = self.Heartbeat:Connect(fun) | |
127 | end, | |
128 | UnbindFromRenderStep = function(self,name) | |
129 | self._btrs[name]:Disconnect() | |
130 | end, | |
131 | },"RunService") | |
132 | ||
133 | setmetatable(g,{ | |
134 | __index=function(self,s) | |
135 | return _rg:GetService(s) or typeof(_rg[s])=="function" | |
136 | and function(_,...)return _rg[s](_rg,...)end or _rg[s] | |
137 | end, | |
138 | __newindex = fsmt.__newindex, | |
139 | __call = fsmt.__call | |
140 | }) | |
141 | --Changing owner to fake player object to support owner:GetMouse() | |
142 | game,owner = g,g.Players.LocalPlayer | |
143 | end | |
144 | --------------- | |
145 | --Darkest Friend Kiro-- | |
146 | ---------------------------------------------------------------- | |
147 | print([[ | |
148 | - | -- Edit by CakeCoo |
148 | + | -- Edit by hero215sugar |
149 | - | --CREATED BY SHACKLUSTER -- |
149 | + | --CREATED BY nuttanun734 -- |
150 | -------------------------------------------------------------------------------------------- | |
151 | Hello, Dont leak the script if you have it,Thank you. | |
152 | Script.name(Darkest Friend,Kiro.Finished.Exe.Loaded | |
153 | --------------------------------------------------------------------------------------------- | |
154 | ]]) | |
155 | ||
156 | wait(0.2) | |
157 | ||
158 | Player = owner | |
159 | PlayerGui = Player.PlayerGui | |
160 | Cam = workspace.CurrentCamera | |
161 | Backpack = Player.Backpack | |
162 | Character = Player.Character | |
163 | Humanoid = Character.Humanoid | |
164 | Mouse = Player:GetMouse() | |
165 | RootPart = Character["HumanoidRootPart"] | |
166 | Torso = Character["Torso"] | |
167 | Head = Character["Head"] | |
168 | RightArm = Character["Right Arm"] | |
169 | LeftArm = Character["Left Arm"] | |
170 | RightLeg = Character["Right Leg"] | |
171 | LeftLeg = Character["Left Leg"] | |
172 | RootJoint = RootPart["RootJoint"] | |
173 | Neck = Torso["Neck"] | |
174 | RightShoulder = Torso["Right Shoulder"] | |
175 | LeftShoulder = Torso["Left Shoulder"] | |
176 | RightHip = Torso["Right Hip"] | |
177 | LeftHip = Torso["Left Hip"] | |
178 | local sick = Instance.new("Sound",Torso) | |
179 | sick.SoundId = "rbxassetid://566603081" | |
180 | sick.Looped = true | |
181 | sick.Pitch = 1 | |
182 | sick.Volume = 3 | |
183 | sick:Play() | |
184 | ||
185 | local Hood = Instance.new("Part", Character) | |
186 | Hood.Name = "Hood" | |
187 | Hood.CanCollide = false | |
188 | Hood.BrickColor = BrickColor.new("Really black") | |
189 | Hood.Transparency = 0 | |
190 | Hood.Material = "Plastic" | |
191 | Hood.Size = Vector3.new(0.1, 0.1, 0.1) | |
192 | Hood.TopSurface = Enum.SurfaceType.Smooth | |
193 | Hood.BottomSurface = Enum.SurfaceType.Smooth | |
194 | ||
195 | local Weld = Instance.new("Weld", Hood) | |
196 | Weld.Part0 = Character.Head | |
197 | Weld.Part1 = Hood | |
198 | Weld.C1 = CFrame.new(0, -0.2, 0) | |
199 | ||
200 | local M2 = Instance.new("SpecialMesh") | |
201 | M2.Parent = Hood | |
202 | M2.MeshId = "http://www.roblox.com/asset/?id=83499032" | |
203 | M2.Scale = Vector3.new( 1, 1.2, 1.1) | |
204 | ||
205 | IT = Instance.new | |
206 | CF = CFrame.new | |
207 | VT = Vector3.new | |
208 | RAD = math.rad | |
209 | C3 = Color3.new | |
210 | UD2 = UDim2.new | |
211 | BRICKC = BrickColor.new | |
212 | ANGLES = CFrame.Angles | |
213 | EULER = CFrame.fromEulerAnglesXYZ | |
214 | COS = math.cos | |
215 | ACOS = math.acos | |
216 | SIN = math.sin | |
217 | ASIN = math.asin | |
218 | ABS = math.abs | |
219 | MRANDOM = math.random | |
220 | FLOOR = math.floor | |
221 | local EYES = {} | |
222 | local WEAPONGUI = IT("ScreenGui", PlayerGui) | |
223 | local RWINGS = {} | |
224 | local LWINGS = {} | |
225 | local BOLTSOUNDS = {419011101,305734380} | |
226 | local LAUGHS = {834001699,834001752,834001797,834001828} | |
227 | local SONGS = {1118967006} | |
228 | local CHOICE = MRANDOM(1,4) | |
229 | local ENERGYSOUND = 1417051162 | |
230 | local BEAMSOUND = 1417056781 | |
231 | local EXPLOSIONSOUND = 1417056081 | |
232 | ||
233 | local ATTACKEDTAUNTS = { | |
234 | "907332040", | |
235 | "907332525", | |
236 | "907330011" | |
237 | } | |
238 | local ATTACKTAUNTS = { | |
239 | "907329893", | |
240 | "907329532", | |
241 | "907333294", | |
242 | "907332856" | |
243 | } | |
244 | local ULTTAUNTS = { | |
245 | "907332997", | |
246 | "907332670", | |
247 | "907330103" | |
248 | } | |
249 | ||
250 | chara = game.Players.LocalPlayer.Character | |
251 | ||
252 | local txt = Instance.new("BillboardGui", chara) | |
253 | CV="Really black" | |
254 | txt.Adornee = chara.Head | |
255 | txt.Name = "_status" | |
256 | txt.Size = UDim2.new(2, 0, 1.2, 0) | |
257 | txt.StudsOffset = Vector3.new(-9, 8, 0) | |
258 | local text = Instance.new("TextLabel", txt) | |
259 | text.Size = UDim2.new(10, 0, 7, 0) | |
260 | text.FontSize = "Size24" | |
261 | text.TextScaled = true | |
262 | text.TextTransparency = 0 | |
263 | text.BackgroundTransparency = 1 | |
264 | text.TextTransparency = 0 | |
265 | text.TextStrokeTransparency = 0 | |
266 | text.Font = "SciFi" | |
267 | text.TextStrokeColor3 = BrickColor.new("Really black").Color | |
268 | text.TextColor3 = BrickColor.new("Gold").Color | |
269 | text.Text = "Darkest Friend, Kiro" | |
270 | ||
271 | p = game.Players.LocalPlayer | |
272 | char = p.Character | |
273 | ||
274 | Character["Body Colors"].HeadColor = BrickColor.new("Really black") | |
275 | Character["Body Colors"].TorsoColor = BrickColor.new("Really black") | |
276 | Character["Body Colors"].LeftArmColor = BrickColor.new("Really black") | |
277 | Character["Body Colors"].RightArmColor = BrickColor.new("Really black") | |
278 | Character["Body Colors"].LeftLegColor = BrickColor.new("Really black") | |
279 | Character["Body Colors"].RightLegColor = BrickColor.new("Really black") | |
280 | --//=================================\\ | |
281 | --|| USEFUL VALUES | |
282 | --\\=================================// | |
283 | ||
284 | Animation_Speed = 1.5 | |
285 | local FORCERESET = false | |
286 | Frame_Speed = 1 / 60 -- (1 / 30) OR (1 / 60) | |
287 | local Speed = 16 | |
288 | local ROOTC0 = CF(0, 0, 0) * ANGLES(RAD(-90), RAD(0), RAD(180)) | |
289 | local NECKC0 = CF(0, 1, 0) * ANGLES(RAD(-90), RAD(0), RAD(180)) | |
290 | local RIGHTSHOULDERC0 = CF(-0.5, 0, 0) * ANGLES(RAD(0), RAD(90), RAD(0)) | |
291 | local LEFTSHOULDERC0 = CF(0.5, 0, 0) * ANGLES(RAD(0), RAD(-90), RAD(0)) | |
292 | local DAMAGEMULTIPLIER = 1 | |
293 | local ANIM = "Idle" | |
294 | local ATTACK = false | |
295 | local EQUIPPED = false | |
296 | local HOLD = false | |
297 | local COMBO = 1 | |
298 | local Rooted = false | |
299 | local SINE = 0 | |
300 | local KEYHOLD = false | |
301 | local CHANGE = 2 / Animation_Speed | |
302 | local WALKINGANIM = false | |
303 | local VALUE1 = false | |
304 | local VALUE2 = false | |
305 | local ROBLOXIDLEANIMATION = IT("Animation") | |
306 | ROBLOXIDLEANIMATION.Name = "Roblox Idle Animation" | |
307 | ROBLOXIDLEANIMATION.AnimationId = "http://www.roblox.com/asset/?id=180435571" | |
308 | --ROBLOXIDLEANIMATION.Parent = Humanoid | |
309 | local WEAPONGUI = IT("ScreenGui", PlayerGui) | |
310 | WEAPONGUI.Name = "BanishV3Gui" | |
311 | local Weapon = IT("Model") | |
312 | Weapon.Name = "Adds" | |
313 | local Effects = IT("Folder", Weapon) | |
314 | Effects.Name = "Effects" | |
315 | local ANIMATOR = Humanoid.Animator | |
316 | local ANIMATE = Character:FindFirstChild("Animate") | |
317 | local UNANCHOR = true | |
318 | local TOBANISH = {} | |
319 | script.Parent = PlayerGui | |
320 | ||
321 | --//=================================\\ | |
322 | --\\=================================// | |
323 | ||
324 | ||
325 | --//=================================\\ | |
326 | --|| SAZERENOS' ARTIFICIAL HEARTBEAT | |
327 | --\\=================================// | |
328 | ||
329 | ArtificialHB = Instance.new("BindableEvent", script) | |
330 | ArtificialHB.Name = "ArtificialHB" | |
331 | ||
332 | script:WaitForChild("ArtificialHB") | |
333 | ||
334 | frame = Frame_Speed | |
335 | tf = 0 | |
336 | allowframeloss = false | |
337 | tossremainder = false | |
338 | lastframe = tick() | |
339 | script.ArtificialHB:Fire() | |
340 | ||
341 | game:GetService("RunService").Heartbeat:connect(function(s, p) | |
342 | tf = tf + s | |
343 | if tf >= frame then | |
344 | if allowframeloss then | |
345 | script.ArtificialHB:Fire() | |
346 | lastframe = tick() | |
347 | else | |
348 | for i = 1, math.floor(tf / frame) do | |
349 | script.ArtificialHB:Fire() | |
350 | end | |
351 | lastframe = tick() | |
352 | end | |
353 | if tossremainder then | |
354 | tf = 0 | |
355 | else | |
356 | tf = tf - frame * math.floor(tf / frame) | |
357 | end | |
358 | end | |
359 | end) | |
360 | ||
361 | --//=================================\\ | |
362 | --\\=================================// | |
363 | ||
364 | --//=================================\\ | |
365 | --|| SOME FUNCTIONS | |
366 | --\\=================================// | |
367 | ||
368 | function Raycast(POSITION, DIRECTION, RANGE, IGNOREDECENDANTS) | |
369 | return workspace:FindPartOnRay(Ray.new(POSITION, DIRECTION.unit * RANGE), IGNOREDECENDANTS) | |
370 | end | |
371 | ||
372 | function PositiveAngle(NUMBER) | |
373 | if NUMBER >= 0 then | |
374 | NUMBER = 0 | |
375 | end | |
376 | return NUMBER | |
377 | end | |
378 | ||
379 | function NegativeAngle(NUMBER) | |
380 | if NUMBER <= 0 then | |
381 | NUMBER = 0 | |
382 | end | |
383 | return NUMBER | |
384 | end | |
385 | ||
386 | function Swait(NUMBER) | |
387 | if NUMBER == 0 or NUMBER == nil then | |
388 | ArtificialHB.Event:wait() | |
389 | else | |
390 | for i = 1, NUMBER do | |
391 | ArtificialHB.Event:wait() | |
392 | end | |
393 | end | |
394 | end | |
395 | ||
396 | function QuaternionFromCFrame(cf) | |
397 | local mx, my, mz, m00, m01, m02, m10, m11, m12, m20, m21, m22 = cf:components() | |
398 | local trace = m00 + m11 + m22 | |
399 | if trace > 0 then | |
400 | local s = math.sqrt(1 + trace) | |
401 | local recip = 0.5 / s | |
402 | return (m21 - m12) * recip, (m02 - m20) * recip, (m10 - m01) * recip, s * 0.5 | |
403 | else | |
404 | local i = 0 | |
405 | if m11 > m00 then | |
406 | i = 1 | |
407 | end | |
408 | if m22 > (i == 0 and m00 or m11) then | |
409 | i = 2 | |
410 | end | |
411 | if i == 0 then | |
412 | local s = math.sqrt(m00 - m11 - m22 + 1) | |
413 | local recip = 0.5 / s | |
414 | return 0.5 * s, (m10 + m01) * recip, (m20 + m02) * recip, (m21 - m12) * recip | |
415 | elseif i == 1 then | |
416 | local s = math.sqrt(m11 - m22 - m00 + 1) | |
417 | local recip = 0.5 / s | |
418 | return (m01 + m10) * recip, 0.5 * s, (m21 + m12) * recip, (m02 - m20) * recip | |
419 | elseif i == 2 then | |
420 | local s = math.sqrt(m22 - m00 - m11 + 1) | |
421 | local recip = 0.5 / s return (m02 + m20) * recip, (m12 + m21) * recip, 0.5 * s, (m10 - m01) * recip | |
422 | end | |
423 | end | |
424 | end | |
425 | ||
426 | function QuaternionToCFrame(px, py, pz, x, y, z, w) | |
427 | local xs, ys, zs = x + x, y + y, z + z | |
428 | local wx, wy, wz = w * xs, w * ys, w * zs | |
429 | local xx = x * xs | |
430 | local xy = x * ys | |
431 | local xz = x * zs | |
432 | local yy = y * ys | |
433 | local yz = y * zs | |
434 | local zz = z * zs | |
435 | 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)) | |
436 | end | |
437 | ||
438 | function QuaternionSlerp(a, b, t) | |
439 | local cosTheta = a[1] * b[1] + a[2] * b[2] + a[3] * b[3] + a[4] * b[4] | |
440 | local startInterp, finishInterp; | |
441 | if cosTheta >= 0.0001 then | |
442 | if (1 - cosTheta) > 0.0001 then | |
443 | local theta = ACOS(cosTheta) | |
444 | local invSinTheta = 1 / SIN(theta) | |
445 | startInterp = SIN((1 - t) * theta) * invSinTheta | |
446 | finishInterp = SIN(t * theta) * invSinTheta | |
447 | else | |
448 | startInterp = 1 - t | |
449 | finishInterp = t | |
450 | end | |
451 | else | |
452 | if (1 + cosTheta) > 0.0001 then | |
453 | local theta = ACOS(-cosTheta) | |
454 | local invSinTheta = 1 / SIN(theta) | |
455 | startInterp = SIN((t - 1) * theta) * invSinTheta | |
456 | finishInterp = SIN(t * theta) * invSinTheta | |
457 | else | |
458 | startInterp = t - 1 | |
459 | finishInterp = t | |
460 | end | |
461 | end | |
462 | 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 | |
463 | end | |
464 | ||
465 | function Clerp(a, b, t) | |
466 | local qa = {QuaternionFromCFrame(a)} | |
467 | local qb = {QuaternionFromCFrame(b)} | |
468 | local ax, ay, az = a.x, a.y, a.z | |
469 | local bx, by, bz = b.x, b.y, b.z | |
470 | local _t = 1 - t | |
471 | return QuaternionToCFrame(_t * ax + t * bx, _t * ay + t * by, _t * az + t * bz, QuaternionSlerp(qa, qb, t)) | |
472 | end | |
473 | ||
474 | function CreateFrame(PARENT, TRANSPARENCY, BORDERSIZEPIXEL, POSITION, SIZE, COLOR, BORDERCOLOR, NAME) | |
475 | local frame = IT("Frame") | |
476 | frame.BackgroundTransparency = TRANSPARENCY | |
477 | frame.BorderSizePixel = BORDERSIZEPIXEL | |
478 | frame.Position = POSITION | |
479 | frame.Size = SIZE | |
480 | frame.BackgroundColor3 = COLOR | |
481 | frame.BorderColor3 = BORDERCOLOR | |
482 | frame.Name = NAME | |
483 | frame.Parent = PARENT | |
484 | return frame | |
485 | end | |
486 | ||
487 | function CreateLabel(PARENT, TEXT, TEXTCOLOR, TEXTFONTSIZE, TEXTFONT, TRANSPARENCY, BORDERSIZEPIXEL, STROKETRANSPARENCY, NAME) | |
488 | local label = IT("TextLabel") | |
489 | label.BackgroundTransparency = 1 | |
490 | label.Size = UD2(1, 0, 1, 0) | |
491 | label.Position = UD2(0, 0, 0, 0) | |
492 | label.TextColor3 = TEXTCOLOR | |
493 | label.TextStrokeTransparency = STROKETRANSPARENCY | |
494 | label.TextTransparency = TRANSPARENCY | |
495 | label.FontSize = TEXTFONTSIZE | |
496 | label.Font = TEXTFONT | |
497 | label.BorderSizePixel = BORDERSIZEPIXEL | |
498 | label.TextScaled = false | |
499 | label.Text = TEXT | |
500 | label.Name = NAME | |
501 | label.Parent = PARENT | |
502 | return label | |
503 | end | |
504 | ||
505 | function NoOutlines(PART) | |
506 | PART.TopSurface, PART.BottomSurface, PART.LeftSurface, PART.RightSurface, PART.FrontSurface, PART.BackSurface = 10, 10, 10, 10, 10, 10 | |
507 | end | |
508 | ||
509 | ||
510 | function CreateWeldOrSnapOrMotor(TYPE, PARENT, PART0, PART1, C0, C1) | |
511 | local NEWWELD = IT(TYPE) | |
512 | NEWWELD.Part0 = PART0 | |
513 | NEWWELD.Part1 = PART1 | |
514 | NEWWELD.C0 = C0 | |
515 | NEWWELD.C1 = C1 | |
516 | NEWWELD.Parent = PARENT | |
517 | return NEWWELD | |
518 | end | |
519 | ||
520 | function CreateSound(ID, PARENT, VOLUME, PITCH) | |
521 | local NEWSOUND = nil | |
522 | coroutine.resume(coroutine.create(function() | |
523 | NEWSOUND = IT("Sound", PARENT) | |
524 | NEWSOUND.Volume = VOLUME | |
525 | NEWSOUND.Pitch = PITCH | |
526 | NEWSOUND.SoundId = "http://www.roblox.com/asset/?id="..ID | |
527 | Swait() | |
528 | NEWSOUND:play() | |
529 | game:GetService("Debris"):AddItem(NEWSOUND, 10) | |
530 | end)) | |
531 | return NEWSOUND | |
532 | end | |
533 | ||
534 | function CFrameFromTopBack(at, top, back) | |
535 | local right = top:Cross(back) | |
536 | return CF(at.x, at.y, at.z, right.x, top.x, back.x, right.y, top.y, back.y, right.z, top.z, back.z) | |
537 | end | |
538 | ||
539 | function CreateSwirl(SIZE,WAIT,CFRAME,DOESROT,ROT,COLOR,GROW) | |
540 | local wave = CreatePart(3, Effects, "Neon", 0, 0.5, BRICKC(COLOR), "Effect", VT(0,0,0)) | |
541 | wave.Color = COLOR | |
542 | local mesh = CreateMesh("SpecialMesh", wave, "FileMesh", "1051557", "", SIZE, VT(0,0,0)) | |
543 | wave.CFrame = CFRAME | |
544 | coroutine.resume(coroutine.create(function(PART) | |
545 | for i = 1, WAIT do | |
546 | Swait() | |
547 | mesh.Scale = mesh.Scale + GROW | |
548 | mesh.Offset = VT(0,0,-(mesh.Scale.X/8)) | |
549 | if DOESROT == true then | |
550 | wave.CFrame = wave.CFrame * CFrame.fromEulerAnglesXYZ(0,ROT,0) | |
551 | end | |
552 | wave.Transparency = wave.Transparency + (0.5/WAIT) | |
553 | if wave.Transparency > 0.99 then | |
554 | wave:remove() | |
555 | end | |
556 | end | |
557 | end)) | |
558 | end | |
559 | ||
560 | function MagicSphere(SIZE,WAIT,CFRAME,COLOR,GROW) | |
561 | local wave = CreatePart(3, Effects, "Neon", 0, 0, BRICKC(COLOR), "Effect", VT(1,1,1), true) | |
562 | wave.Color = COLOR | |
563 | local mesh = CreateMesh("SpecialMesh", wave, "Sphere", "", "", SIZE, VT(0,0,0)) | |
564 | wave.CFrame = CFRAME | |
565 | coroutine.resume(coroutine.create(function(PART) | |
566 | for i = 1, WAIT do | |
567 | Swait() | |
568 | mesh.Scale = mesh.Scale + GROW | |
569 | wave.Transparency = wave.Transparency + (1/WAIT) | |
570 | if wave.Transparency > 0.99 then | |
571 | wave:remove() | |
572 | end | |
573 | end | |
574 | end)) | |
575 | end | |
576 | ||
577 | function Slice(KIND,SIZE,WAIT,CFRAME,COLOR,GROW) | |
578 | local wave = CreatePart(3, Effects, "Neon", 0, 0.5, BRICKC(COLOR), "Effect", VT(1,1,1), true) | |
579 | local mesh = nil | |
580 | if KIND == "Base" then | |
581 | mesh = CreateMesh("SpecialMesh", wave, "FileMesh", "448386996", "", VT(0,SIZE/10,SIZE/10), VT(0,0,0)) | |
582 | elseif KIND == "Thin" then | |
583 | mesh = CreateMesh("SpecialMesh", wave, "FileMesh", "662586858", "", VT(SIZE/10,0,SIZE/10), VT(0,0,0)) | |
584 | elseif KIND == "Round" then | |
585 | mesh = CreateMesh("SpecialMesh", wave, "FileMesh", "662585058", "", VT(SIZE/10,0,SIZE/10), VT(0,0,0)) | |
586 | end | |
587 | wave.CFrame = CFRAME | |
588 | coroutine.resume(coroutine.create(function(PART) | |
589 | for i = 1, WAIT do | |
590 | Swait() | |
591 | mesh.Scale = mesh.Scale + GROW/10 | |
592 | wave.Transparency = wave.Transparency + (0.5/WAIT) | |
593 | if wave.Transparency > 0.99 then | |
594 | wave:remove() | |
595 | end | |
596 | end | |
597 | end)) | |
598 | end | |
599 | ||
600 | function MakeForm(PART,TYPE) | |
601 | if TYPE == "Cyl" then | |
602 | local MSH = IT("CylinderMesh",PART) | |
603 | elseif TYPE == "Ball" then | |
604 | local MSH = IT("SpecialMesh",PART) | |
605 | MSH.MeshType = "Sphere" | |
606 | elseif TYPE == "Wedge" then | |
607 | local MSH = IT("SpecialMesh",PART) | |
608 | MSH.MeshType = "Wedge" | |
609 | end | |
610 | end | |
611 | ||
612 | function CheckTableForString(Table, String) | |
613 | for i, v in pairs(Table) do | |
614 | if string.find(string.lower(String), string.lower(v)) then | |
615 | return true | |
616 | end | |
617 | end | |
618 | return false | |
619 | end | |
620 | ||
621 | function CheckIntangible(Hit) | |
622 | local ProjectileNames = {"Water", "Arrow", "Projectile", "Effect", "Rail", "Lightning", "Bullet"} | |
623 | if Hit and Hit.Parent then | |
624 | if ((not Hit.CanCollide or CheckTableForString(ProjectileNames, Hit.Name)) and not Hit.Parent:FindFirstChild("Humanoid")) then | |
625 | return true | |
626 | end | |
627 | end | |
628 | return false | |
629 | end | |
630 | ||
631 | Debris = game:GetService("Debris") | |
632 | ||
633 | function CastZapRay(StartPos, Vec, Length, Ignore, DelayIfHit) | |
634 | local Direction = CFrame.new(StartPos, Vec).lookVector | |
635 | local Ignore = ((type(Ignore) == "table" and Ignore) or {Ignore}) | |
636 | local RayHit, RayPos, RayNormal = game:GetService("Workspace"):FindPartOnRayWithIgnoreList(Ray.new(StartPos, Direction * Length), Ignore) | |
637 | if RayHit and CheckIntangible(RayHit) then | |
638 | if DelayIfHit then | |
639 | wait() | |
640 | end | |
641 | RayHit, RayPos, RayNormal = CastZapRay((RayPos + (Vec * 0.01)), Vec, (Length - ((StartPos - RayPos).magnitude)), Ignore, DelayIfHit) | |
642 | end | |
643 | return RayHit, RayPos, RayNormal | |
644 | end | |
645 | ||
646 | function FireArc(Part,ToLocation,AmountOfTime,Height,DoesCourontine) | |
647 | if DoesCourontine == false then | |
648 | local Direction = CF(Part.Position,ToLocation) | |
649 | local Distance = (Part.Position - ToLocation).magnitude | |
650 | for i = 1, AmountOfTime do | |
651 | Swait() | |
652 | Part.CFrame = Direction*CF(0,(AmountOfTime/200)+((AmountOfTime/Height)-((i*2)/Height)),-Distance/AmountOfTime) | |
653 | Direction = Part.CFrame | |
654 | end | |
655 | Part:remove() | |
656 | elseif DoesCourontine == true then | |
657 | coroutine.resume(coroutine.create(function() | |
658 | local Direction = CF(Part.Position,ToLocation) | |
659 | local Distance = (Part.Position - ToLocation).magnitude | |
660 | for i = 1, AmountOfTime do | |
661 | Swait() | |
662 | Part.CFrame = Direction*CF(0,(AmountOfTime/200)+((AmountOfTime/Height)-((i*2)/Height)),-Distance/AmountOfTime) | |
663 | Direction = Part.CFrame | |
664 | end | |
665 | Part:remove() | |
666 | end)) | |
667 | end | |
668 | end | |
669 | ||
670 | function turnto(position) | |
671 | RootPart.CFrame=CFrame.new(RootPart.CFrame.p,VT(position.X,RootPart.Position.Y,position.Z)) * CFrame.new(0, 0, 0) | |
672 | end | |
673 | ||
674 | function Raycast(POSITION, DIRECTION, RANGE, IGNOREDECENDANTS) | |
675 | return workspace:FindPartOnRay(Ray.new(POSITION, DIRECTION.unit * RANGE), IGNOREDECENDANTS) | |
676 | end | |
677 | ||
678 | function PositiveAngle(NUMBER) | |
679 | if NUMBER >= 0 then | |
680 | NUMBER = 0 | |
681 | end | |
682 | return NUMBER | |
683 | end | |
684 | ||
685 | function NegativeAngle(NUMBER) | |
686 | if NUMBER <= 0 then | |
687 | NUMBER = 0 | |
688 | end | |
689 | return NUMBER | |
690 | end | |
691 | ||
692 | function Swait(NUMBER) | |
693 | if NUMBER == 0 or NUMBER == nil then | |
694 | ArtificialHB.Event:wait() | |
695 | else | |
696 | for i = 1, NUMBER do | |
697 | ArtificialHB.Event:wait() | |
698 | end | |
699 | end | |
700 | end | |
701 | ||
702 | function CreateMesh(MESH, PARENT, MESHTYPE, MESHID, TEXTUREID, SCALE, OFFSET) | |
703 | local NEWMESH = IT(MESH) | |
704 | if MESH == "SpecialMesh" then | |
705 | NEWMESH.MeshType = MESHTYPE | |
706 | if MESHID ~= "nil" and MESHID ~= "" then | |
707 | NEWMESH.MeshId = "http://www.roblox.com/asset/?id="..MESHID | |
708 | end | |
709 | if TEXTUREID ~= "nil" and TEXTUREID ~= "" then | |
710 | NEWMESH.TextureId = "http://www.roblox.com/asset/?id="..TEXTUREID | |
711 | end | |
712 | end | |
713 | NEWMESH.Offset = OFFSET or VT(0, 0, 0) | |
714 | NEWMESH.Scale = SCALE | |
715 | NEWMESH.Parent = PARENT | |
716 | return NEWMESH | |
717 | end | |
718 | ||
719 | function CreatePart(FORMFACTOR, PARENT, MATERIAL, REFLECTANCE, TRANSPARENCY, BRICKCOLOR, NAME, SIZE, ANCHOR) | |
720 | local NEWPART = IT("Part") | |
721 | NEWPART.formFactor = FORMFACTOR | |
722 | NEWPART.Reflectance = REFLECTANCE | |
723 | NEWPART.Transparency = TRANSPARENCY | |
724 | NEWPART.CanCollide = false | |
725 | NEWPART.Locked = true | |
726 | NEWPART.Anchored = true | |
727 | if ANCHOR == false then | |
728 | NEWPART.Anchored = false | |
729 | end | |
730 | NEWPART.BrickColor = BRICKC(tostring(BRICKCOLOR)) | |
731 | NEWPART.Name = NAME | |
732 | NEWPART.Size = SIZE | |
733 | NEWPART.Position = Torso.Position | |
734 | NEWPART.Material = MATERIAL | |
735 | NEWPART:BreakJoints() | |
736 | NEWPART.Parent = PARENT | |
737 | return NEWPART | |
738 | end | |
739 | ||
740 | local function weldBetween(a, b) | |
741 | local weldd = Instance.new("ManualWeld") | |
742 | weldd.Part0 = a | |
743 | weldd.Part1 = b | |
744 | weldd.C0 = CFrame.new() | |
745 | weldd.C1 = b.CFrame:inverse() * a.CFrame | |
746 | weldd.Parent = a | |
747 | return weldd | |
748 | end | |
749 | ||
750 | ||
751 | function QuaternionFromCFrame(cf) | |
752 | local mx, my, mz, m00, m01, m02, m10, m11, m12, m20, m21, m22 = cf:components() | |
753 | local trace = m00 + m11 + m22 | |
754 | if trace > 0 then | |
755 | local s = math.sqrt(1 + trace) | |
756 | local recip = 0.5 / s | |
757 | return (m21 - m12) * recip, (m02 - m20) * recip, (m10 - m01) * recip, s * 0.5 | |
758 | else | |
759 | local i = 0 | |
760 | if m11 > m00 then | |
761 | i = 1 | |
762 | end | |
763 | if m22 > (i == 0 and m00 or m11) then | |
764 | i = 2 | |
765 | end | |
766 | if i == 0 then | |
767 | local s = math.sqrt(m00 - m11 - m22 + 1) | |
768 | local recip = 0.5 / s | |
769 | return 0.5 * s, (m10 + m01) * recip, (m20 + m02) * recip, (m21 - m12) * recip | |
770 | elseif i == 1 then | |
771 | local s = math.sqrt(m11 - m22 - m00 + 1) | |
772 | local recip = 0.5 / s | |
773 | return (m01 + m10) * recip, 0.5 * s, (m21 + m12) * recip, (m02 - m20) * recip | |
774 | elseif i == 2 then | |
775 | local s = math.sqrt(m22 - m00 - m11 + 1) | |
776 | local recip = 0.5 / s return (m02 + m20) * recip, (m12 + m21) * recip, 0.5 * s, (m10 - m01) * recip | |
777 | end | |
778 | end | |
779 | end | |
780 | ||
781 | function QuaternionToCFrame(px, py, pz, x, y, z, w) | |
782 | local xs, ys, zs = x + x, y + y, z + z | |
783 | local wx, wy, wz = w * xs, w * ys, w * zs | |
784 | local xx = x * xs | |
785 | local xy = x * ys | |
786 | local xz = x * zs | |
787 | local yy = y * ys | |
788 | local yz = y * zs | |
789 | local zz = z * zs | |
790 | 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)) | |
791 | end | |
792 | ||
793 | function QuaternionSlerp(a, b, t) | |
794 | local cosTheta = a[1] * b[1] + a[2] * b[2] + a[3] * b[3] + a[4] * b[4] | |
795 | local startInterp, finishInterp; | |
796 | if cosTheta >= 0.0001 then | |
797 | if (1 - cosTheta) > 0.0001 then | |
798 | local theta = ACOS(cosTheta) | |
799 | local invSinTheta = 1 / SIN(theta) | |
800 | startInterp = SIN((1 - t) * theta) * invSinTheta | |
801 | finishInterp = SIN(t * theta) * invSinTheta | |
802 | else | |
803 | startInterp = 1 - t | |
804 | finishInterp = t | |
805 | end | |
806 | else | |
807 | if (1 + cosTheta) > 0.0001 then | |
808 | local theta = ACOS(-cosTheta) | |
809 | local invSinTheta = 1 / SIN(theta) | |
810 | startInterp = SIN((t - 1) * theta) * invSinTheta | |
811 | finishInterp = SIN(t * theta) * invSinTheta | |
812 | else | |
813 | startInterp = t - 1 | |
814 | finishInterp = t | |
815 | end | |
816 | end | |
817 | 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 | |
818 | end | |
819 | ||
820 | function Clerp(a, b, t) | |
821 | local qa = {QuaternionFromCFrame(a)} | |
822 | local qb = {QuaternionFromCFrame(b)} | |
823 | local ax, ay, az = a.x, a.y, a.z | |
824 | local bx, by, bz = b.x, b.y, b.z | |
825 | local _t = 1 - t | |
826 | return QuaternionToCFrame(_t * ax + t * bx, _t * ay + t * by, _t * az + t * bz, QuaternionSlerp(qa, qb, t)) | |
827 | end | |
828 | ||
829 | function CreateFrame(PARENT, TRANSPARENCY, BORDERSIZEPIXEL, POSITION, SIZE, COLOR, BORDERCOLOR, NAME) | |
830 | local frame = IT("Frame") | |
831 | frame.BackgroundTransparency = TRANSPARENCY | |
832 | frame.BorderSizePixel = BORDERSIZEPIXEL | |
833 | frame.Position = POSITION | |
834 | frame.Size = SIZE | |
835 | frame.BackgroundColor3 = COLOR | |
836 | frame.BorderColor3 = BORDERCOLOR | |
837 | frame.Name = NAME | |
838 | frame.Parent = PARENT | |
839 | return frame | |
840 | end | |
841 | ||
842 | function CreateLabel(PARENT, TEXT, TEXTCOLOR, TEXTFONTSIZE, TEXTFONT, TRANSPARENCY, BORDERSIZEPIXEL, STROKETRANSPARENCY, NAME) | |
843 | local label = IT("TextLabel") | |
844 | label.BackgroundTransparency = 1 | |
845 | label.Size = UD2(1, 0, 1, 0) | |
846 | label.Position = UD2(0, 0, 0, 0) | |
847 | label.TextColor3 = TEXTCOLOR | |
848 | label.TextStrokeTransparency = STROKETRANSPARENCY | |
849 | label.TextTransparency = TRANSPARENCY | |
850 | label.FontSize = TEXTFONTSIZE | |
851 | label.Font = TEXTFONT | |
852 | label.BorderSizePixel = BORDERSIZEPIXEL | |
853 | label.TextScaled = false | |
854 | label.Text = TEXT | |
855 | label.Name = NAME | |
856 | label.Parent = PARENT | |
857 | return label | |
858 | end | |
859 | ||
860 | function NoOutlines(PART) | |
861 | PART.TopSurface, PART.BottomSurface, PART.LeftSurface, PART.RightSurface, PART.FrontSurface, PART.BackSurface = 10, 10, 10, 10, 10, 10 | |
862 | end | |
863 | ||
864 | function CreateWeldOrSnapOrMotor(TYPE, PARENT, PART0, PART1, C0, C1) | |
865 | local NEWWELD = IT(TYPE) | |
866 | NEWWELD.Part0 = PART0 | |
867 | NEWWELD.Part1 = PART1 | |
868 | NEWWELD.C0 = C0 | |
869 | NEWWELD.C1 = C1 | |
870 | NEWWELD.Parent = PARENT | |
871 | return NEWWELD | |
872 | end | |
873 | ||
874 | local S = IT("Sound") | |
875 | function CreateSound(ID, PARENT, VOLUME, PITCH, DOESLOOP) | |
876 | local NEWSOUND = nil | |
877 | coroutine.resume(coroutine.create(function() | |
878 | NEWSOUND = S:Clone() | |
879 | NEWSOUND.Parent = PARENT | |
880 | NEWSOUND.Volume = VOLUME | |
881 | NEWSOUND.Pitch = PITCH | |
882 | NEWSOUND.SoundId = "http://www.roblox.com/asset/?id="..ID | |
883 | NEWSOUND:play() | |
884 | if DOESLOOP == true then | |
885 | NEWSOUND.Looped = true | |
886 | else | |
887 | repeat wait(1) until NEWSOUND.Playing == false or NEWSOUND.Parent ~= PARENT | |
888 | NEWSOUND:remove() | |
889 | end | |
890 | end)) | |
891 | return NEWSOUND | |
892 | end | |
893 | ||
894 | function CFrameFromTopBack(at, top, back) | |
895 | local right = top:Cross(back) | |
896 | return CF(at.x, at.y, at.z, right.x, top.x, back.x, right.y, top.y, back.y, right.z, top.z, back.z) | |
897 | end | |
898 | ||
899 | --WACKYEFFECT({EffectType = "", Size = VT(1,1,1), Size2 = VT(0,0,0), Transparency = 0, Transparency2 = 1, CFrame = CF(), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = C3(1,255,1), SoundID = nil, SoundPitch = nil, SoundVolume = nil}) | |
900 | function WACKYEFFECT(Table) | |
901 | local TYPE = (Table.EffectType or "Sphere") | |
902 | local SIZE = (Table.Size or VT(1,1,1)) | |
903 | local ENDSIZE = (Table.Size2 or VT(0,0,0)) | |
904 | local TRANSPARENCY = (Table.Transparency or 0) | |
905 | local ENDTRANSPARENCY = (Table.Transparency2 or 1) | |
906 | local CFRAME = (Table.CFrame or Torso.CFrame) | |
907 | local MOVEDIRECTION = (Table.MoveToPos or nil) | |
908 | local ROTATION1 = (Table.RotationX or 0) | |
909 | local ROTATION2 = (Table.RotationY or 0) | |
910 | local ROTATION3 = (Table.RotationZ or 0) | |
911 | local MATERIAL = (Table.Material or "Neon") | |
912 | local COLOR = (Table.Color or C3(222,255,0)) | |
913 | local TIME = (Table.Time or 45) | |
914 | local SOUNDID = (Table.SoundID or nil) | |
915 | local SOUNDPITCH = (Table.SoundPitch or nil) | |
916 | local SOUNDVOLUME = (Table.SoundVolume or nil) | |
917 | coroutine.resume(coroutine.create(function() | |
918 | local PLAYSSOUND = false | |
919 | local SOUND = nil | |
920 | local EFFECT = CreatePart(3, Effects, MATERIAL, 0, TRANSPARENCY, BRICKC("Pearl"), "Effect", VT(1,1,1), true) | |
921 | if SOUNDID ~= nil and SOUNDPITCH ~= nil and SOUNDVOLUME ~= nil then | |
922 | PLAYSSOUND = true | |
923 | SOUND = CreateSound(SOUNDID, EFFECT, SOUNDVOLUME, SOUNDPITCH, false) | |
924 | end | |
925 | EFFECT.Color = COLOR | |
926 | local MSH = nil | |
927 | if TYPE == "Sphere" then | |
928 | MSH = CreateMesh("SpecialMesh", EFFECT, "Sphere", "", "", SIZE, VT(0,0,0)) | |
929 | elseif TYPE == "Block" then | |
930 | MSH = IT("BlockMesh",EFFECT) | |
931 | MSH.Scale = VT(SIZE.X,SIZE.X,SIZE.X) | |
932 | elseif TYPE == "Wave" then | |
933 | MSH = CreateMesh("SpecialMesh", EFFECT, "FileMesh", "20329976", "", SIZE, VT(0,0,-SIZE.X/8)) | |
934 | elseif TYPE == "Ring" then | |
935 | MSH = CreateMesh("SpecialMesh", EFFECT, "FileMesh", "559831844", "", VT(SIZE.X,SIZE.X,0.1), VT(0,0,0)) | |
936 | elseif TYPE == "Slash" then | |
937 | MSH = CreateMesh("SpecialMesh", EFFECT, "FileMesh", "662586858", "", VT(SIZE.X/10,0,SIZE.X/10), VT(0,0,0)) | |
938 | elseif TYPE == "Round Slash" then | |
939 | MSH = CreateMesh("SpecialMesh", EFFECT, "FileMesh", "662585058", "", VT(SIZE.X/10,0,SIZE.X/10), VT(0,0,0)) | |
940 | elseif TYPE == "Swirl" then | |
941 | MSH = CreateMesh("SpecialMesh", EFFECT, "FileMesh", "1051557", "", SIZE, VT(0,0,0)) | |
942 | elseif TYPE == "Skull" then | |
943 | MSH = CreateMesh("SpecialMesh", EFFECT, "FileMesh", "4770583", "", SIZE, VT(0,0,0)) | |
944 | elseif TYPE == "Crystal" then | |
945 | MSH = CreateMesh("SpecialMesh", EFFECT, "FileMesh", "9756362", "", SIZE, VT(0,0,0)) | |
946 | end | |
947 | if MSH ~= nil then | |
948 | local MOVESPEED = nil | |
949 | if MOVEDIRECTION ~= nil then | |
950 | MOVESPEED = (CFRAME.p - MOVEDIRECTION).Magnitude/TIME | |
951 | end | |
952 | local GROWTH = SIZE - ENDSIZE | |
953 | local TRANS = TRANSPARENCY - ENDTRANSPARENCY | |
954 | if TYPE == "Block" then | |
955 | EFFECT.CFrame = CFRAME*ANGLES(RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360))) | |
956 | else | |
957 | EFFECT.CFrame = CFRAME | |
958 | end | |
959 | for LOOP = 1, TIME+1 do | |
960 | Swait() | |
961 | MSH.Scale = MSH.Scale - GROWTH/TIME | |
962 | if TYPE == "Wave" then | |
963 | MSH.Offset = VT(0,0,-MSH.Scale.X/8) | |
964 | end | |
965 | EFFECT.Transparency = EFFECT.Transparency - TRANS/TIME | |
966 | if TYPE == "Block" then | |
967 | EFFECT.CFrame = CFRAME*ANGLES(RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360))) | |
968 | else | |
969 | EFFECT.CFrame = EFFECT.CFrame*ANGLES(RAD(ROTATION1),RAD(ROTATION2),RAD(ROTATION3)) | |
970 | end | |
971 | if MOVEDIRECTION ~= nil then | |
972 | local ORI = EFFECT.Orientation | |
973 | EFFECT.CFrame = CF(EFFECT.Position,MOVEDIRECTION)*CF(0,0,-MOVESPEED) | |
974 | EFFECT.Orientation = ORI | |
975 | end | |
976 | end | |
977 | if PLAYSSOUND == false then | |
978 | EFFECT:remove() | |
979 | else | |
980 | SOUND.Stopped:Connect(function() | |
981 | EFFECT:remove() | |
982 | end) | |
983 | end | |
984 | else | |
985 | if PLAYSSOUND == false then | |
986 | EFFECT:remove() | |
987 | else | |
988 | repeat Swait() until SOUND.Playing == false | |
989 | EFFECT:remove() | |
990 | end | |
991 | end | |
992 | end)) | |
993 | end | |
994 | ||
995 | function MakeForm(PART,TYPE) | |
996 | if TYPE == "Cyl" then | |
997 | local MSH = IT("CylinderMesh",PART) | |
998 | elseif TYPE == "Ball" then | |
999 | local MSH = IT("SpecialMesh",PART) | |
1000 | MSH.MeshType = "Sphere" | |
1001 | elseif TYPE == "Wedge" then | |
1002 | local MSH = IT("SpecialMesh",PART) | |
1003 | MSH.MeshType = "Wedge" | |
1004 | end | |
1005 | end | |
1006 | ||
1007 | function SpawnTrail(FROM,TO,BIG) | |
1008 | local TRAIL = CreatePart(3, Effects, "Neon", 0, 0.5, "Really black", "Trail", VT(0,0,0)) | |
1009 | MakeForm(TRAIL,"Cyl") | |
1010 | local DIST = (FROM - TO).Magnitude | |
1011 | if BIG == true then | |
1012 | TRAIL.Size = VT(0.5,DIST,0.5) | |
1013 | else | |
1014 | TRAIL.Size = VT(0.25,DIST,0.25) | |
1015 | end | |
1016 | TRAIL.CFrame = CF(FROM, TO) * CF(0, 0, -DIST/2) * ANGLES(RAD(90),RAD(0),RAD(0)) | |
1017 | coroutine.resume(coroutine.create(function() | |
1018 | for i = 1, 5 do | |
1019 | Swait() | |
1020 | TRAIL.Transparency = TRAIL.Transparency + 0.1 | |
1021 | end | |
1022 | TRAIL:remove() | |
1023 | end)) | |
1024 | end | |
1025 | ||
1026 | Debris = game:GetService("Debris") | |
1027 | ||
1028 | function CastProperRay(StartPos, EndPos, Distance, Ignore) | |
1029 | local DIRECTION = CF(StartPos,EndPos).lookVector | |
1030 | return Raycast(StartPos, DIRECTION, Distance, Ignore) | |
1031 | end | |
1032 | ||
1033 | function turnto(position) | |
1034 | RootPart.CFrame=CFrame.new(RootPart.CFrame.p,VT(position.X,RootPart.Position.Y,position.Z)) * CFrame.new(0, 0, 0) | |
1035 | end | |
1036 | -------- | |
1037 | --//=================================\\ | |
1038 | --|| WEAPON CREATION | |
1039 | --\\=================================// | |
1040 | local Part = CreatePart(3, Weapon, "DiamondPlate", 0, 0, "Stone grey", "Metal", VT(1.1,1,0.525),false) | |
1041 | CreateWeldOrSnapOrMotor("Weld", Torso, Torso, Part, CF(-0.75, 0.51, 0) * ANGLES(RAD(180), RAD(-90), RAD(0)), CF(0, 0, 0)) | |
1042 | MakeForm(Part,"Wedge") | |
1043 | ||
1044 | local Part = CreatePart(3, Weapon, "DiamondPlate", 0, 0, "Stone grey", "Metal", VT(1,1,1.2),false) | |
1045 | CreateWeldOrSnapOrMotor("Weld", Torso, Torso, Part, CF(0, 0, 0) * ANGLES(RAD(0), RAD(0), RAD(0)), CF(0, 0, 0)) | |
1046 | local Part = CreatePart(3, Weapon, "DiamondPlate", 0, 0, "Stone grey", "Metal", VT(0.3,1.7,1.15),false) | |
1047 | CreateWeldOrSnapOrMotor("Weld", Torso, Torso, Part, CF(0, 0, 0) * ANGLES(RAD(0), RAD(0), RAD(45)), CF(0, 0, 0)) | |
1048 | local Part = CreatePart(3, Weapon, "DiamondPlate", 0, 0, "Stone grey", "Metal", VT(0.3,1.7,1.15),false) | |
1049 | CreateWeldOrSnapOrMotor("Weld", Torso, Torso, Part, CF(0, 0, 0) * ANGLES(RAD(0), RAD(0), RAD(-45)), CF(0, 0, 0)) | |
1050 | local Part = CreatePart(3, Weapon, "DiamondPlate", 0, 0, "Dark stone grey", "Metal", VT(0.8,0.8,1.225),false) | |
1051 | CreateWeldOrSnapOrMotor("Weld", Torso, Torso, Part, CF(0, 0, 0) * ANGLES(RAD(0), RAD(0), RAD(0)), CF(0, 0, 0)) | |
1052 | local Eon = CreatePart(3, Weapon, "Neon", 0, 0, "Really red", "Eon", VT(0.5,0.5,1.25),false) | |
1053 | CreateWeldOrSnapOrMotor("Weld", Torso, Torso, Eon, CF(0, 0, 0) * ANGLES(RAD(0), RAD(0), RAD(0)), CF(0, 0, 0)) | |
1054 | ||
1055 | Player=game:GetService('Players').LocalPlayer | |
1056 | Character=Player.Character | |
1057 | Mouse=Player:GetMouse() | |
1058 | m=Instance.new('Model',Character) | |
1059 | local function weldBetween(a, b) | |
1060 | local weldd = Instance.new("ManualWeld") | |
1061 | weldd.Part0 = a | |
1062 | weldd.Part1 = b | |
1063 | weldd.C0 = CFrame.new() | |
1064 | weldd.C1 = b.CFrame:inverse() * a.CFrame | |
1065 | weldd.Parent = a | |
1066 | return weldd | |
1067 | end | |
1068 | ||
1069 | it=Instance.new | |
1070 | ||
1071 | function nooutline(part) | |
1072 | part.TopSurface,part.BottomSurface,part.LeftSurface,part.RightSurface,part.FrontSurface,part.BackSurface = 10,10,10,10,10,10 | |
1073 | end | |
1074 | ||
1075 | function part(formfactor,parent,material,reflectance,transparency,brickcolor,name,size) | |
1076 | local fp=it("Part") | |
1077 | fp.formFactor=formfactor | |
1078 | fp.Parent=parent | |
1079 | fp.Reflectance=reflectance | |
1080 | fp.Transparency=transparency | |
1081 | fp.CanCollide=false | |
1082 | fp.Locked=true | |
1083 | fp.BrickColor=BrickColor.new(tostring(brickcolor)) | |
1084 | fp.Name=name | |
1085 | fp.Size=size | |
1086 | fp.Position=Character.Torso.Position | |
1087 | nooutline(fp) | |
1088 | fp.Material=material | |
1089 | fp:BreakJoints() | |
1090 | return fp | |
1091 | end | |
1092 | ||
1093 | function mesh(Mesh,part,meshtype,meshid,offset,scale) | |
1094 | local mesh=it(Mesh) | |
1095 | mesh.Parent=part | |
1096 | if Mesh=="SpecialMesh" then | |
1097 | mesh.MeshType=meshtype | |
1098 | mesh.MeshId=meshid | |
1099 | end | |
1100 | mesh.Offset=offset | |
1101 | mesh.Scale=scale | |
1102 | return mesh | |
1103 | end | |
1104 | ||
1105 | function weld(parent,part0,part1,c0,c1) | |
1106 | local weld=it("Weld") | |
1107 | weld.Parent=parent | |
1108 | weld.Part0=part0 | |
1109 | weld.Part1=part1 | |
1110 | weld.C0=c0 | |
1111 | weld.C1=c1 | |
1112 | return weld | |
1113 | end | |
1114 | ||
1115 | handle=part(Enum.FormFactor.Brick,m,Enum.Material.Plastic,0,0,"Really black","Handle",Vector3.new(4, 1, 2)) | |
1116 | handleweld=weld(m,Character["Torso"],handle,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(1.72890472, 0.675598145, -1.43186569, 0.258819073, 0, -0.965925813, 0, 1, 0, 0.965925813, 0, 0.258819073)) | |
1117 | mesh("SpecialMesh",handle,Enum.MeshType.FileMesh,"rbxassetid://1553468709",Vector3.new(0, 0, 0),Vector3.new(0.0480000004, 0.0480000004, 0.0480000004)) | |
1118 | ||
1119 | for i = 1, 15 do | |
1120 | local FACE = CreatePart(3, Character, "Fabric", 0, 0+(i-1)/15.2, "Dark stone grey", "FaceGradient", VT(1.01,0.58,1.01),false) | |
1121 | FACE.Color = C3(0,0,0) | |
1122 | Head:FindFirstChildOfClass("SpecialMesh"):Clone().Parent = FACE | |
1123 | CreateWeldOrSnapOrMotor("Weld", Head, Head, FACE, CF(0,0.35-(i-1)/35,0), CF(0, 0, 0)) | |
1124 | end | |
1125 | ||
1126 | Humanoid.DisplayDistanceType = "None" | |
1127 | local naeeym2 = IT("BillboardGui",Character) | |
1128 | naeeym2.AlwaysOnTop = true | |
1129 | naeeym2.Size = UDim2.new(5,35,2,15) | |
1130 | naeeym2.StudsOffset = Vector3.new(0,3,0) | |
1131 | naeeym2.MaxDistance = 75 | |
1132 | naeeym2.Adornee = Character.Head | |
1133 | naeeym2.Name = "Name" | |
1134 | local tecks2 = IT("TextLabel",naeeym2) | |
1135 | tecks2.BackgroundTransparency = 1 | |
1136 | tecks2.TextScaled = true | |
1137 | tecks2.BorderSizePixel = 0 | |
1138 | tecks2.Text = "" | |
1139 | tecks2.Font = "Bodoni" | |
1140 | tecks2.TextSize = 30 | |
1141 | tecks2.TextStrokeTransparency = 0.5 | |
1142 | tecks2.TextColor3 = C3(0,0,0) | |
1143 | tecks2.TextStrokeColor3 = BRICKC"Really black".Color | |
1144 | tecks2.Size = UDim2.new(1,0,0.5,0) | |
1145 | tecks2.Parent = naeeym2 | |
1146 | local EyeSizes={ | |
1147 | NumberSequenceKeypoint.new(0,1,0), | |
1148 | NumberSequenceKeypoint.new(1,0,0) | |
1149 | } | |
1150 | local EyeTrans={ | |
1151 | NumberSequenceKeypoint.new(0,0.8,0), | |
1152 | NumberSequenceKeypoint.new(1,1,0) | |
1153 | } | |
1154 | local PE=Instance.new("ParticleEmitter",nil) | |
1155 | PE.LightEmission=.8 | |
1156 | PE.Color = ColorSequence.new(BRICKC("Really red").Color) | |
1157 | PE.Size=NumberSequence.new(EyeSizes) | |
1158 | PE.Transparency=NumberSequence.new(EyeTrans) | |
1159 | PE.Lifetime=NumberRange.new(0.35,1.5) | |
1160 | PE.Rotation=NumberRange.new(0,360) | |
1161 | PE.Rate=999 | |
1162 | PE.VelocitySpread = 10000 | |
1163 | PE.Acceleration = Vector3.new(0,0,0) | |
1164 | PE.Drag = 5 | |
1165 | PE.Speed = NumberRange.new(0,0,0) | |
1166 | PE.Texture="http://www.roblox.com/asset/?id=1351966707" | |
1167 | PE.ZOffset = -0 | |
1168 | PE.Name = "PE" | |
1169 | PE.Enabled = false | |
1170 | ||
1171 | function particles(art) | |
1172 | local PARTICLES = PE:Clone() | |
1173 | PARTICLES.Parent = art | |
1174 | end | |
1175 | ||
1176 | function CreateDebreeRing(FLOOR,POSITION,SIZE,BLOCKSIZE,SWAIT) | |
1177 | if FLOOR ~= nil then | |
1178 | coroutine.resume(coroutine.create(function() | |
1179 | local PART = CreatePart(3, Effects, "Plastic", 0, 1, "Pearl", "DebreeCenter", VT(0,0,0)) | |
1180 | PART.CFrame = CF(POSITION) | |
1181 | for i = 1, 45 do | |
1182 | local RingPiece = CreatePart(3, Effects, "Plastic", 0, 0, "Pearl", "DebreePart", BLOCKSIZE) | |
1183 | RingPiece.Material = FLOOR.Material | |
1184 | RingPiece.Color = FLOOR.Color | |
1185 | RingPiece.CFrame = PART.CFrame * ANGLES(RAD(0), RAD(i*8), RAD(0)) * CF(SIZE, 0, 0) * ANGLES(RAD(MRANDOM(-360,360)),RAD(MRANDOM(-360,360)),RAD(MRANDOM(-360,360))) | |
1186 | Debris:AddItem(RingPiece,SWAIT) | |
1187 | end | |
1188 | PART:remove() | |
1189 | end)) | |
1190 | end | |
1191 | end | |
1192 | ||
1193 | function CreateFlyingDebree(FLOOR,POSITION,AMOUNT,BLOCKSIZE,SWAIT,STRENGTH) | |
1194 | if FLOOR ~= nil then | |
1195 | for i = 1, AMOUNT do | |
1196 | local DEBREE = CreatePart(3, Effects, "Neon", FLOOR.Reflectance, FLOOR.Transparency, "Peal", "Debree", BLOCKSIZE, false) | |
1197 | DEBREE.Material = FLOOR.Material | |
1198 | DEBREE.Color = FLOOR.Color | |
1199 | DEBREE.CFrame = POSITION * ANGLES(RAD(MRANDOM(-360,360)),RAD(MRANDOM(-360,360)),RAD(MRANDOM(-360,360))) | |
1200 | DEBREE.Velocity = VT(MRANDOM(-STRENGTH,STRENGTH),MRANDOM(-STRENGTH,STRENGTH),MRANDOM(-STRENGTH,STRENGTH)) | |
1201 | coroutine.resume(coroutine.create(function() | |
1202 | Swait(15) | |
1203 | DEBREE.Parent = workspace | |
1204 | DEBREE.CanCollide = true | |
1205 | Debris:AddItem(DEBREE,SWAIT) | |
1206 | end)) | |
1207 | end | |
1208 | end | |
1209 | end | |
1210 | ||
1211 | local top = Instance.new("Shirt") | |
1212 | top.ShirtTemplate = "rbxassetid://981134222" | |
1213 | top.Parent = Character | |
1214 | top.Name = "Cloth" | |
1215 | local bottom = Instance.new("Pants") | |
1216 | bottom.PantsTemplate = "rbxassetid://981134222" | |
1217 | bottom.Parent = Character | |
1218 | bottom.Name = "Cloth" | |
1219 | for _, c in pairs(Character:GetChildren()) do | |
1220 | if c.ClassName == "Part" and c.Name ~= "FaceGradient" and c.Name ~= "Hat" and c.Name ~= "Gem" then | |
1221 | c.Material = "Neon" | |
1222 | if c:FindFirstChildOfClass("ParticleEmitter") then | |
1223 | c:FindFirstChildOfClass("ParticleEmitter"):remove() | |
1224 | end | |
1225 | c.Color = C3(1,1,1) | |
1226 | if c == Head then | |
1227 | if c:FindFirstChild("face") then | |
1228 | c.face:remove() | |
1229 | end | |
1230 | end | |
1231 | elseif c.ClassName == "CharacterMesh" or c.ClassName == "Accessory" or c.ClassName == "Hat" or c.Name == "Body Colors" then | |
1232 | c:remove() | |
1233 | elseif (c.ClassName == "Shirt" or c.ClassName == "Pants") and c.Name ~= "Cloth" then | |
1234 | c:remove() | |
1235 | end | |
1236 | end | |
1237 | local BODY = {} | |
1238 | for _, c in pairs(Character:GetDescendants()) do | |
1239 | if c:IsA("BasePart") and c.Name ~= "Handle" then | |
1240 | if c ~= RootPart and c ~= Torso and c ~= Head and c ~= RightArm and c ~= LeftArm and c ~= RightLeg and c ~= LeftLeg then | |
1241 | c.CustomPhysicalProperties = PhysicalProperties.new(0, 0, 0, 0, 0) | |
1242 | end | |
1243 | table.insert(BODY,{c,c.Parent,c.Material,c.Color,c.Transparency}) | |
1244 | elseif c:IsA("JointInstance") then | |
1245 | table.insert(BODY,{c,c.Parent,nil,nil,nil}) | |
1246 | end | |
1247 | end | |
1248 | for e = 1, #BODY do | |
1249 | if BODY[e] ~= nil then | |
1250 | local STUFF = BODY[e] | |
1251 | local PART = STUFF[1] | |
1252 | local PARENT = STUFF[2] | |
1253 | local MATERIAL = STUFF[3] | |
1254 | local COLOR = STUFF[4] | |
1255 | local TRANSPARENCY = STUFF[5] | |
1256 | if PART.ClassName == "Part" and PART ~= RootPart then | |
1257 | PART.Material = MATERIAL | |
1258 | PART.Color = COLOR | |
1259 | PART.Transparency = TRANSPARENCY | |
1260 | end | |
1261 | PART.AncestryChanged:Connect(function() | |
1262 | PART.Parent = PARENT | |
1263 | end) | |
1264 | end | |
1265 | end | |
1266 | function refit() | |
1267 | Character.Parent = workspace | |
1268 | for e = 1, #BODY do | |
1269 | if BODY[e] ~= nil then | |
1270 | local STUFF = BODY[e] | |
1271 | local PART = STUFF[1] | |
1272 | local PARENT = STUFF[2] | |
1273 | local MATERIAL = STUFF[3] | |
1274 | local COLOR = STUFF[4] | |
1275 | local TRANSPARENCY = STUFF[5] | |
1276 | if PART.ClassName == "Part" and PART ~= RootPart then | |
1277 | PART.Material = MATERIAL | |
1278 | PART.Color = COLOR | |
1279 | PART.Transparency = TRANSPARENCY | |
1280 | end | |
1281 | if PART.Parent ~= PARENT then | |
1282 | Humanoid:remove() | |
1283 | PART.Parent = PARENT | |
1284 | Humanoid = IT("Humanoid",Character) | |
1285 | end | |
1286 | end | |
1287 | end | |
1288 | end | |
1289 | ||
1290 | Humanoid.Died:connect(function() | |
1291 | refit() | |
1292 | end) | |
1293 | ------------------- | |
1294 | -------- | |
1295 | ||
1296 | local Part = CreatePart(3, Character, "Metal", 0, 0, "Really red", "Part", VT(0.2,0.5,0.2),false) | |
1297 | MakeForm(Part,"Wedge") | |
1298 | CreateWeldOrSnapOrMotor("Weld", Handle, Handle, Part, CF(0, -0.55, 0.2) * ANGLES(RAD(-135), RAD(0), RAD(0)), CF(0, -0.3, 0)) | |
1299 | local Part = CreatePart(3, Character, "Metal", 0, 0, "Really red", "Eye", VT(0.39,0.41,0.39),false) | |
1300 | MakeForm(Part,"Cyl") | |
1301 | CreateWeldOrSnapOrMotor("Weld", Handle, Handle, Part, CF(0, -0.45, 0.4) * ANGLES(RAD(90), RAD(0), RAD(0)), CF(0, 0, 0)) | |
1302 | local Part = CreatePart(3, Character, "Metal", 0, 0, "Really red", "Part", VT(0.3,0.5,0.5),false) | |
1303 | CreateWeldOrSnapOrMotor("Weld", Handle, Handle, Part, CF(0, -0.5, 0.2) * ANGLES(RAD(90), RAD(0), RAD(0)), CF(0, 0, 0)) | |
1304 | local Part = CreatePart(3, Character, "Metal", 0, 0, "Really red", "Part", VT(0.3,0.4,0.5),false) | |
1305 | CreateWeldOrSnapOrMotor("Weld", Handle, Handle, Part, CF(0, -0.55, 0.65) * ANGLES(RAD(90), RAD(0), RAD(0)), CF(0, 0, 0)) | |
1306 | local Part = CreatePart(3, Character, "Metal", 0, 0, "Really red", "Part", VT(0.2,0,0.6),false) | |
1307 | CreateWeldOrSnapOrMotor("Weld", Handle, Handle, Part, CF(0, 0, 0) * ANGLES(RAD(45), RAD(0), RAD(0)), CF(0, -0.2, -0.3)) | |
1308 | local LeftBarrel = CreatePart(3, Character, "Metal", 0, 0, "Really red", "Part", VT(0.28,5,0.28),false) | |
1309 | MakeForm(LeftBarrel,"Cyl") | |
1310 | CreateWeldOrSnapOrMotor("Weld", Handle, Handle, LeftBarrel, CF(0, -0.6, 0.5) * ANGLES(RAD(90), RAD(0), RAD(0)), CF(0, -2.5, 0)) | |
1311 | local Part = CreatePart(3, Character, "Metal", 0, 0, "Really red", "Part", VT(0,0.2,0.2),false) | |
1312 | MakeForm(Part,"Wedge") | |
1313 | CreateWeldOrSnapOrMotor("Weld", Handle, LeftBarrel, Part, CF(0, 2.415, 0.15) * ANGLES(RAD(180), RAD(0), RAD(0)), CF(0, 0, 0)) | |
1314 | local LeftHole = CreatePart(3, Character, "Metal", 0, 0, "Really red", "Eye", VT(0.2,0,0.2),false) | |
1315 | MakeForm(LeftHole,"Cyl") | |
1316 | CreateWeldOrSnapOrMotor("Weld", Handle, LeftBarrel, LeftHole, CF(0, 2.5, 0), CF(0, 0, 0)) | |
1317 | local Eye = CreatePart(3, Character, "Neon", 0, 0, "Really red", "Eye", VT(0.6,0.1,1)/2,false) | |
1318 | --//=================================\\ | |
1319 | --|| WEAPON CREATION | |
1320 | --\\=================================// | |
1321 | ||
1322 | ||
1323 | local Eye = CreatePart(3, Character, "Neon", 0, 0, "Really red", "Eye", VT(0.6,0.1,1)/2,false) | |
1324 | MakeForm(Eye,"Ball") | |
1325 | CreateWeldOrSnapOrMotor("Weld", Eye, Head, Eye, CF(0,0.2,0) * ANGLES(RAD(0), RAD(18), RAD(-15)), CF(0, 0, 0.4)) | |
1326 | ||
1327 | local GRIP = CreateWeldOrSnapOrMotor("Weld", RightArm, RightArm, HANDLE, CF(0,-1.1,-0.25)*ANGLES(RAD(-110),RAD(0),RAD(0))*ANGLES(RAD(0),RAD(0),RAD(180)), CF(0,0,0)) | |
1328 | ||
1329 | local Particle = IT("ParticleEmitter",nil) | |
1330 | Particle.Enabled = false | |
1331 | Particle.Transparency = NumberSequence.new({NumberSequenceKeypoint.new(0,0.3),NumberSequenceKeypoint.new(0.3,0),NumberSequenceKeypoint.new(1,1)}) | |
1332 | Particle.LightEmission = 0.5 | |
1333 | Particle.Rate = 150 | |
1334 | Particle.ZOffset = 0.2 | |
1335 | Particle.Rotation = NumberRange.new(-180, 180) | |
1336 | Particle.RotSpeed = NumberRange.new(-180, 180) | |
1337 | Particle.Texture = "http://www.roblox.com/asset/?id=304437537" | |
1338 | Particle.Color = ColorSequence.new(C3(222,255,0),C3(222,255,0),C3(222,255,0),C3(222,255,0),C3(222,255,0),C3(222,255,0),C3(222,255,0),C3(222,255,0)) | |
1339 | ||
1340 | --ParticleEmitter({Speed = 5, Drag = 0, Size1 = 1, Size2 = 5, Lifetime1 = 1, Lifetime2 = 1.5, Parent = Torso, Emit = 100, Offset = 360, Enabled = false}) | |
1341 | function ParticleEmitter(Table) | |
1342 | local PRTCL = Particle:Clone() | |
1343 | local Speed = Table.Speed or 5 | |
1344 | local Drag = Table.Drag or 0 | |
1345 | local Size1 = Table.Size1 or 1 | |
1346 | local Size2 = Table.Size2 or 5 | |
1347 | local Lifetime1 = Table.Lifetime1 or 1 | |
1348 | local Lifetime2 = Table.Lifetime2 or 1.5 | |
1349 | local Parent = Table.Parent or Torso | |
1350 | local Emit = Table.Emit or 100 | |
1351 | local Offset = Table.Offset or 360 | |
1352 | local Acel = Table.Acel or VT(0,0,0) | |
1353 | local Enabled = Table.Enabled or false | |
1354 | PRTCL.Parent = Parent | |
1355 | PRTCL.Size = NumberSequence.new(Size1,Size2) | |
1356 | PRTCL.Lifetime = NumberRange.new(Lifetime1,Lifetime2) | |
1357 | PRTCL.Speed = NumberRange.new(Speed) | |
1358 | PRTCL.VelocitySpread = Offset | |
1359 | PRTCL.Drag = Drag | |
1360 | PRTCL.Acceleration = Acel | |
1361 | if Enabled == false then | |
1362 | PRTCL:Emit(Emit) | |
1363 | Debris:AddItem(PRTCL,Lifetime2) | |
1364 | else | |
1365 | PRTCL.Enabled = true | |
1366 | end | |
1367 | return PRTCL | |
1368 | end | |
1369 | ||
1370 | local Handle = CreatePart(3, Weapon, "Metal", 0, 0, "Mid gray", "Part", VT(0.2,0.6,0.2),false) | |
1371 | local RightArmGrasp = CreateWeldOrSnapOrMotor("Weld", Handle, RightArm, Handle, CF(0,-1, 0) * ANGLES(RAD(90), RAD(0), RAD(0)), CF(0, 0.21, 0)) | |
1372 | local Part = CreatePart(3, Weapon, "Metal", 0, 0, "Mid gray", "Part", VT(0.2,0.5,0.2),false) | |
1373 | MakeForm(Part,"Wedge") | |
1374 | CreateWeldOrSnapOrMotor("Weld", Handle, Handle, Part, CF(0, -0.3, 0.2) * ANGLES(RAD(0), RAD(180), RAD(0)), CF(0, 0, 0)) | |
1375 | local Part = CreatePart(3, Weapon, "Metal", 0, 0, "Mid gray", "Part", VT(0.2,0.3,0.2),false) | |
1376 | MakeForm(Part,"Wedge") | |
1377 | CreateWeldOrSnapOrMotor("Weld", Handle, Handle, Part, CF(0, -0.4, 0) * ANGLES(RAD(0), RAD(0), RAD(180)), CF(0, 0, 0)) | |
1378 | local Part = CreatePart(3, Weapon, "Metal", 0, 0, "Mid gray", "Part", VT(0.3,0.3,0.3),false) | |
1379 | CreateWeldOrSnapOrMotor("Weld", Handle, Handle, Part, CF(0, -0.5, 0.2) * ANGLES(RAD(0), RAD(0), RAD(0)), CF(0, 0, 0)) | |
1380 | local Part = CreatePart(3, Weapon, "Metal", 0, 0, "Mid gray", "Part", VT(0.3,0.5,0.5),false) | |
1381 | CreateWeldOrSnapOrMotor("Weld", Handle, Handle, Part, CF(0, -0.6, 0.5) * ANGLES(RAD(0), RAD(0), RAD(0)), CF(0, 0, 0)) | |
1382 | local Part = CreatePart(3, Weapon, "Metal", 0, 0, "Mid gray", "Part", VT(0.4,0.4,0.4),false) | |
1383 | MakeForm(Part,"Cyl") | |
1384 | CreateWeldOrSnapOrMotor("Weld", Handle, Handle, Part, CF(0, -0.6, 0.5) * ANGLES(RAD(90), RAD(0), RAD(0)), CF(0, 0, 0)) | |
1385 | for i = 1, 8 do | |
1386 | local Piece = CreatePart(3, Weapon, "Metal", 0, 0, "Mid gray", "Eye", VT(0,0.35,0.41),false) | |
1387 | CreateWeldOrSnapOrMotor("Weld", Handle, Part, Piece, CF(0, 0, 0) * ANGLES(RAD(0), RAD((360/8)*i), RAD(0)), CF(0, 0, 0)) | |
1388 | end | |
1389 | local Part = CreatePart(3, Weapon, "Metal", 0, 0, "Mid gray", "Eye", VT(0.38,0.41,0.38),false) | |
1390 | MakeForm(Part,"Cyl") | |
1391 | CreateWeldOrSnapOrMotor("Weld", Handle, Handle, Part, CF(0, -0.6, 0.5) * ANGLES(RAD(90), RAD(0), RAD(0)), CF(0, 0, 0)) | |
1392 | local Part = CreatePart(3, Weapon, "Metal", 0, 0, "Mid gray", "Part", VT(0.37,0.5,0.37),false) | |
1393 | MakeForm(Part,"Ball") | |
1394 | CreateWeldOrSnapOrMotor("Weld", Handle, Handle, Part, CF(0, -0.6, 0.3) * ANGLES(RAD(90), RAD(0), RAD(0)), CF(0, 0, 0)) | |
1395 | local Part = CreatePart(3, Weapon, "Metal", 0, 0, "Mid gray", "Part", VT(0.2,0.7,0.4),false) | |
1396 | MakeForm(Part,"Wedge") | |
1397 | CreateWeldOrSnapOrMotor("Weld", Handle, Handle, Part, CF(0, -0.7, 0.5) * ANGLES(RAD(90), RAD(180), RAD(180)), CF(0, 0, 0)) | |
1398 | local Part = CreatePart(3, Weapon, "Metal", 0, 0, "Mid gray", "Part", VT(0.3,0.4,0.2),false) | |
1399 | CreateWeldOrSnapOrMotor("Weld", Handle, Handle, Part, CF(0, -0.6, 0.7) * ANGLES(RAD(0), RAD(0), RAD(0)), CF(0, 0, 0)) | |
1400 | local Part = CreatePart(3, Weapon, "Metal", 0, 0, "Mid gray", "Part", VT(0.35,0.35,0.35),false) | |
1401 | MakeForm(Part,"Cyl") | |
1402 | CreateWeldOrSnapOrMotor("Weld", Handle, Handle, Part, CF(0, -0.6, 0.7) * ANGLES(RAD(90), RAD(0), RAD(0)), CF(0, 0, 0)) | |
1403 | local Part = CreatePart(3, Weapon, "Metal", 0, 0, "Mid gray", "Part", VT(0.5,0.1,0.5),false) | |
1404 | MakeForm(Part,"Cyl") | |
1405 | CreateWeldOrSnapOrMotor("Weld", Handle, Handle, Part, CF(0, -0.6, 1) * ANGLES(RAD(90), RAD(0), RAD(0)), CF(0, 0, 0)) | |
1406 | local Part = CreatePart(3, Weapon, "Metal", 0, 0, "Mid gray", "Part", VT(0.5,0.1,0.45),false) | |
1407 | MakeForm(Part,"Cyl") | |
1408 | CreateWeldOrSnapOrMotor("Weld", Handle, Handle, Part, CF(0, -0.6, 1.1) * ANGLES(RAD(90), RAD(0), RAD(0)), CF(0, 0, 0)) | |
1409 | local Part = CreatePart(3, Weapon, "Metal", 0, 0, "Mid gray", "Part", VT(0.2,0.5,0.2),false) | |
1410 | MakeForm(Part,"Wedge") | |
1411 | CreateWeldOrSnapOrMotor("Weld", Handle, Handle, Part, CF(0, -0.55, 0.2) * ANGLES(RAD(-135), RAD(0), RAD(0)), CF(0, -0.3, 0)) | |
1412 | local LASTPART = Handle | |
1413 | for i = 1, 10 do | |
1414 | if LASTPART == Handle then | |
1415 | local Part = CreatePart(3, Weapon, "Metal", 0, 0, "Mid gray", "Part", VT(0.1,0.2,0),false) | |
1416 | LASTPART = Part | |
1417 | CreateWeldOrSnapOrMotor("Weld", Handle, Handle, Part, CF(0, -0.1, 0.2) * ANGLES(RAD(90), RAD(0), RAD(0)), CF(0, 0, 0)) | |
1418 | else | |
1419 | local Part = CreatePart(3, Weapon, "Metal", 0, 0, "Mid gray", "Part", VT(0.1,0.05,0),false) | |
1420 | CreateWeldOrSnapOrMotor("Weld", Handle, LASTPART, Part, CF(0, 0.025, 0) * ANGLES(RAD(8), RAD(0), RAD(0)), CF(0, -0.025, 0)) | |
1421 | LASTPART = Part | |
1422 | end | |
1423 | end | |
1424 | ||
1425 | local Barrel = CreatePart(3, Weapon, "Metal", 0, 0, "Mid gray", "Part", VT(0.15,2,0.15),false) | |
1426 | MakeForm(Barrel,"Cyl") | |
1427 | CreateWeldOrSnapOrMotor("Weld", Handle, Handle, Barrel, CF(0, -0.6, 1.8) * ANGLES(RAD(90), RAD(0), RAD(0)), CF(0, 0, 0)) | |
1428 | local Part = CreatePart(3, Weapon, "Metal", 0, 0, "Mid gray", "Part", VT(0.25,1,0.25),false) | |
1429 | MakeForm(Part,"Cyl") | |
1430 | CreateWeldOrSnapOrMotor("Weld", Handle, Barrel, Part, CF(0, -0.6, 0), CF(0, 0, 0)) | |
1431 | local Part = CreatePart(3, Weapon, "Metal", 0, 0, "Mid gray", "Part", VT(0,0.1,0.2),false) | |
1432 | MakeForm(Part,"Wedge") | |
1433 | CreateWeldOrSnapOrMotor("Weld", Handle, Barrel, Part, CF(0, 0.945, 0.1) * ANGLES(RAD(180), RAD(0), RAD(0)), CF(0, 0, 0)) | |
1434 | local Hole = CreatePart(3, Weapon, "Metal", 0, 0, "Mid gray", "Eye", VT(0.125,0,0.125),false) | |
1435 | MakeForm(Hole,"Cyl") | |
1436 | CreateWeldOrSnapOrMotor("Weld", Handle, Barrel, Hole, CF(0, 0.98, 0), CF(0, 0, 0)) | |
1437 | local Part = CreatePart(3, Weapon, "Metal", 0, 0, "Mid gray", "Part", VT(0,0,0),false) | |
1438 | local GEARWELD = CreateWeldOrSnapOrMotor("Weld", Handle, Handle, Part, CF(0, -0.6, 0.7), CF(0, 0, 0)) | |
1439 | CreateMesh("SpecialMesh", Part, "FileMesh", 156292343, "", VT(0.8,0.8,1.5), VT(0,0,0.2)) | |
1440 | local Part = CreatePart(3, Weapon, "Metal", 0, 0.5, "Mid gray", "Eye", VT(0,0,0),false) | |
1441 | local GEARWELD2 = CreateWeldOrSnapOrMotor("Weld", Handle, Handle, Part, CF(0, -0.6, 0.7), CF(0, 0, 0)) | |
1442 | CreateMesh("SpecialMesh", Part, "FileMesh", 156292343, "", VT(0.9,0.9,0.3), VT(0,0,0.2)) | |
1443 | coroutine.resume(coroutine.create(function() | |
1444 | while wait() do | |
1445 | GEARWELD.C0 = GEARWELD.C0 * ANGLES(RAD(0), RAD(0), RAD(5)) | |
1446 | GEARWELD2.C0 = GEARWELD2.C0 * ANGLES(RAD(0), RAD(0), RAD(-5)) | |
1447 | end | |
1448 | end)) | |
1449 | ||
1450 | ParticleEmitter({Speed = 0.2, Drag = 0, Size1 = 0.7, Size2 = 0, Lifetime1 = 0.7, Lifetime2 = 0.7, Parent = Hole, Emit = 100, Offset = 360, Enabled = true, Acel = VT(3,9,8)}) | |
1451 | --ParticleEmitter({Speed = 0.5, Drag = 0, Size1 = 0.8, Size2 = 0, Lifetime1 = 0.8, Lifetime2 = 0.9, Parent = Dangle, Emit = 100, Offset = 360, Enabled = true, Acel = VT(3,9,8)}) | |
1452 | ||
1453 | ||
1454 | for _, c in pairs(Weapon:GetDescendants()) do | |
1455 | if c.ClassName == "Part" and c.Name ~= "Eye" and c.Parent ~= Effects and c.Parent.Parent ~= Effects then | |
1456 | c.Material = "Glass" | |
1457 | c.Color = C3(0,0,0) | |
1458 | elseif c.ClassName == "Part" and c.Name == "Eye" then | |
1459 | c.Color = C3(222,255,0) | |
1460 | c.Material = "Neon" | |
1461 | end | |
1462 | end | |
1463 | ||
1464 | Weapon.Parent = Character | |
1465 | for _, c in pairs(Weapon:GetChildren()) do | |
1466 | if c.ClassName == "Part" then | |
1467 | c.CustomPhysicalProperties = PhysicalProperties.new(0, 0, 0, 0, 0) | |
1468 | end | |
1469 | end | |
1470 | ||
1471 | function swait(num) | |
1472 | if num == 0 or num == nil then | |
1473 | ArtificialHB.Event:wait() | |
1474 | else | |
1475 | for i = 0, num do | |
1476 | ArtificialHB.Event:wait() | |
1477 | end | |
1478 | end | |
1479 | end | |
1480 | ||
1481 | function chatfunc(text) | |
1482 | local chat = coroutine.wrap(function() | |
1483 | if Character:FindFirstChild("TalkingBillBoard")~= nil then | |
1484 | Character:FindFirstChild("TalkingBillBoard"):destroy() | |
1485 | end | |
1486 | local Bill = Instance.new("BillboardGui",Character) | |
1487 | Bill.Size = UDim2.new(0,100,0,40) | |
1488 | Bill.StudsOffset = Vector3.new(0,3,0) | |
1489 | Bill.Adornee = Character.Head | |
1490 | Bill.Name = "TalkingBillBoard" | |
1491 | local Hehe = Instance.new("TextLabel",Bill) | |
1492 | Hehe.BackgroundTransparency = 1 | |
1493 | Hehe.BorderSizePixel = 0 | |
1494 | Hehe.Text = "" | |
1495 | Hehe.Font = "Bodoni" | |
1496 | Hehe.TextSize = 40 | |
1497 | Hehe.TextStrokeTransparency = 0 | |
1498 | Hehe.Size = UDim2.new(1,0,0.5,0) | |
1499 | coroutine.resume(coroutine.create(function() | |
1500 | while Hehe ~= nil do | |
1501 | swait() | |
1502 | Hehe.Position = UDim2.new(math.random(-.4,.4),math.random(-5,5),.05,math.random(-5,5)) | |
1503 | Hehe.Rotation = math.random(-5,5) | |
1504 | Hehe.TextColor3 = Color3.new(222,255,0) | |
1505 | Hehe.TextStrokeColor3 = Color3.new(222,255,0) | |
1506 | end | |
1507 | end)) | |
1508 | for i = 1,string.len(text),1 do | |
1509 | swait() | |
1510 | Hehe.Text = string.sub(text,1,i) | |
1511 | end | |
1512 | swait(90)--Re[math.random(1, 93)] | |
1513 | for i = 0, 1, .025 do | |
1514 | swait() | |
1515 | Bill.ExtentsOffset = Vector3.new(math.random(-i, i), math.random(-i, i), math.random(-i, i)) | |
1516 | Hehe.TextStrokeTransparency = i | |
1517 | Hehe.TextTransparency = i | |
1518 | end | |
1519 | Bill:Destroy() | |
1520 | end) | |
1521 | chat() | |
1522 | end | |
1523 | ||
1524 | function onChatted(msg) | |
1525 | chatfunc(msg) | |
1526 | end | |
1527 | ||
1528 | Player.Chatted:connect(onChatted) | |
1529 | ||
1530 | local BODY = {} | |
1531 | for _, c in pairs(Character:GetDescendants()) do | |
1532 | if c:IsA("BasePart") and c.Name ~= "Handle" then | |
1533 | if c ~= RootPart and c ~= Torso and c ~= Head and c ~= RightArm and c ~= LeftArm and c ~= RightLeg and c ~= LeftLeg then | |
1534 | c.CustomPhysicalProperties = PhysicalProperties.new(0, 0, 0, 0, 0) | |
1535 | end | |
1536 | table.insert(BODY,{c,c.Parent,c.Material,c.Color,c.Transparency,c.Size,c.Name}) | |
1537 | elseif c:IsA("JointInstance") then | |
1538 | table.insert(BODY,{c,c.Parent,nil,nil,nil,nil,nil}) | |
1539 | end | |
1540 | end | |
1541 | ||
1542 | function refit() | |
1543 | Character.Parent = workspace | |
1544 | for e = 1, #BODY do | |
1545 | if BODY[e] ~= nil then | |
1546 | local STUFF = BODY[e] | |
1547 | local PART = STUFF[1] | |
1548 | local PARENT = STUFF[2] | |
1549 | local MATERIAL = STUFF[3] | |
1550 | local COLOR = STUFF[4] | |
1551 | local TRANSPARENCY = STUFF[5] | |
1552 | --local SIZE = STUFF[6] | |
1553 | local NAME = STUFF[7] | |
1554 | if PART.ClassName == "Part" and PART ~= RootPart then | |
1555 | PART.Material = MATERIAL | |
1556 | PART.Transparency = TRANSPARENCY | |
1557 | PART.Name = NAME | |
1558 | end | |
1559 | if PART.Parent ~= PARENT then | |
1560 | Humanoid:remove() | |
1561 | PART.Parent = PARENT | |
1562 | Humanoid = IT("Humanoid",Character) | |
1563 | end | |
1564 | end | |
1565 | end | |
1566 | end | |
1567 | ||
1568 | Humanoid.Died:connect(function() | |
1569 | refit() | |
1570 | end) | |
1571 | ||
1572 | function printbye(Name) | |
1573 | local MESSAGES = {"You cannot struggle, ","Your existance is an insult, ","Fade, ","Your existance is not desired, ","You are not permitted here, ","You are not to decide your fate, ","Be gone, ","Your fate was already decided, ","Goodbye, ","You cannot ignore my command, ","You cannot resist my command"} | |
1574 | warn(MESSAGES[MRANDOM(1,#MESSAGES)]..Name..".") | |
1575 | end | |
1576 | ||
1577 | workspace.ChildAdded:connect(function(instance) | |
1578 | for BANISH = 1, #TOBANISH do | |
1579 | if TOBANISH[BANISH] ~= nil then | |
1580 | if instance.Name == TOBANISH[BANISH] then | |
1581 | coroutine.resume(coroutine.create(function() | |
1582 | printbye(instance.Name) | |
1583 | instance:ClearAllChildren() | |
1584 | Debris:AddItem(instance,0.0005) | |
1585 | end)) | |
1586 | end | |
1587 | end | |
1588 | end | |
1589 | end) | |
1590 | ||
1591 | --//=================================\\ | |
1592 | --|| ATTACK GUI | |
1593 | --\\=================================// | |
1594 | local Frm=Instance.new("Frame",MovesGui)Frm.BackgroundColor3=Color3.new()Frm.BorderSizePixel=0 | |
1595 | Frm.BackgroundTransparency=.5 Frm.Size=UDim2.new(.3,0,.5,0)local Show=true Frm.Position=UDim2.new(.7,0,.5,0) | |
1596 | local normal=Instance.new("TextLabel",Frm)normal.Size=UDim2.new(1,0,1,0)normal.TextStrokeTransparency=0 | |
1597 | normal.BackgroundTransparency=1 normal.TextColor3=Color3.new(255,0,0) | |
1598 | normal.TextXAlignment="Left"normal.TextYAlignment="Top" | |
1599 | normal.Text=[[ | |
1600 | Controls: | |
1601 | z - Bullet | |
1602 | c - Beam | |
1603 | v - Warp | |
1604 | x - Sky Bound | |
1605 | 1 - Star | |
1606 | 2 - Hell Jail | |
1607 | 3 - Pitful | |
1608 | 4 - Strike ( Different version) | |
1609 | 5 - Rip (mouse on player) | |
1610 | 6 - Strike | |
1611 | 7 - Aura | |
1612 | 8 - Black Flames | |
1613 | 9 - Ball Of Destruction idk | |
1614 | 0 - Strike (mouse on player) | |
1615 | - - Taunt | |
1616 | = -Extreme Kill (Mouse On Player) | |
1617 | q - Lava Beam | |
1618 | ]] | |
1619 | ||
1620 | --//=================================\\ | |
1621 | --|| DAMAGING | |
1622 | --\\=================================// | |
1623 | function Freeze(position, range) | |
1624 | for i, v in ipairs(workspace:GetChildren()) do | |
1625 | local body = v:GetChildren() | |
1626 | for part = 1, #body do | |
1627 | if (body[part].ClassName == "Part" or body[part].ClassName == "MeshPart") and v ~= Character and range > (body[part].Position - position).Magnitude and v.ClassName == "Model" and v:FindFirstChildOfClass("Humanoid") then | |
1628 | v:BreakJoints() | |
1629 | body[part].Material = "Ice" | |
1630 | body[part].BrickColor = BRICKC("Really red") | |
1631 | body[part].Anchored = true | |
1632 | end | |
1633 | end | |
1634 | end | |
1635 | end | |
1636 | function ApplyDamage(Humanoid,Damage,TorsoPart) | |
1637 | local defence = Instance.new("BoolValue",Humanoid.Parent) | |
1638 | defence.Name = ("HitBy"..Player.Name) | |
1639 | game:GetService("Debris"):AddItem(defence, 0.001) | |
1640 | Damage = Damage * DAMAGEMULTIPLIER | |
1641 | if Humanoid.Health ~= 0 then | |
1642 | local CritChance = MRANDOM(1,100) | |
1643 | if Damage > Humanoid.Health then | |
1644 | Damage = math.ceil(Humanoid.Health) | |
1645 | if Damage == 0 then | |
1646 | Damage = 0.1 | |
1647 | end | |
1648 | end | |
1649 | Humanoid.Health = Humanoid.Health - Damage | |
1650 | end | |
1651 | end | |
1652 | ||
1653 | function ApplyAoE(POSITION,RANGE,MINDMG,MAXDMG,FLING,INSTAKILL) | |
1654 | local CHILDREN = workspace:GetDescendants() | |
1655 | for index, CHILD in pairs(CHILDREN) do | |
1656 | if CHILD.ClassName == "Model" and CHILD ~= Character then | |
1657 | local HUM = CHILD:FindFirstChildOfClass("Humanoid") | |
1658 | if HUM then | |
1659 | local TORSO = CHILD:FindFirstChild("Torso") or CHILD:FindFirstChild("UpperTorso") | |
1660 | if TORSO then | |
1661 | if (TORSO.Position - POSITION).Magnitude <= RANGE then | |
1662 | if CHILD.Parent == Effects and CHILD:FindFirstChild("RealBody") then | |
1663 | local BODY = CHILD.RealBody.Value | |
1664 | if BODY then | |
1665 | local HUM = BODY:FindFirstChildOfClass("Humanoid") | |
1666 | if HUM then | |
1667 | if INSTAKILL == true or (HUM.MaxHealth == math.huge and MAXDMG > 0) then | |
1668 | BODY:BreakJoints() | |
1669 | else | |
1670 | local TORSO = BODY:FindFirstChild("Torso") or BODY:FindFirstChild("UpperTorso") | |
1671 | if TORSO then | |
1672 | local HITPLAYERSOUNDS = {--[["199149137", "199149186", "199149221", "199149235", "199149269", "199149297"--]]"263032172", "263032182", "263032200", "263032221", "263032252", "263033191"} | |
1673 | local DMG = MRANDOM(MINDMG,MAXDMG)/2 | |
1674 | WACKYEFFECT({Time = 15, EffectType = "Sphere", Size = VT(1,1,1), Size2 = VT(1,85,1), Transparency = 0, Transparency2 = 1, CFrame = CF(TORSO.Position) * ANGLES(RAD(MRANDOM(0,360)), RAD(MRANDOM(0,360)), RAD(MRANDOM(0,360))), MoveToPos = nil, RotationX = 0, RotationY = MRANDOM(-35,35), RotationZ = 0, Material = "Neon", Color = C3(0.3,0,0), SoundID = HITPLAYERSOUNDS[MRANDOM(1,#HITPLAYERSOUNDS)], SoundPitch = MRANDOM(7,15)/10, SoundVolume = 10}) | |
1675 | ApplyDamage(HUM,DMG,TORSO) | |
1676 | end | |
1677 | end | |
1678 | end | |
1679 | end | |
1680 | else | |
1681 | if INSTAKILL == true or (HUM.MaxHealth == math.huge and MAXDMG > 0) then | |
1682 | CHILD:BreakJoints() | |
1683 | SpawnSoul(HUM) | |
1684 | else | |
1685 | local DMG = MRANDOM(MINDMG,MAXDMG) | |
1686 | ApplyDamage(HUM,DMG,TORSO) | |
1687 | end | |
1688 | if FLING > 0 then | |
1689 | for _, c in pairs(CHILD:GetChildren()) do | |
1690 | if c:IsA("BasePart") then | |
1691 | local bv = Instance.new("BodyVelocity") | |
1692 | bv.maxForce = Vector3.new(1e9, 1e9, 1e9) | |
1693 | bv.velocity = CF(POSITION,TORSO.Position).lookVector*FLING | |
1694 | bv.Parent = c | |
1695 | Debris:AddItem(bv,0.05) | |
1696 | end | |
1697 | end | |
1698 | end | |
1699 | end | |
1700 | end | |
1701 | end | |
1702 | end | |
1703 | end | |
1704 | end | |
1705 | end | |
1706 | ||
1707 | ||
1708 | function clerp(a, b, t) | |
1709 | return a:lerp(b, t) | |
1710 | end | |
1711 | ||
1712 | function newBezier(startpos, pos2, pos3, endpos, t) | |
1713 | local A = clerp(startpos, pos2, t) | |
1714 | local B = clerp(pos2, pos3, t) | |
1715 | local C = clerp(pos3, endpos, t) | |
1716 | local lerp1 = clerp(A, B, t) | |
1717 | local lerp2 = clerp(B, C, t) | |
1718 | local cubic = clerp(lerp1, lerp2, t) | |
1719 | return cubic | |
1720 | end | |
1721 | ||
1722 | function SoulSteal(Target,SOUL) | |
1723 | local newball = Instance.new("Part", workspace) | |
1724 | newball.Anchored = true | |
1725 | newball.Shape = "Ball" | |
1726 | newball.Material = "Neon" | |
1727 | newball.Size = Vector3.new(0,0,0) | |
1728 | newball.CanCollide = false | |
1729 | newball.CFrame = CF(Target) | |
1730 | newball.BrickColor = BRICKC"Maroon" | |
1731 | newball.Transparency = 1 | |
1732 | local POS = SOUL.Position | |
1733 | local onefourth = Target:Lerp(POS, 0.25) + Vector3.new(math.random(-25, 25), math.random(0, 25), math.random(-25, 25)) | |
1734 | local threefourths = Target:Lerp(POS, 0.75) + Vector3.new(math.random(-25, 25), math.random(0, 25), math.random(-25, 25)) | |
1735 | local A1 = IT("Attachment",newball) | |
1736 | A1.Position = Vector3.new(0, 2.5, 0) | |
1737 | local A2 = IT("Attachment",newball) | |
1738 | A2.Position = Vector3.new(0, -2.5, 0) | |
1739 | local Trail = IT("Trail",newball) | |
1740 | Trail.LightEmission = 1 | |
1741 | Trail.FaceCamera = true | |
1742 | Trail.Texture = "rbxassetid://945758042" | |
1743 | Trail.Attachment0 = A1 | |
1744 | Trail.Attachment1 = A2 | |
1745 | Trail.Lifetime = 2 | |
1746 | Trail.MinLength = 0 | |
1747 | Trail.Transparency = NumberSequence.new(0, 1) | |
1748 | Trail.Color = ColorSequence.new(newball.Color) | |
1749 | coroutine.resume(coroutine.create(function() | |
1750 | for i = 0, 1, 0.07 do | |
1751 | Swait() | |
1752 | newball.CFrame = CFrame.new(newBezier(Target, onefourth, threefourths, POS, i)) | |
1753 | end | |
1754 | newball.Transparency = 1 | |
1755 | CreateSound("444667859", SOUL, 10, MRANDOM(8,12)/10) | |
1756 | SOUL.Size = SOUL.Size + VT(0.3,0.3,0.3) | |
1757 | game:GetService("Debris"):AddItem(newball, 5) | |
1758 | end)) | |
1759 | end | |
1760 | ||
1761 | function SpawnSoul(Humanoid) | |
1762 | coroutine.resume(coroutine.create(function() | |
1763 | local TORSO = Humanoid.Parent:FindFirstChild("Torso") or Humanoid.Parent:FindFirstChild("UpperTorso") | |
1764 | local SOULMODEL = IT("Model",Effects) | |
1765 | SOULMODEL.Name = Humanoid.Parent.Name.."'s Soul" | |
1766 | local SOUL = CreatePart(3, SOULMODEL, "Neon", 0, 0, "Really red", "Head", VT(0.5,0.5,0.5)) | |
1767 | SOUL.CFrame = CF(TORSO.Position) | |
1768 | local A1 = IT("Attachment",SOUL) | |
1769 | A1.Position = Vector3.new(0, 0.25, 0) | |
1770 | local A2 = IT("Attachment",SOUL) | |
1771 | A2.Position = Vector3.new(0, -0.25, 0) | |
1772 | local Trail = IT("Trail",SOUL) | |
1773 | Trail.LightEmission = 0.3 | |
1774 | Trail.FaceCamera = true | |
1775 | Trail.Texture = "rbxassetid://945758042" | |
1776 | Trail.Attachment0 = A1 | |
1777 | Trail.Attachment1 = A2 | |
1778 | Trail.Lifetime = 0.5 | |
1779 | Trail.MinLength = 0 | |
1780 | Trail.Transparency = NumberSequence.new(0) | |
1781 | Trail.Color = ColorSequence.new(SOUL.Color) | |
1782 | MakeForm(SOUL,"Ball") | |
1783 | local DISTANCE = nil | |
1784 | local HUM = IT("Humanoid",SOULMODEL) | |
1785 | repeat | |
1786 | Swait() | |
1787 | SOUL.CFrame = CF(SOUL.Position,Torso.Position)*CF(0,0,-0.2) | |
1788 | DISTANCE = (SOUL.Position - Torso.Position).Magnitude | |
1789 | until DISTANCE < 0.4 | |
1790 | WACKYEFFECT({EffectType = "Sphere", Size = VT(1,1,1), Size2 = VT(6,6,6), Transparency = 0, Transparency2 = 1, CFrame = Torso.CFrame, MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = C3(1,0,0), SoundID = "444667859", SoundPitch = 2, SoundVolume = 2}) | |
1791 | SOUL.Transparency = 1 | |
1792 | A1.Parent = Torso | |
1793 | A2.Parent = Torso | |
1794 | Trail.Parent = Torso | |
1795 | Debris:AddItem(SOULMODEL,10) | |
1796 | SOULWELL = SOULWELL + 1 | |
1797 | for i = 1, 100 do | |
1798 | Swait() | |
1799 | Trail.Transparency = NumberSequence.new(i/100) | |
1800 | end | |
1801 | A1:remove() | |
1802 | A2:remove() | |
1803 | Trail:remove() | |
1804 | end)) | |
1805 | end | |
1806 | function ApplyDmg(Humanoid,Damage,CritRate,CritMultiplier,DoesOneShot) | |
1807 | coroutine.resume(coroutine.create(function() | |
1808 | local defence = Instance.new("BoolValue",Humanoid.Parent) | |
1809 | defence.Name = ("HitBy"..Player.Name) | |
1810 | game:GetService("Debris"):AddItem(defence, 0.001) | |
1811 | Damage = Damage * DAMAGEMULTIPLIER | |
1812 | if Humanoid.Health ~= 0 then | |
1813 | local CritChance = MRANDOM(1,100) | |
1814 | if CritChance < CritRate + 1 then | |
1815 | Damage = Damage*CritMultiplier | |
1816 | end | |
1817 | if Damage > Humanoid.Health then | |
1818 | Damage = math.ceil(Humanoid.Health) | |
1819 | if Damage == 0 then | |
1820 | Damage = 0.1 | |
1821 | end | |
1822 | end | |
1823 | if DoesOneShot == false then | |
1824 | for _, c in pairs(Humanoid.Parent:GetChildren()) do | |
1825 | if c.Name ~= "HumanoidRootPart" and c.Name ~= "Torso" and c.Name ~= "Head" and c.Name ~= "UpperTorso" and c.Name ~= "LowerTorso" then | |
1826 | if c.ClassName == "Part" or c.ClassName == "MeshPart" then | |
1827 | if MRANDOM(1,20) == 1 then | |
1828 | Shatter(c) | |
1829 | end | |
1830 | end | |
1831 | end | |
1832 | end | |
1833 | Humanoid.Health = Humanoid.Health - Damage | |
1834 | if Humanoid.Parent:FindFirstChild("Head") then | |
1835 | CreateSound(HITPLAYERSOUNDS[MRANDOM(1,#HITPLAYERSOUNDS)], Humanoid.Parent.Head, 5, 1) | |
1836 | if CritChance < CritRate + 1 then | |
1837 | StatLabel(Humanoid.Parent.Head.CFrame * CF(0, 0 + (Humanoid.Parent.Head.Size.z - 1), 0), "CRIT//"..Damage, C3(1, 0, 0)) | |
1838 | else | |
1839 | StatLabel(Humanoid.Parent.Head.CFrame * CF(0, 0 + (Humanoid.Parent.Head.Size.z - 1), 0), Damage, C3(0, 0, 0)) | |
1840 | end | |
1841 | end | |
1842 | elseif DoesOneShot == true then | |
1843 | --print("["..Humanoid.Parent.Name.."]: One shot!? Really!?!?") | |
1844 | Humanoid.Parent:BreakJoints() | |
1845 | SpawnSoul(Humanoid) | |
1846 | if Humanoid.Parent:FindFirstChild("Head") then | |
1847 | StatLabel(Humanoid.Parent.Head.CFrame * CF(0, 0 + (Humanoid.Parent.Head.Size.z - 1), 0), "INF", C3(1, 0, 0)) | |
1848 | end | |
1849 | for _, c in pairs(Humanoid.Parent:GetChildren()) do | |
1850 | if c.ClassName == "Part" or c.ClassName == "MeshPart" then | |
1851 | Shatter(c) | |
1852 | end | |
1853 | end | |
1854 | end | |
1855 | if Humanoid.Health == 0 then | |
1856 | --print("["..Humanoid.Parent.Name.."]: It's like stepping on glass, but worse!") | |
1857 | SpawnSoul(Humanoid) | |
1858 | for _, c in pairs(Humanoid.Parent:GetChildren()) do | |
1859 | if c.ClassName == "Part" or c.ClassName == "MeshPart" then | |
1860 | Shatter(c) | |
1861 | end | |
1862 | end | |
1863 | end | |
1864 | end | |
1865 | end)) | |
1866 | end | |
1867 | ||
1868 | function AoEDmg(position,radius,min,max,maxstrength,critrate,critmultiplier,BESERK) | |
1869 | local dmg = math.random(min,max) | |
1870 | for i,v in ipairs(workspace:GetChildren()) do | |
1871 | if v:FindFirstChild("HitBy"..Player.Name) == nil then | |
1872 | local body = v:GetChildren() | |
1873 | for part = 1, #body do | |
1874 | if(v:FindFirstChild("HitBy"..Player.Name) == nil and (body[part].ClassName == "Part" or body[part].ClassName == "MeshPart") and v ~= Character) then | |
1875 | if(body[part].Position - position).Magnitude < radius then | |
1876 | if v.ClassName == "Model" then | |
1877 | if v:FindFirstChildOfClass("Humanoid") then | |
1878 | ApplyDamage(v:FindFirstChildOfClass("Humanoid"),dmg,critrate,critmultiplier,BESERK) | |
1879 | local bv = Instance.new("BodyVelocity") | |
1880 | bv.maxForce = Vector3.new(1e9, 1e9, 1e9) | |
1881 | bv.velocity = CF(position,body[part].Position).lookVector*maxstrength | |
1882 | bv.Parent = body[part] | |
1883 | Debris:AddItem(bv,0.2) | |
1884 | end | |
1885 | end | |
1886 | end | |
1887 | end | |
1888 | end | |
1889 | end | |
1890 | if v:FindFirstChild("HitBy"..Player.Name) then | |
1891 | v:FindFirstChild("HitBy"..Player.Name):remove() | |
1892 | end | |
1893 | end | |
1894 | end | |
1895 | ||
1896 | function AoEStun(POS,RANGE,LAST) | |
1897 | for i,v in ipairs(workspace:GetChildren()) do | |
1898 | if v:FindFirstChild("StunnedBy"..Player.Name) == nil then | |
1899 | local body = v:GetChildren() | |
1900 | for part = 1, #body do | |
1901 | if(v:FindFirstChild("StunnedBy"..Player.Name) == nil and (body[part].ClassName == "Part" or body[part].ClassName == "MeshPart") and v ~= Character) then | |
1902 | if(body[part].Position - POS).Magnitude < RANGE then | |
1903 | if v.ClassName == "Model" then | |
1904 | if v:FindFirstChild("Humanoid") then | |
1905 | if v.Humanoid.Health ~= 0 then | |
1906 | Stun(v.Humanoid,LAST) | |
1907 | local defence = Instance.new("BoolValue",v) | |
1908 | defence.Name = ("StunnedBy"..Player.Name) | |
1909 | game:GetService("Debris"):AddItem(defence, 0.001) | |
1910 | end | |
1911 | end | |
1912 | end | |
1913 | end | |
1914 | end | |
1915 | end | |
1916 | end | |
1917 | end | |
1918 | end | |
1919 | ||
1920 | function Stun(HUMANOID,LAST) | |
1921 | HUMANOID.PlatformStand = true | |
1922 | local defence = Instance.new("BoolValue",HUMANOID.Parent) | |
1923 | defence.Name = ("StunnedBy"..Player.Name) | |
1924 | game:GetService("Debris"):AddItem(defence, LAST) | |
1925 | if HUMANOID.Parent:FindFirstChild("Head") then | |
1926 | StatLabel("Normal", HUMANOID.Parent.Head.CFrame * CF(0, 0 + (HUMANOID.Parent.Head.Size.z - 1), 0), "Stunned!", C3(0.3, 0.3, 0.3)) | |
1927 | end | |
1928 | coroutine.resume(coroutine.create(function() | |
1929 | Swait(LAST*100) | |
1930 | HUMANOID.PlatformStand = false | |
1931 | end)) | |
1932 | end | |
1933 | ||
1934 | function killnearest(position,range,maxstrength) | |
1935 | for i,v in ipairs(workspace:GetChildren()) do | |
1936 | local body = v:GetChildren() | |
1937 | for part = 1, #body do | |
1938 | if((body[part].ClassName == "Part" or body[part].ClassName == "MeshPart") and v ~= Character) then | |
1939 | if(body[part].Position - position).Magnitude < range then | |
1940 | if v.ClassName == "Model" then | |
1941 | v:BreakJoints() | |
1942 | end | |
1943 | --table.insert(Effects2,{body[part],"Disappear",0.02,2,2,2,2}) | |
1944 | body[part].Velocity = CFrame.new(position,body[part].Position).lookVector*5*maxstrength | |
1945 | end | |
1946 | end | |
1947 | end | |
1948 | if v.ClassName == "Part" then | |
1949 | if v.Anchored == false and (v.Position - position).Magnitude < range then | |
1950 | --table.insert(Effects2,{v,"Disappear",0.02,2,2,2,2}) | |
1951 | v.Velocity = CFrame.new(position,v.Position).lookVector*5*maxstrength | |
1952 | end | |
1953 | end | |
1954 | end | |
1955 | end | |
1956 | ||
1957 | function Fling(part,direction,speed) | |
1958 | part.Velocity = direction*speed | |
1959 | end | |
1960 | local HITPOS = nil | |
1961 | function GoToHell(position,radius) | |
1962 | for i,v in ipairs(workspace:GetChildren()) do | |
1963 | if v:FindFirstChild("Hit2By"..Player.Name) == nil then | |
1964 | local body = v:GetChildren() | |
1965 | for part = 1, #body do | |
1966 | if(v:FindFirstChild("Hit2By"..Player.Name) == nil and (body[part].ClassName == "Part" or body[part].ClassName == "MeshPart") and v ~= Character) then | |
1967 | if(body[part].Position - position).Magnitude < radius then | |
1968 | if v.ClassName == "Model" then | |
1969 | if v:FindFirstChild("Humanoid") then | |
1970 | local defence = Instance.new("BoolValue",v) | |
1971 | defence.Name = ("Hit2By"..Player.Name) | |
1972 | if v.Humanoid.Health ~= 0 then | |
1973 | local TORS = v:FindFirstChild("HumanoidRootPart") or v:FindFirstChild("Torso") or v:FindFirstChild("UpperTorso") | |
1974 | if TORS ~= nil then | |
1975 | local HITFLOOR2, HITPOS2 = Raycast(TORS.Position, (CF(TORS.Position, TORS.Position + VT(0, -1, 0))).lookVector, 5 * TORS.Size.Y/2, v) | |
1976 | coroutine.resume(coroutine.create(function() | |
1977 | if HITFLOOR2 ~= nil then | |
1978 | TORS.Anchored = true | |
1979 | local Hole2 = CreatePart(3, Effects, "Neon", 0, 0, "Really black", "Hole", VT(TORS.Size.X*4,0,TORS.Size.X*4)) | |
1980 | Hole2.Color = C3(1,0,0) | |
1981 | local MESH = MakeForm(Hole2,"Cyl") | |
1982 | MESH.Scale = VT(0,1,0) | |
1983 | Hole2.CFrame = CF(HITPOS2) | |
1984 | for i = 1, 10 do | |
1985 | Swait() | |
1986 | MESH.Scale = MESH.Scale + VT(0.1,0,0.1) | |
1987 | end | |
1988 | repeat | |
1989 | Swait() | |
1990 | TORS.CFrame = TORS.CFrame * CF(0,-0.1,0) | |
1991 | until TORS.Position.Y<position.Y-4 | |
1992 | v:remove() | |
1993 | for i = 1, 10 do | |
1994 | Swait() | |
1995 | MESH.Scale = MESH.Scale - VT(0.1,0,0.1) | |
1996 | end | |
1997 | Hole2:remove() | |
1998 | end | |
1999 | end)) | |
2000 | end | |
2001 | end | |
2002 | end | |
2003 | end | |
2004 | --body[part].Velocity = CFrame.new(position,body[part].Position).lookVector*5*maxstrength | |
2005 | end | |
2006 | end | |
2007 | end | |
2008 | end | |
2009 | end | |
2010 | end | |
2011 | function ApplyDamage(Humanoid, Damage, TorsoPart) | |
2012 | local defence = Instance.new("BoolValue", Humanoid.Parent) | |
2013 | defence.Name = "HitBy" .. Player.Name | |
2014 | game:GetService("Debris"):AddItem(defence, 0.001) | |
2015 | Damage = Damage * DAMAGEMULTIPLIER | |
2016 | if Humanoid.Health ~= 0 then | |
2017 | local CritChance = MRANDOM(1, 100) | |
2018 | if Damage > Humanoid.Health then | |
2019 | Damage = math.ceil(Humanoid.Health) | |
2020 | if Damage == 0 then | |
2021 | Damage = 0.1 | |
2022 | end | |
2023 | end | |
2024 | Humanoid.Health = Humanoid.Health - Damage | |
2025 | StatLabel(TorsoPart.CFrame * CF(0, 0 + (TorsoPart.Size.z - 1), 0), Damage, C3(0, 0, 0)) | |
2026 | end | |
2027 | end | |
2028 | function ApplyAoE(POSITION, RANGE, MINDMG, MAXDMG, FLING, INSTAKILL) | |
2029 | local CHILDREN = workspace:GetDescendants() | |
2030 | for index, CHILD in pairs(CHILDREN) do | |
2031 | if CHILD.ClassName == "Model" and CHILD ~= Character then | |
2032 | local HUM = CHILD:FindFirstChildOfClass("Humanoid") | |
2033 | if HUM then | |
2034 | local TORSO = CHILD:FindFirstChild("Torso") or CHILD:FindFirstChild("UpperTorso") | |
2035 | if TORSO and RANGE >= (TORSO.Position - POSITION).Magnitude then | |
2036 | if INSTAKILL == true then | |
2037 | Petrify(CHILD) | |
2038 | else | |
2039 | local DMG = MRANDOM(MINDMG, MAXDMG) | |
2040 | ApplyDamage(HUM, DMG, TORSO) | |
2041 | end | |
2042 | if FLING > 0 then | |
2043 | for _, c in pairs(CHILD:GetChildren()) do | |
2044 | if c:IsA("BasePart") then | |
2045 | local bv = Instance.new("BodyVelocity") | |
2046 | bv.maxForce = Vector3.new(1000000000, 1000000000, 1000000000) | |
2047 | bv.velocity = CF(POSITION, TORSO.Position).lookVector * FLING | |
2048 | bv.Parent = c | |
2049 | Debris:AddItem(bv, 0.05) | |
2050 | end | |
2051 | end | |
2052 | end | |
2053 | end | |
2054 | end | |
2055 | end | |
2056 | end | |
2057 | end | |
2058 | function newBezier(startpos, pos2, pos3, endpos, t) | |
2059 | local A = clerp(startpos, pos2, t) | |
2060 | local B = clerp(pos2, pos3, t) | |
2061 | local C = clerp(pos3, endpos, t) | |
2062 | local lerp1 = clerp(A, B, t) | |
2063 | local lerp2 = clerp(B, C, t) | |
2064 | local cubic = clerp(lerp1, lerp2, t) | |
2065 | return cubic | |
2066 | end | |
2067 | ||
2068 | function SoulSteal(Target,SOUL) | |
2069 | local newball = Instance.new("Part", workspace) | |
2070 | newball.Anchored = true | |
2071 | newball.Shape = "Ball" | |
2072 | newball.Material = "Neon" | |
2073 | newball.Size = Vector3.new(0,0,0) | |
2074 | newball.CanCollide = false | |
2075 | newball.CFrame = CF(Target) | |
2076 | newball.BrickColor = BRICKC"Maroon" | |
2077 | newball.Transparency = 1 | |
2078 | local POS = SOUL.Position | |
2079 | local onefourth = Target:Lerp(POS, 0.25) + Vector3.new(math.random(-25, 25), math.random(0, 25), math.random(-25, 25)) | |
2080 | local threefourths = Target:Lerp(POS, 0.75) + Vector3.new(math.random(-25, 25), math.random(0, 25), math.random(-25, 25)) | |
2081 | local A1 = IT("Attachment",newball) | |
2082 | A1.Position = Vector3.new(0, 2.5, 0) | |
2083 | local A2 = IT("Attachment",newball) | |
2084 | A2.Position = Vector3.new(0, -2.5, 0) | |
2085 | local Trail = IT("Trail",newball) | |
2086 | Trail.LightEmission = 1 | |
2087 | Trail.FaceCamera = true | |
2088 | Trail.Texture = "rbxassetid://945758042" | |
2089 | Trail.Attachment0 = A1 | |
2090 | Trail.Attachment1 = A2 | |
2091 | Trail.Lifetime = 2 | |
2092 | Trail.MinLength = 0 | |
2093 | Trail.Transparency = NumberSequence.new(0, 1) | |
2094 | Trail.Color = ColorSequence.new(newball.Color) | |
2095 | coroutine.resume(coroutine.create(function() | |
2096 | for i = 0, 1, 0.07 do | |
2097 | Swait() | |
2098 | newball.CFrame = CFrame.new(newBezier(Target, onefourth, threefourths, POS, i)) | |
2099 | end | |
2100 | newball.Transparency = 1 | |
2101 | CreateSound("444667859", SOUL, 10, MRANDOM(8,12)/10) | |
2102 | SOUL.Size = SOUL.Size + VT(0.3,0.3,0.3) | |
2103 | game:GetService("Debris"):AddItem(newball, 5) | |
2104 | end)) | |
2105 | end | |
2106 | ||
2107 | function SpawnSoul(Humanoid) | |
2108 | coroutine.resume(coroutine.create(function() | |
2109 | local TORSO = Humanoid.Parent:FindFirstChild("Torso") or Humanoid.Parent:FindFirstChild("UpperTorso") | |
2110 | local SOULMODEL = IT("Model",Effects) | |
2111 | SOULMODEL.Name = Humanoid.Parent.Name.."'s Soul" | |
2112 | local SOUL = CreatePart(3, SOULMODEL, "Neon", 0, 0, "Really red", "Head", VT(0.5,0.5,0.5)) | |
2113 | SOUL.CFrame = CF(TORSO.Position) | |
2114 | local A1 = IT("Attachment",SOUL) | |
2115 | A1.Position = Vector3.new(0, 0.25, 0) | |
2116 | local A2 = IT("Attachment",SOUL) | |
2117 | A2.Position = Vector3.new(0, -0.25, 0) | |
2118 | local Trail = IT("Trail",SOUL) | |
2119 | Trail.LightEmission = 0.3 | |
2120 | Trail.FaceCamera = true | |
2121 | Trail.Texture = "rbxassetid://945758042" | |
2122 | Trail.Attachment0 = A1 | |
2123 | Trail.Attachment1 = A2 | |
2124 | Trail.Lifetime = 0.5 | |
2125 | Trail.MinLength = 0 | |
2126 | Trail.Transparency = NumberSequence.new(0) | |
2127 | Trail.Color = ColorSequence.new(SOUL.Color) | |
2128 | MakeForm(SOUL,"Ball") | |
2129 | local DISTANCE = nil | |
2130 | local HUM = IT("Humanoid",SOULMODEL) | |
2131 | repeat | |
2132 | Swait() | |
2133 | SOUL.CFrame = CF(SOUL.Position,Torso.Position)*CF(0,0,-0.2) | |
2134 | DISTANCE = (SOUL.Position - Torso.Position).Magnitude | |
2135 | until DISTANCE < 0.4 | |
2136 | WACKYEFFECT({EffectType = "Sphere", Size = VT(1,1,1), Size2 = VT(6,6,6), Transparency = 0, Transparency2 = 1, CFrame = Torso.CFrame, MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = C3(1,0,0), SoundID = "444667859", SoundPitch = 2, SoundVolume = 2}) | |
2137 | SOUL.Transparency = 1 | |
2138 | A1.Parent = Torso | |
2139 | A2.Parent = Torso | |
2140 | Trail.Parent = Torso | |
2141 | Debris:AddItem(SOULMODEL,10) | |
2142 | SOULWELL = SOULWELL + 1 | |
2143 | for i = 1, 100 do | |
2144 | Swait() | |
2145 | Trail.Transparency = NumberSequence.new(i/100) | |
2146 | end | |
2147 | A1:remove() | |
2148 | A2:remove() | |
2149 | Trail:remove() | |
2150 | end)) | |
2151 | end | |
2152 | function ApplyDmg(Humanoid,Damage,CritRate,CritMultiplier,DoesOneShot) | |
2153 | coroutine.resume(coroutine.create(function() | |
2154 | local defence = Instance.new("BoolValue",Humanoid.Parent) | |
2155 | defence.Name = ("HitBy"..Player.Name) | |
2156 | game:GetService("Debris"):AddItem(defence, 0.001) | |
2157 | Damage = Damage * DAMAGEMULTIPLIER | |
2158 | if Humanoid.Health ~= 0 then | |
2159 | local CritChance = MRANDOM(1,100) | |
2160 | if CritChance < CritRate + 1 then | |
2161 | Damage = Damage*CritMultiplier | |
2162 | end | |
2163 | if Damage > Humanoid.Health then | |
2164 | Damage = math.ceil(Humanoid.Health) | |
2165 | if Damage == 0 then | |
2166 | Damage = 0.1 | |
2167 | end | |
2168 | end | |
2169 | if DoesOneShot == false then | |
2170 | for _, c in pairs(Humanoid.Parent:GetChildren()) do | |
2171 | if c.Name ~= "HumanoidRootPart" and c.Name ~= "Torso" and c.Name ~= "Head" and c.Name ~= "UpperTorso" and c.Name ~= "LowerTorso" then | |
2172 | if c.ClassName == "Part" or c.ClassName == "MeshPart" then | |
2173 | if MRANDOM(1,20) == 1 then | |
2174 | Shatter(c) | |
2175 | end | |
2176 | end | |
2177 | end | |
2178 | end | |
2179 | Humanoid.Health = Humanoid.Health - Damage | |
2180 | if Humanoid.Parent:FindFirstChild("Head") then | |
2181 | CreateSound(HITPLAYERSOUNDS[MRANDOM(1,#HITPLAYERSOUNDS)], Humanoid.Parent.Head, 5, 1) | |
2182 | if CritChance < CritRate + 1 then | |
2183 | StatLabel(Humanoid.Parent.Head.CFrame * CF(0, 0 + (Humanoid.Parent.Head.Size.z - 1), 0), "CRIT//"..Damage, C3(1, 0, 0)) | |
2184 | else | |
2185 | StatLabel(Humanoid.Parent.Head.CFrame * CF(0, 0 + (Humanoid.Parent.Head.Size.z - 1), 0), Damage, C3(0, 0, 0)) | |
2186 | end | |
2187 | end | |
2188 | elseif DoesOneShot == true then | |
2189 | --print("["..Humanoid.Parent.Name.."]: One shot!? Really!?!?") | |
2190 | Humanoid.Parent:BreakJoints() | |
2191 | SpawnSoul(Humanoid) | |
2192 | if Humanoid.Parent:FindFirstChild("Head") then | |
2193 | StatLabel(Humanoid.Parent.Head.CFrame * CF(0, 0 + (Humanoid.Parent.Head.Size.z - 1), 0), "INF", C3(1, 0, 0)) | |
2194 | end | |
2195 | for _, c in pairs(Humanoid.Parent:GetChildren()) do | |
2196 | if c.ClassName == "Part" or c.ClassName == "MeshPart" then | |
2197 | Shatter(c) | |
2198 | end | |
2199 | end | |
2200 | end | |
2201 | if Humanoid.Health == 0 then | |
2202 | --print("["..Humanoid.Parent.Name.."]: It's like stepping on glass, but worse!") | |
2203 | SpawnSoul(Humanoid) | |
2204 | for _, c in pairs(Humanoid.Parent:GetChildren()) do | |
2205 | if c.ClassName == "Part" or c.ClassName == "MeshPart" then | |
2206 | Shatter(c) | |
2207 | end | |
2208 | end | |
2209 | end | |
2210 | end | |
2211 | end)) | |
2212 | end | |
2213 | ||
2214 | function AoEDmg(position,radius,min,max,maxstrength,critrate,critmultiplier,BESERK) | |
2215 | local dmg = math.random(min,max) | |
2216 | for i,v in ipairs(workspace:GetChildren()) do | |
2217 | if v:FindFirstChild("HitBy"..Player.Name) == nil then | |
2218 | local body = v:GetChildren() | |
2219 | for part = 1, #body do | |
2220 | if(v:FindFirstChild("HitBy"..Player.Name) == nil and (body[part].ClassName == "Part" or body[part].ClassName == "MeshPart") and v ~= Character) then | |
2221 | if(body[part].Position - position).Magnitude < radius then | |
2222 | if v.ClassName == "Model" then | |
2223 | if v:FindFirstChildOfClass("Humanoid") then | |
2224 | ApplyDamage(v:FindFirstChildOfClass("Humanoid"),dmg,critrate,critmultiplier,BESERK) | |
2225 | local bv = Instance.new("BodyVelocity") | |
2226 | bv.maxForce = Vector3.new(1e9, 1e9, 1e9) | |
2227 | bv.velocity = CF(position,body[part].Position).lookVector*maxstrength | |
2228 | bv.Parent = body[part] | |
2229 | Debris:AddItem(bv,0.2) | |
2230 | end | |
2231 | end | |
2232 | end | |
2233 | end | |
2234 | end | |
2235 | end | |
2236 | if v:FindFirstChild("HitBy"..Player.Name) then | |
2237 | v:FindFirstChild("HitBy"..Player.Name):remove() | |
2238 | end | |
2239 | end | |
2240 | end | |
2241 | ||
2242 | function AoEStun(POS,RANGE,LAST) | |
2243 | for i,v in ipairs(workspace:GetChildren()) do | |
2244 | if v:FindFirstChild("StunnedBy"..Player.Name) == nil then | |
2245 | local body = v:GetChildren() | |
2246 | for part = 1, #body do | |
2247 | if(v:FindFirstChild("StunnedBy"..Player.Name) == nil and (body[part].ClassName == "Part" or body[part].ClassName == "MeshPart") and v ~= Character) then | |
2248 | if(body[part].Position - POS).Magnitude < RANGE then | |
2249 | if v.ClassName == "Model" then | |
2250 | if v:FindFirstChild("Humanoid") then | |
2251 | if v.Humanoid.Health ~= 0 then | |
2252 | Stun(v.Humanoid,LAST) | |
2253 | local defence = Instance.new("BoolValue",v) | |
2254 | defence.Name = ("StunnedBy"..Player.Name) | |
2255 | game:GetService("Debris"):AddItem(defence, 0.001) | |
2256 | end | |
2257 | end | |
2258 | end | |
2259 | end | |
2260 | end | |
2261 | end | |
2262 | end | |
2263 | end | |
2264 | end | |
2265 | ||
2266 | function Stun(HUMANOID,LAST) | |
2267 | HUMANOID.PlatformStand = true | |
2268 | local defence = Instance.new("BoolValue",HUMANOID.Parent) | |
2269 | defence.Name = ("StunnedBy"..Player.Name) | |
2270 | game:GetService("Debris"):AddItem(defence, LAST) | |
2271 | if HUMANOID.Parent:FindFirstChild("Head") then | |
2272 | StatLabel("Normal", HUMANOID.Parent.Head.CFrame * CF(0, 0 + (HUMANOID.Parent.Head.Size.z - 1), 0), "Stunned!", C3(0.3, 0.3, 0.3)) | |
2273 | end | |
2274 | coroutine.resume(coroutine.create(function() | |
2275 | Swait(LAST*100) | |
2276 | HUMANOID.PlatformStand = false | |
2277 | end)) | |
2278 | end | |
2279 | ||
2280 | function killnearest(position,range,maxstrength) | |
2281 | for i,v in ipairs(workspace:GetChildren()) do | |
2282 | local body = v:GetChildren() | |
2283 | for part = 1, #body do | |
2284 | if((body[part].ClassName == "Part" or body[part].ClassName == "MeshPart") and v ~= Character) then | |
2285 | if(body[part].Position - position).Magnitude < range then | |
2286 | if v.ClassName == "Model" then | |
2287 | v:BreakJoints() | |
2288 | end | |
2289 | --table.insert(Effects2,{body[part],"Disappear",0.02,2,2,2,2}) | |
2290 | body[part].Velocity = CFrame.new(position,body[part].Position).lookVector*5*maxstrength | |
2291 | end | |
2292 | end | |
2293 | end | |
2294 | if v.ClassName == "Part" then | |
2295 | if v.Anchored == false and (v.Position - position).Magnitude < range then | |
2296 | --table.insert(Effects2,{v,"Disappear",0.02,2,2,2,2}) | |
2297 | v.Velocity = CFrame.new(position,v.Position).lookVector*5*maxstrength | |
2298 | end | |
2299 | end | |
2300 | end | |
2301 | end | |
2302 | ||
2303 | function Fling(part,direction,speed) | |
2304 | part.Velocity = direction*speed | |
2305 | end | |
2306 | local HITPOS = nil | |
2307 | function GoToHell(position,radius) | |
2308 | for i,v in ipairs(workspace:GetChildren()) do | |
2309 | if v:FindFirstChild("Hit2By"..Player.Name) == nil then | |
2310 | local body = v:GetChildren() | |
2311 | for part = 1, #body do | |
2312 | if(v:FindFirstChild("Hit2By"..Player.Name) == nil and (body[part].ClassName == "Part" or body[part].ClassName == "MeshPart") and v ~= Character) then | |
2313 | if(body[part].Position - position).Magnitude < radius then | |
2314 | if v.ClassName == "Model" then | |
2315 | if v:FindFirstChild("Humanoid") then | |
2316 | local defence = Instance.new("BoolValue",v) | |
2317 | defence.Name = ("Hit2By"..Player.Name) | |
2318 | if v.Humanoid.Health ~= 0 then | |
2319 | local TORS = v:FindFirstChild("HumanoidRootPart") or v:FindFirstChild("Torso") or v:FindFirstChild("UpperTorso") | |
2320 | if TORS ~= nil then | |
2321 | local HITFLOOR2, HITPOS2 = Raycast(TORS.Position, (CF(TORS.Position, TORS.Position + VT(0, -1, 0))).lookVector, 5 * TORS.Size.Y/2, v) | |
2322 | coroutine.resume(coroutine.create(function() | |
2323 | if HITFLOOR2 ~= nil then | |
2324 | TORS.Anchored = true | |
2325 | local Hole2 = CreatePart(3, Effects, "Neon", 0, 0, "Really black", "Hole", VT(TORS.Size.X*4,0,TORS.Size.X*4)) | |
2326 | Hole2.Color = C3(1,0,0) | |
2327 | local MESH = MakeForm(Hole2,"Cyl") | |
2328 | MESH.Scale = VT(0,1,0) | |
2329 | Hole2.CFrame = CF(HITPOS2) | |
2330 | for i = 1, 10 do | |
2331 | Swait() | |
2332 | MESH.Scale = MESH.Scale + VT(0.1,0,0.1) | |
2333 | end | |
2334 | repeat | |
2335 | Swait() | |
2336 | TORS.CFrame = TORS.CFrame * CF(0,-0.1,0) | |
2337 | until TORS.Position.Y<position.Y-4 | |
2338 | v:remove() | |
2339 | for i = 1, 10 do | |
2340 | Swait() | |
2341 | MESH.Scale = MESH.Scale - VT(0.1,0,0.1) | |
2342 | end | |
2343 | Hole2:remove() | |
2344 | end | |
2345 | end)) | |
2346 | end | |
2347 | end | |
2348 | end | |
2349 | end | |
2350 | --body[part].Velocity = CFrame.new(position,body[part].Position).lookVector*5*maxstrength | |
2351 | end | |
2352 | end | |
2353 | end | |
2354 | end | |
2355 | end | |
2356 | end | |
2357 | local DECAL = IT("Decal") | |
2358 | function MakeRing() | |
2359 | local RING = CreatePart(3, Effects, "Neon", 0, 1, BRICKC("Pearl"), "MagicRing", VT(0, 0, 0), true) | |
2360 | local MSH = IT("BlockMesh", RING) | |
2361 | local TOP = DECAL:Clone() | |
2362 | local BOTTOM = DECAL:Clone() | |
2363 | TOP.Parent = RING | |
2364 | BOTTOM.Parent = RING | |
2365 | TOP.Face = "Top" | |
2366 | BOTTOM.Face = "Bottom" | |
2367 | TOP.Texture = "http://www.roblox.com/asset/?id=127817121" | |
2368 | BOTTOM.Texture = "http://www.roblox.com/asset/?id=127817121" | |
2369 | local function REMOVE() | |
2370 | coroutine.resume(coroutine.create(function() | |
2371 | local SIZE = MSH.Scale.X | |
2372 | for i = 1, 35 do | |
2373 | Swait() | |
2374 | MSH.Scale = MSH.Scale - VT(SIZE, 0, SIZE) / 60 | |
2375 | TOP.Transparency = TOP.Transparency + 0.02857142857142857 | |
2376 | BOTTOM.Transparency = BOTTOM.Transparency + 0.02857142857142857 | |
2377 | RING.CFrame = RING.CFrame * ANGLES(RAD(0), RAD(-5), RAD(0)) | |
2378 | end | |
2379 | RING:remove() | |
2380 | end)) | |
2381 | end | |
2382 | return RING, MSH, REMOVE | |
2383 | end | |
2384 | function SHAKECAM(POSITION, RANGE, INTENSITY, TIME) | |
2385 | local TORSO = Torso | |
2386 | local HUM = Humanoid | |
2387 | if TORSO and RANGE >= (TORSO.Position - POSITION).Magnitude then | |
2388 | coroutine.wrap(function() | |
2389 | VT = Vector3.new | |
2390 | MRANDOM = math.random | |
2391 | local A = TIME | |
2392 | local B = INTENSITY | |
2393 | local C = true | |
2394 | local HUMANOID = Humanoid | |
2395 | local TIMER = A or 35 | |
2396 | local SHAKE = B or 5 | |
2397 | local FADE = C or true | |
2398 | if HUMANOID then | |
2399 | local FADER = SHAKE / TIMER | |
2400 | for i = 1, TIMER do | |
2401 | wait() | |
2402 | HUMANOID.CameraOffset = VT(MRANDOM(-(SHAKE - FADER * i), SHAKE - FADER * i) / 10, MRANDOM(-(SHAKE - FADER * i), SHAKE - FADER * i) / 10, MRANDOM(-(SHAKE - FADER * i), SHAKE - FADER * i) / 10) | |
2403 | end | |
2404 | HUMANOID.CameraOffset = VT(0, 0, 0) | |
2405 | end | |
2406 | ||
2407 | end)() | |
2408 | end | |
2409 | end | |
2410 | function CreateSwirl(inair,size,doesrotate,rotatedirection,waitt,cframe,color) | |
2411 | local wave = CreatePart(3, Effects, "Neon", 0, 0.5, BRICKC(color), "Effect", VT(0,0,0)) | |
2412 | local mesh = IT("SpecialMesh",wave) | |
2413 | mesh.MeshType = "FileMesh" | |
2414 | mesh.MeshId = "http://www.roblox.com/asset/?id=1051557" | |
2415 | mesh.Scale = VT(size,size,size) | |
2416 | wave.CFrame = cframe | |
2417 | coroutine.resume(coroutine.create(function(PART) | |
2418 | for i = 1, waitt do | |
2419 | Swait() | |
2420 | mesh.Scale = mesh.Scale + VT(size/5,0,size/5) | |
2421 | if doesrotate == true then | |
2422 | wave.CFrame = wave.CFrame * CFrame.fromEulerAnglesXYZ(0, rotatedirection, 0) | |
2423 | end | |
2424 | wave.Transparency = wave.Transparency + (0.5/waitt) | |
2425 | if wave.Transparency > 0.99 then | |
2426 | wave:remove() | |
2427 | end | |
2428 | end | |
2429 | end)) | |
2430 | end | |
2431 | ||
2432 | function CreateTornado(inair,size,doesrotate,rotatedirection,waitt,cframe,color) | |
2433 | local wave = CreatePart(3, Effects, "Neon", 0, 0.5, BRICKC(color), "Effect", VT(0,0,0)) | |
2434 | local mesh = IT("SpecialMesh",wave) | |
2435 | mesh.MeshType = "FileMesh" | |
2436 | mesh.MeshId = "http://www.roblox.com/asset/?id=102638417" | |
2437 | mesh.Scale = VT(size,size,size) | |
2438 | wave.CFrame = cframe | |
2439 | coroutine.resume(coroutine.create(function(PART) | |
2440 | for i = 1, waitt do | |
2441 | Swait() | |
2442 | mesh.Scale = mesh.Scale + VT(size/5,0,size/5) | |
2443 | if doesrotate == true then | |
2444 | wave.CFrame = wave.CFrame * CFrame.fromEulerAnglesXYZ(0, rotatedirection, 0) | |
2445 | end | |
2446 | wave.Transparency = wave.Transparency + (0.5/waitt) | |
2447 | if wave.Transparency > 0.99 then | |
2448 | wave:remove() | |
2449 | end | |
2450 | end | |
2451 | end)) | |
2452 | end | |
2453 | function freezenearest(position, range) | |
2454 | for i, v in ipairs(workspace:GetChildren()) do | |
2455 | local body = v:GetChildren() | |
2456 | for part = 1, #body do | |
2457 | if (body[part].ClassName == "Part" or body[part].ClassName == "MeshPart") and v ~= Character and range > (body[part].Position - position).Magnitude and v.ClassName == "Model" and v:FindFirstChildOfClass("Humanoid") then | |
2458 | v:BreakJoints() | |
2459 | body[part].Material = "Ice" | |
2460 | body[part].BrickColor = BRICKC("Really red") | |
2461 | body[part].Anchored = true | |
2462 | end | |
2463 | end | |
2464 | end | |
2465 | end | |
2466 | local Decal = IT("Decal") | |
2467 | function MagicRing() | |
2468 | local O1 = CreatePart(3, Effects, "Neon", 0, 1, "Really red", "Warphole", VT(0, 0, 0)) | |
2469 | O1.CFrame = RootPart.CFrame * CF(0, 0, -3) * ANGLES(RAD(90), RAD(0), RAD(0)) | |
2470 | local decal = Decal:Clone() | |
2471 | decal.Parent = O1 | |
2472 | decal.Face = "Top" | |
2473 | decal.Texture = "http://www.roblox.com/asset/?id=391033580" | |
2474 | local decal2 = Decal:Clone() | |
2475 | decal2.Parent = O1 | |
2476 | decal2.Face = "Bottom" | |
2477 | decal2.Texture = "http://www.roblox.com/asset/?id=391033580" | |
2478 | return O1 | |
2479 | end | |
2480 | function BulletDetection(FROM,TO,BRUTAL) | |
2481 | local AIMHIT,AIMPOS,NORMAL = CastProperRay(FROM,TO,2000,Character) | |
2482 | coroutine.resume(coroutine.create(function() | |
2483 | if AIMHIT ~= nil then | |
2484 | if AIMHIT.Parent ~= Character then | |
2485 | if AIMHIT.Parent:FindFirstChildOfClass("Humanoid") or AIMHIT.Parent.Parent:FindFirstChildOfClass("Humanoid") then | |
2486 | if AIMHIT.Parent:FindFirstChildOfClass("Humanoid") then | |
2487 | if BRUTAL == true then | |
2488 | Kill(AIMHIT.Parent) | |
2489 | else | |
2490 | getbloody(AIMHIT,15) | |
2491 | AIMHIT.Parent:BreakJoints() | |
2492 | if AIMHIT.Name == "Head" then | |
2493 | AIMHIT.Name = "HEADSHOT" | |
2494 | AIMHIT:remove() | |
2495 | end | |
2496 | end | |
2497 | else | |
2498 | if BRUTAL == true then | |
2499 | Kill(AIMHIT.Parent.Parent) | |
2500 | else | |
2501 | AIMHIT.Parent.Parent:BreakJoints() | |
2502 | end | |
2503 | end | |
2504 | end | |
2505 | end | |
2506 | end | |
2507 | end)) | |
2508 | SpawnTrail(FROM,AIMPOS) | |
2509 | return AIMHIT,AIMPOS,NORMAL | |
2510 | end | |
2511 | ||
2512 | function Banish(Foe) | |
2513 | if Foe then | |
2514 | coroutine.resume(coroutine.create(function() | |
2515 | --if game.Players:FindFirstChild(Foe.Name) then | |
2516 | table.insert(TOBANISH,Foe.Name) | |
2517 | printbye(Foe.Name) | |
2518 | --end | |
2519 | Foe.Archivable = true | |
2520 | local CLONE = Foe:Clone() | |
2521 | Foe:Destroy() | |
2522 | CLONE.Parent = Effects | |
2523 | CLONE:BreakJoints() | |
2524 | local MATERIALS = {"Glass","Neon"} | |
2525 | for _, c in pairs(CLONE:GetDescendants()) do | |
2526 | if c:IsA("BasePart") then | |
2527 | if c.Name == "Torso" or c.Name == "UpperTorso" or c == CLONE.PrimaryPart then | |
2528 | CreateSound(340722848, c, 10, 1, false) | |
2529 | end | |
2530 | c.Anchored = true | |
2531 | c.Transparency = c.Transparency + 0.2 | |
2532 | c.Material = MATERIALS[MRANDOM(1,2)] | |
2533 | c.Color = C3(1,1,1) | |
2534 | if c.ClassName == "MeshPart" then | |
2535 | c.TextureID = "" | |
2536 | end | |
2537 | if c:FindFirstChildOfClass("SpecialMesh") then | |
2538 | c:FindFirstChildOfClass("SpecialMesh").TextureId = "" | |
2539 | end | |
2540 | if c:FindFirstChildOfClass("Decal") then | |
2541 | c:FindFirstChildOfClass("Decal"):remove() | |
2542 | end | |
2543 | c.Name = "Banished" | |
2544 | c.CanCollide = false | |
2545 | else | |
2546 | c:remove() | |
2547 | end | |
2548 | end | |
2549 | local A = false | |
2550 | for i = 1, 35 do | |
2551 | if A == false then | |
2552 | A = true | |
2553 | elseif A == true then | |
2554 | A = false | |
2555 | end | |
2556 | for _, c in pairs(CLONE:GetDescendants()) do | |
2557 | if c:IsA("BasePart") then | |
2558 | c.Anchored = true | |
2559 | c.Material = MATERIALS[MRANDOM(1,2)] | |
2560 | c.Transparency = c.Transparency + 0.8/35 | |
2561 | if A == false then | |
2562 | c.CFrame = c.CFrame*CF(MRANDOM(-45,45)/45,MRANDOM(-45,45)/45,MRANDOM(-45,45)/45) | |
2563 | elseif A == true then | |
2564 | c.CFrame = c.CFrame*CF(MRANDOM(-45,45)/45,MRANDOM(-45,45)/45,MRANDOM(-45,45)/45) | |
2565 | end | |
2566 | end | |
2567 | end | |
2568 | Swait() | |
2569 | end | |
2570 | CLONE:remove() | |
2571 | end)) | |
2572 | end | |
2573 | end | |
2574 | ||
2575 | function ApplyKill(POSITION,RANGE,BRUTAL) | |
2576 | local CHILDREN = workspace:GetDescendants() | |
2577 | for index, CHILD in pairs(CHILDREN) do | |
2578 | if CHILD.ClassName == "Model" and CHILD ~= Character then | |
2579 | local HUM = CHILD:FindFirstChildOfClass("Humanoid") | |
2580 | if HUM then | |
2581 | local TORSO = CHILD:FindFirstChild("Torso") or CHILD:FindFirstChild("UpperTorso") | |
2582 | if TORSO then | |
2583 | if (TORSO.Position - POSITION).Magnitude <= RANGE then | |
2584 | if BRUTAL == true then | |
2585 | Banish(CHILD) | |
2586 | else | |
2587 | CHILD:BreakJoints() | |
2588 | end | |
2589 | end | |
2590 | end | |
2591 | end | |
2592 | end | |
2593 | end | |
2594 | end | |
2595 | ||
2596 | function ApplyAoE(POSITION,RANGE,ISBANISH) | |
2597 | local CHILDREN = workspace:GetDescendants() | |
2598 | for index, CHILD in pairs(CHILDREN) do | |
2599 | if CHILD.ClassName == "Model" and CHILD ~= Character then | |
2600 | local HUM = CHILD:FindFirstChildOfClass("Humanoid") | |
2601 | if HUM then | |
2602 | local TORSO = CHILD:FindFirstChild("Torso") or CHILD:FindFirstChild("UpperTorso") | |
2603 | if TORSO then | |
2604 | if (TORSO.Position - POSITION).Magnitude <= RANGE then | |
2605 | if ISBANISH == true then | |
2606 | Banish(CHILD) | |
2607 | else | |
2608 | if ISBANISH == "Gravity" then | |
2609 | HUM.PlatformStand = true | |
2610 | if TORSO:FindFirstChild("V3BanishForce"..Player.Name) then | |
2611 | local grav = Instance.new("BodyPosition",TORSO) | |
2612 | grav.D = 15 | |
2613 | grav.P = 20000 | |
2614 | grav.maxForce = Vector3.new(math.huge,math.huge,math.huge) | |
2615 | grav.position = TORSO.Position | |
2616 | grav.Name = "V3BanishForce"..Player.Name | |
2617 | else | |
2618 | TORSO:FindFirstChild("V3BanishForce"..Player.Name).position = TORSO.Position+VT(0,0.3,0) | |
2619 | TORSO.RotVelocity = VT(MRANDOM(-25,25),MRANDOM(-25,25),MRANDOM(-25,25)) | |
2620 | end | |
2621 | else | |
2622 | HUM.PlatformStand = false | |
2623 | end | |
2624 | end | |
2625 | elseif ISBANISH == "Gravity" then | |
2626 | if TORSO:FindFirstChild("V3BanishForce"..Player.Name) then | |
2627 | TORSO:FindFirstChild("V3BanishForce"..Player.Name):remove() | |
2628 | HUM.PlatformStand = false | |
2629 | end | |
2630 | end | |
2631 | end | |
2632 | end | |
2633 | end | |
2634 | end | |
2635 | end | |
2636 | ||
2637 | ||
2638 | function Kill(Char) | |
2639 | local NewCharacter = IT("Model",Effects) | |
2640 | NewCharacter.Name = "Ow im ded ;-;" | |
2641 | for _, c in pairs(Char:GetDescendants()) do | |
2642 | if c:IsA("BasePart") and c.Transparency == 0 then | |
2643 | if c.Parent == Char then | |
2644 | getbloody(c,5) | |
2645 | end | |
2646 | c:BreakJoints() | |
2647 | c.Material = "Glass" | |
2648 | c.Color = C3(0.5,0,0) | |
2649 | c.CanCollide = true | |
2650 | c.Transparency = 0.3 | |
2651 | if c:FindFirstChildOfClass("SpecialMesh") then | |
2652 | c:FindFirstChildOfClass("SpecialMesh").TextureId = "" | |
2653 | end | |
2654 | if c.Name == "Head" then | |
2655 | c:ClearAllChildren() | |
2656 | c.Size = VT(c.Size.Y,c.Size.Y,c.Size.Y) | |
2657 | end | |
2658 | if c.ClassName == "MeshPart" then | |
2659 | c.TextureID = "" | |
2660 | end | |
2661 | if c:FindFirstChildOfClass("BodyPosition") then | |
2662 | c:FindFirstChildOfClass("BodyPosition"):remove() | |
2663 | end | |
2664 | if c:FindFirstChildOfClass("ParticleEmitter") then | |
2665 | c:FindFirstChildOfClass("ParticleEmitter"):remove() | |
2666 | end | |
2667 | c.Parent = NewCharacter | |
2668 | c.Name = "DeadPart" | |
2669 | c.Velocity = VT(MRANDOM(-45,45),MRANDOM(-45,45),MRANDOM(-45,45))/15 | |
2670 | c.RotVelocity = VT(MRANDOM(-45,45),MRANDOM(-15,85),MRANDOM(-45,45)) | |
2671 | end | |
2672 | end | |
2673 | Char:remove() | |
2674 | Debris:AddItem(NewCharacter,5) | |
2675 | end | |
2676 | function ApplyDamage(Humanoid,Damage,TorsoPart) | |
2677 | local defence = Instance.new("BoolValue",Humanoid.Parent) | |
2678 | defence.Name = ("HitBy"..Player.Name) | |
2679 | game:GetService("Debris"):AddItem(defence, 0.001) | |
2680 | Damage = Damage * DAMAGEMULTIPLIER | |
2681 | if Humanoid.Health ~= 0 then | |
2682 | local CritChance = MRANDOM(1,100) | |
2683 | if Damage > Humanoid.Health then | |
2684 | Damage = math.ceil(Humanoid.Health) | |
2685 | if Damage == 0 then | |
2686 | Damage = 0.1 | |
2687 | end | |
2688 | end | |
2689 | Humanoid.Health = Humanoid.Health - Damage*100 | |
2690 | end | |
2691 | end | |
2692 | function killnearest(position, range, maxstrength) | |
2693 | for i, v in ipairs(workspace:GetChildren()) do | |
2694 | local body = v:GetChildren() | |
2695 | for part = 1, #body do | |
2696 | if (body[part].ClassName == "Part" or body[part].ClassName == "MeshPart") and v ~= Character and range > (body[part].Position - position).Magnitude then | |
2697 | if v.ClassName == "Model" then | |
2698 | v:BreakJoints() | |
2699 | end | |
2700 | local bv = Instance.new("BodyVelocity") | |
2701 | bv.maxForce = Vector3.new(1000000000, 1000000000, 1000000000) | |
2702 | bv.velocity = CF(position, body[part].Position).lookVector * maxstrength | |
2703 | bv.Parent = body[part] | |
2704 | Debris:AddItem(bv, 0.2) | |
2705 | end | |
2706 | end | |
2707 | if v.ClassName == "Part" and v.Anchored == false and range > (v.Position - position).Magnitude then | |
2708 | v.Velocity = CFrame.new(position, v.Position).lookVector * 5 * maxstrength | |
2709 | end | |
2710 | end | |
2711 | end | |
2712 | ||
2713 | function CreateWave2(SIZE,WAIT,CFRAME,DOESROT,ROT,COLOR,GROW) | |
2714 | local wave = CreatePart(3, Effects, "Neon", 0, 0.5, BRICKC(COLOR), "Effect", VT(0,0,0)) | |
2715 | local mesh = IT("SpecialMesh",wave) | |
2716 | mesh.MeshType = "FileMesh" | |
2717 | mesh.MeshId = "http://www.roblox.com/asset/?id=20329976" | |
2718 | mesh.Scale = SIZE | |
2719 | mesh.Offset = VT(0,0,-SIZE.X/8) | |
2720 | wave.CFrame = CFRAME | |
2721 | coroutine.resume(coroutine.create(function(PART) | |
2722 | for i = 1, WAIT do | |
2723 | Swait() | |
2724 | mesh.Scale = mesh.Scale + GROW | |
2725 | mesh.Offset = VT(0,0,-(mesh.Scale.X/8)) | |
2726 | if DOESROT == true then | |
2727 | wave.CFrame = wave.CFrame * CFrame.fromEulerAnglesXYZ(0,ROT,0) | |
2728 | end | |
2729 | wave.Transparency = wave.Transparency + (0.5/WAIT) | |
2730 | if wave.Transparency > 0.99 then | |
2731 | wave:remove() | |
2732 | end | |
2733 | end | |
2734 | end)) | |
2735 | end | |
2736 | ||
2737 | function CreateRing2(SIZE,DOESROT,ROT,WAIT,CFRAME,COLOR,GROW) | |
2738 | local wave = CreatePart(3, Effects, "Neon", 0, 0.5, BRICKC(COLOR), "Effect", VT(0,0,0)) | |
2739 | local mesh = IT("SpecialMesh",wave) | |
2740 | mesh.MeshType = "FileMesh" | |
2741 | mesh.MeshId = "http://www.roblox.com/asset/?id=3270017" | |
2742 | mesh.Scale = SIZE | |
2743 | mesh.Offset = VT(0,0,0) | |
2744 | wave.CFrame = CFRAME | |
2745 | coroutine.resume(coroutine.create(function(PART) | |
2746 | for i = 1, WAIT do | |
2747 | Swait() | |
2748 | mesh.Scale = mesh.Scale + GROW | |
2749 | if DOESROT == true then | |
2750 | wave.CFrame = wave.CFrame * CFrame.fromEulerAnglesXYZ(0,ROT,0) | |
2751 | end | |
2752 | wave.Transparency = wave.Transparency + (0.5/WAIT) | |
2753 | if wave.Transparency > 0.99 then | |
2754 | wave:remove() | |
2755 | end | |
2756 | end | |
2757 | end)) | |
2758 | end | |
2759 | ||
2760 | function MagicSphere3(SIZE,WAIT,CFRAME,COLOR,GROW) | |
2761 | local wave = CreatePart(3, Effects, "Neon", 0, 0, BRICKC(COLOR), "Effect", VT(1,1,1), true) | |
2762 | local mesh = IT("SpecialMesh",wave) | |
2763 | mesh.MeshType = "Sphere" | |
2764 | mesh.Scale = SIZE | |
2765 | mesh.Offset = VT(0,0,0) | |
2766 | wave.CFrame = CFRAME | |
2767 | coroutine.resume(coroutine.create(function(PART) | |
2768 | for i = 1, WAIT do | |
2769 | Swait() | |
2770 | mesh.Scale = mesh.Scale + GROW | |
2771 | wave.Transparency = wave.Transparency + (1/WAIT) | |
2772 | if wave.Transparency > 0.99 then | |
2773 | wave:remove() | |
2774 | end | |
2775 | end | |
2776 | end)) | |
2777 | end | |
2778 | ||
2779 | ||
2780 | function CreateRing(inair,size,doesrotate,rotatedirection,waitt,cframe,spin1,spin2,color) | |
2781 | local wave = CreatePart(3, Effects, "Neon", 0, 0.5, BRICKC(color), "Effect", VT(0,0,0)) | |
2782 | local mesh = IT("SpecialMesh",wave) | |
2783 | mesh.MeshType = "FileMesh" | |
2784 | mesh.MeshId = "http://www.roblox.com/asset/?id=3270017" | |
2785 | mesh.Scale = VT(size,size,size) | |
2786 | mesh.Offset = VT(0,0,0) | |
2787 | wave.CFrame = cframe | |
2788 | coroutine.resume(coroutine.create(function(PART) | |
2789 | for i = 1, waitt do | |
2790 | Swait() | |
2791 | mesh.Scale = mesh.Scale + VT(size/5,size/5,size/5) | |
2792 | if doesrotate == true then | |
2793 | wave.CFrame = wave.CFrame * CFrame.fromEulerAnglesXYZ(spin2, rotatedirection, spin1) | |
2794 | end | |
2795 | wave.Transparency = wave.Transparency + (0.5/waitt) | |
2796 | if wave.Transparency > 0.99 then | |
2797 | wave:remove() | |
2798 | end | |
2799 | end | |
2800 | end)) | |
2801 | end | |
2802 | ||
2803 | function MagicSphere(size,waitt,cframe,color) | |
2804 | local wave = CreatePart(3, Effects, "Neon", 0, 0, BRICKC(color), "Effect", VT(1,1,1)) | |
2805 | local mesh = IT("SpecialMesh",wave) | |
2806 | mesh.MeshType = "Sphere" | |
2807 | mesh.Scale = VT(size,size,size) | |
2808 | mesh.Offset = VT(0,0,0) | |
2809 | wave.CFrame = cframe | |
2810 | coroutine.resume(coroutine.create(function(PART) | |
2811 | for i = 1, waitt do | |
2812 | Swait() | |
2813 | mesh.Scale = mesh.Scale + VT(size/5,size/5,size/5) | |
2814 | wave.Transparency = wave.Transparency + (1/waitt) | |
2815 | if wave.Transparency > 0.99 then | |
2816 | wave:remove() | |
2817 | end | |
2818 | end | |
2819 | end)) | |
2820 | end | |
2821 | ||
2822 | function MagicSphere2(size,waitt,cframe,color) | |
2823 | local wave = CreatePart(3, Effects, "Neon", 0, 1, BRICKC(color), "Effect", VT(1,1,1)) | |
2824 | local mesh = IT("SpecialMesh",wave) | |
2825 | mesh.MeshType = "Sphere" | |
2826 | mesh.Scale = VT(size,size,size) | |
2827 | mesh.Offset = VT(0,0,0) | |
2828 | wave.CFrame = cframe | |
2829 | coroutine.resume(coroutine.create(function(PART) | |
2830 | for i = 1, waitt do | |
2831 | Swait() | |
2832 | mesh.Scale = mesh.Scale - VT(size/waitt,size/waitt,size/waitt) | |
2833 | wave.Transparency = wave.Transparency - (1/waitt) | |
2834 | end | |
2835 | wave:remove() | |
2836 | end)) | |
2837 | end | |
2838 | ||
2839 | function BreakEffect(brickcolor,cframe,x1,y1,z1,material) | |
2840 | local prt=part("Custom",workspace,material,0,0,brickcolor,"Effect",VT(0.5,0.5,0.5)) | |
2841 | prt.Anchored=true | |
2842 | prt.CFrame=cframe*EULER(math.random(-50,50),math.random(-50,50),math.random(-50,50)) | |
2843 | local msh=mesh("SpecialMesh",prt,"Sphere","",VT(0,0,0),VT(x1,y1,z1)) | |
2844 | coroutine.resume(coroutine.create(function(Part,CF,Numbb,randnumb) | |
2845 | CF=Part.CFrame | |
2846 | Numbb=0 | |
2847 | randnumb=math.random()-math.random() | |
2848 | for i=0,1,0.05 do | |
2849 | wait() | |
2850 | CF=CF*CF(0,1,0) | |
2851 | --Part.CFrame=Part.CFrame*euler(0.5,0,0)*cf(0,1,0) | |
2852 | Part.CFrame=CF*EULER(Numbb,0,0) | |
2853 | Part.Transparency=i | |
2854 | Numbb=Numbb+randnumb | |
2855 | end | |
2856 | Part.Parent=nil | |
2857 | end),prt) | |
2858 | end | |
2859 | ||
2860 | function MagicBlock(size,waitt,cframe,color) | |
2861 | local wave = CreatePart(3, Effects, "Neon", 0, 0, BRICKC(color), "Effect", VT(size,size,size)) | |
2862 | local mesh = IT("BlockMesh",wave) | |
2863 | wave.CFrame = cframe | |
2864 | coroutine.resume(coroutine.create(function(PART) | |
2865 | for i = 1, waitt do | |
2866 | Swait() | |
2867 | mesh.Scale = mesh.Scale + VT(size/5,size/5,size/5) | |
2868 | wave.CFrame = cframe * ANGLES(RAD(math.random(-360,360)),RAD(math.random(-360,360)),RAD(math.random(-360,360))) | |
2869 | wave.Transparency = wave.Transparency + (1/waitt) | |
2870 | if wave.Transparency > 0.99 then | |
2871 | wave:remove() | |
2872 | end | |
2873 | end | |
2874 | end)) | |
2875 | end | |
2876 | function ApplyAoE(POSITION,RANGE,FLING,BURN) | |
2877 | local CHILDREN = workspace:GetDescendants() | |
2878 | for index, CHILD in pairs(CHILDREN) do | |
2879 | if CHILD.ClassName == "Model" and CHILD ~= Character then | |
2880 | local HUM = CHILD:FindFirstChildOfClass("Humanoid") | |
2881 | if HUM then | |
2882 | local TORSO = CHILD:FindFirstChild("Torso") or CHILD:FindFirstChild("UpperTorso") | |
2883 | if TORSO then | |
2884 | if HUM.Health > 0 and (TORSO.Position - POSITION).Magnitude <= RANGE then | |
2885 | CHILD:BreakJoints() | |
2886 | if FLING ~= 0 then | |
2887 | for _, c in pairs(CHILD:GetChildren()) do | |
2888 | if c:IsA("BasePart") and c.Transparency == 0 then | |
2889 | if BURN == true then | |
2890 | Fire(c) | |
2891 | end | |
2892 | local bv = Instance.new("BodyVelocity") | |
2893 | bv.maxForce = Vector3.new(1e9, 1e9, 1e9) | |
2894 | bv.velocity = CF(POSITION,TORSO.Position).lookVector*FLING | |
2895 | bv.Parent = c | |
2896 | Debris:AddItem(bv,0.05) | |
2897 | end | |
2898 | end | |
2899 | end | |
2900 | end | |
2901 | end | |
2902 | end | |
2903 | end | |
2904 | end | |
2905 | end | |
2906 | ||
2907 | function SpawnMeteor(POS,SIZE,ISDEBREE,ORIPOS) | |
2908 | coroutine.resume(coroutine.create(function() | |
2909 | local METEOR = IT("Model",Effects) | |
2910 | METEOR.Name = "Meteorite" | |
2911 | local CENTER = CreatePart(3, METEOR, "Granite", 0, 0, "Really black", "MeteorCenter", VT(5,5,5)*SIZE) | |
2912 | METEOR.PrimaryPart = CENTER | |
2913 | local PRT = CreatePart(3, METEOR, "Granite", 0, 0, "Really black", "MeteorCenter", VT(5,5,5)*SIZE) | |
2914 | PRT.CFrame = CENTER.CFrame*ANGLES(RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360))) | |
2915 | for i = 1, 15 do | |
2916 | local FIRE = CreatePart(3, METEOR, "Neon", 0, 0, "Really black", "Fire", VT(5.1,1,5.1)*SIZE) | |
2917 | FIRE.CFrame = CENTER.CFrame*ANGLES(RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360))) | |
2918 | end | |
2919 | if ISDEBREE ~= true then | |
2920 | METEOR:SetPrimaryPartCFrame(CF(POS) * ANGLES(RAD(MRANDOM(-15,15)), RAD(0), RAD(MRANDOM(-15,15)))*CF(0,500,0) * ANGLES(RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)))) | |
2921 | else | |
2922 | METEOR:SetPrimaryPartCFrame(CF(ORIPOS,POS) * ANGLES(RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)))) | |
2923 | end | |
2924 | local IMPACT = false | |
2925 | CreateSound(463593339, CENTER, 10, 0.6) | |
2926 | if SIZE >= 3.5 then | |
2927 | for i = 1, MRANDOM(3,7) do | |
2928 | SpawnMeteor(CF(POS) * ANGLES(RAD(0), RAD(MRANDOM(0,360)), RAD(0))*CF(0,0,SIZE*12).p,SIZE/MRANDOM(4,5),true,CENTER.CFrame*ANGLES(RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)))*CF(0,0,SIZE*15).p) | |
2929 | end | |
2930 | end | |
2931 | for i = 1, 200 do | |
2932 | Swait() | |
2933 | local HITFLOOR,HITPOS = Raycast(CENTER.Position, CF(CENTER.Position,POS).lookVector, 3, Character) | |
2934 | if HITFLOOR == nil then | |
2935 | local ORI = CENTER.Orientation | |
2936 | METEOR:SetPrimaryPartCFrame(CF(HITPOS) * ANGLES(RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)))) | |
2937 | else | |
2938 | if HITFLOOR.Anchored == true then | |
2939 | CreateDebreeRing(HITFLOOR,HITPOS,30*SIZE,VT(6,6,6)*SIZE,5) | |
2940 | CreateFlyingDebree(HITFLOOR,CF(HITPOS),8,VT(4,4,4)*SIZE,5,175) | |
2941 | end | |
2942 | IMPACT = true | |
2943 | break | |
2944 | end | |
2945 | end | |
2946 | if IMPACT == true then | |
2947 | WACKYEFFECT({EffectType = "Block", Size = CENTER.Size, Size2 = VT(10,10,10)*4*SIZE, Transparency = 0, Transparency2 = 1, CFrame = CF(CENTER.Position), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = C3(0,0,0), SoundID = 130972023, SoundPitch = 1, SoundVolume = 5}) | |
2948 | WACKYEFFECT({EffectType = "Block", Size = CENTER.Size, Size2 = VT(10,10,10)*3*SIZE, Transparency = 0, Transparency2 = 1, CFrame = CF(CENTER.Position), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = C3(0,0,0), SoundID = 201858144, SoundPitch = 1, SoundVolume = 5}) | |
2949 | WACKYEFFECT({EffectType = "Sphere", Size = VT(SIZE*20,0,SIZE*20), Size2 = VT(0,SIZE*750,0), Transparency = 0, Transparency2 = 1, CFrame = CF(CENTER.Position), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = C3(0,0,0), SoundID = 130972023, SoundPitch = 1, SoundVolume = 5}) | |
2950 | ApplyAoE(CENTER.Position,30*SIZE) | |
2951 | ||
2952 | end | |
2953 | METEOR:remove() | |
2954 | end)) | |
2955 | end | |
2956 | ||
2957 | function KillChildren(Char) | |
2958 | local NewCharacter = IT("Model",Effects) | |
2959 | NewCharacter.Name = "Ow im ded ;-;" | |
2960 | for _, c in pairs(Char:GetDescendants()) do | |
2961 | if c:IsA("BasePart") and c.Transparency == 0 then | |
2962 | if c.Parent == Char then | |
2963 | getbloody(c,5) | |
2964 | end | |
2965 | c:BreakJoints() | |
2966 | c.Material = "Glass" | |
2967 | c.Color = C3(0.5,0,0) | |
2968 | c.CanCollide = true | |
2969 | c.Transparency = 0.3 | |
2970 | if c:FindFirstChildOfClass("SpecialMesh") then | |
2971 | c:FindFirstChildOfClass("SpecialMesh").TextureId = "" | |
2972 | end | |
2973 | if c.Name == "Head" then | |
2974 | c:ClearAllChildren() | |
2975 | c.Size = VT(c.Size.Y,c.Size.Y,c.Size.Y) | |
2976 | end | |
2977 | if c.ClassName == "MeshPart" then | |
2978 | c.TextureID = "" | |
2979 | end | |
2980 | if c:FindFirstChildOfClass("BodyPosition") then | |
2981 | c:FindFirstChildOfClass("BodyPosition"):remove() | |
2982 | end | |
2983 | if c:FindFirstChildOfClass("ParticleEmitter") then | |
2984 | c:FindFirstChildOfClass("ParticleEmitter"):remove() | |
2985 | end | |
2986 | c.Parent = NewCharacter | |
2987 | c.Name = "DeadPart" | |
2988 | c.Velocity = VT(MRANDOM(-45,45),MRANDOM(-45,45),MRANDOM(-45,45))/15 | |
2989 | c.RotVelocity = VT(MRANDOM(-45,45),MRANDOM(-15,85),MRANDOM(-45,45)) | |
2990 | end | |
2991 | end | |
2992 | Char:remove() | |
2993 | Debris:AddItem(NewCharacter,5) | |
2994 | end | |
2995 | ||
2996 | function Kill(Char) | |
2997 | local NewCharacter = IT("Model",Effects) | |
2998 | NewCharacter.Name = "Ow im ded ;-;" | |
2999 | for _, c in pairs(Char:GetDescendants()) do | |
3000 | if c:IsA("BasePart") and c.Transparency == 0 then | |
3001 | if c.Parent == Char then | |
3002 | getbloody(c,5) | |
3003 | end | |
3004 | c:BreakJoints() | |
3005 | c.Material = "Glass" | |
3006 | c.Color = C3(0.5,0,0) | |
3007 | c.CanCollide = true | |
3008 | c.Transparency = 0.3 | |
3009 | if c:FindFirstChildOfClass("SpecialMesh") then | |
3010 | c:FindFirstChildOfClass("SpecialMesh").TextureId = "" | |
3011 | end | |
3012 | if c.Name == "Head" then | |
3013 | c:ClearAllChildren() | |
3014 | c.Size = VT(c.Size.Y,c.Size.Y,c.Size.Y) | |
3015 | end | |
3016 | if c.ClassName == "MeshPart" then | |
3017 | c.TextureID = "" | |
3018 | end | |
3019 | if c:FindFirstChildOfClass("BodyPosition") then | |
3020 | c:FindFirstChildOfClass("BodyPosition"):remove() | |
3021 | end | |
3022 | if c:FindFirstChildOfClass("ParticleEmitter") then | |
3023 | c:FindFirstChildOfClass("ParticleEmitter"):remove() | |
3024 | end | |
3025 | c.Parent = NewCharacter | |
3026 | c.Name = "DeadPart" | |
3027 | c.Velocity = VT(MRANDOM(-45,45),MRANDOM(-45,45),MRANDOM(-45,45))/15 | |
3028 | c.RotVelocity = VT(MRANDOM(-45,45),MRANDOM(-15,85),MRANDOM(-45,45)) | |
3029 | end | |
3030 | end | |
3031 | Char:remove() | |
3032 | Debris:AddItem(NewCharacter,5) | |
3033 | end | |
3034 | ||
3035 | function ApplyAoE(POSITION,RANGE,BRUTAL) | |
3036 | local CHILDREN = workspace:GetDescendants() | |
3037 | for index, CHILD in pairs(CHILDREN) do | |
3038 | if CHILD.ClassName == "Model" and CHILD ~= Character then | |
3039 | local HUM = CHILD:FindFirstChildOfClass("Humanoid") | |
3040 | if HUM then | |
3041 | local TORSO = CHILD:FindFirstChild("Torso") or CHILD:FindFirstChild("UpperTorso") | |
3042 | if TORSO then | |
3043 | if (TORSO.Position - POSITION).Magnitude <= RANGE then | |
3044 | if BRUTAL == true then | |
3045 | Kill(CHILD) | |
3046 | else | |
3047 | CHILD:BreakJoints() | |
3048 | end | |
3049 | end | |
3050 | end | |
3051 | end | |
3052 | end | |
3053 | end | |
3054 | end | |
3055 | function AoEDamage(position,radius,min,max,maxstrength,beserk,critrate,critmultiplier,CanBeDodgedByJumping,doespoison) | |
3056 | local dmg = math.random(min,max) | |
3057 | for i,v in ipairs(workspace:GetChildren()) do | |
3058 | if v:FindFirstChild("HitBy"..Player.Name) == nil and v ~= Character then | |
3059 | local body = v:GetChildren() | |
3060 | for part = 1, #body do | |
3061 | if(v:FindFirstChild("HitBy"..Player.Name) == nil and (body[part].ClassName == "Part" or body[part].ClassName == "MeshPart") and v ~= Character) then | |
3062 | if(body[part].Position - position).Magnitude < radius then | |
3063 | if v.ClassName == "Model" then | |
3064 | if v:FindFirstChildOfClass("Humanoid") then | |
3065 | if v.Humanoid.Health ~= 0 then | |
3066 | if CanBeDodgedByJumping == true then | |
3067 | if body[part].Position.Y < position.Y+5 then | |
3068 | if math.random(1,100) < critrate+1 then | |
3069 | v:FindFirstChildOfClass("Humanoid").Health = v:FindFirstChildOfClass("Humanoid").Health - dmg*critmultiplier | |
3070 | StatLabel("Normal", body[part].CFrame * CF(0, 0 + (body[part].Size.z - 1), 0), "CRIT/"..dmg*critmultiplier, C3(255/255, 0, 0)) | |
3071 | else | |
3072 | v:FindFirstChildOfClass("Humanoid").Health = v:FindFirstChildOfClass("Humanoid").Health - dmg | |
3073 | StatLabel("Normal", body[part].CFrame * CF(0, 0 + (body[part].Size.z - 1), 0), dmg, C3(0, 0, 0)) | |
3074 | end | |
3075 | local defence = Instance.new("BoolValue",v) | |
3076 | defence.Name = ("HitBy"..Player.Name) | |
3077 | game:GetService("Debris"):AddItem(defence, 0.005) | |
3078 | end | |
3079 | else | |
3080 | if beserk == true then | |
3081 | v.Humanoid.Health = 0 | |
3082 | end | |
3083 | if math.random(1,100) < critrate+1 then | |
3084 | v:FindFirstChildOfClass("Humanoid").Health = v:FindFirstChildOfClass("Humanoid").Health - dmg*critmultiplier | |
3085 | StatLabel("Normal", body[part].CFrame * CF(0, 0 + (body[part].Size.z - 1), 0), "CRIT/"..dmg*critmultiplier, C3(255/255, 0, 0)) | |
3086 | else | |
3087 | v:FindFirstChildOfClass("Humanoid").Health = v:FindFirstChildOfClass("Humanoid").Health - dmg | |
3088 | StatLabel("Normal", body[part].CFrame * CF(0, 0 + (body[part].Size.z - 1), 0), dmg, C3(0, 0, 0)) | |
3089 | end | |
3090 | local defence = Instance.new("BoolValue",v) | |
3091 | defence.Name = ("HitBy"..Player.Name) | |
3092 | game:GetService("Debris"):AddItem(defence, 0.005) | |
3093 | end | |
3094 | end | |
3095 | end | |
3096 | end | |
3097 | if doespoison == true and v:FindFirstChildOfClass("Humanoid") then | |
3098 | Poison(v:FindFirstChildOfClass("Humanoid"),MRANDOM(5,15)*2,MRANDOM(4,7)) | |
3099 | end | |
3100 | if maxstrength < 0 then | |
3101 | local bv = Instance.new("BodyVelocity") | |
3102 | bv.maxForce = Vector3.new(1e9, 1e9, 1e9) | |
3103 | bv.velocity = CF(position,body[part].Position).lookVector*maxstrength | |
3104 | bv.Parent = body[part] | |
3105 | bv.Name = "PROJECTILEVELOCITY" | |
3106 | Debris:AddItem(bv,0.2) | |
3107 | else | |
3108 | body[part].Velocity = CFrame.new(position,body[part].Position).lookVector*5*maxstrength | |
3109 | end | |
3110 | end | |
3111 | end | |
3112 | end | |
3113 | end | |
3114 | end | |
3115 | end | |
3116 | function StatLabel(LABELTYPE, CFRAME, TEXT, COLOR) | |
3117 | local STATPART = CreatePart(3, Effects, "SmoothPlastic", 0, 1, "Really black", "Effect", VT()) | |
3118 | STATPART.CFrame = CF(CFRAME.p + VT(0, 1.5, 0)) | |
3119 | local BODYGYRO = IT("BodyGyro", STATPART) | |
3120 | local BODYPOSITION = IT("BodyPosition", STATPART) | |
3121 | BODYPOSITION.P = 2000 | |
3122 | BODYPOSITION.D = 100 | |
3123 | BODYPOSITION.maxForce = VT(math.huge, math.huge, math.huge) | |
3124 | BODYPOSITION.position = STATPART.Position + VT(MRANDOM(-2, 2), 6, MRANDOM(-2, 2)) | |
3125 | game:GetService("Debris"):AddItem(STATPART ,5) | |
3126 | local BILLBOARDGUI = Instance.new("BillboardGui", STATPART) | |
3127 | BILLBOARDGUI.Adornee = STATPART | |
3128 | BILLBOARDGUI.Size = UD2(2.5, 0, 2.5 ,0) | |
3129 | BILLBOARDGUI.StudsOffset = VT(-2, 2, 0) | |
3130 | BILLBOARDGUI.AlwaysOnTop = false | |
3131 | local TEXTLABEL = Instance.new("TextLabel", BILLBOARDGUI) | |
3132 | TEXTLABEL.BackgroundTransparency = 1 | |
3133 | TEXTLABEL.Size = UD2(2.5, 0, 2.5, 0) | |
3134 | TEXTLABEL.Text = TEXT | |
3135 | TEXTLABEL.Font = "SciFi" | |
3136 | TEXTLABEL.FontSize="Size42" | |
3137 | TEXTLABEL.TextColor3 = COLOR | |
3138 | TEXTLABEL.TextStrokeTransparency = 1 | |
3139 | TEXTLABEL.TextScaled = true | |
3140 | TEXTLABEL.TextWrapped = true | |
3141 | coroutine.resume(coroutine.create(function(THEPART, THEBODYPOSITION, THETEXTLABEL) | |
3142 | if LABELTYPE == "Normal" then | |
3143 | for i = 1, 30 do | |
3144 | Swait() | |
3145 | STATPART.Position = STATPART.Position + VT(0, (15-i)/10 ,0) | |
3146 | TEXTLABEL.TextTransparency = TEXTLABEL.TextTransparency + (1/30) | |
3147 | end | |
3148 | elseif LABELTYPE == "Debuff" then | |
3149 | for i = 1, 30 do | |
3150 | Swait() | |
3151 | STATPART.Position = STATPART.Position - VT(0, i/10 ,0) | |
3152 | TEXTLABEL.TextTransparency = TEXTLABEL.TextTransparency + (1/30) | |
3153 | end | |
3154 | elseif LABELTYPE == "Shock" then | |
3155 | local ORIGIN = STATPART.Position | |
3156 | for i = 1, 30 do | |
3157 | Swait() | |
3158 | STATPART.Position = ORIGIN + VT(MRANDOM(-2,2),MRANDOM(-2,2),MRANDOM(-2,2)) | |
3159 | TEXTLABEL.TextTransparency = TEXTLABEL.TextTransparency + (1/30) | |
3160 | end | |
3161 | end | |
3162 | THEPART.Parent = nil | |
3163 | end),STATPART, BODYPOSITION, TEXTLABEL) | |
3164 | end | |
3165 | function AoEStun(POS,RANGE,LAST) | |
3166 | for i,v in ipairs(workspace:GetChildren()) do | |
3167 | if v:FindFirstChild("StunnedBy"..Player.Name) == nil then | |
3168 | local body = v:GetChildren() | |
3169 | for part = 1, #body do | |
3170 | if(v:FindFirstChild("StunnedBy"..Player.Name) == nil and (body[part].ClassName == "Part" or body[part].ClassName == "MeshPart") and v ~= Character) then | |
3171 | if(body[part].Position - POS).Magnitude < RANGE then | |
3172 | if v.ClassName == "Model" then | |
3173 | if v:FindFirstChild("Humanoid") then | |
3174 | if v.Humanoid.Health ~= 0 then | |
3175 | Stun(v.Humanoid,LAST) | |
3176 | local defence = Instance.new("BoolValue",v) | |
3177 | defence.Name = ("StunnedBy"..Player.Name) | |
3178 | game:GetService("Debris"):AddItem(defence, 0.1) | |
3179 | end | |
3180 | end | |
3181 | end | |
3182 | end | |
3183 | end | |
3184 | end | |
3185 | end | |
3186 | end | |
3187 | end | |
3188 | ||
3189 | function Stun(HUMANOID,LAST) | |
3190 | if HUMANOID.Parent:FindFirstChild("StunnedBy"..Player.Name) == nil then | |
3191 | HUMANOID.PlatformStand = true | |
3192 | local defence = Instance.new("BoolValue",HUMANOID.Parent) | |
3193 | defence.Name = ("StunnedBy"..Player.Name) | |
3194 | game:GetService("Debris"):AddItem(defence, LAST) | |
3195 | if HUMANOID.Parent:FindFirstChild("Head") then | |
3196 | StatLabel("Normal", HUMANOID.Parent.Head.CFrame * CF(0, 0 + (HUMANOID.Parent.Head.Size.z - 1), 0), "Stunned!", C3(0.3, 0.3, 0.3)) | |
3197 | end | |
3198 | coroutine.resume(coroutine.create(function() | |
3199 | Swait(LAST*50) | |
3200 | HUMANOID.PlatformStand = false | |
3201 | end)) | |
3202 | end | |
3203 | end | |
3204 | ||
3205 | function Poison(HUMANOID,LAST,DAMAGE) | |
3206 | if HUMANOID.Parent:FindFirstChild("PoisonedBy"..Player.Name) == nil then | |
3207 | local defence = Instance.new("BoolValue",HUMANOID.Parent) | |
3208 | defence.Name = ("PoisonedBy"..Player.Name) | |
3209 | game:GetService("Debris"):AddItem(defence, LAST) | |
3210 | coroutine.resume(coroutine.create(function() | |
3211 | for i = 1, LAST/2 do | |
3212 | if HUMANOID then | |
3213 | if HUMANOID.Health == 0 then | |
3214 | break | |
3215 | end | |
3216 | if HUMANOID.Parent:FindFirstChild("Head") then | |
3217 | StatLabel("Normal", HUMANOID.Parent.Head.CFrame * CF(0, 0, 0), DAMAGE, C3(1,1,1)) | |
3218 | end | |
3219 | Swait(50) | |
3220 | HUMANOID.Health = HUMANOID.Health - DAMAGE | |
3221 | end | |
3222 | end | |
3223 | end)) | |
3224 | end | |
3225 | end | |
3226 | ||
3227 | function killnearest(position,range,maxstrength) | |
3228 | for i,v in ipairs(workspace:GetChildren()) do | |
3229 | local body = v:GetChildren() | |
3230 | for part = 1, #body do | |
3231 | if((body[part].ClassName == "Part" or body[part].ClassName == "MeshPart") and v ~= Character) then | |
3232 | if(body[part].Position - position).Magnitude < range then | |
3233 | if v.ClassName == "Model" then | |
3234 | v:BreakJoints() | |
3235 | end | |
3236 | --table.insert(Effects2,{body[part],"Disappear",0.02,2,2,2,2}) | |
3237 | body[part].Velocity = CFrame.new(position,body[part].Position).lookVector*5*maxstrength | |
3238 | end | |
3239 | end | |
3240 | end | |
3241 | if v.ClassName == "Part" then | |
3242 | if v.Anchored == false and (v.Position - position).Magnitude < range then | |
3243 | --table.insert(Effects2,{v,"Disappear",0.02,2,2,2,2}) | |
3244 | v.Velocity = CFrame.new(position,v.Position).lookVector*5*maxstrength | |
3245 | end | |
3246 | end | |
3247 | end | |
3248 | end | |
3249 | ||
3250 | function clerp(a, b, t) | |
3251 | return a:lerp(b, t) | |
3252 | end | |
3253 | ||
3254 | function newBezier(startpos, pos2, pos3, endpos, t) | |
3255 | local A = clerp(startpos, pos2, t) | |
3256 | local B = clerp(pos2, pos3, t) | |
3257 | local C = clerp(pos3, endpos, t) | |
3258 | local lerp1 = clerp(A, B, t) | |
3259 | local lerp2 = clerp(B, C, t) | |
3260 | local cubic = clerp(lerp1, lerp2, t) | |
3261 | return cubic | |
3262 | end | |
3263 | ||
3264 | function Mortar(Target) | |
3265 | local newball = Instance.new("Part", workspace) | |
3266 | newball.Anchored = true | |
3267 | newball.Shape = "Ball" | |
3268 | newball.Material = "Neon" | |
3269 | newball.Size = Vector3.new(0,0,0) | |
3270 | newball.CanCollide = false | |
3271 | newball.CFrame = CF(Target) | |
3272 | newball.Color = C3(1,1,1) | |
3273 | newball.Transparency = 1 | |
3274 | local POS = Mouse.Hit.p | |
3275 | local onefourth = Target:Lerp(POS, 0.25) + Vector3.new(math.random(-25, 25), math.random(0, 25), math.random(-25, 25)) | |
3276 | local threefourths = Target:Lerp(POS, 0.75) + Vector3.new(math.random(-25, 25), math.random(0, 25), math.random(-25, 25)) | |
3277 | local A1 = IT("Attachment",newball) | |
3278 | A1.Position = Vector3.new(0, 2.5, 0) | |
3279 | local A2 = IT("Attachment",newball) | |
3280 | A2.Position = Vector3.new(0, -2.5, 0) | |
3281 | local Trail = IT("Trail",newball) | |
3282 | Trail.LightEmission = 1 | |
3283 | Trail.FaceCamera = true | |
3284 | Trail.Texture = "rbxassetid://945758042" | |
3285 | Trail.Attachment0 = A1 | |
3286 | Trail.Attachment1 = A2 | |
3287 | Trail.Lifetime = 1 | |
3288 | Trail.MinLength = 0 | |
3289 | Trail.Transparency = NumberSequence.new(0, 1) | |
3290 | Trail.Color = ColorSequence.new(newball.Color) | |
3291 | coroutine.resume(coroutine.create(function() | |
3292 | for i = 0, 1, 0.07 do | |
3293 | Swait() | |
3294 | MagicSphere(VT(2,2,2),50,newball.CFrame,"Pearl",VT(-0.01,-0.01,-0.01)) | |
3295 | newball.CFrame = CFrame.new(newBezier(Target, onefourth, threefourths, POS, i)) | |
3296 | end | |
3297 | AoEDamage(newball.Position,50,50,80,50,false,20,20,false,true) | |
3298 | CreateSound(LIGHTHITSOUNDS[MRANDOM(1,#LIGHTHITSOUNDS)], newball, 10, 1) | |
3299 | MagicSphere(VT(0,0,0),55,newball.CFrame,"Pearl",VT(0.06,0.5,0.06)) | |
3300 | for i = 1, 10 do | |
3301 | MagicSphere(VT(0.5,0.5,3),50,CF(newball.CFrame*CF(MRANDOM(-5,5),MRANDOM(-5,5),MRANDOM(-5,5)).p,newball.Position),"Pearl",VT(-0.005,-0.005,0.03),0) | |
3302 | end | |
3303 | game:GetService("Debris"):AddItem(newball, 5) | |
3304 | end)) | |
3305 | end | |
3306 | ||
3307 | function clerp(a, b, t) | |
3308 | return a:lerp(b, t) | |
3309 | end | |
3310 | function newBezier(startpos, pos2, pos3, endpos, t) | |
3311 | local A = clerp(startpos, pos2, t) | |
3312 | local B = clerp(pos2, pos3, t) | |
3313 | local C = clerp(pos3, endpos, t) | |
3314 | local lerp1 = clerp(A, B, t) | |
3315 | local lerp2 = clerp(B, C, t) | |
3316 | local cubic = clerp(lerp1, lerp2, t) | |
3317 | return cubic | |
3318 | end | |
3319 | ||
3320 | function Mortar(Target) | |
3321 | local newball = Instance.new("Part", workspace) | |
3322 | newball.Anchored = true | |
3323 | newball.Shape = "Ball" | |
3324 | newball.Material = "Neon" | |
3325 | newball.Size = Vector3.new(0,0,0) | |
3326 | newball.CanCollide = false | |
3327 | newball.CFrame = CF(Target) | |
3328 | newball.Color = C3(1,1,1) | |
3329 | newball.Transparency = 1 | |
3330 | local POS = Mouse.Hit.p | |
3331 | local onefourth = Target:Lerp(POS, 0.25) + Vector3.new(math.random(-25, 25), math.random(0, 25), math.random(-25, 25)) | |
3332 | local threefourths = Target:Lerp(POS, 0.75) + Vector3.new(math.random(-25, 25), math.random(0, 25), math.random(-25, 25)) | |
3333 | local A1 = IT("Attachment",newball) | |
3334 | A1.Position = Vector3.new(0, 2.5, 0) | |
3335 | local A2 = IT("Attachment",newball) | |
3336 | A2.Position = Vector3.new(0, -2.5, 0) | |
3337 | local Trail = IT("Trail",newball) | |
3338 | Trail.LightEmission = 1 | |
3339 | Trail.FaceCamera = true | |
3340 | Trail.Texture = "rbxassetid://945758042" | |
3341 | Trail.Attachment0 = A1 | |
3342 | Trail.Attachment1 = A2 | |
3343 | Trail.Lifetime = 1 | |
3344 | Trail.MinLength = 0 | |
3345 | Trail.Transparency = NumberSequence.new(0, 1) | |
3346 | Trail.Color = ColorSequence.new(newball.Color) | |
3347 | coroutine.resume(coroutine.create(function() | |
3348 | for i = 0, 1, 0.07 do | |
3349 | Swait() | |
3350 | MagicSphere(VT(2,2,2),50,newball.CFrame,"Pearl",VT(-0.01,-0.01,-0.01)) | |
3351 | newball.CFrame = CFrame.new(newBezier(Target, onefourth, threefourths, POS, i)) | |
3352 | end | |
3353 | AoEDamage(newball.Position,50,50,80,50,false,20,20,false,true) | |
3354 | CreateSound(LIGHTHITSOUNDS[MRANDOM(1,#LIGHTHITSOUNDS)], newball, 10, 1) | |
3355 | MagicSphere(VT(0,0,0),55,newball.CFrame,"Pearl",VT(0.06,0.5,0.06)) | |
3356 | for i = 1, 10 do | |
3357 | MagicSphere(VT(0.5,0.5,3),50,CF(newball.CFrame*CF(MRANDOM(-5,5),MRANDOM(-5,5),MRANDOM(-5,5)).p,newball.Position),"Pearl",VT(-0.005,-0.005,0.03),0) | |
3358 | end | |
3359 | game:GetService("Debris"):AddItem(newball, 5) | |
3360 | end)) | |
3361 | end | |
3362 | ||
3363 | function CreateGUICircle(TARGET) | |
3364 | local GUI = Instance.new("BillboardGui",Character) | |
3365 | GUI.Size = UDim2.new(15,0,15,0) | |
3366 | GUI.Adornee = TARGET | |
3367 | local GUI2 = IT("ImageLabel",GUI) | |
3368 | GUI2.BackgroundTransparency = 1 | |
3369 | GUI2.BorderSizePixel = 0 | |
3370 | GUI2.Size = UDim2.new(1,0,0,0) | |
3371 | GUI2.Position = UDim2.new(0,0,0.5,0) | |
3372 | GUI2.SizeConstraint = "RelativeYY" | |
3373 | GUI.AlwaysOnTop = true | |
3374 | GUI2.Image = "http://www.roblox.com/asset/?id=74329608" | |
3375 | return GUI,GUI2 | |
3376 | end | |
3377 | ||
3378 | function CastZapRay(StartPos, Vec, Length, Ignore, DelayIfHit) | |
3379 | local Direction = CFrame.new(StartPos, Vec).lookVector | |
3380 | local Ignore = ((type(Ignore) == "table" and Ignore) or {Ignore}) | |
3381 | local RayHit, RayPos, RayNormal = game:GetService("Workspace"):FindPartOnRayWithIgnoreList(Ray.new(StartPos, Direction * Length), Ignore) | |
3382 | if RayHit and CheckIntangible(RayHit) then | |
3383 | if DelayIfHit then | |
3384 | wait() | |
3385 | end | |
3386 | RayHit, RayPos, RayNormal = CastZapRay((RayPos + (Vec * 0.01)), Vec, (Length - ((StartPos - RayPos).magnitude)), Ignore, DelayIfHit) | |
3387 | end | |
3388 | return RayHit, RayPos, RayNormal | |
3389 | end | |
3390 | ||
3391 | function turnto(position) | |
3392 | RootPart.CFrame=CFrame.new(RootPart.CFrame.p,VT(position.X,RootPart.Position.Y,position.Z)) * CFrame.new(0, 0, 0) | |
3393 | end | |
3394 | function CreateWave(SIZE,WAIT,CFRAME,DOESROT,ROT,COLOR,GROW) | |
3395 | local wave = CreatePart(3, Effects, "Neon", 0, 0.5, BRICKC(COLOR), "Effect", VT(0,0,0)) | |
3396 | local mesh = IT("SpecialMesh",wave) | |
3397 | mesh.MeshType = "FileMesh" | |
3398 | mesh.MeshId = "http://www.roblox.com/asset/?id=20329976" | |
3399 | mesh.Scale = SIZE | |
3400 | mesh.Offset = VT(0,0,-SIZE.X/8) | |
3401 | wave.CFrame = CFRAME | |
3402 | coroutine.resume(coroutine.create(function(PART) | |
3403 | for i = 1, WAIT do | |
3404 | Swait() | |
3405 | mesh.Scale = mesh.Scale + GROW | |
3406 | mesh.Offset = VT(0,0,-(mesh.Scale.X/8)) | |
3407 | if DOESROT == true then | |
3408 | wave.CFrame = wave.CFrame * CFrame.fromEulerAnglesXYZ(0,ROT,0) | |
3409 | end | |
3410 | wave.Transparency = wave.Transparency + (0.5/WAIT) | |
3411 | if wave.Transparency > 0.99 then | |
3412 | wave:remove() | |
3413 | end | |
3414 | end | |
3415 | end)) | |
3416 | end | |
3417 | ||
3418 | function CreateRing(SIZE,DOESROT,ROT,WAIT,CFRAME,COLOR,GROW) | |
3419 | local wave = CreatePart(3, Effects, "Neon", 0, 0.5, BRICKC(COLOR), "Effect", VT(0,0,0)) | |
3420 | local mesh = IT("SpecialMesh",wave) | |
3421 | mesh.MeshType = "FileMesh" | |
3422 | mesh.MeshId = "http://www.roblox.com/asset/?id=3270017" | |
3423 | mesh.Scale = SIZE | |
3424 | mesh.Offset = VT(0,0,0) | |
3425 | wave.CFrame = CFRAME | |
3426 | coroutine.resume(coroutine.create(function(PART) | |
3427 | for i = 1, WAIT do | |
3428 | Swait() | |
3429 | mesh.Scale = mesh.Scale + GROW | |
3430 | if DOESROT == true then | |
3431 | wave.CFrame = wave.CFrame * CFrame.fromEulerAnglesXYZ(0,ROT,0) | |
3432 | end | |
3433 | wave.Transparency = wave.Transparency + (0.5/WAIT) | |
3434 | if wave.Transparency > 0.99 then | |
3435 | wave:remove() | |
3436 | end | |
3437 | end | |
3438 | end)) | |
3439 | end | |
3440 | ||
3441 | function MagicSphere(SIZE,WAIT,CFRAME,COLOR,GROW) | |
3442 | local wave = CreatePart(3, Effects, "Neon", 0, 0, BRICKC(COLOR), "Effect", VT(1,1,1), true) | |
3443 | local mesh = IT("SpecialMesh",wave) | |
3444 | mesh.MeshType = "Sphere" | |
3445 | mesh.Scale = SIZE | |
3446 | mesh.Offset = VT(0,0,0) | |
3447 | wave.CFrame = CFRAME | |
3448 | coroutine.resume(coroutine.create(function(PART) | |
3449 | for i = 1, WAIT do | |
3450 | Swait() | |
3451 | mesh.Scale = mesh.Scale + GROW | |
3452 | wave.Transparency = wave.Transparency + (1/WAIT) | |
3453 | if wave.Transparency > 0.99 then | |
3454 | wave:remove() | |
3455 | end | |
3456 | end | |
3457 | end)) | |
3458 | end | |
3459 | function MagicSpheres(size,waitt,cframe,color) | |
3460 | local wave = CreatePart(3, Effects, "Neon", 0, 0, BRICKC(color), "Effect", VT(1,1,1)) | |
3461 | local mesh = IT("SpecialMesh",wave) | |
3462 | mesh.MeshType = "Sphere" | |
3463 | mesh.Scale = VT(size,size,size) | |
3464 | mesh.Offset = VT(0,0,0) | |
3465 | wave.CFrame = cframe | |
3466 | coroutine.resume(coroutine.create(function(PART) | |
3467 | for i = 1, waitt do | |
3468 | Swait() | |
3469 | mesh.Scale = mesh.Scale + VT(size/5,size/5,size/5) | |
3470 | wave.Transparency = wave.Transparency + (1/waitt) | |
3471 | if wave.Transparency > 0.99 then | |
3472 | wave:remove() | |
3473 | end | |
3474 | end | |
3475 | end)) | |
3476 | end | |
3477 | function MagicSpheres2(size,waitt,cframe,color) | |
3478 | local wave = CreatePart(3, Effects, "Neon", 0, 1, BRICKC(color), "Effect", VT(1,1,1)) | |
3479 | local mesh = IT("SpecialMesh",wave) | |
3480 | mesh.MeshType = "Sphere" | |
3481 | mesh.Scale = VT(size,size,size) | |
3482 | mesh.Offset = VT(0,0,0) | |
3483 | wave.CFrame = cframe | |
3484 | coroutine.resume(coroutine.create(function(PART) | |
3485 | for i = 1, waitt do | |
3486 | Swait() | |
3487 | mesh.Scale = mesh.Scale - VT(size/waitt,size/waitt,size/waitt) | |
3488 | wave.Transparency = wave.Transparency - (1/waitt) | |
3489 | end | |
3490 | wave:remove() | |
3491 | end)) | |
3492 | end | |
3493 | function MagicBlock(size,waitt,part,offset,color) | |
3494 | local wave = CreatePart(3, Effects, "Neon", 0, 0, BRICKC(color), "Effect", VT(size,size,size)) | |
3495 | local mesh = IT("BlockMesh",wave) | |
3496 | wave.CFrame = CF(part.Position) * CF(0,offset,0) * ANGLES(RAD(0),RAD(0),RAD(0)) | |
3497 | coroutine.resume(coroutine.create(function(PART) | |
3498 | for i = 1, waitt do | |
3499 | Swait() | |
3500 | mesh.Scale = mesh.Scale + VT(size/15,size/15,size/15) | |
3501 | wave.CFrame = CF(wave.Position) * ANGLES(RAD(MRANDOM(-360,360)),RAD(MRANDOM(-360,360)),RAD(MRANDOM(-360,360))) | |
3502 | wave.Transparency = wave.Transparency + (1/waitt) | |
3503 | if wave.Transparency > 0.99 then | |
3504 | wave:remove() | |
3505 | end | |
3506 | end | |
3507 | end)) | |
3508 | end | |
3509 | function CreateDebreeRing(FLOOR,POSITION,SIZE,BLOCKSIZE,SWAIT) | |
3510 | if FLOOR ~= nil then | |
3511 | coroutine.resume(coroutine.create(function() | |
3512 | local PART = CreatePart(3, Effects, "Plastic", 0, 1, "Really red", "DebreeCenter", VT(0,0,0)) | |
3513 | PART.CFrame = CF(POSITION) | |
3514 | for i = 1, 45 do | |
3515 | local RingPiece = CreatePart(3, Effects, "Plastic", 0, 0, "Really red", "DebreePart", BLOCKSIZE) | |
3516 | RingPiece.Material = FLOOR.Material | |
3517 | RingPiece.Color = FLOOR.Color | |
3518 | RingPiece.CFrame = PART.CFrame * ANGLES(RAD(0), RAD(i*8), RAD(0)) * CF(SIZE*4, 0, 0) * ANGLES(RAD(MRANDOM(-360,360)),RAD(MRANDOM(-360,360)),RAD(MRANDOM(-360,360))) | |
3519 | Debris:AddItem(RingPiece,SWAIT) | |
3520 | end | |
3521 | PART:remove() | |
3522 | end)) | |
3523 | end | |
3524 | end | |
3525 | ||
3526 | function Slice(SIZE,WAIT,CFRAME,COLOR,GROW) | |
3527 | local wave = CreatePart(3, Effects, "Neon", 0, 0.5, BRICKC(COLOR), "Effect", VT(1,1,1), true) | |
3528 | local mesh = CreateMesh("SpecialMesh", wave, "FileMesh", "448386996", "", VT(0,SIZE/10,SIZE/10), VT(0,0,0)) | |
3529 | wave.CFrame = CFRAME | |
3530 | coroutine.resume(coroutine.create(function(PART) | |
3531 | for i = 1, WAIT do | |
3532 | Swait() | |
3533 | mesh.Scale = mesh.Scale * GROW | |
3534 | wave.Transparency = wave.Transparency + (0.5/WAIT) | |
3535 | if wave.Transparency > 0.99 then | |
3536 | wave:remove() | |
3537 | end | |
3538 | end | |
3539 | end)) | |
3540 | end | |
3541 | ||
3542 | function CreateFlyingDebree(FLOOR,POSITION,AMOUNT,BLOCKSIZE,SWAIT,STRENGTH) | |
3543 | if FLOOR ~= nil then | |
3544 | for i = 1, AMOUNT do | |
3545 | local DEBREE = CreatePart(3, Effects, "Neon", 0, 0, "Really red", "Debree", BLOCKSIZE, false) | |
3546 | DEBREE.Material = FLOOR.Material | |
3547 | DEBREE.Color = FLOOR.Color | |
3548 | DEBREE.CFrame = POSITION * ANGLES(RAD(MRANDOM(-360,360)),RAD(MRANDOM(-360,360)),RAD(MRANDOM(-360,360))) | |
3549 | DEBREE.Velocity = VT(MRANDOM(-STRENGTH,STRENGTH),STRENGTH,MRANDOM(-STRENGTH,STRENGTH)) | |
3550 | coroutine.resume(coroutine.create(function() | |
3551 | Swait(15) | |
3552 | DEBREE.Parent = workspace | |
3553 | DEBREE.CanCollide = true | |
3554 | Debris:AddItem(DEBREE,SWAIT) | |
3555 | end)) | |
3556 | end | |
3557 | end | |
3558 | end | |
3559 | function MakeForm(PART,TYPE) | |
3560 | if TYPE == "Cyl" then | |
3561 | local MSH = IT("CylinderMesh",PART) | |
3562 | elseif TYPE == "Ball" then | |
3563 | local MSH = IT("SpecialMesh",PART) | |
3564 | MSH.MeshType = "Sphere" | |
3565 | elseif TYPE == "Wedge" then | |
3566 | local MSH = IT("SpecialMesh",PART) | |
3567 | MSH.MeshType = "Wedge" | |
3568 | end | |
3569 | end | |
3570 | local NewInstance = function(instance,parent,properties) | |
3571 | local inst = Instance.new(instance,parent) | |
3572 | if(properties)then | |
3573 | for i,v in next, properties do | |
3574 | pcall(function() inst[i] = v end) | |
3575 | end | |
3576 | end | |
3577 | return inst; | |
3578 | end | |
3579 | local HW = NewInstance('Weld',char,{Part0=ra,Part1=Handle,C0 = CFrame.new(0,-.9,0)*CFrame.Angles(math.rad(-90),math.rad(0),math.rad(90))}) | |
3580 | ||
3581 | ||
3582 | Humanoid.Died:connect(function() | |
3583 | ATTACK = true | |
3584 | end) | |
3585 | ||
3586 | function killnearest(position,range,maxstrength,direction) | |
3587 | for i,v in ipairs(workspace:GetChildren()) do | |
3588 | local body = v:GetChildren() | |
3589 | for part = 1, #body do | |
3590 | if((body[part].ClassName == "Part" or body[part].ClassName == "MeshPart") and v ~= Character) then | |
3591 | if(body[part].Position - position).Magnitude < range then | |
3592 | if v.ClassName == "Model" then | |
3593 | --v:BreakJoints() | |
3594 | end | |
3595 | local POS = position | |
3596 | coroutine.resume(coroutine.create(function() | |
3597 | body[part].Anchored = true | |
3598 | body[part].Parent = Effects | |
3599 | body[part].CanCollide = true | |
3600 | local SIZE = body[part].Size | |
3601 | body[part].Material = "Neon" | |
3602 | CreateSound("952306739", body[part], 2, MRANDOM(7, 12) / 10) | |
3603 | for i = 1, 75 do | |
3604 | Swait() | |
3605 | body[part].Color = C3(MRANDOM(0,100)/100,MRANDOM(0,100)/100,MRANDOM(0,100)/100) | |
3606 | body[part].Size = VT(SIZE.X+MRANDOM(-2,2),SIZE.Y+MRANDOM(-2,2),SIZE.Z+MRANDOM(-2,2)) | |
3607 | end | |
3608 | coroutine.resume(coroutine.create(function() | |
3609 | while true do | |
3610 | Swait() | |
3611 | body[part].Color = C3(MRANDOM(0,100)/100,MRANDOM(0,100)/100,MRANDOM(0,100)/100) | |
3612 | body[part].Size = VT(SIZE.X+MRANDOM(-2,2),SIZE.Y+MRANDOM(-2,2),SIZE.Z+MRANDOM(-2,2)) | |
3613 | end | |
3614 | end)) | |
3615 | body[part].Anchored = false | |
3616 | body[part].Velocity = direction.lookVector*maxstrength | |
3617 | end)) | |
3618 | end | |
3619 | end | |
3620 | end | |
3621 | if v.ClassName == "Part" then | |
3622 | if v.Anchored == false and (v.Position - position).Magnitude < range then | |
3623 | local POS = position | |
3624 | coroutine.resume(coroutine.create(function() | |
3625 | v.Anchored = true | |
3626 | v.Parent = Effects | |
3627 | local SIZE = v.Size | |
3628 | v.Material = "Neon" | |
3629 | CreateSound("952306739", v, 2, MRANDOM(7, 12) / 10) | |
3630 | for i = 1, 75 do | |
3631 | Swait() | |
3632 | v.Color = C3(MRANDOM(0,100)/100,MRANDOM(0,100)/100,MRANDOM(0,100)/100) | |
3633 | v.Size = VT(SIZE.X+MRANDOM(-2,2),SIZE.Y+MRANDOM(-2,2),SIZE.Z+MRANDOM(-2,2)) | |
3634 | end | |
3635 | coroutine.resume(coroutine.create(function() | |
3636 | while true do | |
3637 | Swait() | |
3638 | v.Color = C3(MRANDOM(0,100)/100,MRANDOM(0,100)/100,MRANDOM(0,100)/100) | |
3639 | v.Size = VT(SIZE.X+MRANDOM(-2,2),SIZE.Y+MRANDOM(-2,2),SIZE.Z+MRANDOM(-2,2)) | |
3640 | end | |
3641 | end)) | |
3642 | v.Anchored = false | |
3643 | v.Velocity = direction.lookVector*maxstrength | |
3644 | end)) | |
3645 | end | |
3646 | end | |
3647 | end | |
3648 | end | |
3649 | ||
3650 | function Kill(Char) | |
3651 | local NewCharacter = IT("Model",Effects) | |
3652 | NewCharacter.Name = "Ow im ded ;-;" | |
3653 | for _, c in pairs(Char:GetDescendants()) do | |
3654 | if c:IsA("Part") then | |
3655 | if c.Parent == Char then | |
3656 | end | |
3657 | c:BreakJoints() | |
3658 | c.Material = "Glass" | |
3659 | c.Color = C3(0,0,0) | |
3660 | c.CanCollide = true | |
3661 | c.Transparency = 0.8 | |
3662 | if c:FindFirstChildOfClass("SpecialMesh") then | |
3663 | c:FindFirstChildOfClass("SpecialMesh").TextureId = "" | |
3664 | end | |
3665 | if c.Name == "Head" then | |
3666 | c:ClearAllChildren() | |
3667 | c.Size = VT(c.Size.Y,c.Size.Y,c.Size.Y) | |
3668 | end | |
3669 | if c.ClassName == "MeshPart" then | |
3670 | c.TextureID = "" | |
3671 | end | |
3672 | if c:FindFirstChildOfClass("BodyPosition") then | |
3673 | c:FindFirstChildOfClass("BodyPosition"):remove() | |
3674 | end | |
3675 | if c:FindFirstChildOfClass("ParticleEmitter") then | |
3676 | c:FindFirstChildOfClass("ParticleEmitter"):remove() | |
3677 | end | |
3678 | c.Parent = NewCharacter | |
3679 | c.Name = "DeadPart" | |
3680 | c.Velocity = VT(MRANDOM(-45,45),MRANDOM(-45,45),MRANDOM(-45,45))/15 | |
3681 | c.RotVelocity = VT(MRANDOM(-45,45),MRANDOM(-15,85),MRANDOM(-45,45)) | |
3682 | end | |
3683 | end | |
3684 | Char:remove() | |
3685 | Debris:AddItem(NewCharacter,5) | |
3686 | end | |
3687 | ||
3688 | function ApplyAoE2(POSITION, RANGE) | |
3689 | local PARTS = {} | |
3690 | for index, CHILD in pairs(workspace:GetDescendants()) do | |
3691 | if CHILD.ClassName == "Model" and CHILD ~= Character then | |
3692 | local HUM = CHILD:FindFirstChildOfClass("Humanoid") | |
3693 | if HUM then | |
3694 | local TORSO = CHILD:FindFirstChild("Torso") or CHILD:FindFirstChild("UpperTorso") | |
3695 | if TORSO and HUM.Health > 0 and RANGE >= (TORSO.Position - POSITION).Magnitude then | |
3696 | CHILD:BreakJoints() | |
3697 | for index, PART in pairs(CHILD:GetChildren()) do | |
3698 | if PART:IsA("BasePart") and PART.Name ~= "HumanoidRootPart" then | |
3699 | local P = Particle:Clone() | |
3700 | ||
3701 | P.Color = ColorSequence.new(PART.Color, C3(1, 1, 1)) | |
3702 | ||
3703 | table.insert(PARTS, {PART, P}) | |
3704 | end | |
3705 | end | |
3706 | end | |
3707 | end | |
3708 | elseif CHILD:IsA("BasePart") and CHILD.Parent.Parent ~= Character and CHILD.Parent:FindFirstChildOfClass("Humanoid") == nil and CHILD:FindFirstChild("ewdfrfgrwefd") == nil and CHILD.Size.Magnitude < RANGE * 2 and CHILD.Size.Magnitude < 200 and RANGE > (CHILD.Position - POSITION).Magnitude then | |
3709 | local FOLDER = IT("Folder", CHILD) | |
3710 | FOLDER.Name = "ewdfrfgrwefd" | |
3711 | local P = Particle:Clone() | |
3712 | ||
3713 | CHILD.Velocity = Vector3.new(math.huge,math.huge,math.huge) | |
3714 | ||
3715 | ||
3716 | P.Rate = math.ceil(CHILD.Size.Magnitude / 2) | |
3717 | P.Color = ColorSequence.new(CHILD.Color, C3(1, 1, 1)) | |
3718 | table.insert(PARTS, {CHILD, P}) | |
3719 | end | |
3720 | end | |
3721 | coroutine.resume(coroutine.create(function() | |
3722 | if #PARTS > 0 then | |
3723 | for i = 1, 85 do | |
3724 | Swait() | |
3725 | for E = 1, #PARTS do | |
3726 | local F = PARTS[E] | |
3727 | local A = F[1] | |
3728 | local B = F[2] | |
3729 | A.Transparency = A.Transparency + 0.011764705882352941 | |
3730 | B.Rate = math.ceil(B.Rate * 1.2) | |
3731 | for index, E in pairs(A:GetChildren()) do | |
3732 | ||
3733 | end | |
3734 | end | |
3735 | end | |
3736 | for E = 1, #PARTS do | |
3737 | local F = PARTS[E] | |
3738 | local A = F[1] | |
3739 | local B = F[2] | |
3740 | B.Enabled = false | |
3741 | Debris:AddItem(A, 3) | |
3742 | end | |
3743 | end | |
3744 | end)) | |
3745 | end | |
3746 | function recurse(root,callback,i) | |
3747 | i= i or 0 | |
3748 | for _,v in pairs(root:GetChildren()) do | |
3749 | i = i + 1 | |
3750 | callback(i,v) | |
3751 | ||
3752 | if #v:GetChildren() > 0 then | |
3753 | i = recurse(v,callback,i) | |
3754 | end | |
3755 | end | |
3756 | ||
3757 | return i | |
3758 | end | |
3759 | ||
3760 | function ragdollJoint(character, part0, part1, attachmentName, className, properties) | |
3761 | attachmentName = attachmentName.."RigAttachment" | |
3762 | local constraint = Instance.new(className.."Constraint") | |
3763 | constraint.Attachment0 = part0:FindFirstChild(attachmentName) | |
3764 | constraint.Attachment1 = part1:FindFirstChild(attachmentName) | |
3765 | constraint.Name = "RagdollConstraint"..part1.Name | |
3766 | ||
3767 | for _,propertyData in next,properties or {} do | |
3768 | constraint[propertyData[1]] = propertyData[2] | |
3769 | end | |
3770 | ||
3771 | constraint.Parent = character | |
3772 | end | |
3773 | ||
3774 | function getAttachment0(character, attachmentName) | |
3775 | for _,child in next,character:GetChildren() do | |
3776 | local attachment = child:FindFirstChild(attachmentName) | |
3777 | if attachment then | |
3778 | return attachment | |
3779 | end | |
3780 | end | |
3781 | end | |
3782 | ||
3783 | function ArtificialHitbox(Part) | |
3784 | local HITBOX = CreatePart(3, Part, "Metal", 0, 1, "Really black", "Hitbox", Part.Size/2, false) | |
3785 | HITBOX.CanCollide = true | |
3786 | HITBOX.CFrame = Part.CFrame | |
3787 | weldBetween(Part,HITBOX) | |
3788 | end | |
3789 | ||
3790 | function R15Ragdoll(character,KeepArms) | |
3791 | character:BreakJoints() | |
3792 | coroutine.resume(coroutine.create(function() | |
3793 | recurse(character, function(_,v) | |
3794 | if v:IsA("Attachment") then | |
3795 | v.Axis = Vector3.new(0, 1, 0) | |
3796 | v.SecondaryAxis = Vector3.new(0, 0, 1) | |
3797 | v.Rotation = Vector3.new(0, 0, 0) | |
3798 | end | |
3799 | end) | |
3800 | for _,child in next,character:GetChildren() do | |
3801 | if child:IsA("Accoutrement") then | |
3802 | for _,part in next,child:GetChildren() do | |
3803 | if part:IsA("BasePart") and part.Name ~= "HumanoidRootPart" then | |
3804 | local attachment1 = part:FindFirstChildOfClass("Attachment") | |
3805 | local attachment0 = getAttachment0(character,attachment1.Name) | |
3806 | if attachment0 and attachment1 then | |
3807 | local constraint = Instance.new("HingeConstraint") | |
3808 | constraint.Attachment0 = attachment0 | |
3809 | constraint.Attachment1 = attachment1 | |
3810 | constraint.LimitsEnabled = true | |
3811 | constraint.UpperAngle = 0 | |
3812 | constraint.LowerAngle = 0 | |
3813 | constraint.Parent = character | |
3814 | end | |
3815 | ArtificialHitbox(part) | |
3816 | elseif part.Name == "HumanoidRootPart" then | |
3817 | part:remove() | |
3818 | end | |
3819 | end | |
3820 | end | |
3821 | end | |
3822 | ||
3823 | ragdollJoint(character,character.LowerTorso, character.UpperTorso, "Waist", "BallSocket", { | |
3824 | {"LimitsEnabled",true}; | |
3825 | {"UpperAngle",5}; | |
3826 | }) | |
3827 | if character:FindFirstChild("Head") then | |
3828 | ragdollJoint(character,character.UpperTorso, character.Head, "Neck", "BallSocket", { | |
3829 | {"LimitsEnabled",true}; | |
3830 | {"UpperAngle",15}; | |
3831 | }) | |
3832 | end | |
3833 | ||
3834 | local handProperties = { | |
3835 | {"LimitsEnabled", true}; | |
3836 | {"UpperAngle",0}; | |
3837 | {"LowerAngle",0}; | |
3838 | } | |
3839 | ragdollJoint(character,character.LeftLowerArm, character.LeftHand, "LeftWrist", "Hinge", handProperties) | |
3840 | ragdollJoint(character,character.RightLowerArm, character.RightHand, "RightWrist", "Hinge", handProperties) | |
3841 | ||
3842 | local shinProperties = { | |
3843 | {"LimitsEnabled", true}; | |
3844 | {"UpperAngle", 0}; | |
3845 | {"LowerAngle", -75}; | |
3846 | } | |
3847 | ragdollJoint(character,character.LeftUpperLeg, character.LeftLowerLeg, "LeftKnee", "Hinge", shinProperties) | |
3848 | ragdollJoint(character,character.RightUpperLeg, character.RightLowerLeg, "RightKnee", "Hinge", shinProperties) | |
3849 | ||
3850 | local footProperties = { | |
3851 | {"LimitsEnabled", true}; | |
3852 | {"UpperAngle", 15}; | |
3853 | {"LowerAngle", -45}; | |
3854 | } | |
3855 | ragdollJoint(character,character.LeftLowerLeg, character.LeftFoot, "LeftAnkle", "Hinge", footProperties) | |
3856 | ragdollJoint(character,character.RightLowerLeg, character.RightFoot, "RightAnkle", "Hinge", footProperties) | |
3857 | if KeepArms == true then | |
3858 | ragdollJoint(character,character.UpperTorso, character.RightUpperArm, "RightShoulder", "BallSocket") | |
3859 | ragdollJoint(character,character.RightUpperArm, character.RightLowerArm, "RightElbow", "BallSocket") | |
3860 | ragdollJoint(character,character.UpperTorso, character.LeftUpperArm, "LeftShoulder", "BallSocket") | |
3861 | ragdollJoint(character,character.LeftUpperArm, character.LeftLowerArm, "LeftElbow", "BallSocket") | |
3862 | end | |
3863 | ragdollJoint(character,character.LowerTorso, character.LeftUpperLeg, "LeftHip", "BallSocket") | |
3864 | ragdollJoint(character,character.LowerTorso, character.RightUpperLeg, "RightHip", "BallSocket") | |
3865 | Debris:AddItem(character,5) | |
3866 | end)) | |
3867 | end | |
3868 | ||
3869 | function Ragdoll(Character2,CharTorso,KeepArms) | |
3870 | coroutine.resume(coroutine.create(function() | |
3871 | Character2:BreakJoints() | |
3872 | local hum = Character2:findFirstChild("Humanoid") | |
3873 | hum:remove() | |
3874 | local function Scan(ch) | |
3875 | local e | |
3876 | for e = 1,#ch do | |
3877 | Scan(ch[e]:GetChildren()) | |
3878 | if ch[e].ClassName == "Weld" or ch[e].ClassName == "Motor6D" then | |
3879 | ch[e]:remove() | |
3880 | end | |
3881 | end | |
3882 | end | |
3883 | local NEWHUM = IT("Humanoid") | |
3884 | NEWHUM.Name = "Corpse" | |
3885 | NEWHUM.Health = 0 | |
3886 | NEWHUM.MaxHealth = 0 | |
3887 | NEWHUM.PlatformStand = true | |
3888 | NEWHUM.Parent = Character2 | |
3889 | NEWHUM.DisplayDistanceType = "None" | |
3890 | ||
3891 | local ch = Character2:GetChildren() | |
3892 | local i | |
3893 | for i = 1,#ch do | |
3894 | if ch[i].Name == "THandle1" or ch[i].Name == "THandle2" then | |
3895 | ch[i]:remove() | |
3896 | end | |
3897 | end | |
3898 | ||
3899 | local Torso2 = Character2.Torso | |
3900 | local movevector = Vector3.new() | |
3901 | ||
3902 | if Torso2 then | |
3903 | movevector = CFrame.new(CharTorso.Position,Torso2.Position).lookVector | |
3904 | local Head = Character2:FindFirstChild("Head") | |
3905 | if Head then | |
3906 | local Neck = Instance.new("Weld") | |
3907 | Neck.Name = "Neck" | |
3908 | Neck.Part0 = Torso2 | |
3909 | Neck.Part1 = Head | |
3910 | Neck.C0 = CFrame.new(0, 1.5, 0) | |
3911 | Neck.C1 = CFrame.new() | |
3912 | Neck.Parent = Torso2 | |
3913 | ||
3914 | end | |
3915 | local Limb = Character2:FindFirstChild("Right Arm") | |
3916 | if Limb and KeepArms == true then | |
3917 | ||
3918 | Limb.CFrame = Torso2.CFrame * CFrame.new(1.5, 0, 0) | |
3919 | local Joint = Instance.new("Glue") | |
3920 | Joint.Name = "RightShoulder" | |
3921 | Joint.Part0 = Torso2 | |
3922 | Joint.Part1 = Limb | |
3923 | Joint.C0 = CFrame.new(1.5, 0.5, 0, 0, 0, 1, 0, 1, 0, -1, -0, -0) | |
3924 | Joint.C1 = CFrame.new(-0, 0.5, 0, 0, 0, 1, 0, 1, 0, -1, -0, -0) | |
3925 | Joint.Parent = Torso2 | |
3926 | ||
3927 | local B = Instance.new("Part") | |
3928 | B.TopSurface = 0 | |
3929 | B.BottomSurface = 0 | |
3930 | B.formFactor = "Symmetric" | |
3931 | B.Size = Vector3.new(1, 1, 1) | |
3932 | B.Transparency = 1 | |
3933 | B.CFrame = Limb.CFrame * CFrame.new(0, -0.5, 0) | |
3934 | B.Parent = Character2 | |
3935 | local W = Instance.new("Weld") | |
3936 | W.Part0 = Limb | |
3937 | W.Part1 = B | |
3938 | W.C0 = CFrame.new(0, -0.5, 0) | |
3939 | W.Parent = Limb | |
3940 | ||
3941 | end | |
3942 | local Limb = Character2:FindFirstChild("Left Arm") | |
3943 | if Limb and KeepArms == true then | |
3944 | ||
3945 | Limb.CFrame = Torso2.CFrame * CFrame.new(-1.5, 0, 0) | |
3946 | local Joint = Instance.new("Glue") | |
3947 | Joint.Name = "LeftShoulder" | |
3948 | Joint.Part0 = Torso2 | |
3949 | Joint.Part1 = Limb | |
3950 | Joint.C0 = CFrame.new(-1.5, 0.5, 0, -0, -0, -1, 0, 1, 0, 1, 0, 0) | |
3951 | Joint.C1 = CFrame.new(0, 0.5, 0, -0, -0, -1, 0, 1, 0, 1, 0, 0) | |
3952 | Joint.Parent = Torso2 | |
3953 | ||
3954 | local B = Instance.new("Part") | |
3955 | B.TopSurface = 0 | |
3956 | B.BottomSurface = 0 | |
3957 | B.formFactor = "Symmetric" | |
3958 | B.Size = Vector3.new(1, 1, 1) | |
3959 | B.Transparency = 1 | |
3960 | B.CFrame = Limb.CFrame * CFrame.new(0, -0.5, 0) | |
3961 | B.Parent = Character2 | |
3962 | local W = Instance.new("Weld") | |
3963 | W.Part0 = Limb | |
3964 | W.Part1 = B | |
3965 | W.C0 = CFrame.new(0, -0.5, 0) | |
3966 | W.Parent = Limb | |
3967 | ||
3968 | end | |
3969 | local Limb = Character2:FindFirstChild("Right Leg") | |
3970 | if Limb then | |
3971 | ||
3972 | Limb.CFrame = Torso2.CFrame * CFrame.new(0.5, -2, 0) | |
3973 | local Joint = Instance.new("Glue") | |
3974 | Joint.Name = "RightHip" | |
3975 | Joint.Part0 = Torso2 | |
3976 | Joint.Part1 = Limb | |
3977 | Joint.C0 = CFrame.new(0.5, -1, 0, 0, 0, 1, 0, 1, 0, -1, -0, -0) | |
3978 | Joint.C1 = CFrame.new(0, 1, 0, 0, 0, 1, 0, 1, 0, -1, -0, -0) | |
3979 | Joint.Parent = Torso2 | |
3980 | ||
3981 | local B = Instance.new("Part") | |
3982 | B.TopSurface = 0 | |
3983 | B.BottomSurface = 0 | |
3984 | B.formFactor = "Symmetric" | |
3985 | B.Size = Vector3.new(1, 1, 1) | |
3986 | B.Transparency = 1 | |
3987 | B.CFrame = Limb.CFrame * CFrame.new(0, -0.5, 0) | |
3988 | B.Parent = Character2 | |
3989 | local W = Instance.new("Weld") | |
3990 | W.Part0 = Limb | |
3991 | W.Part1 = B | |
3992 | W.C0 = CFrame.new(0, -0.5, 0) | |
3993 | W.Parent = Limb | |
3994 | ||
3995 | end | |
3996 | local Limb = Character2:FindFirstChild("Left Leg") | |
3997 | if Limb then | |
3998 | ||
3999 | Limb.CFrame = Torso2.CFrame * CFrame.new(-0.5, -2, 0) | |
4000 | local Joint = Instance.new("Glue") | |
4001 | Joint.Name = "LeftHip" | |
4002 | Joint.Part0 = Torso2 | |
4003 | Joint.Part1 = Limb | |
4004 | Joint.C0 = CFrame.new(-0.5, -1, 0, -0, -0, -1, 0, 1, 0, 1, 0, 0) | |
4005 | Joint.C1 = CFrame.new(-0, 1, 0, -0, -0, -1, 0, 1, 0, 1, 0, 0) | |
4006 | Joint.Parent = Torso2 | |
4007 | ||
4008 | local B = Instance.new("Part") | |
4009 | B.TopSurface = 0 | |
4010 | B.BottomSurface = 0 | |
4011 | B.formFactor = "Symmetric" | |
4012 | B.Size = Vector3.new(1, 1, 1) | |
4013 | B.Transparency = 1 | |
4014 | B.CFrame = Limb.CFrame * CFrame.new(0, -0.5, 0) | |
4015 | B.Parent = Character2 | |
4016 | local W = Instance.new("Weld") | |
4017 | W.Part0 = Limb | |
4018 | W.Part1 = B | |
4019 | W.C0 = CFrame.new(0, -0.5, 0) | |
4020 | W.Parent = Limb | |
4021 | ||
4022 | end | |
4023 | --[ | |
4024 | local Bar = Instance.new("Part") | |
4025 | Bar.TopSurface = 0 | |
4026 | Bar.BottomSurface = 0 | |
4027 | Bar.formFactor = "Symmetric" | |
4028 | Bar.Size = Vector3.new(1, 1, 1) | |
4029 | Bar.Transparency = 1 | |
4030 | Bar.CFrame = Torso2.CFrame * CFrame.new(0, 0.5, 0) | |
4031 | Bar.Parent = Character2 | |
4032 | local Weld = Instance.new("Weld") | |
4033 | Weld.Part0 = Torso2 | |
4034 | Weld.Part1 = Bar | |
4035 | Weld.C0 = CFrame.new(0, 0.5, 0) | |
4036 | Weld.Parent = Torso2 | |
4037 | --]] | |
4038 | end | |
4039 | Character2.Parent = workspace | |
4040 | Debris:AddItem(Character2,5) | |
4041 | ||
4042 | return Character2,Torso2 | |
4043 | end)) | |
4044 | end | |
4045 | function CreateWave(SIZE, WAIT, CFRAME, DOESROT, ROT, COLOR, GROW) | |
4046 | local wave = CreatePart(3, Effects, "Neon", 0, 0.5, BRICKC(COLOR), "Effect", VT(0, 0, 0)) | |
4047 | local mesh = CreateMesh("SpecialMesh", wave, "FileMesh", "20329976", "", SIZE, VT(0, 0, -SIZE.X / 8)) | |
4048 | wave.CFrame = CFRAME | |
4049 | coroutine.resume(coroutine.create(function(PART) | |
4050 | for i = 1, WAIT do | |
4051 | Swait() | |
4052 | mesh.Scale = mesh.Scale + GROW | |
4053 | mesh.Offset = VT(0, 0, -(mesh.Scale.X / 8)) | |
4054 | if DOESROT == true then | |
4055 | wave.CFrame = wave.CFrame * CFrame.fromEulerAnglesXYZ(0, ROT, 0) | |
4056 | end | |
4057 | wave.Transparency = wave.Transparency + 0.5 / WAIT | |
4058 | if wave.Transparency > 0.99 then | |
4059 | wave:remove() | |
4060 | end | |
4061 | end | |
4062 | end)) | |
4063 | end | |
4064 | ||
4065 | function FireArc(Part, ToLocation, AmountOfTime, Height, DoesCourontine) | |
4066 | if DoesCourontine == false then | |
4067 | local Direction = CF(Part.Position, ToLocation) | |
4068 | local Distance = (Part.Position - ToLocation).magnitude | |
4069 | for i = 1, AmountOfTime do | |
4070 | Swait() | |
4071 | Part.CFrame = Direction * CF(0, AmountOfTime / 200 + (AmountOfTime / Height - i * 2 / Height), -Distance / AmountOfTime) | |
4072 | Direction = Part.CFrame | |
4073 | end | |
4074 | Part:remove() | |
4075 | elseif DoesCourontine == true then | |
4076 | coroutine.resume(coroutine.create(function() | |
4077 | local Direction = CF(Part.Position, ToLocation) | |
4078 | local Distance = (Part.Position - ToLocation).magnitude | |
4079 | for i = 1, AmountOfTime do | |
4080 | Swait() | |
4081 | Part.CFrame = Direction * CF(0, AmountOfTime / 200 + (AmountOfTime / Height - i * 2 / Height), -Distance / AmountOfTime) | |
4082 | Direction = Part.CFrame | |
4083 | end | |
4084 | Part:remove() | |
4085 | end)) | |
4086 | end | |
4087 | end | |
4088 | ||
4089 | function Slice(KIND, SIZE, WAIT, CFRAME, COLOR, GROW) | |
4090 | local wave = CreatePart(3, Effects, "Neon", 0, 0.5, BRICKC(COLOR), "Effect", VT(1, 1, 1), true) | |
4091 | local mesh | |
4092 | if KIND == "Base" then | |
4093 | mesh = CreateMesh("SpecialMesh", wave, "FileMesh", "448386996", "", VT(0, SIZE / 10, SIZE / 10), VT(0, 0, 0)) | |
4094 | elseif KIND == "Thin" then | |
4095 | mesh = CreateMesh("SpecialMesh", wave, "FileMesh", "662586858", "", VT(SIZE / 10, 0, SIZE / 10), VT(0, 0, 0)) | |
4096 | elseif KIND == "Round" then | |
4097 | mesh = CreateMesh("SpecialMesh", wave, "FileMesh", "662585058", "", VT(SIZE / 10, 0, SIZE / 10), VT(0, 0, 0)) | |
4098 | end | |
4099 | wave.CFrame = CFRAME | |
4100 | coroutine.resume(coroutine.create(function(PART) | |
4101 | for i = 1, WAIT do | |
4102 | Swait() | |
4103 | mesh.Scale = mesh.Scale + GROW / 10 | |
4104 | wave.Transparency = wave.Transparency + 0.5 / WAIT | |
4105 | if wave.Transparency > 0.99 then | |
4106 | wave:remove() | |
4107 | end | |
4108 | end | |
4109 | end)) | |
4110 | end | |
4111 | function AddChildrenToTable(FROM, PARENT, DIST, TABLE) | |
4112 | for _, c in pairs(PARENT:GetChildren()) do | |
4113 | if c.ClassName == "Model" then | |
4114 | if c ~= Character and c:FindFirstChildOfClass("Humanoid") and (c:FindFirstChild("Torso") or c:FindFirstChild("UpperTorso")) then | |
4115 | local HUMANOID = c:FindFirstChildOfClass("Humanoid") | |
4116 | local TORSO = c:FindFirstChild("Torso") or c:FindFirstChild("UpperTorso") | |
4117 | if DIST > (TORSO.Position - FROM).Magnitude then | |
4118 | table.insert(TABLE, c) | |
4119 | end | |
4120 | AddChildrenToTable(FROM, c, DIST, TABLE) | |
4121 | elseif c.ClassName == "Folder" then | |
4122 | AddChildrenToTable(FROM, c, DIST, TABLE) | |
4123 | end | |
4124 | end | |
4125 | end | |
4126 | end | |
4127 | ||
4128 | function Transparency(TRANS) | |
4129 | text.TextTransparency = TRANS | |
4130 | text.TextStrokeTransparency = TRANS | |
4131 | for _, c in pairs(Character:GetChildren()) do | |
4132 | if c.ClassName == "Part" and c ~= RootPart then | |
4133 | c.Transparency = TRANS | |
4134 | if c:FindFirstChildOfClass("Decal") then | |
4135 | c:FindFirstChildOfClass("Decal").Transparency = TRANS | |
4136 | end | |
4137 | elseif c.ClassName == "Accessory" then | |
4138 | c.Handle.Transparency = TRANS | |
4139 | elseif c.ClassName == "Model" then | |
4140 | for _, q in pairs(c:GetChildren()) do | |
4141 | if q.ClassName == "Part" then | |
4142 | q.Transparency = TRANS | |
4143 | if q:FindFirstChildOfClass("Decal") then | |
4144 | q:FindFirstChildOfClass("Decal").Transparency = TRANS | |
4145 | end | |
4146 | end | |
4147 | end | |
4148 | end | |
4149 | end | |
4150 | end | |
4151 | function CreateRing(SIZE, DOESROT, ROT, WAIT, CFRAME, COLOR, GROW) | |
4152 | local wave = CreatePart(3, Effects, "Neon", 0, 0.5, BRICKC(COLOR), "Effect", VT(0, 0, 0)) | |
4153 | local mesh = CreateMesh("SpecialMesh", wave, "FileMesh", "559831844", "", SIZE, VT(0, 0, 0)) | |
4154 | wave.CFrame = CFRAME | |
4155 | coroutine.resume(coroutine.create(function(PART) | |
4156 | for i = 1, WAIT do | |
4157 | Swait() | |
4158 | mesh.Scale = mesh.Scale + GROW | |
4159 | if DOESROT == true then | |
4160 | wave.CFrame = wave.CFrame * CFrame.fromEulerAnglesXYZ(0, ROT, 0) | |
4161 | end | |
4162 | wave.Transparency = wave.Transparency + 0.5 / WAIT | |
4163 | if wave.Transparency > 0.99 then | |
4164 | wave:remove() | |
4165 | end | |
4166 | end | |
4167 | end)) | |
4168 | end | |
4169 | function MagicSphere2(size,waitt,cframe,color) | |
4170 | local wave = CreatePart(3, Effects, "Neon", 0, 1, BRICKC(color), "Effect", VT(1,1,1)) | |
4171 | local mesh = IT("SpecialMesh",wave) | |
4172 | mesh.MeshType = "Sphere" | |
4173 | mesh.Scale = VT(size,size,size) | |
4174 | mesh.Offset = VT(0,0,0) | |
4175 | wave.CFrame = cframe | |
4176 | coroutine.resume(coroutine.create(function(PART) | |
4177 | for i = 1, waitt do | |
4178 | Swait() | |
4179 | mesh.Scale = mesh.Scale - VT(size/waitt,size/waitt,size/waitt) | |
4180 | wave.Transparency = wave.Transparency - (1/waitt) | |
4181 | end | |
4182 | wave:remove() | |
4183 | end)) | |
4184 | end | |
4185 | ||
4186 | function MagicSphere(size,waitt,cframe,color) | |
4187 | local wave = CreatePart(3, Effects, "Neon", 0, 0, BRICKC(color), "Effect", VT(1,1,1)) | |
4188 | local mesh = IT("SpecialMesh",wave) | |
4189 | mesh.MeshType = "Sphere" | |
4190 | mesh.Scale = VT(size,size,size) | |
4191 | mesh.Offset = VT(0,0,0) | |
4192 | wave.CFrame = cframe | |
4193 | coroutine.resume(coroutine.create(function(PART) | |
4194 | for i = 1, waitt do | |
4195 | Swait() | |
4196 | mesh.Scale = mesh.Scale + VT(size/5,size/5,size/5) | |
4197 | wave.Transparency = wave.Transparency + (1/waitt) | |
4198 | if wave.Transparency > 0.99 then | |
4199 | wave:remove() | |
4200 | end | |
4201 | end | |
4202 | end)) | |
4203 | end | |
4204 | ||
4205 | function CreateSwirl(inair,size,doesrotate,rotatedirection,waitt,cframe,color) | |
4206 | local wave = CreatePart(3, Effects, "Neon", 0, 0.5, BRICKC(color), "Effect", VT(0,0,0)) | |
4207 | local mesh = IT("SpecialMesh",wave) | |
4208 | mesh.MeshType = "FileMesh" | |
4209 | mesh.MeshId = "http://www.roblox.com/asset/?id=1051557" | |
4210 | mesh.Scale = VT(size,size,size) | |
4211 | wave.CFrame = cframe | |
4212 | coroutine.resume(coroutine.create(function(PART) | |
4213 | for i = 1, waitt do | |
4214 | Swait() | |
4215 | mesh.Scale = mesh.Scale + VT(size/5,0,size/5) | |
4216 | if doesrotate == true then | |
4217 | wave.CFrame = wave.CFrame * CFrame.fromEulerAnglesXYZ(0, rotatedirection, 0) | |
4218 | end | |
4219 | wave.Transparency = wave.Transparency + (0.5/waitt) | |
4220 | if wave.Transparency > 0.99 then | |
4221 | wave:remove() | |
4222 | end | |
4223 | end | |
4224 | end)) | |
4225 | end | |
4226 | ||
4227 | function CheckTableForString(Table, String) | |
4228 | for i, v in pairs(Table) do | |
4229 | if string.find(string.lower(String), string.lower(v)) then | |
4230 | return true | |
4231 | end | |
4232 | end | |
4233 | return false | |
4234 | end | |
4235 | ||
4236 | function CheckIntangible(Hit) | |
4237 | local ProjectileNames = {"Water", "Arrow", "Projectile", "Effect", "Rail", "Lightning", "Bullet"} | |
4238 | if Hit and Hit.Parent then | |
4239 | if ((not Hit.CanCollide or CheckTableForString(ProjectileNames, Hit.Name)) and not Hit.Parent:FindFirstChild("Humanoid")) then | |
4240 | return true | |
4241 | end | |
4242 | end | |
4243 | return false | |
4244 | end | |
4245 | ||
4246 | function CastZapRay(StartPos, Vec, Length, Ignore, DelayIfHit) | |
4247 | local Direction = CFrame.new(StartPos, Vec).lookVector | |
4248 | local Ignore = ((type(Ignore) == "table" and Ignore) or {Ignore}) | |
4249 | local RayHit, RayPos, RayNormal = game:GetService("Workspace"):FindPartOnRayWithIgnoreList(Ray.new(StartPos, Direction * Length), Ignore) | |
4250 | if RayHit and CheckIntangible(RayHit) then | |
4251 | if DelayIfHit then | |
4252 | wait() | |
4253 | end | |
4254 | RayHit, RayPos, RayNormal = CastZapRay((RayPos + (Vec * 0.01)), Vec, (Length - ((StartPos - RayPos).magnitude)), Ignore, DelayIfHit) | |
4255 | end | |
4256 | return RayHit, RayPos, RayNormal | |
4257 | end | |
4258 | ||
4259 | function attractnearest(postype,position,range,maxstrength,last) | |
4260 | if postype == "Vector" then | |
4261 | for i,v in ipairs(workspace:GetChildren()) do | |
4262 | local body = v:GetChildren() | |
4263 | for part = 1, #body do | |
4264 | if((body[part].ClassName == "Part" or body[part].ClassName == "MeshPart") and v ~= Character) then | |
4265 | if(body[part].Position - position).Magnitude < range then | |
4266 | if body[part]:FindFirstChild("ATTRACT") == nil then | |
4267 | local bv = Instance.new("BodyVelocity") | |
4268 | bv.maxForce = Vector3.new(1e9, 1e9, 1e9) | |
4269 | bv.velocity = CF(body[part].Position,position).lookVector*maxstrength | |
4270 | bv.Parent = body[part] | |
4271 | bv.Name = "ATTRACT" | |
4272 | else | |
4273 | coroutine.resume(coroutine.create(function() | |
4274 | for i = 1, last/5 do | |
4275 | Swait(5) | |
4276 | body[part].ATTRACT.velocity = CF(body[part].Position,position).lookVector*maxstrength | |
4277 | end | |
4278 | body[part].ATTRACT:remove() | |
4279 | end)) | |
4280 | end | |
4281 | end | |
4282 | end | |
4283 | end | |
4284 | if v.ClassName == "Part" then | |
4285 | if v.Anchored == false and (v.Position - position).Magnitude < range then | |
4286 | if v:FindFirstChild("ATTRACT") == nil then | |
4287 | local bv = Instance.new("BodyVelocity") | |
4288 | bv.maxForce = Vector3.new(1e9, 1e9, 1e9) | |
4289 | bv.velocity = CF(v.Position,position).lookVector*maxstrength | |
4290 | bv.Parent = v | |
4291 | bv.Name = "ATTRACT" | |
4292 | else | |
4293 | coroutine.resume(coroutine.create(function() | |
4294 | for i = 1, last/5 do | |
4295 | Swait(5) | |
4296 | v.ATTRACT.velocity = CF(v.Position,position).lookVector*maxstrength | |
4297 | end | |
4298 | v.ATTRACT:remove() | |
4299 | end)) | |
4300 | end | |
4301 | end | |
4302 | end | |
4303 | end | |
4304 | elseif postype == "Part" then | |
4305 | for i,v in ipairs(workspace:GetChildren()) do | |
4306 | local body = v:GetChildren() | |
4307 | for part = 1, #body do | |
4308 | if((body[part].ClassName == "Part" or body[part].ClassName == "MeshPart") and v ~= Character) then | |
4309 | if(body[part].Position - position.Position).Magnitude < range then | |
4310 | if body[part]:FindFirstChild("ATTRACT") == nil then | |
4311 | local bv = Instance.new("BodyVelocity") | |
4312 | bv.maxForce = Vector3.new(1e9, 1e9, 1e9) | |
4313 | bv.velocity = CF(body[part].Position,position.Position).lookVector*maxstrength | |
4314 | bv.Parent = body[part] | |
4315 | bv.Name = "ATTRACT" | |
4316 | else | |
4317 | coroutine.resume(coroutine.create(function() | |
4318 | for i = 1, last/5 do | |
4319 | Swait(5) | |
4320 | body[part].ATTRACT.velocity = CF(body[part].Position,position.Position).lookVector*maxstrength | |
4321 | end | |
4322 | body[part].ATTRACT:remove() | |
4323 | end)) | |
4324 | end | |
4325 | end | |
4326 | end | |
4327 | end | |
4328 | if v.ClassName == "Part" then | |
4329 | if v.Anchored == false and (v.Position - position.Position).Magnitude < range then | |
4330 | if v:FindFirstChild("ATTRACT") == nil then | |
4331 | local bv = Instance.new("BodyVelocity") | |
4332 | bv.maxForce = Vector3.new(1e9, 1e9, 1e9) | |
4333 | bv.velocity = CF(v.Position,position.Position).lookVector*maxstrength | |
4334 | bv.Parent = v | |
4335 | bv.Name = "ATTRACT" | |
4336 | else | |
4337 | coroutine.resume(coroutine.create(function() | |
4338 | for i = 1, last/5 do | |
4339 | Swait(5) | |
4340 | v.ATTRACT.velocity = CF(v.Position,position.Position).lookVector*maxstrength | |
4341 | end | |
4342 | v.ATTRACT:remove() | |
4343 | end)) | |
4344 | end | |
4345 | end | |
4346 | end | |
4347 | end | |
4348 | end | |
4349 | end | |
4350 | ||
4351 | function killnearest(position,range,maxstrength) | |
4352 | for i,v in ipairs(workspace:GetChildren()) do | |
4353 | local body = v:GetChildren() | |
4354 | for part = 1, #body do | |
4355 | if((body[part].ClassName == "Part" or body[part].ClassName == "MeshPart") and v ~= Character) then | |
4356 | if(body[part].Position - position).Magnitude < range then | |
4357 | if v.ClassName == "Model" then | |
4358 | v:BreakJoints() | |
4359 | end | |
4360 | --table.insert(Effects2,{body[part],"Disappear",0.02,2,2,2,2}) | |
4361 | body[part].Velocity = CFrame.new(position,body[part].Position).lookVector*5*maxstrength | |
4362 | end | |
4363 | end | |
4364 | end | |
4365 | if v.ClassName == "Part" then | |
4366 | if v.Anchored == false and (v.Position - position).Magnitude < range then | |
4367 | --table.insert(Effects2,{v,"Disappear",0.02,2,2,2,2}) | |
4368 | v.Velocity = CFrame.new(position,v.Position).lookVector*5*maxstrength | |
4369 | end | |
4370 | end | |
4371 | end | |
4372 | end | |
4373 | local HATWELD = nil | |
4374 | function Pose(WhichPose,Speed,Time,Magic,Gyro,Tors) | |
4375 | PLAYMAINANIM = false | |
4376 | if WhichPose == "Cast1" then | |
4377 | for i=0, Time, 0.1 / Animation_Speed do | |
4378 | Swait() | |
4379 | if Magic == true then | |
4380 | WACKYEFFECT({Time = 15, EffectType = "Crystal", Size = VT(1,1,1)*1.5, Size2 = VT(0,4,0), Transparency = 0, Transparency2 = 1, CFrame = RightArm.CFrame*CF(0,-1,0)*ANGLES(RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360))), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Glass", Color = BRICKC"Lavender".Color, SoundID = nil, SoundPitch = nil, SoundVolume = nil}) | |
4381 | end | |
4382 | if Gyro ~= nil and Gyro ~= false then | |
4383 | Gyro.cframe = CF(RootPart.Position,Mouse.Hit.p) | |
4384 | end | |
4385 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(0), RAD(0), RAD(35)), Speed / Animation_Speed) | |
4386 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(5 - 6.5 * SIN(SINE / 12)), RAD(0), RAD(-35)), Speed / Animation_Speed) | |
4387 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.65 + 0.15 * COS(SINE / 12) - 0.05 * COS(SINE / 12), -0.5) * ANGLES(RAD(125), RAD(0), RAD(45)) * RIGHTSHOULDERC0, Speed / Animation_Speed) | |
4388 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.25, 0.5 + 0.15 * COS(SINE / 12) - 0.05 * COS(SINE / 12), 0.5) * ANGLES(RAD(-45), RAD(0), RAD(45)) * LEFTSHOULDERC0, Speed / Animation_Speed) | |
4389 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -0.5, -0.5) * ANGLES(RAD(0), RAD(65), RAD(0)) * ANGLES(RAD(-3), RAD(0), RAD(-15)), Speed / Animation_Speed) | |
4390 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1, -0.01) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), Speed / Animation_Speed) | |
4391 | end | |
4392 | elseif WhichPose == "Cast2" then | |
4393 | for i=0, Time, 0.1 / Animation_Speed do | |
4394 | Swait() | |
4395 | if Magic == true then | |
4396 | WACKYEFFECT({Time = 15, EffectType = "Crystal", Size = VT(1,1,1)*1.5, Size2 = VT(0,4,0), Transparency = 0, Transparency2 = 1, CFrame = RightArm.CFrame*CF(0,-1,0)*ANGLES(RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360))), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Glass", Color = BRICKC"Lavender".Color, SoundID = nil, SoundPitch = nil, SoundVolume = nil}) | |
4397 | WACKYEFFECT({Time = 15, EffectType = "Crystal", Size = VT(1,1,1)*1.5, Size2 = VT(0,4,0), Transparency = 0, Transparency2 = 1, CFrame = LeftArm.CFrame*CF(0,-1,0)*ANGLES(RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360))), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Glass", Color = BRICKC"Lavender".Color, SoundID = nil, SoundPitch = nil, SoundVolume = nil}) | |
4398 | end | |
4399 | if Gyro ~= nil and Gyro ~= false then | |
4400 | Gyro.cframe = CF(RootPart.Position,Mouse.Hit.p) | |
4401 | end | |
4402 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(0), RAD(0), RAD(0)), Speed / Animation_Speed) | |
4403 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(-15 - 6.5 * SIN(SINE / 12)), RAD(0), RAD(0)), Speed / Animation_Speed) | |
4404 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.65 + 0.15 * COS(SINE / 12) - 0.05 * COS(SINE / 12), -0.5) * ANGLES(RAD(120), RAD(0), RAD(15)) * RIGHTSHOULDERC0, Speed / Animation_Speed) | |
4405 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.65 + 0.15 * COS(SINE / 12) - 0.05 * COS(SINE / 12), -0.5) * ANGLES(RAD(120), RAD(0), RAD(-15)) * LEFTSHOULDERC0, Speed / Animation_Speed) | |
4406 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -0.5, -0.5) * ANGLES(RAD(0), RAD(65), RAD(0)) * ANGLES(RAD(-3), RAD(0), RAD(-15)), Speed / Animation_Speed) | |
4407 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1, -0.01) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), Speed / Animation_Speed) | |
4408 | end | |
4409 | elseif WhichPose == "RightArmUp" then | |
4410 | for i=0, Time, 0.1 / Animation_Speed do | |
4411 | Swait() | |
4412 | if Magic == true then | |
4413 | WACKYEFFECT({Time = 15, EffectType = "Crystal", Size = VT(1,1,1)*1.5, Size2 = VT(0,4,0), Transparency = 0, Transparency2 = 1, CFrame = RightArm.CFrame*CF(0,-1,0)*ANGLES(RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360))), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Glass", Color = BRICKC"Lavender".Color, SoundID = nil, SoundPitch = nil, SoundVolume = nil}) | |
4414 | end | |
4415 | if Gyro ~= nil and Gyro ~= false then | |
4416 | Gyro.cframe = CF(RootPart.Position,Mouse.Hit.p) | |
4417 | end | |
4418 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(0), RAD(0), RAD(15)), Speed / Animation_Speed) | |
4419 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(-5 - 6.5 * SIN(SINE / 12)), RAD(0), RAD(-15)), Speed / Animation_Speed) | |
4420 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.65 + 0.15 * COS(SINE / 12) - 0.05 * COS(SINE / 12), -0.2) * ANGLES(RAD(125), RAD(0), RAD(25)) * RIGHTSHOULDERC0, Speed / Animation_Speed) | |
4421 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.25, 0.5 + 0.15 * COS(SINE / 12) - 0.05 * COS(SINE / 12), 0.5) * ANGLES(RAD(-45), RAD(0), RAD(45)) * LEFTSHOULDERC0, Speed / Animation_Speed) | |
4422 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -0.5, -0.5) * ANGLES(RAD(0), RAD(65), RAD(0)) * ANGLES(RAD(-3), RAD(0), RAD(-15)), Speed / Animation_Speed) | |
4423 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1, -0.01) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), Speed / Animation_Speed) | |
4424 | end | |
4425 | elseif WhichPose == "Taunt" then | |
4426 | for i=0, Time, 0.1 / Animation_Speed do | |
4427 | Swait() | |
4428 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(0), RAD(0), RAD(0)), Speed / Animation_Speed) | |
4429 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(-5 - 6.5 * SIN(SINE / 12)), RAD(0), RAD(0)), Speed / Animation_Speed) | |
4430 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.25, 0.5 + 0.15 * COS(SINE / 12) - 0.05 * COS(SINE / 12), -0.5) * ANGLES(RAD(175), RAD(0), RAD(-35)) * RIGHTSHOULDERC0, Speed / Animation_Speed) | |
4431 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.25, 0.5 + 0.15 * COS(SINE / 12) - 0.05 * COS(SINE / 12), 0.5) * ANGLES(RAD(-45), RAD(0), RAD(45)) * LEFTSHOULDERC0, Speed / Animation_Speed) | |
4432 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -0.5, -0.5) * ANGLES(RAD(0), RAD(65), RAD(0)) * ANGLES(RAD(-3), RAD(0), RAD(-15)), Speed / Animation_Speed) | |
4433 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1, -0.01) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), Speed / Animation_Speed) | |
4434 | end | |
4435 | HATWELD.Part0 = RightArm | |
4436 | HATWELD.C0 = CF(0,-1.1,-0.4) * ANGLES(RAD(0), RAD(0), RAD(180)) * ANGLES(RAD(-20), RAD(0), RAD(0)) | |
4437 | CreateSound(221057812,Torso,10,1,false) | |
4438 | for i=0, Time*2, 0.1 / Animation_Speed do | |
4439 | Swait() | |
4440 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(0), RAD(0), RAD(0)), Speed / Animation_Speed) | |
4441 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(35 - 6.5 * SIN(SINE / 12)), RAD(0), RAD(0)), Speed / Animation_Speed) | |
4442 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.25, 0.5 + 0.15 * COS(SINE / 12) - 0.05 * COS(SINE / 12), 0.5) * ANGLES(RAD(145), RAD(0), RAD(45)) * RIGHTSHOULDERC0, Speed / Animation_Speed) | |
4443 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.25, 0.5 + 0.15 * COS(SINE / 12) - 0.05 * COS(SINE / 12), 0.5) * ANGLES(RAD(5), RAD(25), RAD(-15)) * LEFTSHOULDERC0, Speed / Animation_Speed) | |
4444 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -0.5, -0.5) * ANGLES(RAD(0), RAD(65), RAD(0)) * ANGLES(RAD(-3), RAD(0), RAD(-15)), Speed / Animation_Speed) | |
4445 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1, -0.01) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), Speed / Animation_Speed) | |
4446 | end | |
4447 | for i=0, Time, 0.1 / Animation_Speed do | |
4448 | Swait() | |
4449 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(0), RAD(0), RAD(0)), Speed / Animation_Speed) | |
4450 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(5), RAD(0), RAD(0)), Speed / Animation_Speed) | |
4451 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.35, 0.65, -0.5) * ANGLES(RAD(175), RAD(0), RAD(-35)) * RIGHTSHOULDERC0, Speed / Animation_Speed) | |
4452 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.25, 0.5 + 0.15 * COS(SINE / 12) - 0.05 * COS(SINE / 12), 0.5) * ANGLES(RAD(-45), RAD(0), RAD(45)) * LEFTSHOULDERC0, Speed / Animation_Speed) | |
4453 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -0.5, -0.5) * ANGLES(RAD(0), RAD(65), RAD(0)) * ANGLES(RAD(-3), RAD(0), RAD(-15)), Speed / Animation_Speed) | |
4454 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1, -0.01) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), Speed / Animation_Speed) | |
4455 | HATWELD.C0 = Clerp(HATWELD.C0, CF(-0.5,-1.2,-0.3) * ANGLES(RAD(0), RAD(0), RAD(180)) * ANGLES(RAD(35), RAD(0), RAD(35)), Speed / Animation_Speed) | |
4456 | end | |
4457 | HATWELD.Part0 = Head | |
4458 | HATWELD.C0 = CF(0,0.35,0) | |
4459 | elseif WhichPose == "Prepare key" then | |
4460 | for i=0, Time, 0.1 / Animation_Speed do | |
4461 | Swait() | |
4462 | if Gyro ~= nil and Gyro ~= false then | |
4463 | Gyro.cframe = CF(RootPart.Position,Tors.Position) | |
4464 | end | |
4465 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(0), RAD(0), RAD(65)), Speed / Animation_Speed) | |
4466 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(5 - 6.5 * SIN(SINE / 12)), RAD(0), RAD(-65)), Speed / Animation_Speed) | |
4467 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5 + 0.15 * COS(SINE / 12) - 0.05 * COS(SINE / 12), -0.25) * ANGLES(RAD(90), RAD(0), RAD(65)) * RIGHTSHOULDERC0, Speed / Animation_Speed) | |
4468 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.25, 0.5 + 0.15 * COS(SINE / 12) - 0.05 * COS(SINE / 12), 0.5) * ANGLES(RAD(-45), RAD(0), RAD(45)) * LEFTSHOULDERC0, Speed / Animation_Speed) | |
4469 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -0.5, -0.5) * ANGLES(RAD(0), RAD(65), RAD(0)) * ANGLES(RAD(-3), RAD(0), RAD(-15)), Speed / Animation_Speed) | |
4470 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1, -0.01) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), Speed / Animation_Speed) | |
4471 | end | |
4472 | elseif WhichPose == "Turn key" then | |
4473 | for i=0, Time, 0.1 / Animation_Speed do | |
4474 | Swait() | |
4475 | if Gyro ~= nil and Gyro ~= false then | |
4476 | Gyro.cframe = CF(RootPart.Position,Tors.Position) | |
4477 | end | |
4478 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(0), RAD(0), RAD(75)), Speed / Animation_Speed) | |
4479 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(5 - 6.5 * SIN(SINE / 12)), RAD(0), RAD(-75)), Speed / Animation_Speed) | |
4480 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5 + 0.15 * COS(SINE / 12) - 0.05 * COS(SINE / 12), -0.25) * ANGLES(RAD(90), RAD(0), RAD(75)) * ANGLES(RAD(0), RAD(-90), RAD(0)) * RIGHTSHOULDERC0, Speed / Animation_Speed) | |
4481 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.25, 0.5 + 0.15 * COS(SINE / 12) - 0.05 * COS(SINE / 12), 0.5) * ANGLES(RAD(-45), RAD(0), RAD(45)) * LEFTSHOULDERC0, Speed / Animation_Speed) | |
4482 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -0.5, -0.5) * ANGLES(RAD(0), RAD(65), RAD(0)) * ANGLES(RAD(-3), RAD(0), RAD(-15)), Speed / Animation_Speed) | |
4483 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1, -0.01) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), Speed / Animation_Speed) | |
4484 | end | |
4485 | end | |
4486 | PLAYMAINANIM = true | |
4487 | end | |
4488 | ||
4489 | ||
4490 | function StatLabel(CFRAME, TEXT, COLOR) | |
4491 | local STATPART = CreatePart(3, Effects, "SmoothPlastic", 0, 1, "Really black", "Effect", VT()) | |
4492 | STATPART.CFrame = CF(CFRAME.p,CFRAME.p+VT(MRANDOM(-5,5),MRANDOM(0,5),MRANDOM(-5,5))) | |
4493 | local BODYGYRO = IT("BodyGyro", STATPART) | |
4494 | game:GetService("Debris"):AddItem(STATPART ,5) | |
4495 | local BILLBOARDGUI = Instance.new("BillboardGui", STATPART) | |
4496 | BILLBOARDGUI.Adornee = STATPART | |
4497 | BILLBOARDGUI.Size = UD2(2.5, 0, 2.5 ,0) | |
4498 | BILLBOARDGUI.StudsOffset = VT(-2, 2, 0) | |
4499 | BILLBOARDGUI.AlwaysOnTop = false | |
4500 | local TEXTLABEL = Instance.new("TextLabel", BILLBOARDGUI) | |
4501 | TEXTLABEL.BackgroundTransparency = 1 | |
4502 | TEXTLABEL.Size = UD2(2.5, 0, 2.5, 0) | |
4503 | TEXTLABEL.Text = TEXT | |
4504 | TEXTLABEL.Font = SKILLFONT | |
4505 | TEXTLABEL.FontSize="Size42" | |
4506 | TEXTLABEL.TextColor3 = COLOR | |
4507 | TEXTLABEL.TextStrokeTransparency = 0 | |
4508 | TEXTLABEL.TextScaled = true | |
4509 | TEXTLABEL.TextWrapped = true | |
4510 | coroutine.resume(coroutine.create(function(THEPART, THEBODYPOSITION, THETEXTLABEL) | |
4511 | for i = 1, 50 do | |
4512 | Swait() | |
4513 | STATPART.CFrame = STATPART.CFrame * CF(0,0,-0.2) | |
4514 | TEXTLABEL.TextTransparency = TEXTLABEL.TextTransparency + (1/50) | |
4515 | TEXTLABEL.TextStrokeTransparency = TEXTLABEL.TextTransparency | |
4516 | end | |
4517 | THEPART.Parent = nil | |
4518 | end),STATPART, TEXTLABEL) | |
4519 | end | |
4520 | ||
4521 | function CreateDebreeRing(FLOOR,POSITION,SIZE,BLOCKSIZE,SWAIT) | |
4522 | if FLOOR ~= nil then | |
4523 | coroutine.resume(coroutine.create(function() | |
4524 | local PART = CreatePart(3, Effects, "Plastic", 0, 1, "Pearl", "DebreeCenter", VT(0,0,0)) | |
4525 | PART.CFrame = CF(POSITION) | |
4526 | for i = 1, 45 do | |
4527 | local RingPiece = CreatePart(3, Effects, "Plastic", 0, 0, "Pearl", "DebreePart", BLOCKSIZE) | |
4528 | RingPiece.Material = FLOOR.Material | |
4529 | RingPiece.Color = FLOOR.Color | |
4530 | RingPiece.CFrame = PART.CFrame * ANGLES(RAD(0), RAD(i*8), RAD(0)) * CF(SIZE, 0, 0) * ANGLES(RAD(MRANDOM(-360,360)),RAD(MRANDOM(-360,360)),RAD(MRANDOM(-360,360))) | |
4531 | Debris:AddItem(RingPiece,SWAIT) | |
4532 | end | |
4533 | PART:remove() | |
4534 | end)) | |
4535 | end | |
4536 | end | |
4537 | ||
4538 | function CreateFlyingDebree(FLOOR,POSITION,AMOUNT,BLOCKSIZE,SWAIT,STRENGTH) | |
4539 | if FLOOR ~= nil then | |
4540 | for i = 1, AMOUNT do | |
4541 | local DEBREE = CreatePart(3, Effects, "Neon", FLOOR.Reflectance, FLOOR.Transparency, "Peal", "Debree", BLOCKSIZE, false) | |
4542 | DEBREE.Material = FLOOR.Material | |
4543 | DEBREE.Color = FLOOR.Color | |
4544 | DEBREE.CFrame = POSITION * ANGLES(RAD(MRANDOM(-360,360)),RAD(MRANDOM(-360,360)),RAD(MRANDOM(-360,360))) | |
4545 | DEBREE.Velocity = VT(MRANDOM(-STRENGTH,STRENGTH),MRANDOM(-STRENGTH,STRENGTH),MRANDOM(-STRENGTH,STRENGTH)) | |
4546 | coroutine.resume(coroutine.create(function() | |
4547 | Swait(15) | |
4548 | DEBREE.Parent = workspace | |
4549 | DEBREE.CanCollide = true | |
4550 | Debris:AddItem(DEBREE,SWAIT) | |
4551 | end)) | |
4552 | end | |
4553 | end | |
4554 | end | |
4555 | --//=================================\\ | |
4556 | --|| DAMAGING | |
4557 | --\\=================================// | |
4558 | function ApplyDamage(Humanoid, Damage, TorsoPart) | |
4559 | local defence = Instance.new("BoolValue", Humanoid.Parent) | |
4560 | defence.Name = "HitBy" .. Player.Name | |
4561 | game:GetService("Debris"):AddItem(defence, 0.001) | |
4562 | Damage = Damage * DAMAGEMULTIPLIER | |
4563 | if Humanoid.Health ~= 0 then | |
4564 | local CritChance = MRANDOM(1, 100) | |
4565 | if Damage > Humanoid.Health then | |
4566 | Damage = math.ceil(Humanoid.Health) | |
4567 | if Damage == 0 then | |
4568 | Damage = 0.1 | |
4569 | end | |
4570 | end | |
4571 | Humanoid.Health = Humanoid.Health - Damage | |
4572 | StatLabel(TorsoPart.CFrame * CF(0, 0 + (TorsoPart.Size.z - 1), 0), Damage, C3(0, 0, 0)) | |
4573 | end | |
4574 | end | |
4575 | function ApplyAoE(POSITION, RANGE, MINDMG, MAXDMG, FLING, INSTAKILL) | |
4576 | local CHILDREN = workspace:GetDescendants() | |
4577 | for index, CHILD in pairs(CHILDREN) do | |
4578 | if CHILD.ClassName == "Model" and CHILD ~= Character then | |
4579 | local HUM = CHILD:FindFirstChildOfClass("Humanoid") | |
4580 | if HUM then | |
4581 | local TORSO = CHILD:FindFirstChild("Torso") or CHILD:FindFirstChild("UpperTorso") | |
4582 | if TORSO and RANGE >= (TORSO.Position - POSITION).Magnitude then | |
4583 | if INSTAKILL == true then | |
4584 | CHILD:BreakJoints() | |
4585 | else | |
4586 | local DMG = MRANDOM(MINDMG, MAXDMG) | |
4587 | ApplyDamage(HUM, DMG, TORSO) | |
4588 | end | |
4589 | if FLING > 0 then | |
4590 | for _, c in pairs(CHILD:GetChildren()) do | |
4591 | if c:IsA("BasePart") then | |
4592 | local bv = Instance.new("BodyVelocity") | |
4593 | bv.maxForce = Vector3.new(1000000000, 1000000000, 1000000000) | |
4594 | bv.velocity = CF(POSITION, TORSO.Position).lookVector * FLING | |
4595 | bv.Parent = c | |
4596 | Debris:AddItem(bv, 0.05) | |
4597 | end | |
4598 | end | |
4599 | end | |
4600 | end | |
4601 | end | |
4602 | end | |
4603 | end | |
4604 | end | |
4605 | function CreateNeonCircle(ATTACHPART, POSITION, SIZE, DOESSPIN, COLOR, MATERIAL, THICKNESS, WIDTH) | |
4606 | local PART = CreatePart(3, Weapon, MATERIAL, 0, 1, COLOR, "CirclePart", VT(0, 0, 0), false) | |
4607 | for i = 1, 45 do | |
4608 | local RingPiece = CreatePart(3, Weapon, MATERIAL, 0, 0, COLOR, "CirclePart", VT(THICKNESS, WIDTH, SIZE * 0.65), false) | |
4609 | local RingWeld = CreateWeldOrSnapOrMotor("Weld", RingPiece, PART, RingPiece, CF(0, 0, 0) * ANGLES(RAD(0), RAD(i * 8), RAD(0)), CF(0, 0, 0) * CF(SIZE * 4, 0, 0)) | |
4610 | end | |
4611 | local PartWeld = CreateWeldOrSnapOrMotor("Weld", ATTACHPART, PART, ATTACHPART, POSITION * ANGLES(RAD(0), RAD(0), RAD(0)), CF(0, 0, 0)) | |
4612 | coroutine.resume(coroutine.create(function() | |
4613 | if DOESSPIN == true then | |
4614 | while true do | |
4615 | wait() | |
4616 | PartWeld.C0 = Clerp(PartWeld.C0, POSITION * ANGLES(RAD(0), RAD(SINE * 2), RAD(0)), 1) | |
4617 | end | |
4618 | end | |
4619 | end)) | |
4620 | end | |
4621 | function CreateDebreeRing(FLOOR, POSITION, SIZE, BLOCKSIZE, SWAIT) | |
4622 | if FLOOR ~= nil then | |
4623 | coroutine.resume(coroutine.create(function() | |
4624 | local PART = CreatePart(3, Effects, "Plastic", 0, 1, "Pearl", "DebreeCenter", VT(0, 0, 0)) | |
4625 | PART.CFrame = CF(POSITION) | |
4626 | for i = 1, 45 do | |
4627 | local RingPiece = CreatePart(3, Effects, "Plastic", 0, 0, "Pearl", "DebreePart", BLOCKSIZE) | |
4628 | RingPiece.Material = FLOOR.Material | |
4629 | RingPiece.Color = FLOOR.Color | |
4630 | RingPiece.CFrame = PART.CFrame * ANGLES(RAD(0), RAD(i * 8), RAD(0)) * CF(SIZE * 4, 0, 0) * ANGLES(RAD(MRANDOM(-360, 360)), RAD(MRANDOM(-360, 360)), RAD(MRANDOM(-360, 360))) | |
4631 | Debris:AddItem(RingPiece, SWAIT) | |
4632 | end | |
4633 | PART:remove() | |
4634 | end)) | |
4635 | end | |
4636 | end | |
4637 | function CreateFlyingDebree(FLOOR, POSITION, AMOUNT, BLOCKSIZE, SWAIT, STRENGTH) | |
4638 | if FLOOR ~= nil then | |
4639 | for i = 1, AMOUNT do | |
4640 | do | |
4641 | local DEBREE = CreatePart(3, Effects, "Neon", FLOOR.Reflectance, FLOOR.Transparency, "Peal", "Debree", BLOCKSIZE, false) | |
4642 | DEBREE.Material = FLOOR.Material | |
4643 | DEBREE.Color = FLOOR.Color | |
4644 | DEBREE.CFrame = POSITION * ANGLES(RAD(MRANDOM(-360, 360)), RAD(MRANDOM(-360, 360)), RAD(MRANDOM(-360, 360))) | |
4645 | DEBREE.Velocity = VT(MRANDOM(-STRENGTH, STRENGTH), MRANDOM(-STRENGTH, STRENGTH), MRANDOM(-STRENGTH, STRENGTH)) | |
4646 | coroutine.resume(coroutine.create(function() | |
4647 | Swait(15) | |
4648 | DEBREE.Parent = workspace | |
4649 | DEBREE.CanCollide = true | |
4650 | Debris:AddItem(DEBREE, SWAIT) | |
4651 | end)) | |
4652 | end | |
4653 | end | |
4654 | end | |
4655 | end | |
4656 | function ApplyAoE(POSITION,RANGE,FLING,BURN) | |
4657 | local CHILDREN = workspace:GetDescendants() | |
4658 | for index, CHILD in pairs(CHILDREN) do | |
4659 | if CHILD.ClassName == "Model" and CHILD ~= Character then | |
4660 | local HUM = CHILD:FindFirstChildOfClass("Humanoid") | |
4661 | if HUM then | |
4662 | local TORSO = CHILD:FindFirstChild("Torso") or CHILD:FindFirstChild("UpperTorso") | |
4663 | if TORSO then | |
4664 | if HUM.Health > 0 and (TORSO.Position - POSITION).Magnitude <= RANGE then | |
4665 | CHILD:BreakJoints() | |
4666 | if FLING ~= 0 then | |
4667 | for _, c in pairs(CHILD:GetChildren()) do | |
4668 | if c:IsA("BasePart") and c.Transparency == 0 then | |
4669 | if BURN == true then | |
4670 | Fire(c) | |
4671 | end | |
4672 | local bv = Instance.new("BodyVelocity") | |
4673 | bv.maxForce = Vector3.new(1e9, 1e9, 1e9) | |
4674 | bv.velocity = CF(POSITION,TORSO.Position).lookVector*FLING | |
4675 | bv.Parent = c | |
4676 | Debris:AddItem(bv,0.05) | |
4677 | end | |
4678 | end | |
4679 | end | |
4680 | end | |
4681 | end | |
4682 | end | |
4683 | end | |
4684 | end | |
4685 | end | |
4686 | ||
4687 | function SpawnMeteor(POS,SIZE,ISDEBREE,ORIPOS) | |
4688 | coroutine.resume(coroutine.create(function() | |
4689 | local METEOR = IT("Model",Effects) | |
4690 | METEOR.Name = "Meteorite" | |
4691 | local CENTER = CreatePart(3, METEOR, "Granite", 0, 0, "Really black", "MeteorCenter", VT(5,5,5)*SIZE) | |
4692 | METEOR.PrimaryPart = CENTER | |
4693 | local PRT = CreatePart(3, METEOR, "Granite", 0, 0, "Really black", "MeteorCenter", VT(5,5,5)*SIZE) | |
4694 | PRT.CFrame = CENTER.CFrame*ANGLES(RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360))) | |
4695 | for i = 1, 15 do | |
4696 | local FIRE = CreatePart(3, METEOR, "Neon", 0, 0, "Really black", "Fire", VT(5.1,1,5.1)*SIZE) | |
4697 | FIRE.CFrame = CENTER.CFrame*ANGLES(RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360))) | |
4698 | end | |
4699 | if ISDEBREE ~= true then | |
4700 | METEOR:SetPrimaryPartCFrame(CF(POS) * ANGLES(RAD(MRANDOM(-15,15)), RAD(0), RAD(MRANDOM(-15,15)))*CF(0,500,0) * ANGLES(RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)))) | |
4701 | else | |
4702 | METEOR:SetPrimaryPartCFrame(CF(ORIPOS,POS) * ANGLES(RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)))) | |
4703 | end | |
4704 | local IMPACT = false | |
4705 | CreateSound(463593339, CENTER, 10, 0.6) | |
4706 | if SIZE >= 3.5 then | |
4707 | for i = 1, MRANDOM(3,7) do | |
4708 | SpawnMeteor(CF(POS) * ANGLES(RAD(0), RAD(MRANDOM(0,360)), RAD(0))*CF(0,0,SIZE*12).p,SIZE/MRANDOM(4,5),true,CENTER.CFrame*ANGLES(RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)))*CF(0,0,SIZE*15).p) | |
4709 | end | |
4710 | end | |
4711 | for i = 1, 200 do | |
4712 | Swait() | |
4713 | local HITFLOOR,HITPOS = Raycast(CENTER.Position, CF(CENTER.Position,POS).lookVector, 3, Character) | |
4714 | if HITFLOOR == nil then | |
4715 | local ORI = CENTER.Orientation | |
4716 | METEOR:SetPrimaryPartCFrame(CF(HITPOS) * ANGLES(RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)))) | |
4717 | else | |
4718 | if HITFLOOR.Anchored == true then | |
4719 | CreateDebreeRing(HITFLOOR,HITPOS,30*SIZE,VT(6,6,6)*SIZE,5) | |
4720 | CreateFlyingDebree(HITFLOOR,CF(HITPOS),8,VT(4,4,4)*SIZE,5,175) | |
4721 | end | |
4722 | IMPACT = true | |
4723 | break | |
4724 | end | |
4725 | end | |
4726 | if IMPACT == true then | |
4727 | WACKYEFFECT({EffectType = "Block", Size = CENTER.Size, Size2 = VT(10,10,10)*4*SIZE, Transparency = 0, Transparency2 = 1, CFrame = CF(CENTER.Position), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = C3(0,0,0), SoundID = 130972023, SoundPitch = 1, SoundVolume = 5}) | |
4728 | WACKYEFFECT({EffectType = "Block", Size = CENTER.Size, Size2 = VT(10,10,10)*3*SIZE, Transparency = 0, Transparency2 = 1, CFrame = CF(CENTER.Position), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = C3(0,0,0), SoundID = 201858144, SoundPitch = 1, SoundVolume = 5}) | |
4729 | WACKYEFFECT({EffectType = "Sphere", Size = VT(SIZE*20,0,SIZE*20), Size2 = VT(0,SIZE*750,0), Transparency = 0, Transparency2 = 1, CFrame = CF(CENTER.Position), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = C3(0,0,0), SoundID = 130972023, SoundPitch = 1, SoundVolume = 5}) | |
4730 | ApplyAoE(CENTER.Position,30*SIZE) | |
4731 | ||
4732 | end | |
4733 | METEOR:remove() | |
4734 | end)) | |
4735 | end | |
4736 | ||
4737 | function KillChildren(Char) | |
4738 | local NewCharacter = IT("Model",Effects) | |
4739 | NewCharacter.Name = "Ow im ded ;-;" | |
4740 | for _, c in pairs(Char:GetDescendants()) do | |
4741 | if c:IsA("BasePart") and c.Transparency == 0 then | |
4742 | if c.Parent == Char then | |
4743 | getbloody(c,5) | |
4744 | end | |
4745 | c:BreakJoints() | |
4746 | c.Material = "Glass" | |
4747 | c.Color = C3(0.5,0,0) | |
4748 | c.CanCollide = true | |
4749 | c.Transparency = 0.3 | |
4750 | if c:FindFirstChildOfClass("SpecialMesh") then | |
4751 | c:FindFirstChildOfClass("SpecialMesh").TextureId = "" | |
4752 | end | |
4753 | if c.Name == "Head" then | |
4754 | c:ClearAllChildren() | |
4755 | c.Size = VT(c.Size.Y,c.Size.Y,c.Size.Y) | |
4756 | end | |
4757 | if c.ClassName == "MeshPart" then | |
4758 | c.TextureID = "" | |
4759 | end | |
4760 | if c:FindFirstChildOfClass("BodyPosition") then | |
4761 | c:FindFirstChildOfClass("BodyPosition"):remove() | |
4762 | end | |
4763 | if c:FindFirstChildOfClass("ParticleEmitter") then | |
4764 | c:FindFirstChildOfClass("ParticleEmitter"):remove() | |
4765 | end | |
4766 | c.Parent = NewCharacter | |
4767 | c.Name = "DeadPart" | |
4768 | c.Velocity = VT(MRANDOM(-45,45),MRANDOM(-45,45),MRANDOM(-45,45))/15 | |
4769 | c.RotVelocity = VT(MRANDOM(-45,45),MRANDOM(-15,85),MRANDOM(-45,45)) | |
4770 | end | |
4771 | end | |
4772 | Char:remove() | |
4773 | Debris:AddItem(NewCharacter,5) | |
4774 | end | |
4775 | ||
4776 | function Kill(Char) | |
4777 | local NewCharacter = IT("Model",Effects) | |
4778 | NewCharacter.Name = "Ow im ded ;-;" | |
4779 | for _, c in pairs(Char:GetDescendants()) do | |
4780 | if c:IsA("BasePart") and c.Transparency == 0 then | |
4781 | if c.Parent == Char then | |
4782 | getbloody(c,5) | |
4783 | end | |
4784 | c:BreakJoints() | |
4785 | c.Material = "Glass" | |
4786 | c.Color = C3(0.5,0,0) | |
4787 | c.CanCollide = true | |
4788 | c.Transparency = 0.3 | |
4789 | if c:FindFirstChildOfClass("SpecialMesh") then | |
4790 | c:FindFirstChildOfClass("SpecialMesh").TextureId = "" | |
4791 | end | |
4792 | if c.Name == "Head" then | |
4793 | c:ClearAllChildren() | |
4794 | c.Size = VT(c.Size.Y,c.Size.Y,c.Size.Y) | |
4795 | end | |
4796 | if c.ClassName == "MeshPart" then | |
4797 | c.TextureID = "" | |
4798 | end | |
4799 | if c:FindFirstChildOfClass("BodyPosition") then | |
4800 | c:FindFirstChildOfClass("BodyPosition"):remove() | |
4801 | end | |
4802 | if c:FindFirstChildOfClass("ParticleEmitter") then | |
4803 | c:FindFirstChildOfClass("ParticleEmitter"):remove() | |
4804 | end | |
4805 | c.Parent = NewCharacter | |
4806 | c.Name = "DeadPart" | |
4807 | c.Velocity = VT(MRANDOM(-45,45),MRANDOM(-45,45),MRANDOM(-45,45))/15 | |
4808 | c.RotVelocity = VT(MRANDOM(-45,45),MRANDOM(-15,85),MRANDOM(-45,45)) | |
4809 | end | |
4810 | end | |
4811 | Char:remove() | |
4812 | Debris:AddItem(NewCharacter,5) | |
4813 | end | |
4814 | ||
4815 | function ApplyAoE(POSITION,RANGE,BRUTAL) | |
4816 | local CHILDREN = workspace:GetDescendants() | |
4817 | for index, CHILD in pairs(CHILDREN) do | |
4818 | if CHILD.ClassName == "Model" and CHILD ~= Character then | |
4819 | local HUM = CHILD:FindFirstChildOfClass("Humanoid") | |
4820 | if HUM then | |
4821 | local TORSO = CHILD:FindFirstChild("Torso") or CHILD:FindFirstChild("UpperTorso") | |
4822 | if TORSO then | |
4823 | if (TORSO.Position - POSITION).Magnitude <= RANGE then | |
4824 | if BRUTAL == true then | |
4825 | Kill(CHILD) | |
4826 | else | |
4827 | CHILD:BreakJoints() | |
4828 | end | |
4829 | end | |
4830 | end | |
4831 | end | |
4832 | end | |
4833 | end | |
4834 | end | |
4835 | ||
4836 | function BulletDetection(FROM,TO,BRUTAL) | |
4837 | local AIMHIT,AIMPOS,NORMAL = CastProperRay(FROM,TO,2000,Character) | |
4838 | coroutine.resume(coroutine.create(function() | |
4839 | if AIMHIT ~= nil then | |
4840 | if AIMHIT.Parent ~= Character then | |
4841 | if AIMHIT.Parent:FindFirstChildOfClass("Humanoid") or AIMHIT.Parent.Parent:FindFirstChildOfClass("Humanoid") then | |
4842 | if AIMHIT.Parent:FindFirstChildOfClass("Humanoid") then | |
4843 | if BRUTAL == true then | |
4844 | Kill(AIMHIT.Parent) | |
4845 | else | |
4846 | getbloody(AIMHIT,15) | |
4847 | AIMHIT.Parent:BreakJoints() | |
4848 | if AIMHIT.Name == "Head" then | |
4849 | AIMHIT.Name = "HEADSHOT" | |
4850 | AIMHIT:remove() | |
4851 | end | |
4852 | end | |
4853 | else | |
4854 | if BRUTAL == true then | |
4855 | Kill(AIMHIT.Parent.Parent) | |
4856 | else | |
4857 | AIMHIT.Parent.Parent:BreakJoints() | |
4858 | end | |
4859 | end | |
4860 | end | |
4861 | end | |
4862 | end | |
4863 | end)) | |
4864 | SpawnTrail(FROM,AIMPOS) | |
4865 | return AIMHIT,AIMPOS,NORMAL | |
4866 | end | |
4867 | ||
4868 | local Weapon = nil | |
4869 | local BasePart = CreatePart(3, Weapon, "SmoothPlastic", 1, 1, "Really black", "BraceletPart", VT(1.01,0.3,1.01),false) | |
4870 | CreateWeldOrSnapOrMotor("Weld", RightArm, RightArm, BasePart, CF(0, -0.2, 0) * ANGLES(RAD(0), RAD(0), RAD(0)), CF(0, 0, 0)) | |
4871 | ||
4872 | function Charge(TIME,GYRO) | |
4873 | local SND = CreateSound(ENERGYSOUND,Torso,6,TIME,false) | |
4874 | local G = nil | |
4875 | if GYRO == true then | |
4876 | G = IT("BodyGyro",RootPart) | |
4877 | G.D = 250 | |
4878 | G.P = 200000 | |
4879 | G.MaxTorque = VT(math.huge,math.huge,math.huge) | |
4880 | end | |
4881 | for i=0, TIME, 0.1 / Animation_Speed do | |
4882 | Swait() | |
4883 | if G then | |
4884 | G.cframe = CF(RootPart.Position,Mouse.Hit.p) | |
4885 | end | |
4886 | WACKYEFFECT({TIME = 25, EffectType = "Sphere", Size = VT(1.2,1.2,1.2), Size2 = VT(0,0,0), Transparency = 0.5, Transparency2 = 1, CFrame = BasePart.CFrame, MoveToPos = BasePart.CFrame*ANGLES(RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)))*CF(0,0,-4).p, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = SKILLTEXTCOLOR, SoundID = nil, SoundPitch = nil, SoundVolume = nil}) | |
4887 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed) | |
4888 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(15 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 0.15 / Animation_Speed) | |
4889 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.25, 0.5, -0.5) * ANGLES(RAD(90), RAD(0), RAD(-45)) * RIGHTSHOULDERC0, 2 / Animation_Speed) | |
4890 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.25, 0.5, -0.5) * ANGLES(RAD(90), RAD(0), RAD(45)) * LEFTSHOULDERC0, 2 / Animation_Speed) | |
4891 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 0.15 / Animation_Speed) | |
4892 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 0.15 / Animation_Speed) | |
4893 | end | |
4894 | SND:remove() | |
4895 | if G then | |
4896 | return G | |
4897 | end | |
4898 | end | |
4899 | ||
4900 | --Lightning({Material = "Neon", FadeIn = false, Color = C3(204,0,204), Start = Torso.Position, End = Mouse.Hit.p, SegmentL = 2, Thickness = 0.1, DoesFade = false, Ignore = Character, MaxDist = 400, Branches = false, FadeTime = 15, Thicken = false}) | |
4901 | function Lightning(Table) | |
4902 | local Color = Table.Color or C3(204,0,204) | |
4903 | local StartPos = Table.Start or Torso.Position | |
4904 | local EndPos = Table.End or Mouse.Hit.p | |
4905 | local SegmentLength = Table.SegmentL or 2 | |
4906 | local Thickness = Table.Thickness or 0.1 | |
4907 | local Dissapear = Table.DoesFade or false | |
4908 | local Parent = Table.Ignore or Character | |
4909 | local MaxDist = Table.MaxDist or 400 | |
4910 | local Branches = Table.Branches or false | |
4911 | local Thicken = Table.Thicken or false | |
4912 | local FadeTime = Table.FadeTime or 15 | |
4913 | local FadeIn = Table.FadeIn or false | |
4914 | local Material = Table.Material or "Neon" | |
4915 | local HIT,HITPOS = CastProperRay(StartPos, EndPos, MaxDist, Parent) | |
4916 | local DISTANCE = math.ceil((StartPos - HITPOS).Magnitude/((SegmentLength/SegmentLength)/1.5)) | |
4917 | local LIGHTNINGMODEL = IT("Model",Effects) | |
4918 | LIGHTNINGMODEL.Name = "Lightning" | |
4919 | local LastBolt = nil | |
4920 | for E = 1, DISTANCE do | |
4921 | local ExtraSize = 0 | |
4922 | if Thicken == true then | |
4923 | ExtraSize = (DISTANCE-E)/15 | |
4924 | end | |
4925 | local TRANSPARENCY = 0 | |
4926 | if FadeIn == true then | |
4927 | TRANSPARENCY = 1-(E/(DISTANCE/1.5)) | |
4928 | if TRANSPARENCY < 0 then | |
4929 | TRANSPARENCY = 0 | |
4930 | end | |
4931 | end | |
4932 | local PART = CreatePart(3, LIGHTNINGMODEL, Material, 0, TRANSPARENCY, BRICKC("Pearl"), "LightningPart"..E, VT(Thickness+ExtraSize,SegmentLength,Thickness+ExtraSize)) | |
4933 | PART.Color = Color | |
4934 | MakeForm(PART,"Cyl") | |
4935 | if LastBolt == nil then | |
4936 | PART.CFrame = CF(StartPos,HITPOS)*ANGLES(RAD(90),RAD(0),RAD(0))*CF(0,-PART.Size.Y/2,0) | |
4937 | else | |
4938 | PART.CFrame = CF(LastBolt.CFrame*CF(0,-LastBolt.Size.Y/2,0).p,CF(HITPOS)*ANGLES(RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)))*CF(0,0,DISTANCE-E).p)*ANGLES(RAD(90),RAD(0),RAD(0))*CF(0,-PART.Size.Y/2,0) | |
4939 | end | |
4940 | LastBolt = PART | |
4941 | if Branches == true and E < (DISTANCE-5) then | |
4942 | local CHOICE = MRANDOM(1,7+((DISTANCE-E)*2)) | |
4943 | if CHOICE == 1 then | |
4944 | local LASTBRANCH = nil | |
4945 | for i = 1, MRANDOM(2,5) do | |
4946 | local ExtraSize2 = 0 | |
4947 | if Thicken == true then | |
4948 | ExtraSize = ((DISTANCE-E)/25)/i | |
4949 | end | |
4950 | local PART = CreatePart(3, LIGHTNINGMODEL, Material, 0, TRANSPARENCY, BRICKC("Pearl"), "Branch"..E.."-"..i, VT(Thickness+ExtraSize2,SegmentLength,Thickness+ExtraSize2)) | |
4951 | PART.Color = Color | |
4952 | MakeForm(PART,"Cyl") | |
4953 | if LASTBRANCH == nil then | |
4954 | PART.CFrame = CF(LastBolt.CFrame*CF(0,-LastBolt.Size.Y/2,0).p,LastBolt.CFrame*CF(0,-LastBolt.Size.Y/2,0)*ANGLES(RAD(0),RAD(0),RAD(MRANDOM(0,360)))*CF(0,Thickness*7,0)*CF(0,0,-1).p)*ANGLES(RAD(90),RAD(0),RAD(0))*CF(0,-PART.Size.Y/2,0) | |
4955 | else | |
4956 | PART.CFrame = CF(LASTBRANCH.CFrame*CF(0,-LASTBRANCH.Size.Y/2,0).p,LASTBRANCH.CFrame*CF(0,-LASTBRANCH.Size.Y/2,0)*ANGLES(RAD(0),RAD(0),RAD(MRANDOM(0,360)))*CF(0,Thickness*3,0)*CF(0,0,-1).p)*ANGLES(RAD(90),RAD(0),RAD(0))*CF(0,-PART.Size.Y/2,0) | |
4957 | end | |
4958 | LASTBRANCH = PART | |
4959 | end | |
4960 | end | |
4961 | end | |
4962 | end | |
4963 | if Dissapear == true then | |
4964 | coroutine.resume(coroutine.create(function() | |
4965 | for i = 1, FadeTime do | |
4966 | Swait() | |
4967 | for _, c in pairs(LIGHTNINGMODEL:GetChildren()) do | |
4968 | if c.ClassName == "Part" then | |
4969 | c.Transparency = c.Transparency + (i/FadeTime)/10 | |
4970 | end | |
4971 | end | |
4972 | end | |
4973 | LIGHTNINGMODEL:remove() | |
4974 | end)) | |
4975 | elseif Dissapear == false then | |
4976 | Debris:AddItem(LIGHTNINGMODEL,0.1) | |
4977 | end | |
4978 | return {Hit = HIT,Pos = HITPOS,End = LastBolt.CFrame*CF(0,0,-LastBolt.Size.Z).p,LastBolt = LastBolt,Model = LIGHTNINGMODEL} | |
4979 | end | |
4980 | ||
4981 | function killnearest(position,range,maxstrength) | |
4982 | for i,v in ipairs(workspace:GetChildren()) do | |
4983 | local body = v:GetChildren() | |
4984 | for part = 1, #body do | |
4985 | if((body[part].ClassName == "Part" or body[part].ClassName == "MeshPart") and v ~= Character) then | |
4986 | if(body[part].Position - position).Magnitude < range then | |
4987 | if v.ClassName == "Model" then | |
4988 | v:BreakJoints() | |
4989 | end | |
4990 | --table.insert(Effects,{body[part],"Disappear",0.02,2,2,2,2}) | |
4991 | local bv = Instance.new("BodyVelocity") | |
4992 | bv.maxForce = Vector3.new(1e9, 1e9, 1e9) | |
4993 | bv.velocity = CF(position,body[part].Position).lookVector*maxstrength | |
4994 | bv.Parent = body[part] | |
4995 | Debris:AddItem(bv,0.2) | |
4996 | end | |
4997 | end | |
4998 | end | |
4999 | if v.ClassName == "Part" then | |
5000 | if v.Anchored == false and (v.Position - position).Magnitude < range then | |
5001 | --table.insert(Effects,{v,"Disappear",0.02,2,2,2,2}) | |
5002 | v.Velocity = CFrame.new(position,v.Position).lookVector*5*maxstrength | |
5003 | end | |
5004 | end | |
5005 | end | |
5006 | end | |
5007 | ||
5008 | function ApplyDamage(Humanoid,Damage,TorsoPart) | |
5009 | local defence = Instance.new("BoolValue",Humanoid.Parent) | |
5010 | defence.Name = ("HitBy"..Player.Name) | |
5011 | game:GetService("Debris"):AddItem(defence, 0.001) | |
5012 | Damage = Damage * DAMAGEMULTIPLIER | |
5013 | if Humanoid.Health ~= 0 then | |
5014 | local CritChance = MRANDOM(1,100) | |
5015 | if Damage > Humanoid.Health then | |
5016 | Damage = math.ceil(Humanoid.Health) | |
5017 | if Damage == 0 then | |
5018 | Damage = 0.1 | |
5019 | end | |
5020 | end | |
5021 | Humanoid.Health = Humanoid.Health - Damage | |
5022 | end | |
5023 | end | |
5024 | ||
5025 | function ApplyAoE(POSITION,RANGE,MINDMG,MAXDMG,FLING,INSTAKILL) | |
5026 | local CHILDREN = workspace:GetDescendants() | |
5027 | for index, CHILD in pairs(CHILDREN) do | |
5028 | if CHILD.ClassName == "Model" and CHILD ~= Character and CHILD.Parent ~= Effects then | |
5029 | local HUM = CHILD:FindFirstChildOfClass("Humanoid") | |
5030 | if HUM then | |
5031 | local TORSO = CHILD:FindFirstChild("Torso") or CHILD:FindFirstChild("UpperTorso") | |
5032 | if TORSO then | |
5033 | if (TORSO.Position - POSITION).Magnitude <= RANGE then | |
5034 | if INSTAKILL == true then | |
5035 | CHILD:BreakJoints() | |
5036 | else | |
5037 | local DMG = MRANDOM(MINDMG,MAXDMG) | |
5038 | ApplyDamage(HUM,DMG,TORSO) | |
5039 | end | |
5040 | if FLING > 0 then | |
5041 | for _, c in pairs(CHILD:GetChildren()) do | |
5042 | if c:IsA("BasePart") then | |
5043 | local bv = Instance.new("BodyVelocity") | |
5044 | bv.maxForce = Vector3.new(1e9, 1e9, 1e9) | |
5045 | bv.velocity = CF(POSITION,TORSO.Position).lookVector*FLING | |
5046 | bv.Parent = c | |
5047 | Debris:AddItem(bv,0.05) | |
5048 | end | |
5049 | end | |
5050 | end | |
5051 | end | |
5052 | end | |
5053 | end | |
5054 | end | |
5055 | end | |
5056 | end | |
5057 | ||
5058 | ||
5059 | ||
5060 | function AOEFunction(where,range,callback) | |
5061 | for _,v in next, getRegion(where,range,{Char}) do | |
5062 | if(v.Parent and v.Parent:FindFirstChildOfClass'Humanoid')then | |
5063 | callback(v.Parent) | |
5064 | end | |
5065 | end | |
5066 | end | |
5067 | function KillChildren(v) | |
5068 | v:BreakJoints() | |
5069 | for _, c in pairs(v:GetChildren()) do | |
5070 | if c:IsA("BasePart") then | |
5071 | if c.Transparency < 1 then | |
5072 | if c:FindFirstChildOfClass("Decal") then | |
5073 | c:FindFirstChildOfClass("Decal"):remove() | |
5074 | end | |
5075 | particles(c) | |
5076 | c.PE.Enabled = true | |
5077 | c.Parent = Effects | |
5078 | c.CanCollide = false | |
5079 | c.Material = "Neon" | |
5080 | c.Color = C3(1,1,1) | |
5081 | c.Transparency = 1 | |
5082 | local grav = Instance.new("BodyPosition",c) | |
5083 | grav.P = 20000 | |
5084 | grav.maxForce = Vector3.new(math.huge,math.huge,math.huge) | |
5085 | grav.position = c.Position + VT(MRANDOM(-5,5),MRANDOM(-5,5),MRANDOM(-5,5)) | |
5086 | grav.Name = "GravityForce" | |
5087 | coroutine.resume(coroutine.create(function() | |
5088 | for i = 1, 20 do | |
5089 | Swait() | |
5090 | c.Transparency = c.Transparency + 1/20 | |
5091 | end | |
5092 | c.PE.Enabled = false | |
5093 | Debris:AddItem(c,2) | |
5094 | end)) | |
5095 | end | |
5096 | end | |
5097 | end | |
5098 | end | |
5099 | ||
5100 | function killnearest(position,range,maxstrength) | |
5101 | for i,v in ipairs(workspace:GetChildren()) do | |
5102 | local body = v:GetChildren() | |
5103 | for part = 1, #body do | |
5104 | if((body[part].ClassName == "Part" or body[part].ClassName == "MeshPart") and v ~= Character) then | |
5105 | if(body[part].Position - position).Magnitude < range then | |
5106 | if v.ClassName == "Model" then | |
5107 | v:BreakJoints() | |
5108 | end | |
5109 | --table.insert(Effects2,{body[part],"Disappear",0.02,2,2,2,2}) | |
5110 | body[part].Velocity = CFrame.new(position,body[part].Position).lookVector*5*maxstrength | |
5111 | end | |
5112 | end | |
5113 | end | |
5114 | if v.ClassName == "Part" then | |
5115 | if v.Anchored == false and (v.Position - position).Magnitude < range then | |
5116 | --table.insert(Effects2,{v,"Disappear",0.02,2,2,2,2}) | |
5117 | v.Velocity = CFrame.new(position,v.Position).lookVector*5*maxstrength | |
5118 | end | |
5119 | end | |
5120 | end | |
5121 | end | |
5122 | ||
5123 | function AntiTimeStop() | |
5124 | for _, c in pairs(Character:GetChildren()) do | |
5125 | if c:IsA("Part") and c ~= RootPart then | |
5126 | c.Anchored = false | |
5127 | end | |
5128 | end | |
5129 | if UNANCHOR == true then | |
5130 | RootPart.Anchored = false | |
5131 | else | |
5132 | RootPart.Anchored = true | |
5133 | end | |
5134 | end | |
5135 | ||
5136 | Humanoid.Changed:connect(function(Jump) | |
5137 | if Jump == "Jump" and (Disable_Jump == true) then | |
5138 | Humanoid.Jump = false | |
5139 | end | |
5140 | ||
5141 | ||
5142 | end) | |
5143 | --//=================================\\ | |
5144 | --|| ATTACK FUNCTIONS AND STUFF | |
5145 | --\\=================================// | |
5146 | function LavaBeam() | |
5147 | ATTACK = true | |
5148 | Rooted = false | |
5149 | VALUE2 = true | |
5150 | local GYRO = IT("BodyGyro", RootPart) | |
5151 | GYRO.D = 20 | |
5152 | GYRO.P = 4000 | |
5153 | GYRO.MaxTorque = VT(0, 40000, 0) | |
5154 | local POS = RootPart.Position + VT(0, 25, 0) | |
5155 | CreateSound("1371567007", Effects, 35, MRANDOM(9, 10) / 10) | |
5156 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0) * ANGLES(RAD(0), RAD(0), RAD(90)), 0.5 / Animation_Speed) | |
5157 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0) * ANGLES(RAD(0), RAD(0), RAD(-90)), 0.5 / Animation_Speed) | |
5158 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, 0) * ANGLES(RAD(90), RAD(0), RAD(90)) * RIGHTSHOULDERC0, 0.5 / Animation_Speed) | |
5159 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.6, 0) * ANGLES(RAD(-45), RAD(0), RAD(45)) * LEFTSHOULDERC0, 0.5 / Animation_Speed) | |
5160 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -1, 0) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 0.5 / Animation_Speed) | |
5161 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1, 0) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 0.5 / Animation_Speed) | |
5162 | coroutine.resume(coroutine.create(function() | |
5163 | local E = 0 | |
5164 | repeat | |
5165 | E = E + 5 | |
5166 | GYRO.CFrame = CF(RootPart.Position, Mouse.Hit.p) | |
5167 | Swait() | |
5168 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0) * ANGLES(RAD(0), RAD(0), RAD(90)), 0.5 / Animation_Speed) | |
5169 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0) * ANGLES(RAD(0), RAD(0), RAD(-90)), 0.5 / Animation_Speed) | |
5170 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, 0) * ANGLES(RAD(90), RAD(0), RAD(90)) * RIGHTSHOULDERC0, 0.5 / Animation_Speed) | |
5171 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.6, 0) * ANGLES(RAD(-45), RAD(0), RAD(45)) * LEFTSHOULDERC0, 0.5 / Animation_Speed) | |
5172 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -1, 0) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 0.5 / Animation_Speed) | |
5173 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1, 0) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 0.5 / Animation_Speed) | |
5174 | until ATTACK == false | |
5175 | GYRO:remove() | |
5176 | end)) | |
5177 | for i = 1, 50 do | |
5178 | Swait() | |
5179 | end | |
5180 | for i = 1, 25 do | |
5181 | Swait() | |
5182 | WACKYEFFECT({ | |
5183 | Time = 15, | |
5184 | EffectType = "Skull", | |
5185 | Size = VT(4, 4, 4), | |
5186 | Size2 = VT(0, 0, 0), | |
5187 | Transparency = 1, | |
5188 | Transparency2 = 0, | |
5189 | CFrame = CF(Eon.Position) * ANGLES(RAD(MRANDOM(0, 360)), RAD(MRANDOM(0, 360)), RAD(MRANDOM(0, 360))) * CF(0, 0, 35), | |
5190 | MoveToPos = Eon.Position, | |
5191 | RotationX = 0, | |
5192 | RotationY = 0, | |
5193 | RotationZ = 0, | |
5194 | Material = "Neon", | |
5195 | Color = C3(1, 0, 0), | |
5196 | SoundID = nil, | |
5197 | SoundPitch = nil, | |
5198 | SoundVolume = nil | |
5199 | }) | |
5200 | end | |
5201 | local LOOP = 0 | |
5202 | local BEAMO = CreatePart(3, Effects, "Neon", 0, 0, BRICKC("Really black"), "Beamo", VT(0,0,0)) | |
5203 | MakeForm(BEAMO, "Ball") | |
5204 | local BEAM = CreatePart(3, Effects, "Neon", 0, 0, BRICKC("Really red"), "Beam", VT(0, 0, 0), true) | |
5205 | MakeForm(BEAM, "Cyl") | |
5206 | repeat | |
5207 | local DISTANCE = (Eon.Position - Mouse.Hit.p).Magnitude | |
5208 | if DISTANCE < 2000 then | |
5209 | BEAMO.Size = VT(3 + 1 * COS(SINE / 4), 3 + 1 * COS(SINE / 4), 3 + 1 * COS(SINE / 4)) | |
5210 | BEAMO.CFrame = CF(Eon.Position) | |
5211 | BEAM.Size = VT(2 + 1 * COS(SINE / 4), DISTANCE, 2 + 1 * COS(SINE / 4)) | |
5212 | BEAM.CFrame = CF(Eon.Position, Mouse.Hit.p) * CF(0, 0, -DISTANCE / 2) * ANGLES(RAD(90), RAD(0), RAD(0)) | |
5213 | ApplyAoE(Mouse.Hit.p, 14,true,false) | |
5214 | WACKYEFFECT({ | |
5215 | Time = 35, | |
5216 | EffectType = "Sphere", | |
5217 | Size = VT(6 + 2 * COS(SINE / 4), 6 + 2 * COS(SINE / 4), 6 + 2 * COS(SINE / 4)) * 2, | |
5218 | Size2 = VT(5, 75, 5), | |
5219 | Transparency = 0, | |
5220 | Transparency2 = 1, | |
5221 | CFrame = CF(Mouse.Hit.p) * ANGLES(RAD(MRANDOM(0, 360)), RAD(MRANDOM(0, 360)), RAD(MRANDOM(0, 360))), | |
5222 | MoveToPos = nil, | |
5223 | RotationX = 0, | |
5224 | RotationY = 0, | |
5225 | RotationZ = 0, | |
5226 | Material = "Neon", | |
5227 | Color = C3(1, 0, 0), | |
5228 | SoundID = nil, | |
5229 | SoundPitch = MRANDOM(9, 12) / 10, | |
5230 | SoundVolume = 10 | |
5231 | }) | |
5232 | WACKYEFFECT({TIME = 25, EffectType = "Sphere", Size = VT(1.5,1.5,1.5), Size2 = VT(0,0,0), Transparency = 0.5, Transparency2 = 1, CFrame = Eon.CFrame, MoveToPos = Eon.CFrame*ANGLES(RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)))*CF(0,0,-6).p, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = SKILLTEXTCOLOR, SoundID = nil, SoundPitch = nil, SoundVolume = nil}) | |
5233 | Swait() | |
5234 | LOOP = LOOP + 1 | |
5235 | end | |
5236 | until KEYHOLD == false and LOOP >= 35 or DISTANCE >= 2000 | |
5237 | coroutine.resume(coroutine.create(function() | |
5238 | for i = 1, 15 do | |
5239 | Swait() | |
5240 | BEAM.Size = BEAM.Size - VT(0.1, 0, 0.1) | |
5241 | BEAMO.Size = BEAMO.Size - VT(0.1, 0.1, 0.1) | |
5242 | BEAM.Transparency = BEAM.Transparency + 0.06666666666666667 | |
5243 | BEAMO.Transparency = BEAMO.Transparency + 0.06666666666666667 | |
5244 | end | |
5245 | BEAM:remove() | |
5246 | BEAMO:remove() | |
5247 | end)) | |
5248 | ATTACK = false | |
5249 | Rooted = false | |
5250 | VALUE2 = false | |
5251 | end | |
5252 | function Taunt2() | |
5253 | ATTACK = true | |
5254 | Rooted = true | |
5255 | CreateSound("907330011", Head, 10, 1.1) | |
5256 | for i=0, 1, 0.1 / Animation_Speed do | |
5257 | Swait() | |
5258 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(0), RAD(0), RAD(0)), 2 / Animation_Speed) | |
5259 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(0 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 2 / Animation_Speed) | |
5260 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.15, 0.5, -0.8) * ANGLES(RAD(170), RAD(0), RAD(-30)) * RIGHTSHOULDERC0, 2 / Animation_Speed) | |
5261 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, 0) * ANGLES(RAD(0), RAD(0), RAD(-12)) * LEFTSHOULDERC0, 2 / Animation_Speed) | |
5262 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 2 / Animation_Speed) | |
5263 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 2 / Animation_Speed) | |
5264 | end | |
5265 | for i=0, 2, 0.1 / Animation_Speed do | |
5266 | Swait() | |
5267 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(0), RAD(0), RAD(0)), 2 / Animation_Speed) | |
5268 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(0 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 2 / Animation_Speed) | |
5269 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, 0) * ANGLES(RAD(75), RAD(0), RAD(0)) * RIGHTSHOULDERC0, 2 / Animation_Speed) | |
5270 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, 0) * ANGLES(RAD(0), RAD(0), RAD(-12)) * LEFTSHOULDERC0, 2 / Animation_Speed) | |
5271 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 2 / Animation_Speed) | |
5272 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 2 / Animation_Speed) | |
5273 | end | |
5274 | ATTACK = false | |
5275 | Rooted = false | |
5276 | end | |
5277 | function Extreme_Offset() | |
5278 | local HITFLOOR, HITPOS = Raycast(Mouse.Hit.p + VT(0, 1, 0), CF(Mouse.Hit.p + VT(0, 1, 0), Mouse.Hit.p - VT(0, 1, 0)).lookVector, 25, Character) | |
5279 | if HITFLOOR then | |
5280 | local ORIGINPOS = VT(RootPart.Position.X, HITPOS.Y + 8, RootPart.Position.Z) | |
5281 | CreateSound("1295446488", Torso, 5, 1) | |
5282 | for i = 1, 5 do | |
5283 | WACKYEFFECT({ | |
5284 | Time = MRANDOM(15, 35), | |
5285 | EffectType = "Round Slash", | |
5286 | Size = VT(0, 0, 0), | |
5287 | Size2 = VT(0.3, 0, 0.3), | |
5288 | Transparency = 0.5, | |
5289 | Transparency2 = 1, | |
5290 | CFrame = CF(Torso.Position) * ANGLES(RAD(MRANDOM(-25, 25)), RAD(MRANDOM(0, 360)), RAD(MRANDOM(-25, 25))), | |
5291 | MoveToPos = nil, | |
5292 | RotationX = MRANDOM(-50, 50) / 10, | |
5293 | RotationY = MRANDOM(-50, 50) / 10, | |
5294 | RotationZ = MRANDOM(-50, 50) / 10, | |
5295 | Material = "Neon", | |
5296 | Color = C3(1, 1, 1), | |
5297 | SoundID = nil, | |
5298 | SoundPitch = nil, | |
5299 | SoundVolume = nil | |
5300 | }) | |
5301 | end | |
5302 | ATTACK = true | |
5303 | Rooted = true | |
5304 | UNANCHOR = false | |
5305 | RootPart.Anchored = true | |
5306 | RootPart.CFrame = CF(HITPOS + VT(0, 8, 0), ORIGINPOS) * ANGLES(RAD(0), RAD(180), RAD(0)) | |
5307 | for i = 1, 5 do | |
5308 | WACKYEFFECT({ | |
5309 | Time = MRANDOM(15, 35), | |
5310 | EffectType = "Round Slash", | |
5311 | Size = VT(0, 0, 0), | |
5312 | Size2 = VT(0.3, 0, 0.3), | |
5313 | Transparency = 0.5, | |
5314 | Transparency2 = 1, | |
5315 | CFrame = CF(Torso.Position) * ANGLES(RAD(MRANDOM(-25, 25)), RAD(MRANDOM(0, 360)), RAD(MRANDOM(-25, 25))), | |
5316 | MoveToPos = nil, | |
5317 | RotationX = MRANDOM(-50, 50) / 10, | |
5318 | RotationY = MRANDOM(-50, 50) / 10, | |
5319 | RotationZ = MRANDOM(-50, 50) / 10, | |
5320 | Material = "Neon", | |
5321 | Color = C3(1, 1, 1), | |
5322 | SoundID = nil, | |
5323 | SoundPitch = nil, | |
5324 | SoundVolume = nil | |
5325 | }) | |
5326 | end | |
5327 | for i = 0, 0.2, 0.1 / Animation_Speed do | |
5328 | Swait() | |
5329 | RootJoint.C0 = Clerp(RootJoint.C0, ROOTC0 * CF(0, 0, 0) * ANGLES(RAD(90), RAD(0), RAD(150)), 2 / Animation_Speed) | |
5330 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0) * ANGLES(RAD(0), RAD(0), RAD(0)), 2 / Animation_Speed) | |
5331 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, 0) * ANGLES(RAD(90), RAD(0), RAD(-12)) * RIGHTSHOULDERC0, 2 / Animation_Speed) | |
5332 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, 0) * ANGLES(RAD(0), RAD(0), RAD(-12)) * LEFTSHOULDERC0, 2 / Animation_Speed) | |
5333 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -1, -0.01) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 2 / Animation_Speed) | |
5334 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -0.5, -0.5) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(-4), RAD(0), RAD(0)), 2 / Animation_Speed) | |
5335 | end | |
5336 | for i = 0, 1, 0.1 / Animation_Speed do | |
5337 | Swait() | |
5338 | RootJoint.C0 = Clerp(RootJoint.C0, ROOTC0 * CF(0, 0, 0) * ANGLES(RAD(90), RAD(0), RAD(300)), 0.02 / Animation_Speed) | |
5339 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0) * ANGLES(RAD(0), RAD(0), RAD(-45)), 0.02 / Animation_Speed) | |
5340 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, 0) * ANGLES(RAD(90), RAD(0), RAD(-12)) * RIGHTSHOULDERC0, 0.02 / Animation_Speed) | |
5341 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, 0) * ANGLES(RAD(0), RAD(0), RAD(-12)) * LEFTSHOULDERC0, 0.02 / Animation_Speed) | |
5342 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -1, -0.01) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.02 / Animation_Speed) | |
5343 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -0.5, -0.5) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(-4), RAD(0), RAD(0)), 0.02 / Animation_Speed) | |
5344 | end | |
5345 | for i = 1, 10 do | |
5346 | Swait() | |
5347 | RootPart.CFrame = RootPart.CFrame * CF(0, -0.4, 0) | |
5348 | RootJoint.C0 = Clerp(RootJoint.C0, ROOTC0 * CF(0, 0, 0) * ANGLES(RAD(90), RAD(0), RAD(300)), 1.7 / Animation_Speed) | |
5349 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0) * ANGLES(RAD(0), RAD(0), RAD(-45)), 1.7 / Animation_Speed) | |
5350 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, 0) * ANGLES(RAD(90), RAD(0), RAD(-12)) * RIGHTSHOULDERC0, 1.7 / Animation_Speed) | |
5351 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, 0) * ANGLES(RAD(0), RAD(0), RAD(-12)) * LEFTSHOULDERC0, 1.7 / Animation_Speed) | |
5352 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -1, -0.01) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 1.7 / Animation_Speed) | |
5353 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -0.5, -0.5) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(-4), RAD(0), RAD(0)), 1.7 / Animation_Speed) | |
5354 | end | |
5355 | for i = 0, 0.2, 0.1 / Animation_Speed do | |
5356 | Swait() | |
5357 | RootJoint.C0 = Clerp(RootJoint.C0, ROOTC0 * CF(0, 0, 0) * ANGLES(RAD(90), RAD(0), RAD(90)), 1.5 / Animation_Speed) | |
5358 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0) * ANGLES(RAD(0), RAD(0), RAD(-90)), 1.5 / Animation_Speed) | |
5359 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, 0) * ANGLES(RAD(0), RAD(0), RAD(90)) * RIGHTSHOULDERC0, 1.5 / Animation_Speed) | |
5360 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, 0) * ANGLES(RAD(0), RAD(0), RAD(-12)) * LEFTSHOULDERC0, 1.5 / Animation_Speed) | |
5361 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -1, -0.01) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 1.5 / Animation_Speed) | |
5362 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -0.5, -0.5) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(-4), RAD(0), RAD(0)), 1.5 / Animation_Speed) | |
5363 | end | |
5364 | local HITFLOOR, HITPOS = Raycast(RightArm.Position, CF(RightArm.Position, RightArm.Position + VT(0, -1, 0)).lookVector, 8, Character) | |
5365 | if HITFLOOR then | |
5366 | if HITFLOOR.Parent:FindFirstChildOfClass("Humanoid") then | |
5367 | local CHILDREN = HITFLOOR.Parent:GetDescendants() | |
5368 | for index, CHILD in pairs(CHILDREN) do | |
5369 | if CHILD:IsA("BasePart") and CHILD.Parent:FindFirstChildOfClass("Humanoid") then | |
5370 | for i = 1, 5 do | |
5371 | CreateFlyingDebree(CHILD, CF(CHILD.Position), 1, CHILD.Size / 2, 5, MRANDOM(15, 25)) | |
5372 | CHILD:remove() | |
5373 | end | |
5374 | end | |
5375 | end | |
5376 | local SOUNDPART = CreatePart(3, Effects, "Grass", 0, 1, "Really black", "Sound", VT(0, 0, 0)) | |
5377 | SOUNDPART.CFrame = CF(HITPOS) | |
5378 | Debris:AddItem(SOUNDPART, 5) | |
5379 | CreateSound("130972023", SOUNDPART, 6, 3) | |
5380 | CreateSound("182765513", SOUNDPART, 6, 1) | |
5381 | WACKYEFFECT({ | |
5382 | EffectType = "Ring", | |
5383 | Size = VT(0, 0, 0), | |
5384 | Size2 = VT(1, 1, 0), | |
5385 | Transparency = 0.7, | |
5386 | Transparency2 = 1, | |
5387 | CFrame = CF(HITPOS) * ANGLES(RAD(90), RAD(0), RAD(0)), | |
5388 | MoveToPos = nil, | |
5389 | RotationX = 0, | |
5390 | RotationY = 0, | |
5391 | RotationZ = 0, | |
5392 | Material = "Neon", | |
5393 | Color = C3(1, 1, 1), | |
5394 | SoundID = nil, | |
5395 | SoundPitch = nil, | |
5396 | SoundVolume = nil | |
5397 | }) | |
5398 | elseif HITFLOOR.Parent.Parent:FindFirstChildOfClass("Humanoid") then | |
5399 | local CHILDREN = HITFLOOR.Parent.Parent:GetDescendants() | |
5400 | for index, CHILD in pairs(CHILDREN) do | |
5401 | if CHILD:IsA("BasePart") and CHILD.Parent:FindFirstChildOfClass("Humanoid") then | |
5402 | for i = 1, 5 do | |
5403 | CreateFlyingDebree(CHILD, CF(CHILD.Position), 1, CHILD.Size / 2, 5, MRANDOM(15, 25)) | |
5404 | CHILD:remove() | |
5405 | end | |
5406 | end | |
5407 | end | |
5408 | local SOUNDPART = CreatePart(3, Effects, "Grass", 0, 1, "Really black", "Sound", VT(0, 0, 0)) | |
5409 | SOUNDPART.CFrame = CF(HITPOS) | |
5410 | Debris:AddItem(SOUNDPART, 5) | |
5411 | CreateSound("130972023", SOUNDPART, 6, 3) | |
5412 | CreateSound("182765513", SOUNDPART, 6, 1) | |
5413 | WACKYEFFECT({ | |
5414 | EffectType = "Ring", | |
5415 | Size = VT(0, 0, 0), | |
5416 | Size2 = VT(1, 1, 0), | |
5417 | Transparency = 0.7, | |
5418 | Transparency2 = 1, | |
5419 | CFrame = CF(HITPOS) * ANGLES(RAD(90), RAD(0), RAD(0)), | |
5420 | MoveToPos = nil, | |
5421 | RotationX = 0, | |
5422 | RotationY = 0, | |
5423 | RotationZ = 0, | |
5424 | Material = "Neon", | |
5425 | Color = C3(1, 1, 1), | |
5426 | SoundID = nil, | |
5427 | SoundPitch = nil, | |
5428 | SoundVolume = nil | |
5429 | }) | |
5430 | elseif HITFLOOR.Anchored == false then | |
5431 | if HITFLOOR.Parent ~= workspace then | |
5432 | local CHILDREN = HITFLOOR.Parent:GetDescendants() | |
5433 | for index, CHILD in pairs(CHILDREN) do | |
5434 | if CHILD:IsA("BasePart") and CHILD.Position.Y < HITPOS.Y then | |
5435 | for i = 1, 5 do | |
5436 | CreateFlyingDebree(CHILD, CF(CHILD.Position), 1, CHILD.Size / 3, 5, MRANDOM(15, 25)) | |
5437 | end | |
5438 | CHILD:remove() | |
5439 | end | |
5440 | end | |
5441 | else | |
5442 | for i = 1, 5 do | |
5443 | CreateFlyingDebree(HITFLOOR, CF(HITFLOOR.Position), 1, HITFLOOR.Size / 3, 5, MRANDOM(15, 25)) | |
5444 | end | |
5445 | HITFLOOR:remove() | |
5446 | end | |
5447 | local SOUNDPART = CreatePart(3, Effects, "Grass", 0, 1, "Really black", "Sound", VT(0, 0, 0)) | |
5448 | SOUNDPART.CFrame = CF(HITPOS) | |
5449 | Debris:AddItem(SOUNDPART, 5) | |
5450 | CreateSound("130972023", SOUNDPART, 10, 3) | |
5451 | CreateSound("178452217", SOUNDPART, 6, 1) | |
5452 | WACKYEFFECT({ | |
5453 | EffectType = "Ring", | |
5454 | Size = VT(0, 0, 0), | |
5455 | Size2 = VT(1, 1, 0), | |
5456 | Transparency = 0.7, | |
5457 | Transparency2 = 1, | |
5458 | CFrame = CF(HITPOS) * ANGLES(RAD(90), RAD(0), RAD(0)), | |
5459 | MoveToPos = nil, | |
5460 | RotationX = 0, | |
5461 | RotationY = 0, | |
5462 | RotationZ = 0, | |
5463 | Material = "Neon", | |
5464 | Color = C3(1, 1, 1), | |
5465 | SoundID = nil, | |
5466 | SoundPitch = nil, | |
5467 | SoundVolume = nil | |
5468 | }) | |
5469 | else | |
5470 | local SOUNDPART = CreatePart(3, Effects, "Grass", 0, 1, "Really black", "Sound", VT(0, 0, 0)) | |
5471 | SOUNDPART.CFrame = CF(HITPOS) | |
5472 | Debris:AddItem(SOUNDPART, 5) | |
5473 | CreateSound("130972023", SOUNDPART, 10, 1) | |
5474 | CreateSound("130972023", SOUNDPART, 6, 0.7) | |
5475 | CreateDebreeRing(HITFLOOR, HITPOS, 5, VT(5, 5, 5), 5) | |
5476 | CreateDebreeRing(HITFLOOR, HITPOS, 8, VT(8, 8, 8), 5) | |
5477 | ApplyAoE(HITPOS, 15, 45, 75, 75, false) | |
5478 | ApplyAoE(HITPOS, 25, 25, 35, 35, false) | |
5479 | for i = 1, 5 do | |
5480 | CreateFlyingDebree(HITFLOOR, CF(HITPOS), 1, VT(MRANDOM(10, 30) / 10, MRANDOM(10, 30) / 10, MRANDOM(10, 30) / 10), 5, MRANDOM(75, 150)) | |
5481 | end | |
5482 | for i = 1, 5 do | |
5483 | CreateFlyingDebree(HITFLOOR, CF(HITPOS), 1, VT(MRANDOM(10, 30) / 2, MRANDOM(10, 30) / 2, MRANDOM(10, 30) / 2), 5, MRANDOM(75, 150)) | |
5484 | end | |
5485 | end | |
5486 | end | |
5487 | for i = 0, 1.2, 0.1 / Animation_Speed do | |
5488 | Swait() | |
5489 | RootJoint.C0 = Clerp(RootJoint.C0, ROOTC0 * CF(0, 0, 0) * ANGLES(RAD(90), RAD(0), RAD(90)), 1.5 / Animation_Speed) | |
5490 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0) * ANGLES(RAD(0), RAD(0), RAD(-90)), 1.5 / Animation_Speed) | |
5491 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, 0) * ANGLES(RAD(90), RAD(0), RAD(40)) * RIGHTSHOULDERC0, 1.5 / Animation_Speed) | |
5492 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, 0) * ANGLES(RAD(0), RAD(0), RAD(-12)) * LEFTSHOULDERC0, 1.5 / Animation_Speed) | |
5493 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -1, -0.01) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 1.5 / Animation_Speed) | |
5494 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -0.5, -0.5) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(-4), RAD(0), RAD(0)), 1.5 / Animation_Speed) | |
5495 | end | |
5496 | ATTACK = false | |
5497 | Rooted = false | |
5498 | UNANCHOR = true | |
5499 | RootPart.Anchored = false | |
5500 | end | |
5501 | end | |
5502 | ||
5503 | function Taunt() | |
5504 | ATTACK = true | |
5505 | Rooted = true | |
5506 | local SOUND = CreateSound("134978657", Head, 10, 1) | |
5507 | Swait() | |
5508 | repeat | |
5509 | Swait() | |
5510 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, -0.5, -0.5) * ANGLES(RAD(-45+(SOUND.PlaybackLoudness/10)), RAD(0), RAD(0)), 0.5 / Animation_Speed) | |
5511 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(-25), RAD(0), RAD(0)), 0.5 / Animation_Speed) | |
5512 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, 0) * ANGLES(RAD(-55), RAD(0), RAD(12)) * RIGHTSHOULDERC0, 0.5 / Animation_Speed) | |
5513 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, 0) * ANGLES(RAD(-55), RAD(0), RAD(-12)) * LEFTSHOULDERC0, 0.5 / Animation_Speed) | |
5514 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(-45+(SOUND.PlaybackLoudness/10)), RAD(90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 0.5 / Animation_Speed) | |
5515 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(-45+(SOUND.PlaybackLoudness/10)), RAD(-90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 0.5 / Animation_Speed) | |
5516 | until SOUND.Playing == false | |
5517 | ATTACK = false | |
5518 | Rooted = false | |
5519 | end | |
5520 | ||
5521 | local SIZE = 1 | |
5522 | function Black_Flames() | |
5523 | ATTACK = true | |
5524 | Rooted = true | |
5525 | for i=0, 1, 0.1 / Animation_Speed do | |
5526 | Swait() | |
5527 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0 * SIZE, 0 * SIZE, 0 * SIZE + 0.05 * COS(SINE / 12) * SIZE) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed) | |
5528 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(-25 + 4.5 * SIN(SINE / 12)), RAD(25), RAD(-15 - 2.5 * SIN(SINE / 12))), 1 / Animation_Speed) | |
5529 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.25, 1.5 + 0.25 * COS(SINE / 12), 0) * ANGLES(RAD(170), RAD(0 - 7.5 * SIN(SINE / 12)), RAD(-12 + 7.5 * SIN(SINE / 12))) * RIGHTSHOULDERC0, 1 / Animation_Speed) | |
5530 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5 + 0.25 * COS(SINE / 12), 0) * ANGLES(RAD(0), RAD(0 + 7.5 * SIN(SINE / 12)), RAD(-12 - 7.5 * SIN(SINE / 12))) * LEFTSHOULDERC0, 1 / Animation_Speed) | |
5531 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -1, -0.01) * ANGLES(RAD(-7.5 * SIN(SINE / 12)), RAD(75), RAD(0)) * ANGLES(RAD(-8 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed) | |
5532 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -0.5, -0.5) * ANGLES(RAD(-7.5 * SIN(SINE / 12)), RAD(-90), RAD(0)) * ANGLES(RAD(-8 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed) | |
5533 | end | |
5534 | CreateSound("348663022", Torso, 5, 1) | |
5535 | local StartPos = RootPart.CFrame * CF(0,10,0).p | |
5536 | for i = 1, 5 do | |
5537 | MagicSphere2(50,50,CF(StartPos),"Really black") | |
5538 | Swait(15) | |
5539 | end | |
5540 | local soundeffect = IT("Sound",Torso) | |
5541 | soundeffect.SoundId = "rbxassetid://487186990" | |
5542 | soundeffect.Looped = true | |
5543 | soundeffect.Volume = 10 | |
5544 | soundeffect.Playing = true | |
5545 | repeat | |
5546 | turnto(Mouse.Hit.p) | |
5547 | MagicSphere2(25,25,CF(StartPos),"Really black") | |
5548 | MagicSphere(25/10,25,CF(StartPos),"Really black") | |
5549 | local RayHit, RayPos, RayNormal = CastZapRay(StartPos, Mouse.Hit.p, 750, Character, false) | |
5550 | local distance = (StartPos - RayPos).magnitude | |
5551 | local RayBeam = IT("Part",Effects) | |
5552 | RayBeam.Material = "Neon" | |
5553 | RayBeam.Anchored = true | |
5554 | RayBeam.BrickColor = BRICKC"Really black" | |
5555 | local mesh = IT("SpecialMesh",RayBeam) | |
5556 | mesh.MeshType = "Cylinder" | |
5557 | RayBeam.Size = Vector3.new(distance+10, 5, 5) | |
5558 | RayBeam.CFrame = CFrame.new(StartPos, RayPos) * CFrame.new(0, 0, -distance/2) * ANGLES(RAD(0),RAD(90),RAD(0)) | |
5559 | MagicSphere(65,30,CF(RayPos),"Really black") | |
5560 | killnearest(RayPos,65,100) | |
5561 | for i = 1, 3 do | |
5562 | CreateSwirl(0,65,true,-0.2,5,CF(RayPos) * ANGLES(RAD(math.random(-360,360)),RAD(math.random(-360,360)),RAD(math.random(-360,360))),"Really black") | |
5563 | end | |
5564 | Swait() | |
5565 | if KEYHOLD == false then | |
5566 | coroutine.resume(coroutine.create(function() | |
5567 | for i = 1, 5 do | |
5568 | RayBeam.Transparency = RayBeam.Transparency + 1/5 | |
5569 | Swait() | |
5570 | end | |
5571 | RayBeam:remove() | |
5572 | end)) | |
5573 | else | |
5574 | RayBeam:remove() | |
5575 | end | |
5576 | until KEYHOLD == false | |
5577 | soundeffect:remove() | |
5578 | ATTACK = false | |
5579 | Rooted = false | |
5580 | end | |
5581 | ||
5582 | local COLOR = "Really red" | |
5583 | ||
5584 | function TastyBlood() | |
5585 | if Mouse.Target.Parent ~= Character and Mouse.Target.Parent.Parent ~= Character and Mouse.Target.Parent:FindFirstChildOfClass("Humanoid") ~= nil then | |
5586 | local HUM = Mouse.Target.Parent:FindFirstChildOfClass("Humanoid") | |
5587 | local TORSO = HUM.Parent:FindFirstChild("Torso") or HUM.Parent:FindFirstChild("UpperTorso") | |
5588 | if TORSO and HUM.Health > 0 then | |
5589 | ATTACK = true | |
5590 | Rooted = true | |
5591 | local SOULSPHERE = CreatePart(3, Effects, "Neon", 0, 0, BRICKC(COLOR), "Effect", VT(0,0,0)) | |
5592 | SOULSPHERE.CFrame = CF(RootPart.Position+VT(0.2,0.2,0.2)) | |
5593 | MakeForm(SOULSPHERE,"Ball") | |
5594 | local POS = Mouse.Hit.p | |
5595 | WACKYEFFECT({Time = 25, EffectType = "Sphere", Size = VT(10,0.2,10), Size2 = VT(0,0.5,0), Transparency = 1, Transparency2 = 0, CFrame = CF(POS), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = C3(0,0,0), SoundID = nil, SoundPitch = MRANDOM(7,15)/10, SoundVolume = MRANDOM(15,30)/10}) | |
5596 | wait(0.3) | |
5597 | local SPIKE = CreatePart(3, Effects, "Fabric", 0, 0, "Maroon", "Spike", VT(8,100,8)) | |
5598 | SPIKE.Color = C3(0,0,0) | |
5599 | local MSH = IT("SpecialMesh",SPIKE) | |
5600 | MSH.MeshType = "FileMesh" | |
5601 | MSH.MeshId = "http://www.roblox.com/asset/?id=785967755" | |
5602 | MSH.Scale = SPIKE.Size/50 | |
5603 | SPIKE.CFrame = CF(POS+VT(0,15,0)) | |
5604 | Ragdoll(HUM.Parent,Torso,true) | |
5605 | WACKYEFFECT({Time = 25, EffectType = "Wave", Size = VT(0,5,0), Size2 = VT(5,1,5), Transparency = 0, Transparency2 = 1, CFrame = CF(POS), MoveToPos = nil, RotationX = 0, RotationY = 5, RotationZ = 0, Material = "Neon", Color = C3(0,0,0), SoundID = 178452241, SoundPitch = MRANDOM(7,15)/10, SoundVolume = MRANDOM(15,30)/10}) | |
5606 | WACKYEFFECT({Time = 25, EffectType = "Sphere", Size = VT(0,0,0), Size2 = VT(25,1,25), Transparency = 0, Transparency2 = 1, CFrame = CF(TORSO.Position), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = C3(0,0,0), SoundID = 1368637781, SoundPitch = 1.3, SoundVolume = 4}) | |
5607 | local grav = Instance.new("BodyPosition",TORSO) | |
5608 | grav.D = 1500 | |
5609 | grav.P = 20000 | |
5610 | grav.maxForce = Vector3.new(math.huge,math.huge,math.huge) | |
5611 | grav.position = TORSO.Position+VT(0,20,0) | |
5612 | Debris:AddItem(grav,0.50) | |
5613 | for i = 1, 14 do | |
5614 | WACKYEFFECT({Time = 25, EffectType = "Sphere", Size = VT(0,0,0), Size2 = VT(25,1,25), Transparency = 0+((i/14)-(1/14)), Transparency2 = 1, CFrame = CF(TORSO.Position), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = C3(0,0,0), SoundID = nil, SoundPitch = nil, SoundVolume = nil}) | |
5615 | for i = 1, 16 do | |
5616 | Swait() | |
5617 | SoulSteal(TORSO.Position,SOULSPHERE) | |
5618 | SPIKE.CFrame = SPIKE.CFrame*CF(0,-2,0) | |
5619 | end | |
5620 | coroutine.resume(coroutine.create(function() | |
5621 | Swait() | |
5622 | CreateSound("463598785", SOULSPHERE, 10, MRANDOM(8,12)/10) | |
5623 | MagicSphere(SOULSPHERE.Size,25,SOULSPHERE.CFrame,COLOR,SOULSPHERE.Size/50) | |
5624 | for i = 1, 50 do | |
5625 | Swait() | |
5626 | SOULSPHERE.Size = SOULSPHERE.Size * 0.9 | |
5627 | end | |
5628 | SOULSPHERE:remove() | |
5629 | wait(0.20) | |
5630 | SPIKE:remove() | |
5631 | end)) | |
5632 | end | |
5633 | ATTACK = false | |
5634 | Rooted = false | |
5635 | end | |
5636 | end | |
5637 | end | |
5638 | ||
5639 | Player_Size = 1 | |
5640 | function Absol() | |
5641 | local HITFLOOR, HITPOS, NORMAL = Raycast(RootPart.Position, CF(RootPart.Position, RootPart.Position + VT(0, -1, 0)).lookVector, 7 * Player_Size, Character) | |
5642 | if HITFLOOR ~= nil then | |
5643 | do | |
5644 | local HITBODIES = {} | |
5645 | ATTACK = true | |
5646 | Rooted = true | |
5647 | local ABSOLUTE = CreatePart(3, Effects, "Neon", 0, 1, "Really red", "ABSOLUTEUM", VT(0, 0, 0)) | |
5648 | MakeForm(ABSOLUTE, "Ball") | |
5649 | CreateSound("416200578", RootPart, 10, 1) | |
5650 | for i = 0, 8, 0.1 / Animation_Speed do | |
5651 | Swait() | |
5652 | ABSOLUTE.Size = ABSOLUTE.Size + VT(0.2, 0.2, 0.2) | |
5653 | ABSOLUTE.CFrame = RootPart.CFrame * CF(0, 5 + ABSOLUTE.Size.Y / 2, 0) | |
5654 | ABSOLUTE.Transparency = ABSOLUTE.Transparency - 0.01 | |
5655 | local CHARGE = CreatePart(3, Effects, "Neon", 0, 0, "Really red", "ABSOLUTEUM", VT(2, 2, 2)) | |
5656 | MakeForm(CHARGE, "Ball") | |
5657 | CHARGE.CFrame = CF(RootPart.Position) * CF(MRANDOM(-15, 15), -15, MRANDOM(-15, 15)) | |
5658 | FireArc(CHARGE, ABSOLUTE.Position, 45, 45, true) | |
5659 | RootJoint.C0 = Clerp(RootJoint.C0, ROOTC0 * CF(0, 0, 0 + 0.25 * COS(SINE / 12)) * ANGLES(RAD(4 + 2.5 * SIN(SINE / 12)), RAD(0), RAD(15 + 2.5 * SIN(SINE / 12))), 1 / Animation_Speed) | |
5660 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0) * ANGLES(RAD(-25 + 4.5 * SIN(SINE / 12)), RAD(25), RAD(-15 - 2.5 * SIN(SINE / 12))), 1 / Animation_Speed) | |
5661 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.25, 1.5 + 0.25 * COS(SINE / 12), 0) * ANGLES(RAD(170), RAD(0 - 7.5 * SIN(SINE / 12)), RAD(-12 + 7.5 * SIN(SINE / 12))) * RIGHTSHOULDERC0, 1 / Animation_Speed) | |
5662 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5 + 0.25 * COS(SINE / 12), 0) * ANGLES(RAD(0), RAD(0 + 7.5 * SIN(SINE / 12)), RAD(-12 - 7.5 * SIN(SINE / 12))) * LEFTSHOULDERC0, 1 / Animation_Speed) | |
5663 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -1, -0.01) * ANGLES(RAD(-7.5 * SIN(SINE / 12)), RAD(75), RAD(0)) * ANGLES(RAD(-8 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed) | |
5664 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -0.5, -0.5) * ANGLES(RAD(-7.5 * SIN(SINE / 12)), RAD(-90), RAD(0)) * ANGLES(RAD(-8 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed) | |
5665 | end | |
5666 | CreateSound(ULTTAUNTS[MRANDOM(1, #ULTTAUNTS)], Head, 10, 0.9) | |
5667 | CreateSound("160772554", ABSOLUTE, 10, MRANDOM(5, 7) / 10) | |
5668 | for i = 1, 45 do | |
5669 | Swait() | |
5670 | RootJoint.C0 = Clerp(RootJoint.C0, ROOTC0 * CF(0, 0, 0 + 0.25 * COS(SINE / 12)) * ANGLES(RAD(4 + 2.5 * SIN(SINE / 12)), RAD(0), RAD(15 + 2.5 * SIN(SINE / 12))), 1 / Animation_Speed) | |
5671 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0) * ANGLES(RAD(-25 + 4.5 * SIN(SINE / 12)), RAD(25), RAD(-15 - 2.5 * SIN(SINE / 12))), 1 / Animation_Speed) | |
5672 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.25, 1.5 + 0.25 * COS(SINE / 12), 0) * ANGLES(RAD(170), RAD(0 - 7.5 * SIN(SINE / 12)), RAD(-12 + 7.5 * SIN(SINE / 12))) * RIGHTSHOULDERC0, 1 / Animation_Speed) | |
5673 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5 + 0.25 * COS(SINE / 12), 0) * ANGLES(RAD(0), RAD(0 + 7.5 * SIN(SINE / 12)), RAD(-12 - 7.5 * SIN(SINE / 12))) * LEFTSHOULDERC0, 1 / Animation_Speed) | |
5674 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -1, -0.01) * ANGLES(RAD(-7.5 * SIN(SINE / 12)), RAD(75), RAD(0)) * ANGLES(RAD(-8 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed) | |
5675 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -0.5, -0.5) * ANGLES(RAD(-7.5 * SIN(SINE / 12)), RAD(-90), RAD(0)) * ANGLES(RAD(-8 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed) | |
5676 | end | |
5677 | coroutine.resume(coroutine.create(function() | |
5678 | local IMPACT = false | |
5679 | local BULLET = ABSOLUTE | |
5680 | MakeForm(BULLET, "Ball") | |
5681 | BULLET.CFrame = CF(BULLET.Position, Mouse.Hit.p) | |
5682 | for i = 1, 500 do | |
5683 | Swait() | |
5684 | BULLET.CFrame = BULLET.CFrame * CF(0, 0, -2) | |
5685 | local HIT = Raycast(BULLET.Position, BULLET.CFrame.lookVector, BULLET.Size.X / 2, Character) | |
5686 | MagicSphere(VT(10, 10, 10), 55, CF(BULLET.CFrame * CF(MRANDOM(-BULLET.Size.X / 2.5, BULLET.Size.X / 2.5), MRANDOM(-BULLET.Size.X / 2.5, BULLET.Size.X / 2.5), MRANDOM(-BULLET.Size.X / 2.5, BULLET.Size.X / 2.5)).p), "Really red", VT(-10, -10, -10) / 55) | |
5687 | if HIT ~= nil then | |
5688 | IMPACT = true | |
5689 | break | |
5690 | end | |
5691 | end | |
5692 | if IMPACT == false then | |
5693 | for i = 1, 40 do | |
5694 | Swait() | |
5695 | BULLET.Size = BULLET.Size * 0.9 | |
5696 | end | |
5697 | BULLET:remove() | |
5698 | else | |
5699 | CreateSound("1127492102", BULLET, 10, MRANDOM(8, 13) / 10) | |
5700 | for i = 1, 175 do | |
5701 | Swait() | |
5702 | BULLET.Size = BULLET.Size * 0.99 | |
5703 | Slice("Round", 0, 35, CF(BULLET.Position) * ANGLES(RAD(MRANDOM(-18, 18)), RAD(MRANDOM(-180, 180)), RAD(MRANDOM(-18, 18))), "Black", VT(i, 0, i) / 85) | |
5704 | end | |
5705 | CreateSound("438666001", BULLET, 10, 3) | |
5706 | Swait(35) | |
5707 | BULLET.Transparency = 1 | |
5708 | for i = 1, 20 do | |
5709 | for e = 1, 5 do | |
5710 | MagicSphere(VT(0.2, 0.2, 0.2), 50, CF(BULLET.CFrame * CF(MRANDOM(-5, 5), MRANDOM(-5, 5), MRANDOM(-5, 5)).p, BULLET.Position), "Really black", VT(1, 1, i * 4), 0) | |
5711 | Slice("Round", 0, 35, CF(BULLET.Position) * ANGLES(RAD(MRANDOM(-18, 18)), RAD(MRANDOM(-180, 180)), RAD(MRANDOM(-18, 18))), "Really red", VT(i, 0, i) / 3) | |
5712 | end | |
5713 | AddChildrenToTable(BULLET.Position, workspace, i * 25, HITBODIES) | |
5714 | CreateSound("178452241", BULLET, 10, MRANDOM(8, 13) / 10) | |
5715 | CreateSound("178452243", BULLET, 10, MRANDOM(8, 13) / 10) | |
5716 | MagicSphere(BULLET.Size, 35, BULLET.CFrame, C3(MRANDOM(0, 10) / 10, 0, 0), VT(i, i, i) * 2) | |
5717 | Swait(5) | |
5718 | for e = 1, #HITBODIES do | |
5719 | if HITBODIES[e] ~= nil then | |
5720 | local BOD = HITBODIES[e] | |
5721 | local TORS = BOD:FindFirstChild("Torso") or BOD:FindFirstChild("UpperTorso") | |
5722 | if TORS then | |
5723 | BOD:BreakJoints() | |
5724 | for _, c in pairs(BOD:GetChildren()) do | |
5725 | if c.ClassName == "Part" or c.ClassName == "MeshPart" then | |
5726 | local bv = Instance.new("BodyVelocity") | |
5727 | bv.maxForce = Vector3.new(1000000000, 1000000000, 1000000000) | |
5728 | bv.velocity = CF(BULLET.Position, c.Position).lookVector * 250 | |
5729 | bv.Parent = c | |
5730 | Debris:AddItem(bv, 0.2) | |
5731 | end | |
5732 | end | |
5733 | end | |
5734 | end | |
5735 | end | |
5736 | CreateWave(VT(0, 2, 0), 75, CF(BULLET.Position), true, -15, "Really black", VT(i, 0, i) * 2) | |
5737 | end | |
5738 | MagicSphere(BULLET.Size, 100, BULLET.CFrame, C3(0, 0, 150), VT(12, 12, 12)) | |
5739 | Debris:AddItem(BULLET, 10) | |
5740 | end | |
5741 | end)) | |
5742 | ATTACK = false | |
5743 | Rooted = false | |
5744 | end | |
5745 | end | |
5746 | end | |
5747 | ||
5748 | function findNearestTorso(pos) | |
5749 | local list = game.Workspace:children() | |
5750 | local torso = nil | |
5751 | local dist = 1000 | |
5752 | local temp = nil | |
5753 | local human = nil | |
5754 | local temp2 = nil | |
5755 | for x = 1, #list do | |
5756 | temp2 = list[x] | |
5757 | if (temp2.className == "Model") and (temp2 ~= Character) and (temp2 ~= pos.Parent) then | |
5758 | temp = temp2:findFirstChild("Torso") or temp2:findFirstChild("UpperTorso") | |
5759 | human = temp2:findFirstChildOfClass("Humanoid") | |
5760 | if (temp ~= nil) and (human ~= nil) and (human.Health > 0) then | |
5761 | if (temp.Position - pos.Position).magnitude < dist then | |
5762 | torso = temp | |
5763 | dist = (temp.Position - pos.Position).magnitude | |
5764 | end | |
5765 | end | |
5766 | end | |
5767 | end | |
5768 | return torso,dist | |
5769 | end | |
5770 | ||
5771 | function LavaAura() | |
5772 | ATTACK = true | |
5773 | Rooted = true | |
5774 | CHOSENBRICK = "Really red" | |
5775 | CreateSound("214954135", Effects, 35, MRANDOM(9, 10) / 10) | |
5776 | for i=0, 2, 0.1 / Animation_Speed do | |
5777 | Swait() | |
5778 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0) * ANGLES(RAD(-15), RAD(0), RAD(0)), 0.5 / Animation_Speed) | |
5779 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(15), RAD(0), RAD(0)), 0.5 / Animation_Speed) | |
5780 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, 0) * ANGLES(RAD(-5), RAD(180), RAD(-145)) * RIGHTSHOULDERC0, 0.5 / Animation_Speed) | |
5781 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, 0) * ANGLES(RAD(-5), RAD(180), RAD(145)) * LEFTSHOULDERC0, 0.5 / Animation_Speed) | |
5782 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -1, -0.01) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(-15)), 0.5 / Animation_Speed) | |
5783 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1, -0.01) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(15)), 0.5 / Animation_Speed) | |
5784 | end | |
5785 | ATTACK = false | |
5786 | Rooted = false | |
5787 | VALUE2 = true | |
5788 | for i = 15, 35 do | |
5789 | for i = 15, 45 do | |
5790 | Swait() | |
5791 | Slice("Round",15,40,RootPart.CFrame*CF(0,MRANDOM(-15,15),0)*ANGLES(RAD(MRANDOM(-180,180)),RAD(MRANDOM(-180,180)),RAD(MRANDOM(-180,180))),"Really red",VT(0.1,0,0.1)) | |
5792 | MagicSphere(VT(0, 0, 0), 40, Eon.CFrame*CF(0,MRANDOM(-0,0),0)*ANGLES(RAD(MRANDOM(-180,180)),RAD(MRANDOM(-180,180)),RAD(MRANDOM(-180,180))), C3(0.5, 0.5, 1), VT(1, 0.1, 0.1)) | |
5793 | end | |
5794 | Freeze(Torso.Position,45) | |
5795 | for i = 15, 35 do | |
5796 | Slice("Thin",15,40,RootPart.CFrame*CF(0,MRANDOM(-15,15),0)*ANGLES(RAD(MRANDOM(-15,15)),RAD(MRANDOM(-180,180)),RAD(MRANDOM(-15,15))),"Really red",VT(0.1,0,0.1)) | |
5797 | end | |
5798 | end | |
5799 | VALUE2 = false | |
5800 | CHOSENBRICK = "Really red" | |
5801 | end | |
5802 | ||
5803 | function Strike() | |
5804 | local HITBODIES = {} | |
5805 | local CENTER = CreatePart(3, Effects, "SmoothPlastic", 0, 1, "Lime green", "CenterPart", VT(0,0,0)) | |
5806 | local HITFLOOR,ECH,NORMAL = Raycast(Mouse.Hit.p+VT(0,2,0), (CF(Mouse.Hit.p, Mouse.Hit.p + VT(0, -1, 0))).lookVector, 10000000, Character) | |
5807 | CENTER.CFrame = CF(ECH) | |
5808 | local RAY = CreatePart(3, Effects, "Neon", 0, 1, "Really black", "Laser01", VT(25,99999,25)) | |
5809 | RAY.Color = C3(255,0,0) | |
5810 | MakeForm(RAY,"Cyl") | |
5811 | RAY.CFrame = CF(ECH) | |
5812 | for i = 1, 75 do | |
5813 | Swait() | |
5814 | RAY.Transparency = RAY.Transparency - 1/75 | |
5815 | RAY.Size = RAY.Size - VT(25/75,0,25/75) | |
5816 | MagicSphere(VT(1,1,1),15,CF(ECH)*CF(MRANDOM(-15,15),MRANDOM(0,100),MRANDOM(-15,15)),C3(1,1,1),VT(0,0,0)) | |
5817 | end | |
5818 | ApplyAoE2(ECH,25,25) | |
5819 | MagicSphere(VT(0,0,0),55,CF(ECH),C3(255,0,0),VT(2,2,2)) | |
5820 | for i = 1, 25 do | |
5821 | MagicSphere(VT(1,1,1),i*3,CF(ECH)*CF(MRANDOM(-45,45),MRANDOM(-45,45),MRANDOM(-45,45)),C3(1,1,1),VT(0,0,0)) | |
5822 | end | |
5823 | CreateSound("168586621", CENTER, 10, 0.8) | |
5824 | RAY:remove() | |
5825 | Debris:AddItem(CENTER,5) | |
5826 | end | |
5827 | ||
5828 | function Click() | |
5829 | ATTACK = true | |
5830 | Rooted = false | |
5831 | local HIT = nil | |
5832 | OFFSET = -45 | |
5833 | for i=0, 1, 0.1 / Animation_Speed do | |
5834 | Swait() | |
5835 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(5 - 2.5), RAD(0), RAD(45)), 0.15 / Animation_Speed) | |
5836 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, 0.5) * ANGLES(RAD(90), RAD(0), RAD(12)) * RIGHTSHOULDERC0, 2 / Animation_Speed) | |
5837 | end | |
5838 | OFFSET = 45 | |
5839 | local PUNCH = CreatePart(3, Effects, "Granite", 0, 1, "Really black", "Hit", VT(0.7,0.7,0.7),false) | |
5840 | PUNCH.CanCollide = true | |
5841 | CreateWeldOrSnapOrMotor("Weld", RightArm, RightArm, PUNCH, CF(0,-1,0), CF(0, 0, 0)) | |
5842 | TAUNT = true | |
5843 | local TOUCH = PUNCH.Touched:Connect(function(hit) | |
5844 | if hit.Parent:FindFirstChildOfClass("Humanoid") then | |
5845 | HIT = hit.Parent | |
5846 | end | |
5847 | end) | |
5848 | for i=0, 0.3, 0.1 / Animation_Speed do | |
5849 | Swait() | |
5850 | RootPart.CFrame = RootPart.CFrame*CF(0,0,-0.3) | |
5851 | if HIT ~= nil then | |
5852 | break | |
5853 | end | |
5854 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(5 - 2.5), RAD(0), RAD(-45)), 0.15 / Animation_Speed) | |
5855 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.45, 0.5, -0.75) * ANGLES(RAD(90), RAD(0), RAD(35)) * RIGHTSHOULDERC0, 2 / Animation_Speed) | |
5856 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, 0) * ANGLES(RAD(0), RAD(45), RAD(-12)) * ANGLES(RAD(-35), RAD(0), RAD(0)) * LEFTSHOULDERC0, 2 / Animation_Speed) | |
5857 | end | |
5858 | PUNCH:remove() | |
5859 | TOUCH:disconnect() | |
5860 | if HIT ~= nil then | |
5861 | for _, c in pairs(HIT:GetChildren()) do | |
5862 | if c:IsA("BasePart") then | |
5863 | c.Anchored = true | |
5864 | end | |
5865 | end | |
5866 | Rooted = true | |
5867 | CreateSound(649634100, Torso, 10, 0.8) | |
5868 | CreateSound(1368573150, RightArm, 3, 1.5) | |
5869 | for i=0, 0.6, 0.1 / Animation_Speed do | |
5870 | Swait() | |
5871 | WACKYEFFECT({EffectType = "Block", Size = VT(3,3,3)/3, Size2 = VT(1,1,1)/3, Transparency = 0.5, Transparency2 = 1, CFrame = RightArm.CFrame*CF(0,-1.3,0), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = C3(1,1,1), SoundID = nil, SoundPitch = 1, SoundVolume = 5}) | |
5872 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(5 - 2.5), RAD(25), RAD(-45)), 0.05 / Animation_Speed) | |
5873 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.45, 0.5, -0.75) * ANGLES(RAD(90), RAD(0), RAD(35)) * RIGHTSHOULDERC0, 2 / Animation_Speed) | |
5874 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, 0) * ANGLES(RAD(0), RAD(45), RAD(-12)) * ANGLES(RAD(-35), RAD(0), RAD(0)) * LEFTSHOULDERC0, 2 / Animation_Speed) | |
5875 | end | |
5876 | for _, c in pairs(HIT:GetChildren()) do | |
5877 | if c:IsA("BasePart") then | |
5878 | c.Anchored = false | |
5879 | end | |
5880 | end | |
5881 | KillChildren(HIT) | |
5882 | end | |
5883 | OFFSET = 0 | |
5884 | ATTACK = false | |
5885 | Rooted = false | |
5886 | TAUNT = false | |
5887 | end | |
5888 | function LimbRip() | |
5889 | ATTACK = true | |
5890 | Rooted = false | |
5891 | local TARGET = nil | |
5892 | local ROOT = nil | |
5893 | local HUMAN = nil | |
5894 | local DIST = 4 | |
5895 | Speed = 12 | |
5896 | for i=0, 1, 0.1 / Animation_Speed do | |
5897 | Swait() | |
5898 | local CHILDREN = workspace:GetDescendants() | |
5899 | for index, CHILD in pairs(CHILDREN) do | |
5900 | if CHILD.ClassName == "Model" and CHILD ~= Character then | |
5901 | local HUM = CHILD:FindFirstChildOfClass("Humanoid") | |
5902 | if HUM then | |
5903 | local TORSO = CHILD:FindFirstChild("HumanoidRootPart") or CHILD:FindFirstChild("Torso") or CHILD:FindFirstChild("UpperTorso") | |
5904 | if TORSO and HUM.Health > 0 then | |
5905 | if (TORSO.Position - RightArm.Position).Magnitude <= DIST then | |
5906 | DIST = (TORSO.Position - RightArm.Position).Magnitude | |
5907 | ROOT = TORSO | |
5908 | HUMAN = HUM | |
5909 | TARGET = CHILD:FindFirstChild("Torso") or CHILD:FindFirstChild("UpperTorso") | |
5910 | end | |
5911 | end | |
5912 | end | |
5913 | end | |
5914 | end | |
5915 | if ROOT then | |
5916 | break | |
5917 | end | |
5918 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0) * ANGLES(RAD(0), RAD(0), RAD(45)), 1 / Animation_Speed) | |
5919 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(10), RAD(0), RAD(-25)), 1 / Animation_Speed) | |
5920 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.35, 0.5, -0.4) * ANGLES(RAD(90), RAD(0), RAD(45)) * RIGHTSHOULDERC0, 1 / Animation_Speed) | |
5921 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, 0) * ANGLES(RAD(-25), RAD(0), RAD(15)) * LEFTSHOULDERC0, 1 / Animation_Speed) | |
5922 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -1, 0) * ANGLES(RAD(0), RAD(80), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 1 / Animation_Speed) | |
5923 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1, 0) * ANGLES(RAD(0), RAD(-70), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 1 / Animation_Speed) | |
5924 | end | |
5925 | Speed = 16 | |
5926 | if ROOT then | |
5927 | CreateSound(305685800,Torso,5,1.3,false) | |
5928 | Rooted = true | |
5929 | local GORED = false | |
5930 | coroutine.resume(coroutine.create(function() | |
5931 | repeat | |
5932 | Swait() | |
5933 | ROOT.Anchored = true | |
5934 | until GORED == true | |
5935 | ROOT.Anchored = false | |
5936 | end)) | |
5937 | RootPart.CFrame = ROOT.CFrame*CF(0,0,2.25) | |
5938 | if TARGET.Name == "Torso" then | |
5939 | local RARM = TARGET.Parent:FindFirstChild("Right Arm") | |
5940 | local LARM = TARGET.Parent:FindFirstChild("Left Arm") | |
5941 | if RARM and LARM then | |
5942 | for i=0, 1, 0.1 / Animation_Speed do | |
5943 | Swait() | |
5944 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0) * ANGLES(RAD(0), RAD(0), RAD(0)), 1 / Animation_Speed) | |
5945 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(-5), RAD(0), RAD(0)), 1 / Animation_Speed) | |
5946 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, -0.4) * ANGLES(RAD(90), RAD(0), RAD(0)) * RIGHTSHOULDERC0, 1 / Animation_Speed) | |
5947 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, -0.4) * ANGLES(RAD(90), RAD(0), RAD(0)) * LEFTSHOULDERC0, 1 / Animation_Speed) | |
5948 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -1, 0) * ANGLES(RAD(0), RAD(70), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 1 / Animation_Speed) | |
5949 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1, 0) * ANGLES(RAD(0), RAD(-70), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 1 / Animation_Speed) | |
5950 | end | |
5951 | for _, c in pairs(TARGET.Parent:GetDescendants()) do | |
5952 | if c:IsA("JointInstance") then | |
5953 | if c.Part1 == RARM or c.Part1 == LARM or c.Part0 == RARM or c.Part0 == LARM then | |
5954 | c:remove() | |
5955 | end | |
5956 | end | |
5957 | end | |
5958 | CreateSound(363808674, TARGET, 3, MRANDOM(7,9)/10, false) | |
5959 | CreateWeldOrSnapOrMotor("Weld", RightArm, RightArm, RARM, CF(0,-1.35,0) * ANGLES(RAD(90), RAD(0), RAD(0)), CF(0, 0, 0)) | |
5960 | CreateWeldOrSnapOrMotor("Weld", LeftArm, LeftArm, LARM, CF(0,-1.35,0) * ANGLES(RAD(90), RAD(0), RAD(0)), CF(0, 0, 0)) | |
5961 | for i=0, 1, 0.1 / Animation_Speed do | |
5962 | Swait() | |
5963 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0) * ANGLES(RAD(0), RAD(0), RAD(0)), 1 / Animation_Speed) | |
5964 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(-5), RAD(0), RAD(0)), 1 / Animation_Speed) | |
5965 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, -0.4) * ANGLES(RAD(160), RAD(0), RAD(0)) * RIGHTSHOULDERC0, 1 / Animation_Speed) | |
5966 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, -0.4) * ANGLES(RAD(160), RAD(0), RAD(0)) * LEFTSHOULDERC0, 1 / Animation_Speed) | |
5967 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -1, 0) * ANGLES(RAD(0), RAD(70), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 1 / Animation_Speed) | |
5968 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1, 0) * ANGLES(RAD(0), RAD(-70), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 1 / Animation_Speed) | |
5969 | end | |
5970 | for i=0, 1, 0.1 / Animation_Speed do | |
5971 | Swait() | |
5972 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0.25) * ANGLES(RAD(-25), RAD(0), RAD(80)), 1 / Animation_Speed) | |
5973 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(15), RAD(0), RAD(-30)), 1 / Animation_Speed) | |
5974 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, -0.4) * ANGLES(RAD(160), RAD(0), RAD(0)) * RIGHTSHOULDERC0, 1 / Animation_Speed) | |
5975 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, -0.4) * ANGLES(RAD(160), RAD(0), RAD(0)) * LEFTSHOULDERC0, 1 / Animation_Speed) | |
5976 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -1, -0.6) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(-65), RAD(0), RAD(0)) * CF(0,1.5,0), 1 / Animation_Speed) | |
5977 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1, 0) * ANGLES(RAD(0), RAD(-45), RAD(0)) * ANGLES(RAD(-35), RAD(0), RAD(0)), 1 / Animation_Speed) | |
5978 | end | |
5979 | for i=0, 0.1, 0.1 / Animation_Speed do | |
5980 | Swait() | |
5981 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0.2, 0.25) * ANGLES(RAD(-35), RAD(0), RAD(80)), 1 / Animation_Speed) | |
5982 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(15), RAD(0), RAD(-30)), 1 / Animation_Speed) | |
5983 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, -0.4) * ANGLES(RAD(160), RAD(0), RAD(0)) * RIGHTSHOULDERC0, 1 / Animation_Speed) | |
5984 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, -0.4) * ANGLES(RAD(160), RAD(0), RAD(0)) * LEFTSHOULDERC0, 1 / Animation_Speed) | |
5985 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -1, -0.6) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(-65), RAD(0), RAD(0)) * CF(0,-0.3,0), 1 / Animation_Speed) | |
5986 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1, 0) * ANGLES(RAD(0), RAD(-45), RAD(0)) * ANGLES(RAD(-35), RAD(0), RAD(0)), 1 / Animation_Speed) | |
5987 | end | |
5988 | GORED = true | |
5989 | Ragdoll(TARGET.Parent,Torso) | |
5990 | if ROOT.Name ~= "Torso" then | |
5991 | ROOT:remove() | |
5992 | end | |
5993 | local RGRAB = CreateWeldOrSnapOrMotor("Weld", RightArm, RightArm, RARM, CF(0,-1.35,0) * ANGLES(RAD(90), RAD(0), RAD(0)), CF(0, 0, 0)) | |
5994 | local LGRAB = CreateWeldOrSnapOrMotor("Weld", LeftArm, LeftArm, LARM, CF(0,-1.35,0) * ANGLES(RAD(90), RAD(0), RAD(0)), CF(0, 0, 0)) | |
5995 | local bv = Instance.new("BodyVelocity",TARGET) | |
5996 | bv.maxForce = Vector3.new(1e9, 1e9, 1e9) | |
5997 | bv.velocity = TARGET.CFrame.lookVector*75 | |
5998 | Debris:AddItem(bv,0.05) | |
5999 | CreateSound(621557962, RightLeg, 1, MRANDOM(7,9)/10, false) | |
6000 | for i=0, 0.5, 0.1 / Animation_Speed do | |
6001 | Swait() | |
6002 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0.2, 0.25) * ANGLES(RAD(-35), RAD(0), RAD(80)), 1 / Animation_Speed) | |
6003 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(15), RAD(0), RAD(-30)), 1 / Animation_Speed) | |
6004 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, -0.4) * ANGLES(RAD(160), RAD(0), RAD(0)) * RIGHTSHOULDERC0, 1 / Animation_Speed) | |
6005 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, -0.4) * ANGLES(RAD(160), RAD(0), RAD(0)) * LEFTSHOULDERC0, 1 / Animation_Speed) | |
6006 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -1, -0.6) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(-65), RAD(0), RAD(0)) * CF(0,-0.3,0), 1 / Animation_Speed) | |
6007 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1, 0) * ANGLES(RAD(0), RAD(-45), RAD(0)) * ANGLES(RAD(-35), RAD(0), RAD(0)), 1 / Animation_Speed) | |
6008 | end | |
6009 | for i=0, 1, 0.1 / Animation_Speed do | |
6010 | Swait() | |
6011 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0) * ANGLES(RAD(0), RAD(0), RAD(0)), 1 / Animation_Speed) | |
6012 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(25), RAD(0), RAD(0)), 1 / Animation_Speed) | |
6013 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, -0.4) * ANGLES(RAD(0), RAD(0), RAD(90)) * RIGHTSHOULDERC0, 0.6 / Animation_Speed) | |
6014 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, -0.4) * ANGLES(RAD(0), RAD(0), RAD(-90)) * LEFTSHOULDERC0, 0.6 / Animation_Speed) | |
6015 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -1, 0) * ANGLES(RAD(0), RAD(70), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 1 / Animation_Speed) | |
6016 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1, 0) * ANGLES(RAD(0), RAD(-70), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 1 / Animation_Speed) | |
6017 | end | |
6018 | local HITBOX = CreatePart(3, RARM, "Metal", 0, 1, "Really black", "Part", RARM.Size, false) | |
6019 | HITBOX.CFrame = RARM.CFrame | |
6020 | HITBOX.CanCollide = true | |
6021 | weldBetween(RARM,HITBOX) | |
6022 | local HITBOX = CreatePart(3, LARM, "Metal", 0, 1, "Really black", "Part", RARM.Size, false) | |
6023 | HITBOX.CFrame = LARM.CFrame | |
6024 | HITBOX.CanCollide = true | |
6025 | weldBetween(LARM,HITBOX) | |
6026 | RGRAB:remove() | |
6027 | LGRAB:remove() | |
6028 | for i=0, 0.4, 0.1 / Animation_Speed do | |
6029 | Swait() | |
6030 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0) * ANGLES(RAD(0), RAD(0), RAD(0)), 1 / Animation_Speed) | |
6031 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(25), RAD(0), RAD(0)), 1 / Animation_Speed) | |
6032 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, -0.4) * ANGLES(RAD(0), RAD(0), RAD(110)) * RIGHTSHOULDERC0, 1 / Animation_Speed) | |
6033 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, -0.4) * ANGLES(RAD(0), RAD(0), RAD(-110)) * LEFTSHOULDERC0, 1 / Animation_Speed) | |
6034 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -1, 0) * ANGLES(RAD(0), RAD(70), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 1 / Animation_Speed) | |
6035 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1, 0) * ANGLES(RAD(0), RAD(-70), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 1 / Animation_Speed) | |
6036 | end | |
6037 | end | |
6038 | elseif TARGET.Name == "UpperTorso" then | |
6039 | if TARGET.Parent:FindFirstChild("RightUpperArm") and TARGET.Parent:FindFirstChild("LeftUpperArm") then | |
6040 | for i=0, 0.3, 0.1 / Animation_Speed do | |
6041 | Swait() | |
6042 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0) * ANGLES(RAD(0), RAD(0), RAD(45)), 1 / Animation_Speed) | |
6043 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(0), RAD(0), RAD(-45)), 1 / Animation_Speed) | |
6044 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.45, 0.5, -0.5) * ANGLES(RAD(140), RAD(0), RAD(45)) * ANGLES(RAD(0), RAD(25), RAD(0)) * RIGHTSHOULDERC0, 1 / Animation_Speed) | |
6045 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, 0) * ANGLES(RAD(0), RAD(0), RAD(0)) * LEFTSHOULDERC0, 1 / Animation_Speed) | |
6046 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -1, 0) * ANGLES(RAD(0), RAD(70), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 1 / Animation_Speed) | |
6047 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1, 0) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 1 / Animation_Speed) | |
6048 | end | |
6049 | local SAWBLADE = CreatePart(3, Weapon, "Neon", 0, 0.5, "Really red", "Part", VT(0,0,0),false) | |
6050 | local WELD = CreateWeldOrSnapOrMotor("Weld", RightArm, RightArm, SAWBLADE, CF(0,-1,0) * ANGLES(RAD(0), RAD(90), RAD(0)), CF(0, 0, 0)) | |
6051 | local BLADE = true | |
6052 | CreateMesh("SpecialMesh", SAWBLADE, "FileMesh", "74322089", "", VT(1,1,1), VT(0,0,0)) | |
6053 | coroutine.resume(coroutine.create(function() | |
6054 | repeat | |
6055 | Swait() | |
6056 | WELD.C1 = WELD.C1 * ANGLES(RAD(0), RAD(0), RAD(25)) | |
6057 | until BLADE == false | |
6058 | SAWBLADE:remove() | |
6059 | end)) | |
6060 | CreateSound(1165167936, SAWBLADE, 2, 1, true) | |
6061 | for i=0, 1, 0.1 / Animation_Speed do | |
6062 | Swait() | |
6063 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0) * ANGLES(RAD(0), RAD(0), RAD(45)), 1 / Animation_Speed) | |
6064 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(0), RAD(0), RAD(-45)), 1 / Animation_Speed) | |
6065 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.45, 0.5, -0.5) * ANGLES(RAD(140), RAD(0), RAD(45)) * ANGLES(RAD(0), RAD(25), RAD(0)) * RIGHTSHOULDERC0, 1 / Animation_Speed) | |
6066 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, 0) * ANGLES(RAD(0), RAD(0), RAD(0)) * LEFTSHOULDERC0, 1 / Animation_Speed) | |
6067 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -1, 0) * ANGLES(RAD(0), RAD(70), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 1 / Animation_Speed) | |
6068 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1, 0) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 1 / Animation_Speed) | |
6069 | end | |
6070 | for i=0, 3, 0.1 / Animation_Speed do | |
6071 | Swait() | |
6072 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0) * ANGLES(RAD(0), RAD(0), RAD(45)), 1 / Animation_Speed) | |
6073 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(0), RAD(0), RAD(-45)), 1 / Animation_Speed) | |
6074 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.45, 0.5, -0.5) * ANGLES(RAD(15), RAD(0), RAD(45)) * ANGLES(RAD(0), RAD(-25), RAD(0)) * RIGHTSHOULDERC0, 0.1 / Animation_Speed) | |
6075 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, 0) * ANGLES(RAD(0), RAD(0), RAD(0)) * LEFTSHOULDERC0, 1 / Animation_Speed) | |
6076 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -1, 0) * ANGLES(RAD(0), RAD(70), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 1 / Animation_Speed) | |
6077 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1, 0) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 1 / Animation_Speed) | |
6078 | end | |
6079 | CreateSound(363808674, TARGET, 3, MRANDOM(7,9)/10, false) | |
6080 | TARGET.Parent:FindFirstChild("RightUpperArm").RightShoulder:remove() | |
6081 | for i=0, 1, 0.1 / Animation_Speed do | |
6082 | Swait() | |
6083 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(1, 0, 0.3) * ANGLES(RAD(0), RAD(0), RAD(90)), 1 / Animation_Speed) | |
6084 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(0), RAD(0), RAD(-80)), 1 / Animation_Speed) | |
6085 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.45, 0.5, 0) * ANGLES(RAD(140), RAD(0), RAD(90)) * ANGLES(RAD(0), RAD(45), RAD(0)) * RIGHTSHOULDERC0, 1 / Animation_Speed) | |
6086 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, 0) * ANGLES(RAD(0), RAD(0), RAD(0)) * LEFTSHOULDERC0, 1 / Animation_Speed) | |
6087 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -1, 0) * ANGLES(RAD(0), RAD(70), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 1 / Animation_Speed) | |
6088 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1, 0) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 1 / Animation_Speed) | |
6089 | end | |
6090 | for i=0, 3, 0.1 / Animation_Speed do | |
6091 | Swait() | |
6092 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(1, 0, 0) * ANGLES(RAD(0), RAD(0), RAD(90)), 1 / Animation_Speed) | |
6093 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(0), RAD(0), RAD(-80)), 1 / Animation_Speed) | |
6094 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, 0) * ANGLES(RAD(0), RAD(0), RAD(15)) * ANGLES(RAD(0), RAD(-45), RAD(0)) * RIGHTSHOULDERC0, 0.1 / Animation_Speed) | |
6095 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, 0) * ANGLES(RAD(0), RAD(0), RAD(0)) * LEFTSHOULDERC0, 1 / Animation_Speed) | |
6096 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -1, 0) * ANGLES(RAD(0), RAD(70), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 1 / Animation_Speed) | |
6097 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1, 0) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 1 / Animation_Speed) | |
6098 | end | |
6099 | CreateSound(363808674, TARGET, 3, MRANDOM(7,9)/10, false) | |
6100 | TARGET.Parent:FindFirstChild("LeftUpperArm").LeftShoulder:remove() | |
6101 | BLADE = false | |
6102 | for i=0, 0.5, 0.1 / Animation_Speed do | |
6103 | Swait() | |
6104 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0.25) * ANGLES(RAD(-25), RAD(0), RAD(80)), 1 / Animation_Speed) | |
6105 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(15), RAD(0), RAD(-30)), 1 / Animation_Speed) | |
6106 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, 0) * ANGLES(RAD(0), RAD(45), RAD(0)) * ANGLES(RAD(-25), RAD(0), RAD(0)) * RIGHTSHOULDERC0, 1 / Animation_Speed) | |
6107 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, 0) * ANGLES(RAD(-15), RAD(0), RAD(-25)) * LEFTSHOULDERC0, 1 / Animation_Speed) | |
6108 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -1, -0.6) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(-65), RAD(0), RAD(0)) * CF(0,1.5,0), 1 / Animation_Speed) | |
6109 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1, 0) * ANGLES(RAD(0), RAD(-45), RAD(0)) * ANGLES(RAD(-35), RAD(0), RAD(0)), 1 / Animation_Speed) | |
6110 | end | |
6111 | for i=0, 0.1, 0.1 / Animation_Speed do | |
6112 | Swait() | |
6113 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0.2, 0.25) * ANGLES(RAD(-35), RAD(0), RAD(80)), 1 / Animation_Speed) | |
6114 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(15), RAD(0), RAD(-30)), 1 / Animation_Speed) | |
6115 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, 0) * ANGLES(RAD(0), RAD(45), RAD(0)) * ANGLES(RAD(-32), RAD(0), RAD(0)) * RIGHTSHOULDERC0, 1 / Animation_Speed) | |
6116 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, 0) * ANGLES(RAD(-20), RAD(0), RAD(-25)) * LEFTSHOULDERC0, 1 / Animation_Speed) | |
6117 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -1, -0.6) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(-65), RAD(0), RAD(0)) * CF(0,-0.3,0), 1 / Animation_Speed) | |
6118 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1, 0) * ANGLES(RAD(0), RAD(-45), RAD(0)) * ANGLES(RAD(-35), RAD(0), RAD(0)), 1 / Animation_Speed) | |
6119 | end | |
6120 | GORED = true | |
6121 | TARGET.Parent:BreakJoints() | |
6122 | R15Ragdoll(TARGET.Parent) | |
6123 | if ROOT.Name ~= "Torso" then | |
6124 | ROOT:remove() | |
6125 | end | |
6126 | local bv = Instance.new("BodyVelocity",TARGET) | |
6127 | bv.maxForce = Vector3.new(1e9, 1e9, 1e9) | |
6128 | bv.velocity = TARGET.CFrame.lookVector*75 | |
6129 | Debris:AddItem(bv,0.05) | |
6130 | CreateSound(621557962, RightLeg, 1, MRANDOM(7,9)/10, false) | |
6131 | for i=0, 0.3, 0.1 / Animation_Speed do | |
6132 | Swait() | |
6133 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0.2, 0.25) * ANGLES(RAD(-35), RAD(0), RAD(80)), 1 / Animation_Speed) | |
6134 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(15), RAD(0), RAD(-30)), 1 / Animation_Speed) | |
6135 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, 0) * ANGLES(RAD(0), RAD(45), RAD(0)) * ANGLES(RAD(-32), RAD(0), RAD(0)) * RIGHTSHOULDERC0, 1 / Animation_Speed) | |
6136 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, 0) * ANGLES(RAD(-20), RAD(0), RAD(-25)) * LEFTSHOULDERC0, 1 / Animation_Speed) | |
6137 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -1, -0.6) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(-65), RAD(0), RAD(0)) * CF(0,-0.3,0), 1 / Animation_Speed) | |
6138 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1, 0) * ANGLES(RAD(0), RAD(-45), RAD(0)) * ANGLES(RAD(-35), RAD(0), RAD(0)), 1 / Animation_Speed) | |
6139 | end | |
6140 | end | |
6141 | end | |
6142 | end | |
6143 | ATTACK = false | |
6144 | Rooted = false | |
6145 | end | |
6146 | function CreateBody() | |
6147 | local zombie = IT("Model",Effects) | |
6148 | zombie.Name = "NOOB" | |
6149 | local tors = IT("Part",zombie) | |
6150 | tors.Name = "Torso" | |
6151 | tors.Size = Torso.Size | |
6152 | tors.CFrame = RootPart.CFrame * CF(math.random(-5,5),0,-5) | |
6153 | tors.Color = C3(0,0,245) | |
6154 | local heed = IT("Part",zombie) | |
6155 | heed.Size = Head.Size | |
6156 | heed.CFrame = tors.CFrame * CF(0,1.5,0) | |
6157 | heed.Name = "Head" | |
6158 | heed.Color = C3(255/255, 0/0, 0/0) | |
6159 | local face = IT("Decal",heed) | |
6160 | face.Texture = "http://www.roblox.com/asset/?id=152527250" | |
6161 | weldBetween(tors,heed) | |
6162 | local headmesh = IT("SpecialMesh",heed) | |
6163 | headmesh.Scale = VT(1.25,1.25,1.25) | |
6164 | local limb = IT("Part",zombie) | |
6165 | limb.Size = VT(1,2,1) | |
6166 | limb.Name = "Left Arm" | |
6167 | limb.CFrame = tors.CFrame * CF(-1.5,0,0) | |
6168 | limb.Color = C3(255/255, 0/0, 0/0) | |
6169 | weldBetween(tors,limb) | |
6170 | local limb = IT("Part",zombie) | |
6171 | limb.Size = VT(1,2,1) | |
6172 | limb.Name = "Right Arm" | |
6173 | limb.CFrame = tors.CFrame * CF(1.5,0,0) | |
6174 | limb.Color = C3(255/255, 0/0, 0/0) | |
6175 | weldBetween(tors,limb) | |
6176 | local limb = IT("Part",zombie) | |
6177 | limb.Size = VT(1,2,1) | |
6178 | limb.Name = "Right Leg" | |
6179 | limb.CFrame = tors.CFrame * CF(0.5,-2,0) | |
6180 | limb.Color = C3(0,0,245) | |
6181 | weldBetween(tors,limb) | |
6182 | local limb = IT("Part",zombie) | |
6183 | limb.Size = VT(1,2,1) | |
6184 | limb.Name = "Left Leg" | |
6185 | limb.CFrame = tors.CFrame * CF(-0.5,-2,0) | |
6186 | limb.Color = C3(0,0,245) | |
6187 | weldBetween(tors,limb) | |
6188 | local hooman = IT("Humanoid",zombie) | |
6189 | return zombie | |
6190 | end | |
6191 | ||
6192 | --//=================================\\ | |
6193 | --|| ATTACK FUNCTIONS AND STUFF | |
6194 | --\\=================================// | |
6195 | local LAUGHS = {"529391838"} | |
6196 | local HITPLAYERSOUNDS = {--[["199149137", "199149186", "199149221", "199149235", "199149269", "199149297"--]]"263032172", "263032182", "263032200", "263032221", "263032252", "263033191"} | |
6197 | local HITARMORSOUNDS = {"199149321", "199149338", "199149367", "199149409", "199149452"} | |
6198 | local HITWEAPONSOUNDS = {"199148971", "199149025", "199149072", "199149109", "199149119"} | |
6199 | local HITBLOCKSOUNDS = {"199148933", "199148947"} | |
6200 | local UNANCHOR = true | |
6201 | ||
6202 | local ATTACKEDTAUNTS = { | |
6203 | "907332040", | |
6204 | "907332525", | |
6205 | "907330011" | |
6206 | } | |
6207 | local ATTACKTAUNTS = { | |
6208 | "907329893", | |
6209 | "907329532", | |
6210 | "907333294", | |
6211 | "907332856" | |
6212 | } | |
6213 | local ULTTAUNTS = { | |
6214 | "907332997", | |
6215 | "907332670", | |
6216 | "907330103" | |
6217 | } | |
6218 | ||
6219 | ||
6220 | local RightHole = CreatePart(3, Character, "Metal", 0, 0, "Mid gray", "Eye", VT(0.2,0,0.2),false) | |
6221 | MakeForm(RightHole,"Cyl") | |
6222 | local LeftHole = CreatePart(3, Character, "Metal", 0, 0, "Mid gray", "Eye", VT(0.2,0,0.2),false) | |
6223 | MakeForm(LeftHole,"Cyl") | |
6224 | ||
6225 | function getbloody(victim,amount) | |
6226 | local PART = CreatePart(3, Effects, "Metal", 0, 1, "Mid gray", "Blood", victim.Size) | |
6227 | PART.CFrame = victim.CFrame | |
6228 | local HITPLAYERSOUNDS = {"356551938","264486467"} | |
6229 | Debris:AddItem(PART,5) | |
6230 | CreateSound(HITPLAYERSOUNDS[MRANDOM(1, #HITPLAYERSOUNDS)], PART, 1, (math.random(8,12)/10)) | |
6231 | CreateSound(HITPLAYERSOUNDS[MRANDOM(1, #HITPLAYERSOUNDS)], PART, 1, (math.random(8,12)/10)) | |
6232 | CreateSound(HITPLAYERSOUNDS[MRANDOM(1, #HITPLAYERSOUNDS)], PART, 1, (math.random(8,12)/10)) | |
6233 | local prtcl = asd:Clone() | |
6234 | prtcl.Parent = PART | |
6235 | prtcl:Emit(amount*10) | |
6236 | end | |
6237 | ||
6238 | function Kill(Char) | |
6239 | local NewCharacter = IT("Model",Effects) | |
6240 | NewCharacter.Name = "Ow im ded ;-;" | |
6241 | for _, c in pairs(Char:GetDescendants()) do | |
6242 | if c:IsA("BasePart") and c.Transparency == 0 then | |
6243 | if c.Parent == Char then | |
6244 | getbloody(c,5) | |
6245 | end | |
6246 | c:BreakJoints() | |
6247 | c.Material = "Glass" | |
6248 | c.Color = C3(0.5,0,0) | |
6249 | c.CanCollide = true | |
6250 | c.Transparency = 0.3 | |
6251 | if c:FindFirstChildOfClass("SpecialMesh") then | |
6252 | c:FindFirstChildOfClass("SpecialMesh").TextureId = "" | |
6253 | end | |
6254 | if c.Name == "Head" then | |
6255 | c:ClearAllChildren() | |
6256 | c.Size = VT(c.Size.Y,c.Size.Y,c.Size.Y) | |
6257 | end | |
6258 | if c.ClassName == "MeshPart" then | |
6259 | c.TextureID = "" | |
6260 | end | |
6261 | if c:FindFirstChildOfClass("BodyPosition") then | |
6262 | c:FindFirstChildOfClass("BodyPosition"):remove() | |
6263 | end | |
6264 | if c:FindFirstChildOfClass("ParticleEmitter") then | |
6265 | c:FindFirstChildOfClass("ParticleEmitter"):remove() | |
6266 | end | |
6267 | c.Parent = NewCharacter | |
6268 | c.Name = "DeadPart" | |
6269 | c.Velocity = VT(MRANDOM(-45,45),MRANDOM(-45,45),MRANDOM(-45,45))/15 | |
6270 | c.RotVelocity = VT(MRANDOM(-45,45),MRANDOM(-15,85),MRANDOM(-45,45)) | |
6271 | end | |
6272 | end | |
6273 | Char:remove() | |
6274 | Debris:AddItem(NewCharacter,5) | |
6275 | end | |
6276 | ||
6277 | function Banisher_Bullet() | |
6278 | ATTACK = true | |
6279 | Rooted = false | |
6280 | for i=0, 0.05, 0.1 / Animation_Speed do | |
6281 | Swait() | |
6282 | turnto(Mouse.Hit.p) | |
6283 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0) * ANGLES(RAD(0), RAD(0), RAD(90)), 0.5 / Animation_Speed) | |
6284 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0) * ANGLES(RAD(0), RAD(0), RAD(-90)), 0.5 / Animation_Speed) | |
6285 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, 0) * ANGLES(RAD(90), RAD(0), RAD(90)) * RIGHTSHOULDERC0, 0.5 / Animation_Speed) | |
6286 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.6, 0) * ANGLES(RAD(-45), RAD(0), RAD(45)) * LEFTSHOULDERC0, 0.5 / Animation_Speed) | |
6287 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -1, 0) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 0.5 / Animation_Speed) | |
6288 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1, 0) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 0.5 / Animation_Speed) | |
6289 | end | |
6290 | repeat | |
6291 | for i=0, 0.05, 0.1 / Animation_Speed do | |
6292 | Swait() | |
6293 | turnto(Mouse.Hit.p) | |
6294 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0) * ANGLES(RAD(0), RAD(0), RAD(90)), 0.5 / Animation_Speed) | |
6295 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0) * ANGLES(RAD(0), RAD(0), RAD(-90)), 0.5 / Animation_Speed) | |
6296 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, 0) * ANGLES(RAD(90), RAD(0), RAD(90)) * RIGHTSHOULDERC0, 0.5 / Animation_Speed) | |
6297 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.6, 0) * ANGLES(RAD(-45), RAD(0), RAD(45)) * LEFTSHOULDERC0, 0.5 / Animation_Speed) | |
6298 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -1, 0) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 0.5 / Animation_Speed) | |
6299 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1, 0) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 0.5 / Animation_Speed) | |
6300 | end | |
6301 | local HIT,POS = CastProperRay(Hole.Position, Mouse.Hit.p, 1000, Character) | |
6302 | SpawnTrail(Hole.Position,POS) | |
6303 | if HIT ~= nil then | |
6304 | if HIT.Parent ~= workspace and HIT.Parent.ClassName ~= "Folder" then | |
6305 | Banish(HIT.Parent) | |
6306 | end | |
6307 | end | |
6308 | WACKYEFFECT({Time = 25, EffectType = "Wave", Size = VT(0.3,0,0.3), Size2 = VT(1,1.5,1), Transparency = 0, Transparency2 = 1, CFrame = Hole.CFrame, MoveToPos = Hole.CFrame*CF(0,0.5,0).p, RotationX = 0, RotationY = -15, RotationZ = 0, Material = "Neon", Color = C3(222,255,0), SoundID = nil, SoundPitch = nil, SoundVolume = nil}) | |
6309 | WACKYEFFECT({Time = 25, EffectType = "Wave", Size = VT(0.3,0,0.3), Size2 = VT(2,0.5,2), Transparency = 0, Transparency2 = 1, CFrame = Hole.CFrame, MoveToPos = nil, RotationX = 0, RotationY = 5, RotationZ = 0, Material = "Neon", Color = C3(222,255,0), SoundID = 162209821, SoundPitch = MRANDOM(8,11)/10, SoundVolume = 8}) | |
6310 | WACKYEFFECT({Time = 25, EffectType = "Wave", Size = VT(0.3,0,0.3), Size2 = VT(2,0.5,2), Transparency = 0, Transparency2 = 1, CFrame = CF(POS,Hole.Position) * ANGLES(RAD(-90), RAD(0), RAD(0)), MoveToPos = nil, RotationX = 0, RotationY = -5, RotationZ = 0, Material = "Neon", Color = C3(222,255,0), SoundID = nil, SoundPitch = MRANDOM(8,11)/10, SoundVolume = 8}) | |
6311 | WACKYEFFECT({Time = 25, EffectType = "Wave", Size = VT(0.3,0,0.3), Size2 = VT(2,0.5,2), Transparency = 0, Transparency2 = 1, CFrame = CF(POS,Hole.Position) * ANGLES(RAD(-90), RAD(0), RAD(0)), MoveToPos = nil, RotationX = 0, RotationY = 5, RotationZ = 0, Material = "Neon", Color = C3(222,255,0), SoundID = nil, SoundPitch = MRANDOM(8,11)/10, SoundVolume = 8}) | |
6312 | for i=0, 0.05, 0.1 / Animation_Speed do | |
6313 | Swait() | |
6314 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0) * ANGLES(RAD(0), RAD(0), RAD(90)), 0.5 / Animation_Speed) | |
6315 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0) * ANGLES(RAD(0), RAD(0), RAD(-90)), 0.25 / Animation_Speed) | |
6316 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, 0) * ANGLES(RAD(130), RAD(15), RAD(90)) * RIGHTSHOULDERC0, 0.5 / Animation_Speed) | |
6317 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.6, 0) * ANGLES(RAD(-45), RAD(0), RAD(45)) * LEFTSHOULDERC0, 0.5 / Animation_Speed) | |
6318 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -1, 0) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 0.5 / Animation_Speed) | |
6319 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1, 0) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 0.5 / Animation_Speed) | |
6320 | end | |
6321 | until KEYHOLD == false | |
6322 | ATTACK = false | |
6323 | Rooted = false | |
6324 | end | |
6325 | function CreateRing(SIZE, DOESROT, ROT, WAIT, CFRAME, COLOR, GROW) | |
6326 | local wave = CreatePart(3, Effects, "Neon", 0, 0.5, BRICKC(COLOR), "Effect", VT(0, 0, 0)) | |
6327 | wave.Color = COLOR | |
6328 | local mesh = CreateMesh("SpecialMesh", wave, "FileMesh", "559831844", "", SIZE, VT(0, 0, 0)) | |
6329 | wave.CFrame = CFRAME | |
6330 | coroutine.resume(coroutine.create(function(PART) | |
6331 | for i = 1, WAIT do | |
6332 | Swait() | |
6333 | mesh.Scale = mesh.Scale + GROW | |
6334 | if DOESROT == true then | |
6335 | wave.CFrame = wave.CFrame * CFrame.fromEulerAnglesXYZ(0, ROT, 0) | |
6336 | end | |
6337 | wave.Transparency = wave.Transparency + 0.5 / WAIT | |
6338 | if wave.Transparency > 0.99 then | |
6339 | wave:remove() | |
6340 | end | |
6341 | end | |
6342 | end)) | |
6343 | end | |
6344 | function Erruption() | |
6345 | ATTACK = true | |
6346 | Rooted = true | |
6347 | CreateSound(LAUGHS[MRANDOM(1,#LAUGHS)], Torso, 7, 1, false) | |
6348 | for i=0, 1, 0.1 / Animation_Speed do | |
6349 | Swait() | |
6350 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.25 * COS(SINE / 12)) * ANGLES(RAD(0), RAD(0), RAD(0)), 1 / Animation_Speed) | |
6351 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(15 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed) | |
6352 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, -0.5) * ANGLES(RAD(0), RAD(0), RAD(-85)) * RIGHTSHOULDERC0, 1 / Animation_Speed) | |
6353 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.15, -0.5) * ANGLES(RAD(-15), RAD(0), RAD(85)) * LEFTSHOULDERC0, 1 / Animation_Speed) | |
6354 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -1, -0.01) * ANGLES(RAD(-2.5 * SIN(SINE / 12)), RAD(75), RAD(0)) * ANGLES(RAD(-8 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed) | |
6355 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -0.5, -0.5) * ANGLES(RAD(-2.5 * SIN(SINE / 12)), RAD(-90), RAD(0)) * ANGLES(RAD(-8 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed) | |
6356 | end | |
6357 | coroutine.resume(coroutine.create(function() | |
6358 | local POS = Mouse.Hit.p | |
6359 | local RAY = CreatePart(3, Effects, "Neon", 0, 0, "Really black", "Strike", VT(0,2000,0)) | |
6360 | MakeForm(RAY,"Cyl") | |
6361 | local SPHERE = CreatePart(3, Effects, "Neon", 0, 0, "Really black", "Strike", VT(0,0,0)) | |
6362 | MakeForm(SPHERE,"Ball") | |
6363 | local SHIELD = CreatePart(3, Effects, "Neon", 0, 0.5, "Really black", "Strike", VT(0,0,0)) | |
6364 | MakeForm(SHIELD,"Ball") | |
6365 | SHIELD.CFrame = CF(POS) | |
6366 | RAY.CFrame = CF(POS) | |
6367 | SPHERE.CFrame = CF(POS) | |
6368 | CreateSound(440145570, SPHERE, 10, 0.8, false) | |
6369 | CreateSound(415700134, SPHERE, 10, 0.8, false) | |
6370 | for i = 1, 200 do | |
6371 | Swait() | |
6372 | WACKYEFFECT({Time = 15, EffectType = "Wave", Size = VT(0,0,0), Size2 = VT(SPHERE.Size.X*1.2,5+(i),SPHERE.Size.X*1.2), Transparency = 0, Transparency2 = 1, CFrame = SPHERE.CFrame*ANGLES(RAD(0), RAD(i), RAD(0)), MoveToPos = nil, RotationX = 0, RotationY = i, RotationZ = 0, Material = "Neon", Color = C3(0,0,0), SoundID = nil, SoundPitch = nil, SoundVolume = nil}) | |
6373 | RAY.Size = RAY.Size + VT(0.05,0,0.05) | |
6374 | SPHERE.Size = SPHERE.Size + VT(5,5,5) | |
6375 | SHIELD.Size = SPHERE.Size + VT(6,6,6) | |
6376 | ApplyAoE(SPHERE.Position,SPHERE.Size.X/3,true) | |
6377 | end | |
6378 | for i = 1, 45 do | |
6379 | Swait() | |
6380 | RAY.Transparency = RAY.Transparency + 1/45 | |
6381 | SPHERE.Transparency = RAY.Transparency | |
6382 | SHIELD.Transparency = SPHERE.Transparency + 1/45 | |
6383 | end | |
6384 | RAY:remove() | |
6385 | SHIELD:remove() | |
6386 | SPHERE:remove() | |
6387 | end)) | |
6388 | for i=0, 1, 0.1 / Animation_Speed do | |
6389 | Swait() | |
6390 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.25 * COS(SINE / 12)) * ANGLES(RAD(-35), RAD(0), RAD(0)), 1 / Animation_Speed) | |
6391 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(-15 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed) | |
6392 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, -0.15) * ANGLES(RAD(65), RAD(-45), RAD(85)) * RIGHTSHOULDERC0, 1 / Animation_Speed) | |
6393 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, -0.15) * ANGLES(RAD(65), RAD(45), RAD(-85)) * LEFTSHOULDERC0, 1 / Animation_Speed) | |
6394 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -1, -0.01) * ANGLES(RAD(-35-2.5 * SIN(SINE / 12)), RAD(75), RAD(0)) * ANGLES(RAD(-8 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed) | |
6395 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -0.5, -0.5) * ANGLES(RAD(-35-2.5 * SIN(SINE / 12)), RAD(-90), RAD(0)) * ANGLES(RAD(-8 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed) | |
6396 | end | |
6397 | ATTACK = false | |
6398 | Rooted = false | |
6399 | end | |
6400 | ||
6401 | function Teleport() | |
6402 | ATTACK = true | |
6403 | Rooted = false | |
6404 | for i=0, 0.5, 0.1 / Animation_Speed do | |
6405 | Swait() | |
6406 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(15 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed) | |
6407 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.6, 0.75, -0.5) * ANGLES(RAD(0), RAD(-25), RAD(12)) * ANGLES(RAD(125 - 2.5 * COS(SINE / 12) + 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)) * RIGHTSHOULDERC0, 1.5 / Animation_Speed) | |
6408 | end | |
6409 | for e = 1, #BODY do | |
6410 | if BODY[e] ~= nil then | |
6411 | local STUFF = BODY[e] | |
6412 | local PART = STUFF[1] | |
6413 | if PART:IsA("BasePart") and PART ~= RootPart and PART.Name ~= "FaceGradient" and PART.Name ~= "Hair" and PART.Transparency ~= 1 then | |
6414 | local PRT = PART:Clone() | |
6415 | PRT.Anchored = true | |
6416 | PRT.CanCollide = false | |
6417 | PRT.Material = "Neon" | |
6418 | PRT.Color = C3(1,1,1) | |
6419 | PRT.Name = "WarpEffect" | |
6420 | PRT.Parent = Effects | |
6421 | PRT.CFrame = PART.CFrame | |
6422 | PRT:BreakJoints() | |
6423 | if PRT:FindFirstChildOfClass("Sound") then | |
6424 | PRT:FindFirstChildOfClass("Sound"):remove() | |
6425 | end | |
6426 | if PRT:FindFirstChildOfClass("Decal") then | |
6427 | PRT:FindFirstChildOfClass("Decal"):remove() | |
6428 | end | |
6429 | coroutine.resume(coroutine.create(function() | |
6430 | for i = 1, 100 do | |
6431 | Swait() | |
6432 | PRT.Transparency = PRT.Transparency + 1/100 | |
6433 | end | |
6434 | PRT:remove() | |
6435 | end)) | |
6436 | end | |
6437 | end | |
6438 | end | |
6439 | CreateSound(217767125, Torso, 10, 1) | |
6440 | local POS = RootPart.Orientation | |
6441 | RootPart.CFrame = CF(Mouse.Hit.p+VT(0,6,0)) | |
6442 | RootPart.Orientation = POS | |
6443 | RootJoint.Parent = RootPart | |
6444 | for i=0, 0.5, 0.1 / Animation_Speed do | |
6445 | Swait() | |
6446 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(15 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed) | |
6447 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.6, 0.75, -0.5) * ANGLES(RAD(0), RAD(-15), RAD(12)) * ANGLES(RAD(175 - 2.5 * COS(SINE / 12) + 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)) * RIGHTSHOULDERC0, 2.5 / Animation_Speed) | |
6448 | end | |
6449 | for i=0, 0.1, 0.1 / Animation_Speed do | |
6450 | Swait() | |
6451 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1, 0.5, 0.5) * ANGLES(RAD(0), RAD(-45), RAD(12)) * ANGLES(RAD(45 - 2.5 * COS(SINE / 12) + 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)) * RIGHTSHOULDERC0, 0.75 / Animation_Speed) | |
6452 | end | |
6453 | ATTACK = false | |
6454 | Rooted = false | |
6455 | end | |
6456 | function Sky() | |
6457 | local HITBODIES = {} | |
6458 | local CENTER = CreatePart(3, Effects, "SmoothPlastic", 0, 1, "Pearl", "CenterPart", VT(0, 0, 0)) | |
6459 | local HITFLOOR, ECH, NORMAL = Raycast(Mouse.Hit.p + VT(0, 2, 0), CF(Mouse.Hit.p, Mouse.Hit.p + VT(0, -1, 0)).lookVector, 10000000, Character) | |
6460 | CENTER.CFrame = CF(ECH) | |
6461 | local RAY = CreatePart(3, Effects, "Neon", 0, 1, "Really black", "Laser01", VT(25, 99999, 25)) | |
6462 | MakeForm(RAY, "Cyl") | |
6463 | local RAY2 = CreatePart(3, Effects, "Neon", 0, 1, "Really black", "Laser01", VT(28, 99999, 28)) | |
6464 | MakeForm(RAY2, "Cyl") | |
6465 | RAY.CFrame = CF(ECH) | |
6466 | RAY2.CFrame = CF(ECH) | |
6467 | CreateSound("1368573150", CENTER, 10, 0.8) | |
6468 | for i = 1, 100 do | |
6469 | Swait() | |
6470 | RAY.Transparency = RAY.Transparency - 0.01 | |
6471 | RAY.Size = RAY.Size - VT(0.25, 0, 0.25) | |
6472 | RAY2.Transparency = RAY2.Transparency - 0.012 | |
6473 | RAY2.Size = RAY2.Size - VT(0.28, 0, 0.28) | |
6474 | end | |
6475 | for i = 1, 5 do | |
6476 | CreateRing(VT(i / 10, i / 10, 0), false, 0, 25, CF(ECH) * ANGLES(RAD(MRANDOM(-180, 180)), RAD(MRANDOM(-180, 180)), RAD(MRANDOM(-180, 180))), C3(MRANDOM(0, 10) / 10, 0, 0), VT(i / 5, i / 5, 0)) | |
6477 | end | |
6478 | RAY:remove() | |
6479 | RAY2:remove() | |
6480 | CreateSound("1368637781", CENTER, 10, 0.8) | |
6481 | MagicSphere(VT(0, 0, 0), 15, CF(ECH), "Really black", VT(8, 8, 8)) | |
6482 | MagicSphere(VT(1, 1, 1), 25, CF(ECH), "Really black", VT(8, 8, 8)) | |
6483 | AddChildrenToTable(ECH, workspace, 80, HITBODIES) | |
6484 | Debris:AddItem(CENTER, 5) | |
6485 | CreateSound("414517163", CENTER, 10, 0.8) | |
6486 | for i = 1, 5 do | |
6487 | Slice("Round", 0, 35, CF(ECH) * ANGLES(RAD(MRANDOM(-18, 18)), RAD(MRANDOM(-180, 180)), RAD(MRANDOM(-18, 18))), "Really black", VT(0.5, 0, 0.5)) | |
6488 | end | |
6489 | for e = 1, #HITBODIES do | |
6490 | if HITBODIES[e] ~= nil then | |
6491 | local BOD = HITBODIES[e] | |
6492 | local TORS = BOD:FindFirstChild("Torso") or BOD:FindFirstChild("UpperTorso") | |
6493 | if TORS then | |
6494 | BOD:BreakJoints() | |
6495 | for _, c in pairs(BOD:GetChildren()) do | |
6496 | if c.ClassName == "Part" or c.ClassName == "MeshPart" then | |
6497 | local bv = Instance.new("BodyVelocity") | |
6498 | bv.maxForce = Vector3.new(1000000000, 1000000000, 1000000000) | |
6499 | bv.velocity = CF(ECH, c.Position).lookVector * 250 | |
6500 | bv.Parent = c | |
6501 | Debris:AddItem(bv, 0.2) | |
6502 | end | |
6503 | end | |
6504 | end | |
6505 | end | |
6506 | end | |
6507 | end | |
6508 | function Prison_Key() | |
6509 | if Mouse.Target ~= nil then | |
6510 | if Mouse.Target.Parent ~= Character and Mouse.Target.Parent.Parent ~= Character and Mouse.Target.Parent:FindFirstChildOfClass("Humanoid") ~= nil then | |
6511 | local HUM = Mouse.Target.Parent:FindFirstChildOfClass("Humanoid") | |
6512 | local TORSO = HUM.Parent:FindFirstChild("Torso") or HUM.Parent:FindFirstChild("UpperTorso") | |
6513 | local GYRO = IT("BodyGyro",RootPart) | |
6514 | GYRO.D = 750 | |
6515 | GYRO.P = 20000 | |
6516 | GYRO.MaxTorque = VT(0,40000000,0) | |
6517 | local grav = Instance.new("BodyPosition",TORSO) | |
6518 | grav.D = 15 | |
6519 | grav.P = 20000 | |
6520 | grav.maxForce = Vector3.new(math.huge,math.huge,math.huge) | |
6521 | grav.position = TORSO.Position | |
6522 | local GYRO2 = IT("BodyGyro",TORSO) | |
6523 | GYRO2.D = 750 | |
6524 | GYRO2.P = 20000 | |
6525 | GYRO2.MaxTorque = VT(0,40000000,0) | |
6526 | GYRO2.cframe = CF(TORSO.Position,RootPart.Position) | |
6527 | grav.Name = "Jail" | |
6528 | local LOCKPARTS = {} | |
6529 | ATTACK = true | |
6530 | Rooted = false | |
6531 | local LOCK = IT("Model",Effects) | |
6532 | LOCK.Name = "Lock" | |
6533 | local LOCK2 = IT("Model",LOCK) | |
6534 | LOCK2.Name = "Metal" | |
6535 | --CREATE LOCK-- | |
6536 | local BASE = CreatePart(3, LOCK, "Glass", 0, 0, "Really black", "Keylock", VT(3, 2.5, 1)) | |
6537 | LOCK.PrimaryPart = BASE | |
6538 | BASE.CFrame = CF(TORSO.Position,RootPart.Position)*CF(0,0,-4) | |
6539 | local PRT = CreatePart(3, LOCK, "Glass", 0, 0, "Really black", "Keylock", VT(3, 1, 3)) | |
6540 | PRT.CFrame = BASE.CFrame*CF(0,-1.25,0)*ANGLES(RAD(90),RAD(0),RAD(0)) | |
6541 | MakeForm(PRT,"Cyl") | |
6542 | local PRT = CreatePart(3, LOCK, "Glass", 0, 0, "White", "Hole", VT(1, 1, 1)) | |
6543 | PRT.Color = C3(0,0,0) | |
6544 | PRT.CFrame = BASE.CFrame*CF(0,0.3,-0.01)*ANGLES(RAD(90),RAD(0),RAD(0)) | |
6545 | MakeForm(PRT,"Cyl") | |
6546 | local PRT = CreatePart(3, LOCK, "Glass", 0, 0, "White", "Hole", VT(0.5, 1, 1)) | |
6547 | PRT.Color = C3(0,0,0) | |
6548 | PRT.CFrame = BASE.CFrame*CF(0,-0.2,-0.01) | |
6549 | for i = 1, 45 do | |
6550 | local PRT = CreatePart(3, LOCK2, "Glass", 0, 0, "Grey", "Keylock", VT(0.5, 0.5, 0.5)) | |
6551 | PRT.CFrame = BASE.CFrame*CF(0,2,0)*ANGLES(RAD(0),RAD(0),RAD(-90+(360/90*i)))*CF(0,1,0) | |
6552 | end | |
6553 | local PRT = CreatePart(3, LOCK2, "Glass", 0, 0, "Grey", "Keylock", VT(0.5, 0.5, 0.5)) | |
6554 | PRT.CFrame = BASE.CFrame*CF(0,1.5,0)*ANGLES(RAD(0),RAD(0),RAD(90))*CF(0,1,0) | |
6555 | LOCK2.PrimaryPart = PRT | |
6556 | --------------- | |
6557 | local CHILDREN = LOCK:GetDescendants() | |
6558 | for index, CHILD in pairs(CHILDREN) do | |
6559 | if CHILD:IsA("BasePart") then | |
6560 | CHILD.Transparency = 1 | |
6561 | end | |
6562 | end | |
6563 | for i = 1, 75 do | |
6564 | LOCK:SetPrimaryPartCFrame(CF(TORSO.Position,RootPart.Position)*CF(0,0,-4)) | |
6565 | Swait() | |
6566 | GYRO2.cframe = CF(TORSO.Position,RootPart.Position) | |
6567 | GYRO.cframe = CF(RootPart.Position,TORSO.Position) | |
6568 | local CHILDREN = LOCK:GetDescendants() | |
6569 | for index, CHILD in pairs(CHILDREN) do | |
6570 | if CHILD:IsA("BasePart") then | |
6571 | CHILD.Transparency = CHILD.Transparency - 1/75 | |
6572 | end | |
6573 | end | |
6574 | end | |
6575 | HUM.DisplayDistanceType = "None" | |
6576 | local KEY = IT("Model",Effects) | |
6577 | KEY.Name = "Key" | |
6578 | --CREATE KEY-- | |
6579 | local KBASE = CreatePart(3, KEY, "Neon", 0, 0, "Really black", "KeyBase", VT(0.1, 1, 0.1),false) | |
6580 | KEY.PrimaryPart = KBASE | |
6581 | KBASE.CFrame = RightArm.CFrame*CF(0,-2.1,0)*ANGLES(RAD(0),RAD(90),RAD(0)) | |
6582 | local WLD = weldBetween(RightArm,KBASE) | |
6583 | for i = 1, 45 do | |
6584 | local PRT = CreatePart(3, KEY, "Neon", 0, 0, "Really black", "Key", VT(0.1, 0.1, 0.1),false) | |
6585 | PRT.CFrame = KBASE.CFrame*CF(0,0.8,0)*ANGLES(RAD(0),RAD(0),RAD((360/45*i)))*CF(0,0.25,0) | |
6586 | weldBetween(KBASE,PRT) | |
6587 | end | |
6588 | local PRT = CreatePart(3, KEY, "Neon", 0, 0, "Really black", "Key", VT(0.3, 0.1, 0.1),false) | |
6589 | PRT.CFrame = KBASE.CFrame*CF(-0.15,-0.45,0) | |
6590 | weldBetween(KBASE,PRT) | |
6591 | local PRT = CreatePart(3, KEY, "Neon", 0, 0, "Really black", "Key", VT(0.3, 0.1, 0.1),false) | |
6592 | PRT.CFrame = KBASE.CFrame*CF(-0.15,-0.25,0) | |
6593 | weldBetween(KBASE,PRT) | |
6594 | -------------- | |
6595 | Rooted = true | |
6596 | Pose("Prepare key",1.5,1.2,false,GYRO,TORSO) | |
6597 | coroutine.resume(coroutine.create(function() | |
6598 | for i = 1, 10 do | |
6599 | Swait() | |
6600 | GYRO2.cframe = CF(TORSO.Position,RootPart.Position) | |
6601 | GYRO.cframe = CF(RootPart.Position,TORSO.Position) | |
6602 | end | |
6603 | CreateSound(1149318312,BASE,5,1,false) | |
6604 | CreateSound(160772554,BASE,3,1,false) | |
6605 | LOCK2:SetPrimaryPartCFrame(BASE.CFrame*CF(0,0.8,0)*ANGLES(RAD(0),RAD(0),RAD(90))*CF(0,1,0)) | |
6606 | for i = 1, 4 do | |
6607 | WACKYEFFECT({Time = 35, EffectType = "Crystal", Size = VT(1,1,1), Size2 = VT(0,15,0), Transparency = 0, Transparency2 = 1, CFrame = BASE.CFrame*CF(1,1.45,0)*ANGLES(RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360))), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = BRICKC"Lavender".Color, SoundID = nil, SoundPitch = nil, SoundVolume = nil}) | |
6608 | end | |
6609 | WACKYEFFECT({Time = 35, EffectType = "Sphere", Size = VT(0,0,0), Size2 = VT(1,1,1)*25, Transparency = 0, Transparency2 = 1, CFrame = TORSO.CFrame, MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = BRICKC"Lavender".Color, SoundID = nil, SoundPitch = MRANDOM(8,12)/10, SoundVolume = 5}) | |
6610 | wait(1) | |
6611 | TORSO.Parent.Parent = LOCK | |
6612 | for i = 1, 75 do | |
6613 | Swait() | |
6614 | local CHILDREN = KEY:GetDescendants() | |
6615 | for index, CHILD in pairs(CHILDREN) do | |
6616 | if CHILD:IsA("BasePart") then | |
6617 | CHILD.Transparency = i/25 | |
6618 | end | |
6619 | end | |
6620 | local CHILDREN = LOCK:GetDescendants() | |
6621 | for index, CHILD in pairs(CHILDREN) do | |
6622 | if CHILD:IsA("BasePart") and CHILD.Name ~= "HumanoidRootPart" then | |
6623 | CHILD.Transparency = CHILD.Transparency + 1/75 | |
6624 | elseif CHILD.ClassName == "Decal" then | |
6625 | CHILD.Transparency = CHILD.Transparency + 1/75 | |
6626 | end | |
6627 | end | |
6628 | end | |
6629 | TORSO.Parent:ClearAllChildren() | |
6630 | KEY:remove() | |
6631 | LOCK:remove() | |
6632 | end)) | |
6633 | Pose("Turn key",0.8,1.2,false,GYRO,TORSO) | |
6634 | GYRO:remove() | |
6635 | ATTACK = false | |
6636 | Rooted = false | |
6637 | end | |
6638 | end | |
6639 | end | |
6640 | function BanishmentBeam() | |
6641 | ATTACK = true | |
6642 | Rooted = false | |
6643 | local GYRO = IT("BodyGyro",RootPart) | |
6644 | GYRO.D = 100 | |
6645 | GYRO.P = 2000 | |
6646 | GYRO.MaxTorque = VT(0,4000000,0) | |
6647 | GYRO.cframe = CF(RootPart.Position,Mouse.Hit.p) | |
6648 | CreateSound("93724183", RightArm, 5, 1, false) | |
6649 | for i=1, 35 do | |
6650 | Swait() | |
6651 | WACKYEFFECT({Time = 5, EffectType = "Block", Size = VT(5,5,5), Size2 = VT(0,0,0), Transparency = 1, Transparency2 = 0.25, CFrame = RightArm.CFrame*CF(0,-5,0), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = SKILLTEXTCOLOR, SoundID = nil, SoundPitch = 0.6, SoundVolume = 6}) | |
6652 | GYRO.cframe = CF(RootPart.Position,Mouse.Hit.p) | |
6653 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.25 * COS(SINE / 12)) * ANGLES(RAD(4 + 2.5 * SIN(SINE / 12)), RAD(0), RAD(45)), 1 / Animation_Speed) | |
6654 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(15 + 4.5 * SIN(SINE / 12)), RAD(0), RAD(-45 - 4 * SIN(SINE / 12))), 1 / Animation_Speed) | |
6655 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5 + 0.025 * COS(SINE / 12), -0.5) * ANGLES(RAD(90), RAD(0 - 7.5 * SIN(SINE / 12)), RAD(45 + 7.5 * SIN(SINE / 12))) * RIGHTSHOULDERC0, 1 / Animation_Speed) | |
6656 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5 + 0.025 * COS(SINE / 12), 0) * ANGLES(RAD(0), RAD(0 + 7.5 * SIN(SINE / 12)), RAD(-12 - 7.5 * SIN(SINE / 12))) * LEFTSHOULDERC0, 1 / Animation_Speed) | |
6657 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -1, -0.01) * ANGLES(RAD(-7.5 * SIN(SINE / 12)), RAD(75), RAD(0)) * ANGLES(RAD(-8 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed) | |
6658 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -0.5, -0.5) * ANGLES(RAD(-7.5 * SIN(SINE / 12)), RAD(-90), RAD(0)) * ANGLES(RAD(-8 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed) | |
6659 | end | |
6660 | local BEAM = CreatePart(3, Effects, "Neon", 0, 1, "White", "Lazer", VT(0,0,0)) | |
6661 | local LOOP = CreateSound("162209821", RightArm, 5, 1, false) | |
6662 | local TOCH = BEAM.Touched:Connect(function(hit) | |
6663 | if hit.Anchored == false and hit.Parent ~= Head and hit.Parent ~= Character and hit.Parent ~= Effects then | |
6664 | Kill(hit) | |
6665 | end | |
6666 | end) | |
6667 | local I = 0 | |
6668 | repeat | |
6669 | Swait() | |
6670 | I = I + 1 | |
6671 | if I <= 10 then | |
6672 | BEAM.Transparency = BEAM.Transparency - 0.1 | |
6673 | end | |
6674 | local STARTPOS = RightArm.CFrame*CF(0,-4,0).p | |
6675 | local ENDHIT,ENDPOS = CastProperRay(STARTPOS,Mouse.Hit.p,650,Character) | |
6676 | local DISTANCE = (STARTPOS - ENDPOS).Magnitude | |
6677 | BEAM.CFrame = CF(STARTPOS,ENDPOS)*CF(0,0,-DISTANCE/2)*ANGLES(RAD(0),RAD(0),RAD(I*5)) | |
6678 | BEAM.Size = VT(2,2,DISTANCE) | |
6679 | WACKYEFFECT({Time = 5, EffectType = "Box", Size = VT(1,1,1), Size2 = VT(1,1,1), Transparency = 0, Transparency2 = 1, CFrame = CF(ENDPOS), MoveToPos = CF(ENDPOS)*ANGLES(RAD(MRANDOM(-180,180)),RAD(MRANDOM(-180,180)),RAD(MRANDOM(-180,180)))*CF(0,15,0).p, RotationX = MRANDOM(-5,5), RotationY = MRANDOM(-5,5), RotationZ = MRANDOM(-5,5), Material = "Neon", Color = SKILLTEXTCOLOR, SoundID = nil, SoundPitch = nil, SoundVolume = nil}) | |
6680 | WACKYEFFECT({Time = 5, EffectType = "Block", Size = VT(5,5,5), Size2 = VT(0,0,0), Transparency = 0, Transparency2 = 0.25, CFrame = RightArm.CFrame*CF(0,-4,0), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = SKILLTEXTCOLOR, SoundID = nil, SoundPitch = 0.6, SoundVolume = 6}) | |
6681 | WACKYEFFECT({Time = 5, EffectType = "Block", Size = VT(5,5,5), Size2 = VT(0,0,0), Transparency = 0, Transparency2 = 0.25, CFrame = CF(ENDPOS), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = SKILLTEXTCOLOR, SoundID = nil, SoundPitch = 0.6, SoundVolume = 6}) | |
6682 | GYRO.cframe = CF(RootPart.Position,Mouse.Hit.p) | |
6683 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.25 * COS(SINE / 12)) * ANGLES(RAD(4 + 2.5 * SIN(SINE / 12)), RAD(0), RAD(45)), 1 / Animation_Speed) | |
6684 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(15 + 4.5 * SIN(SINE / 12)), RAD(0), RAD(-45 - 4 * SIN(SINE / 12))), 1 / Animation_Speed) | |
6685 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5 + 0.025 * COS(SINE / 12), -0.5) * ANGLES(RAD(90), RAD(0 - 7.5 * SIN(SINE / 12)), RAD(45 + 7.5 * SIN(SINE / 12))) * RIGHTSHOULDERC0, 1 / Animation_Speed) | |
6686 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5 + 0.025 * COS(SINE / 12), 0) * ANGLES(RAD(0), RAD(0 + 7.5 * SIN(SINE / 12)), RAD(-12 - 7.5 * SIN(SINE / 12))) * LEFTSHOULDERC0, 1 / Animation_Speed) | |
6687 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -1, -0.01) * ANGLES(RAD(-7.5 * SIN(SINE / 12)), RAD(75), RAD(0)) * ANGLES(RAD(-8 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed) | |
6688 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -0.5, -0.5) * ANGLES(RAD(-7.5 * SIN(SINE / 12)), RAD(-90), RAD(0)) * ANGLES(RAD(-8 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed) | |
6689 | if ENDHIT ~= nil then | |
6690 | if ENDHIT.Anchored == false and ENDHIT.Parent ~= Effects then | |
6691 | Banish(ENDHIT) | |
6692 | end | |
6693 | end | |
6694 | until LOOP.Playing == false | |
6695 | GYRO:remove() | |
6696 | BEAM:remove() | |
6697 | ATTACK = false | |
6698 | Rooted = false | |
6699 | end | |
6700 | function Deathbound() | |
6701 | CreateSound(LAUGHS[MRANDOM(1,#LAUGHS)], Torso, 10, 1, false) | |
6702 | ATTACK = true | |
6703 | Rooted = true | |
6704 | for i=0, 1, 0.1 / Animation_Speed do | |
6705 | Swait() | |
6706 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 1 + 0.25 * COS(SINE / 12)) * ANGLES(RAD(0), RAD(0), RAD(0)), 1 / Animation_Speed) | |
6707 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(15 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed) | |
6708 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 1, 0) * ANGLES(RAD(15), RAD(0), RAD(12)) * RIGHTSHOULDERC0, 1 / Animation_Speed) | |
6709 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 1, 0) * ANGLES(RAD(15), RAD(0), RAD(-12)) * LEFTSHOULDERC0, 1 / Animation_Speed) | |
6710 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -1, -0.01) * ANGLES(RAD(-35-2.5 * SIN(SINE / 12)), RAD(75), RAD(0)) * ANGLES(RAD(-8 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed) | |
6711 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -0.5, -0.5) * ANGLES(RAD(-35-2.5 * SIN(SINE / 12)), RAD(-90), RAD(0)) * ANGLES(RAD(-8 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed) | |
6712 | end | |
6713 | local DONE = false | |
6714 | local GATE = nil | |
6715 | local GATESPIN = true | |
6716 | coroutine.resume(coroutine.create(function() | |
6717 | repeat | |
6718 | Swait() | |
6719 | if GATE ~= nil then | |
6720 | GATE.CFrame = GATE.CFrame * ANGLES(RAD(0), RAD(-3), RAD(0)) | |
6721 | end | |
6722 | until GATESPIN == false | |
6723 | end)) | |
6724 | coroutine.resume(coroutine.create(function() | |
6725 | repeat | |
6726 | Swait() | |
6727 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0.2 - 0.25 * COS(SINE / 12)) * ANGLES(RAD(15), RAD(0), RAD(0)), 1 / Animation_Speed) | |
6728 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(5 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed) | |
6729 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5 + 0.25 * COS(SINE / 12), 0) * ANGLES(RAD(15), RAD(0), RAD(5)) * RIGHTSHOULDERC0, 1 / Animation_Speed) | |
6730 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5 + 0.25 * COS(SINE / 12), 0) * ANGLES(RAD(15), RAD(0), RAD(-5)) * LEFTSHOULDERC0, 1 / Animation_Speed) | |
6731 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -1, -0.01) * ANGLES(RAD(-35-2.5 * SIN(SINE / 12)), RAD(75), RAD(0)) * ANGLES(RAD(-8 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed) | |
6732 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -0.5, -0.5) * ANGLES(RAD(-35-2.5 * SIN(SINE / 12)), RAD(-90), RAD(0)) * ANGLES(RAD(-8 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed) | |
6733 | until DONE == true | |
6734 | Swait(35) | |
6735 | for i = 1, 35 do | |
6736 | Swait(4) | |
6737 | local FIRED = false | |
6738 | local CHILDREN = workspace:GetDescendants() | |
6739 | for index, CHILD in pairs(CHILDREN) do | |
6740 | if CHILD.ClassName == "Model" and CHILD ~= Character then | |
6741 | local HUM = CHILD:FindFirstChildOfClass("Humanoid") | |
6742 | if HUM then | |
6743 | local TORSO = CHILD:FindFirstChild("Torso") or CHILD:FindFirstChild("UpperTorso") | |
6744 | if TORSO then | |
6745 | if (TORSO.Position - GATE.Position).Magnitude <= GATE.Size.X/10.5 + TORSO.Size.Magnitude/5 then | |
6746 | local HITFLOOR,HITPOS = Raycast(TORSO.Position, (CF(TORSO.Position, TORSO.Position + VT(0, -1, 0))).lookVector, 15, Character) | |
6747 | local CFRAME = CF(HITPOS)*ANGLES(RAD(MRANDOM(-15,15)),RAD(MRANDOM(-15,15)),RAD(MRANDOM(-15,15))) | |
6748 | WACKYEFFECT({Time = 25, EffectType = "Wave", Size = VT(10.3,0,0.30), Size2 = VT(1,1.5,1), Transparency = 0, Transparency2 = 1, CFrame = CFRAME, MoveToPos = CFRAME*CF(0,0.5,0).p, RotationX = 0, RotationY = -15, RotationZ = 0, Material = "Neon", Color = C3(58,125,21), SoundID = 160718677, SoundPitch = 1.5, SoundVolume = 6}) | |
6749 | WACKYEFFECT({Time = 25, EffectType = "Wave", Size = VT(10.3,0,0.30), Size2 = VT(2,0.5,2), Transparency = 0, Transparency2 = 1, CFrame = CFRAME, MoveToPos = nil, RotationX = 0, RotationY = -15, RotationZ = 0, Material = "Neon", Color = C3(58,125,21), SoundID = nil, SoundPitch = nil, SoundVolume = nil}) | |
6750 | SpawnTrail(CFRAME.p,CFRAME*CF(0,1000,0).p) | |
6751 | Banish(CHILD) | |
6752 | FIRED = true | |
6753 | break | |
6754 | end | |
6755 | end | |
6756 | end | |
6757 | end | |
6758 | end | |
6759 | if FIRED == false then | |
6760 | local CFRAME = GATE.CFrame*ANGLES(RAD(0),RAD(MRANDOM(0,360)),RAD(0))*CF(0,0,MRANDOM(2,math.ceil(GATE.Size.X/10.5)))*ANGLES(RAD(MRANDOM(-15,15)),RAD(MRANDOM(-15,15)),RAD(MRANDOM(-15,15))) | |
6761 | WACKYEFFECT({Time = 25, EffectType = "Wave", Size = VT(10.3,0,0.30), Size2 = VT(1,1.5,1), Transparency = 0, Transparency2 = 1, CFrame = CFRAME, MoveToPos = CFRAME*CF(0,0.5,0).p, RotationX = 0, RotationY = -15, RotationZ = 0, Material = "Neon", Color = C3(58,125,21), SoundID = 160718677, SoundPitch = 1.5, SoundVolume = 6}) | |
6762 | WACKYEFFECT({Time = 25, EffectType = "Wave", Size = VT(10.3,0,0.30), Size2 = VT(2,0.5,2), Transparency = 0, Transparency2 = 1, CFrame = CFRAME, MoveToPos = nil, RotationX = 0, RotationY = -15, RotationZ = 0, Material = "Neon", Color = C3(58,125,21), SoundID = nil, SoundPitch = nil, SoundVolume = nil}) | |
6763 | SpawnTrail(CFRAME.p,CFRAME*CF(0,1000,0).p) | |
6764 | local HITBOD = Raycast(CFRAME.p, (CF(CFRAME.p, CFRAME.p + VT(0, 1, 0))).lookVector, 1000, Character) | |
6765 | if HITBOD ~= nil then | |
6766 | if HITBOD.Parent:FindFirstChildOfClass("Humanoid") then | |
6767 | Kill(HITBOD.Parent) | |
6768 | end | |
6769 | end | |
6770 | end | |
6771 | end | |
6772 | for i = 1, 45 do | |
6773 | Swait() | |
6774 | GATE.Size = GATE.Size - VT(10,0,10) | |
6775 | end | |
6776 | GATESPIN = false | |
6777 | GATE:remove() | |
6778 | end)) | |
6779 | Swait(15) | |
6780 | local HITFLOOR,HITPOS = Raycast(RootPart.Position, (CF(RootPart.Position, RootPart.Position + VT(0, -1, 0))).lookVector, 15, Character) | |
6781 | GATE = CreatePart(3, Effects, "Neon", 0, 1, "Teal", "Gate", VT(0,0,0)) | |
6782 | local DECAL = IT("Decal",GATE) | |
6783 | DECAL.Texture = "http://www.roblox.com/asset/?id=153700391" | |
6784 | DECAL.Face = "Top" | |
6785 | GATE.CFrame = CF(HITPOS) | |
6786 | CreateSound(160718677, GATE, 7, 1.3, false) | |
6787 | for i = 1, 45 do | |
6788 | Swait() | |
6789 | GATE.Size = GATE.Size + VT(10,10,10) | |
6790 | end | |
6791 | CreateSound(160718677, RightHole, 7, 1, false) | |
6792 | CreateSound(160718677, LeftHole, 7, 1, false) | |
6793 | WACKYEFFECT({Time = 25, EffectType = "Wave", Size = VT(10.3,0,0.30), Size2 = VT(10,10,10), Transparency = 0, Transparency2 = 1, CFrame = RightHole.CFrame*CF(0,-1,0) * ANGLES(RAD(180), RAD(0), RAD(0)), MoveToPos = nil, RotationX = 0, RotationY = -5, RotationZ = 0, Material = "Neon", Color = C3(58,125,21), SoundID = nil, SoundPitch = nil, SoundVolume = nil}) | |
6794 | WACKYEFFECT({Time = 25, EffectType = "Wave", Size = VT(10.3,0,0.30), Size2 = VT(10,10,10), Transparency = 0, Transparency2 = 1, CFrame = LeftHole.CFrame*CF(0,-1,0) * ANGLES(RAD(180), RAD(0), RAD(0)), MoveToPos = nil, RotationX = 0, RotationY = 5, RotationZ = 0, Material = "Neon", Color = C3(58,125,21), SoundID = nil, SoundPitch = nil, SoundVolume = nil}) | |
6795 | ATTACK = false | |
6796 | Rooted = false | |
6797 | DONE = true | |
6798 | end | |
6799 | ||
6800 | ||
6801 | --//=================================\\ | |
6802 | --|| ASSIGN THINGS TO KEYS | |
6803 | --\\=================================// | |
6804 | ||
6805 | function MouseDown(Mouse) | |
6806 | if ATTACK == false then | |
6807 | Click() | |
6808 | end | |
6809 | end | |
6810 | ||
6811 | function MouseUp(Mouse) | |
6812 | HOLD = false | |
6813 | end | |
6814 | ||
6815 | function KeyDown(Key) | |
6816 | KEYHOLD = true | |
6817 | if Key == "z" and ATTACK == false then | |
6818 | Banisher_Bullet() | |
6819 | end | |
6820 | ||
6821 | if Key == "c" and ATTACK == false then | |
6822 | BanishmentBeam() | |
6823 | end | |
6824 | ||
6825 | if Key == "v" and ATTACK == false then | |
6826 | Teleport() | |
6827 | end | |
6828 | ||
6829 | if Key == "x" and ATTACK == false then | |
6830 | Deathbound() | |
6831 | end | |
6832 | ||
6833 | if Key == "1" and ATTACK == false then | |
6834 | Erruption() | |
6835 | end | |
6836 | if Key == "2" and ATTACK == false then | |
6837 | Prison_Key() | |
6838 | end | |
6839 | if Key == "3" and ATTACK == false then | |
6840 | Taunt2() | |
6841 | end | |
6842 | if Key == "4" and ATTACK == false then | |
6843 | Sky() | |
6844 | end | |
6845 | if Key == "5" and ATTACK == false then | |
6846 | LimbRip() | |
6847 | end | |
6848 | if Key == "6" and ATTACK == false then | |
6849 | Strike () | |
6850 | end | |
6851 | if Key == "7" and ATTACK == false then | |
6852 | LavaAura() | |
6853 | end | |
6854 | if Key == "8" and ATTACK == false then | |
6855 | Black_Flames() | |
6856 | end | |
6857 | if Key == "9" and ATTACK == false then | |
6858 | Absol() | |
6859 | end | |
6860 | if Key == "0" and ATTACK == false then | |
6861 | TastyBlood() | |
6862 | end | |
6863 | if Key == "-" and ATTACK == false then | |
6864 | Taunt() | |
6865 | end | |
6866 | if Key == "=" and ATTACK == false then | |
6867 | Extreme_Offset() | |
6868 | end | |
6869 | if Key == "q" and ATTACK == false then | |
6870 | LavaBeam() | |
6871 | end | |
6872 | end | |
6873 | ||
6874 | function KeyUp(Key) | |
6875 | KEYHOLD = false | |
6876 | end | |
6877 | ||
6878 | Mouse.Button1Down:connect(function(NEWKEY) | |
6879 | MouseDown(NEWKEY) | |
6880 | end) | |
6881 | Mouse.Button1Up:connect(function(NEWKEY) | |
6882 | MouseUp(NEWKEY) | |
6883 | end) | |
6884 | Mouse.KeyDown:connect(function(NEWKEY) | |
6885 | KeyDown(NEWKEY) | |
6886 | end) | |
6887 | Mouse.KeyUp:connect(function(NEWKEY) | |
6888 | KeyUp(NEWKEY) | |
6889 | end) | |
6890 | ||
6891 | --//=================================\\ | |
6892 | --\\=================================// | |
6893 | ||
6894 | ||
6895 | ||
6896 | function unanchor() | |
6897 | for _, c in pairs(Character:GetChildren()) do | |
6898 | if c:IsA("BasePart") and c ~= RootPart then | |
6899 | c.Anchored = false | |
6900 | end | |
6901 | end | |
6902 | if UNANCHOR == true then | |
6903 | RootPart.Anchored = false | |
6904 | else | |
6905 | RootPart.Anchored = true | |
6906 | end | |
6907 | end | |
6908 | ||
6909 | --//=================================\\ | |
6910 | --|| WRAP THE WHOLE SCRIPT UP | |
6911 | --\\=================================// | |
6912 | ||
6913 | Humanoid.Changed:connect(function(Jump) | |
6914 | if Jump == "Jump" and (Disable_Jump == true) then | |
6915 | Humanoid.Jump = false | |
6916 | end | |
6917 | end) | |
6918 | ||
6919 | while true do | |
6920 | Swait() | |
6921 | script.Parent = WEAPONGUI | |
6922 | ANIMATE.Parent = nil | |
6923 | for _,v in next, Humanoid:GetPlayingAnimationTracks() do | |
6924 | v:Stop(); | |
6925 | end | |
6926 | SINE = SINE + CHANGE | |
6927 | local TORSOVELOCITY = (RootPart.Velocity * VT(1, 0, 1)).magnitude | |
6928 | local TORSOVERTICALVELOCITY = RootPart.Velocity.y | |
6929 | local HITFLOOR = Raycast(RootPart.Position, (CF(RootPart.Position, RootPart.Position + VT(0, -1, 0))).lookVector, 4+Humanoid.HipHeight, Character) | |
6930 | local WALKSPEEDVALUE = 8 / (Humanoid.WalkSpeed / 16) | |
6931 | Humanoid.HipHeight = 1 | |
6932 | if TORSOVERTICALVELOCITY > 1 and HITFLOOR == nil then | |
6933 | ANIM = "Jump" | |
6934 | if ATTACK == false then | |
6935 | RootJoint.C0 = Clerp(RootJoint.C0, ROOTC0 * CF(0, 0, 0) * ANGLES(RAD(-5), RAD(0), RAD(0)), 1 / Animation_Speed) | |
6936 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0 , 0 + ((1) - 1)) * ANGLES(RAD(-25), RAD(0), RAD(0)), 1 / Animation_Speed) | |
6937 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, 0) * ANGLES(RAD(-35), RAD(0), RAD(25 + 10 * COS(SINE / 12))) * RIGHTSHOULDERC0, 1 / Animation_Speed) | |
6938 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, 0) * ANGLES(RAD(-35), RAD(0), RAD(-25 - 10 * COS(SINE / 12))) * LEFTSHOULDERC0, 1 / Animation_Speed) | |
6939 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -0.4, -0.6) * ANGLES(RAD(1), RAD(90), RAD(0)) * ANGLES(RAD(-1 * SIN(SINE / 6)), RAD(0), RAD(0)), 1 / Animation_Speed) | |
6940 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1, 0) * ANGLES(RAD(0), RAD(-85), RAD(0)) * ANGLES(RAD(-1 * SIN(SINE / 6)), RAD(0), RAD(0)), 1 / Animation_Speed) | |
6941 | end | |
6942 | elseif TORSOVERTICALVELOCITY < -1 and HITFLOOR == nil then | |
6943 | ANIM = "Fall" | |
6944 | if ATTACK == false then | |
6945 | RootJoint.C0 = Clerp(RootJoint.C0, ROOTC0 * CF(0, 0, 0) * ANGLES(RAD(15), RAD(0), RAD(0)), 1 / Animation_Speed) | |
6946 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0 , 0 + ((1) - 1)) * ANGLES(RAD(15), RAD(0), RAD(0)), 1 / Animation_Speed) | |
6947 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, 0) * ANGLES(RAD(35 - 4 * COS(SINE / 6)), RAD(0), RAD(45 + 10 * COS(SINE / 12))) * RIGHTSHOULDERC0, 1 / Animation_Speed) | |
6948 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, 0) * ANGLES(RAD(35 - 4 * COS(SINE / 6)), RAD(0), RAD(-45 - 10 * COS(SINE / 12))) * LEFTSHOULDERC0, 1 / Animation_Speed) | |
6949 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -0.3, -0.7) * ANGLES(RAD(-25 + 5 * SIN(SINE / 12)), RAD(90), RAD(0)) * ANGLES(RAD(-1 * SIN(SINE / 6)), RAD(0), RAD(0)), 1 / Animation_Speed) | |
6950 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -0.8, -0.3) * ANGLES(RAD(-10), RAD(-80), RAD(0)) * ANGLES(RAD(-1 * SIN(SINE / 6)), RAD(0), RAD(0)), 1 / Animation_Speed) | |
6951 | end | |
6952 | elseif TORSOVELOCITY < 1 and HITFLOOR ~= nil then | |
6953 | ANIM = "Idle" | |
6954 | if ATTACK == false then | |
6955 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.1 * COS(SINE / 12)) * ANGLES(RAD(0), RAD(0), RAD(0)), 1 / Animation_Speed) | |
6956 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(0 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed) | |
6957 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(0.75, 0.5 + 0.05 * SIN(SINE / 12), -0.7) * ANGLES(RAD(0), RAD(0), RAD(-95)) * ANGLES(RAD(5), RAD(0), RAD(0)) * RIGHTSHOULDERC0, 1 / Animation_Speed) | |
6958 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-0.75, 0.35 + 0.05 * SIN(SINE / 12), -0.6) * ANGLES(RAD(0), RAD(0), RAD(92)) * ANGLES(RAD(0), RAD(0), RAD(0)) * LEFTSHOULDERC0, 1 / Animation_Speed) | |
6959 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -0.6 - 0.05 * SIN(SINE / 12), -0.5) * ANGLES(RAD(0), RAD(70), RAD(0)) * ANGLES(RAD(-1), RAD(0), RAD(-25)), 1 / Animation_Speed) | |
6960 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1 - 0.05 * SIN(SINE / 12), 0) * ANGLES(RAD(-5), RAD(-70), RAD(0)) * ANGLES(RAD(1), RAD(0), RAD(0)), 1 / Animation_Speed) | |
6961 | end | |
6962 | elseif TORSOVELOCITY > 1 and HITFLOOR ~= nil then | |
6963 | ANIM = "Walk" | |
6964 | if ATTACK == false then | |
6965 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.1 * COS(SINE / 12)) * ANGLES(RAD(10), RAD(0), RAD(0)), 1 / Animation_Speed) | |
6966 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(-10 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed) | |
6967 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(0.75, 0.5 + 0.05 * SIN(SINE / 12), -0.7) * ANGLES(RAD(0), RAD(0), RAD(-95)) * ANGLES(RAD(5), RAD(0), RAD(0)) * RIGHTSHOULDERC0, 1 / Animation_Speed) | |
6968 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-0.75, 0.35 + 0.05 * SIN(SINE / 12), -0.6) * ANGLES(RAD(0), RAD(0), RAD(92)) * ANGLES(RAD(0), RAD(0), RAD(0)) * LEFTSHOULDERC0, 1 / Animation_Speed) | |
6969 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -0.6 - 0.05 * SIN(SINE / 12), -0.5) * ANGLES(RAD(0), RAD(70), RAD(0)) * ANGLES(RAD(-1), RAD(0), RAD(-35)), 1 / Animation_Speed) | |
6970 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1 - 0.05 * SIN(SINE / 12), 0) * ANGLES(RAD(-15), RAD(-70), RAD(0)) * ANGLES(RAD(1), RAD(0), RAD(0)), 1 / Animation_Speed) | |
6971 | end | |
6972 | end | |
6973 | if ANIM ~= "Walk" and FADERS == true then | |
6974 | if MRANDOM(1,7) == 1 then | |
6975 | CharacterFade(C3(151, 0, 0),65,R_RANDOM(Torso.CFrame,0.5).p) | |
6976 | end | |
6977 | end | |
6978 | unanchor() | |
6979 | if Rooted == false then | |
6980 | Disable_Jump = false | |
6981 | Humanoid.WalkSpeed = Speed+(DAMAGEMULTIPLIER/5) | |
6982 | elseif Rooted == true then | |
6983 | Disable_Jump = true | |
6984 | Humanoid.WalkSpeed = 0 | |
6985 | end | |
6986 | if Head:FindFirstChild("face") then | |
6987 | Head:FindFirstChild("face"):remove() | |
6988 | end | |
6989 | Humanoid.Name = "Black Butler" | |
6990 | Humanoid.MaxHealth = "inf" | |
6991 | Humanoid.Health = "inf" | |
6992 | end | |
6993 | sick.Parent = Torso | |
6994 | sick.Playing = true | |
6995 | sick.SoundId = "rbxassetid://566603081" | |
6996 | for _, c in pairs(Weapon:GetChildren()) do | |
6997 | if c.Name == "Eon" then | |
6998 | c.BrickColor = BRICKC(CHOSENBRICK) | |
6999 | end | |
7000 | end | |
7001 | ||
7002 | --//=================================\\ | |
7003 | --\\=================================// | |
7004 | ||
7005 | refit() | |
7006 | ||
7007 | ||
7008 | ||
7009 | --//====================================================\\-- | |
7010 | --|| END OF SCRIPT | |
7011 | --\\====================================================//-- |