SHOW:
|
|
- or go back to the newest paste.
1 | --//====================================================\\-- | |
2 | --|| CREATED BY SHACKLUSTER, EDIT BY AINGOAM | |
3 | --\\====================================================//-- | |
4 | ||
5 | ||
6 | ||
7 | wait(0.2) | |
8 | ||
9 | ||
10 | ||
11 | Player = game:GetService("Players").LocalPlayer | |
12 | PlayerGui = Player.PlayerGui | |
13 | Cam = workspace.CurrentCamera | |
14 | Backpack = Player.Backpack | |
15 | Character = Player.Character | |
16 | Humanoid = Character.Humanoid | |
17 | Mouse = Player:GetMouse() | |
18 | RootPart = Character["HumanoidRootPart"] | |
19 | Torso = Character["Torso"] | |
20 | Head = Character["Head"] | |
21 | RightArm = Character["Right Arm"] | |
22 | LeftArm = Character["Left Arm"] | |
23 | RightLeg = Character["Right Leg"] | |
24 | LeftLeg = Character["Left Leg"] | |
25 | RootJoint = RootPart["RootJoint"] | |
26 | Neck = Torso["Neck"] | |
27 | RightShoulder = Torso["Right Shoulder"] | |
28 | LeftShoulder = Torso["Left Shoulder"] | |
29 | RightHip = Torso["Right Hip"] | |
30 | LeftHip = Torso["Left Hip"] | |
31 | local sick = Instance.new("Sound",Torso) | |
32 | - | sick.SoundId = "rbxassetid://325107611" |
32 | + | sick.SoundId = "rbxassetid://145655556" |
33 | sick.Looped = true | |
34 | sick.Pitch = 1 | |
35 | - | sick.Volume = 5 |
35 | + | sick.Volume = 8 |
36 | sick.TimePosition = 16.3 | |
37 | sick:Play() | |
38 | ||
39 | local naeeym2 = Instance.new("BillboardGui",Character) | |
40 | naeeym2.AlwaysOnTop = true | |
41 | naeeym2.Size = UDim2.new(5,35,2,35) | |
42 | - | hat = Instance.new("Part", game.Players.LocalPlayer.Character.Head) |
42 | + | |
43 | - | w3ld = Instance.new("Weld", hat) |
43 | + | |
44 | - | w3ld.Part0 = hat |
44 | + | |
45 | - | w3ld.Part1 = game.Players.LocalPlayer.Character.Head |
45 | + | |
46 | - | w3ld.C0 = w3ld.C0 * CFrame.new(0,-0.5,-0.1) |
46 | + | |
47 | - | mesh = Instance.new("SpecialMesh", hat) |
47 | + | |
48 | - | mesh.MeshId = "http://www.roblox.com/asset/?id=19326912" |
48 | + | |
49 | - | mesh.TextureId = "http://www.roblox.com/asset/?id=102397532" |
49 | + | |
50 | - | ---------------------------------------- |
50 | + | tecks2.Text = "Βĺâçķ C͎̕o̼̹͆d͓͋͜e̝̞" |
51 | - | -- Originally made by Alfederate :D -- |
51 | + | |
52 | - | ---------------------------------------- |
52 | + | |
53 | tecks2.TextStrokeTransparency = 1 | |
54 | - | -- there's no time to explain! -- |
54 | + | |
55 | - | for i,v in pairs(game:GetService("Players").LocalPlayer.Character:children()) do if v:IsA("Accessory") then v:Destroy() end end for i,v in pairs(game:GetService("Players").LocalPlayer.Character:GetChildren()) do if v:IsA("Shirt") then v:Remove() end end for i,v in pairs(game:GetService("Players").LocalPlayer.Character:GetChildren()) do if v:IsA("Pants") then v:Remove() end end wait()shirt = Instance.new("Shirt", game:GetService("Players").LocalPlayer.Character) shirt.Name = "Shirt" pants = Instance.new("Pants", game:GetService("Players").LocalPlayer.Character) pants.Name = "Pants" |
55 | + | tecks2.TextStrokeColor3 = Color3.new(0,0,0) |
56 | - | game:GetService("Players").LocalPlayer.Character.Shirt.ShirtTemplate = "http://www.roblox.com/asset/?id=781724178" |
56 | + | tecks2.Size = UDim2.new(1,0,0.5,0) |
57 | - | game:GetService("Players").LocalPlayer.Character.Pants.PantsTemplate = "http://www.roblox.com/asset/?id=783023476" |
57 | + | |
58 | - | game.Players.LocalPlayer.Character.Head.face.Texture = "http://www.roblox.com/asset/?id=775503445" |
58 | + | |
59 | IT = Instance.new | |
60 | CF = CFrame.new | |
61 | VT = Vector3.new | |
62 | RAD = math.rad | |
63 | C3 = Color3.new | |
64 | UD2 = UDim2.new | |
65 | BRICKC = BrickColor.new | |
66 | ANGLES = CFrame.Angles | |
67 | EULER = CFrame.fromEulerAnglesXYZ | |
68 | COS = math.cos | |
69 | ACOS = math.acos | |
70 | SIN = math.sin | |
71 | ASIN = math.asin | |
72 | ABS = math.abs | |
73 | MRANDOM = math.random | |
74 | - | tecks2.Text = "Rick" |
74 | + | |
75 | ||
76 | ||
77 | ||
78 | local particles = Instance.new("ParticleEmitter",efxBlock) | |
79 | - | tecks2.TextStrokeColor3 = Color3.new(0,155,155) |
79 | + | particles.LightEmission = .95 |
80 | - | tecks2.Size = UDim2.new(0,155,155) |
80 | + | particles.Size = Size |
81 | particles.Name = "Fire" | |
82 | particles.Transparency = Transparency | |
83 | particles.LockedToPart = true | |
84 | particles.VelocityInheritance = .5 | |
85 | particles.LockedToPart = true | |
86 | particles.Rate = 70 | |
87 | particles.Texture = "rbxassetid://12417396" | |
88 | particles.Lifetime = NumberRange.new(2,2) | |
89 | particles.RotSpeed = NumberRange.new(100,100) | |
90 | particles.Speed = NumberRange.new(7,7) | |
91 | script.Parent = efxBlock | |
92 | fire = particles | |
93 | local offset = Vector3.new(-0.11, .23, -0.5) | |
94 | local weld = Instance.new("Weld",c.Head) | |
95 | weld.Part0 = c.Head | |
96 | weld.Part1 = efxBlock | |
97 | weld.C0 = CFrame.new(offset) * CFrame.Angles(math.rad(-40),math.rad(10),math.rad(40)) | |
98 | ||
99 | function CreateMesh(MESH, PARENT, MESHTYPE, MESHID, TEXTUREID, SCALE, OFFSET) | |
100 | local NEWMESH = IT(MESH) | |
101 | if MESH == "SpecialMesh" then | |
102 | NEWMESH.MeshType = MESHTYPE | |
103 | if MESHID ~= "nil" and MESHID ~= "" then | |
104 | NEWMESH.MeshId = "http://www.roblox.com/asset/?id="..MESHID | |
105 | end | |
106 | if TEXTUREID ~= "nil" and TEXTUREID ~= "" then | |
107 | NEWMESH.TextureId = "http://www.roblox.com/asset/?id="..TEXTUREID | |
108 | end | |
109 | end | |
110 | NEWMESH.Offset = OFFSET or VT(0, 0, 0) | |
111 | NEWMESH.Scale = SCALE | |
112 | NEWMESH.Parent = PARENT | |
113 | return NEWMESH | |
114 | end | |
115 | ||
116 | function CreatePart(FORMFACTOR, PARENT, MATERIAL, REFLECTANCE, TRANSPARENCY, BRICKCOLOR, NAME, SIZE) | |
117 | local NEWPART = IT("Part") | |
118 | NEWPART.formFactor = FORMFACTOR | |
119 | NEWPART.Reflectance = REFLECTANCE | |
120 | NEWPART.Transparency = TRANSPARENCY | |
121 | NEWPART.CanCollide = false | |
122 | NEWPART.Locked = true | |
123 | NEWPART.BrickColor = BRICKC(tostring(BRICKCOLOR)) | |
124 | NEWPART.Name = NAME | |
125 | NEWPART.Size = SIZE | |
126 | NEWPART.Position = Torso.Position | |
127 | NEWPART.Material = MATERIAL | |
128 | NEWPART:BreakJoints() | |
129 | NEWPART.Parent = PARENT | |
130 | return NEWPART | |
131 | end | |
132 | ||
133 | ||
134 | --//=================================\\ | |
135 | --|| CUSTOMIZATION | |
136 | --\\=================================// | |
137 | ||
138 | Class_Name = "₱Ɽł₴₥.exe" | |
139 | Weapon_Name = "Add-ons" | |
140 | ||
141 | Custom_Colors = { | |
142 | Custom_Color_1 = BRICKC("Toothpaste"); --1st color for the weapon. | |
143 | Custom_Color_2 = BRICKC("Toothpaste"); --2nd color for the weapon. | |
144 | ||
145 | Custom_Color_3 = BRICKC("Toothpaste"); --Color for the abilities. | |
146 | Custom_Color_4 = BRICKC("Toothpaste"); --Color for the secondary bar. | |
147 | Custom_Color_5 = BRICKC("Toothpaste"); --Color for the mana bar. | |
148 | Custom_Color_6 = BRICKC("Toothpaste"); --Color for the health bar. | |
149 | Custom_Color_7 = BRICKC("Toothpaste"); --Color for the stun bar. | |
150 | ||
151 | Custom_Color_8 = BRICKC("Toothpaste"); --Background for the mana bar. | |
152 | Custom_Color_9 = BRICKC("Toothpaste"); --Background for the secondary mana bar. | |
153 | Custom_Color_10 = BRICKC("Toothpaste"); --Background for the stun bar. | |
154 | Custom_Color_11 = BRICKC("Toothpaste"); --Background for the health bar. | |
155 | Custom_Color_12 = BRICKC("Toothpaste"); --Background for the abilities. | |
156 | } | |
157 | ||
158 | ||
159 | Player_Size = 1 --Size of the player. | |
160 | Animation_Speed = 3 | |
161 | Frame_Speed = 1 / 60 -- (1 / 30) OR (1 / 60) | |
162 | ||
163 | local Speed = 36 | |
164 | local Effects2 = {} | |
165 | ||
166 | --//=================================\\ | |
167 | --|| END OF CUSTOMIZATION | |
168 | --\\=================================// | |
169 | ||
170 | local function weldBetween(a, b) | |
171 | local weldd = Instance.new("ManualWeld") | |
172 | weldd.Part0 = a | |
173 | weldd.Part1 = b | |
174 | weldd.C0 = CFrame.new() | |
175 | weldd.C1 = b.CFrame:inverse() * a.CFrame | |
176 | weldd.Parent = a | |
177 | return weldd | |
178 | end | |
179 | ||
180 | function createaccessory(attachmentpart,mesh,texture,scale,offset,color) | |
181 | local acs = Instance.new("Part") | |
182 | acs.CanCollide = false | |
183 | acs.Anchored = false | |
184 | acs.Size = Vector3.new(0,0,0) | |
185 | acs.CFrame = attachmentpart.CFrame | |
186 | acs.Parent = Character | |
187 | acs.BrickColor = color | |
188 | local meshs = Instance.new("SpecialMesh") | |
189 | meshs.MeshId = mesh | |
190 | meshs.TextureId = texture | |
191 | meshs.Parent = acs | |
192 | meshs.Scale = scale | |
193 | meshs.Offset = offset | |
194 | weldBetween(attachmentpart,acs) | |
195 | end | |
196 | ||
197 | function createbodypart(TYPE,COLOR,PART,OFFSET,SIZE) | |
198 | if TYPE == "Gem" then | |
199 | local acs = CreatePart(3, Character, "Neon", 0, 0, COLOR, "Part", VT(0,0,0)) | |
200 | acs.Anchored = false | |
201 | acs.CanCollide = false | |
202 | acs.CFrame = PART.CFrame | |
203 | local acs2 = CreateMesh("SpecialMesh", acs, "FileMesh", "9756362", "", SIZE, OFFSET) | |
204 | weldBetween(PART,acs) | |
205 | elseif TYPE == "Skull" then | |
206 | local acs = CreatePart(3, Character, "Neon", 0, 0, COLOR, "Part", VT(0,0,0)) | |
207 | acs.Anchored = false | |
208 | acs.CanCollide = false | |
209 | acs.CFrame = PART.CFrame | |
210 | local acs2 = CreateMesh("SpecialMesh", acs, "FileMesh", "4770583", "", SIZE, OFFSET) | |
211 | weldBetween(PART,acs) | |
212 | elseif TYPE == "Eye" then | |
213 | local acs = CreatePart(3, Character, "Neon", 0, 0, COLOR, "Part", VT(0,0,0)) | |
214 | acs.Anchored = false | |
215 | acs.CanCollide = false | |
216 | acs.CFrame = PART.CFrame | |
217 | local acs2 = CreateMesh("SpecialMesh", acs, "Sphere", "", "", SIZE, OFFSET) | |
218 | weldBetween(PART,acs) | |
219 | end | |
220 | end | |
221 | ||
222 | --//=================================\\ | |
223 | --|| USEFUL VALUES | |
224 | --\\=================================// | |
225 | ||
226 | local ROOTC0 = CF(0, 0, 0) * ANGLES(RAD(-90), RAD(0), RAD(180)) | |
227 | local NECKC0 = CF(0, 1, 0) * ANGLES(RAD(-90), RAD(0), RAD(180)) | |
228 | local RIGHTSHOULDERC0 = CF(-0.5, 0, 0) * ANGLES(RAD(0), RAD(90), RAD(0)) | |
229 | local LEFTSHOULDERC0 = CF(0.5, 0, 0) * ANGLES(RAD(0), RAD(-90), RAD(0)) | |
230 | local CO1 = 0 | |
231 | local CO2 = 0 | |
232 | local CO3 = 0 | |
233 | local CO4 = 0 | |
234 | local CHANGEDEFENSE = 0 | |
235 | local CHANGEDAMAGE = 0 | |
236 | local CHANGEMOVEMENT = 0 | |
237 | local ANIM = "Idle" | |
238 | local ATTACK = false | |
239 | local EQUIPPED = false | |
240 | local HOLD = false | |
241 | local COMBO = 1 | |
242 | local LASTPOINT = nil | |
243 | local BLCF = nil | |
244 | local SCFR = nil | |
245 | local STAGGERHITANIM = false | |
246 | local STAGGERANIM = false | |
247 | local STUNANIM = false | |
248 | local CRITCHANCENUMBER = 0 | |
249 | local IDLENUMBER = 0 | |
250 | local DONUMBER = 0 | |
251 | local HANDIDLE = false | |
252 | local SINE = 0 | |
253 | local CHANGE = 2 / Animation_Speed | |
254 | local WALKINGANIM = false | |
255 | local WALK = 0 | |
256 | local KEYHOLD = false | |
257 | local DISABLEJUMPING = false | |
258 | local HASBEENBLOCKED = false | |
259 | local STUNDELAYNUMBER = 0 | |
260 | local MANADELAYNUMBER = 0 | |
261 | local SECONDARYMANADELAYNUMBER = 0 | |
262 | local ROBLOXIDLEANIMATION = IT("Animation") | |
263 | ROBLOXIDLEANIMATION.Name = "Roblox Idle Animation" | |
264 | ROBLOXIDLEANIMATION.AnimationId = "http://www.roblox.com/asset/?id=180435571" | |
265 | --ROBLOXIDLEANIMATION.Parent = Humanoid | |
266 | local WEAPONGUI = IT("ScreenGui", nil) | |
267 | WEAPONGUI.Name = "Weapon GUI" | |
268 | local WEAPONTOOL = IT("HopperBin", nil) | |
269 | WEAPONTOOL.Name = Weapon_Name | |
270 | local Weapon = IT("Model") | |
271 | Weapon.Name = Weapon_Name | |
272 | local Effects = IT("Folder", Weapon) | |
273 | Effects.Name = "Effects" | |
274 | local ANIMATOR = Humanoid.Animator | |
275 | local ANIMATE = Character.Animate | |
276 | local HITPLAYERSOUNDS = {--[["199149137", "199149186", "199149221", "199149235", "199149269", "199149297"--]]"263032172", "263032182", "263032200", "263032221", "263032252", "263033191"} | |
277 | local HITARMORSOUNDS = {"199149321", "199149338", "199149367", "199149409", "199149452"} | |
278 | local HITWEAPONSOUNDS = {"199148971", "199149025", "199149072", "199149109", "199149119"} | |
279 | local HITBLOCKSOUNDS = {"199148933", "199148947"} | |
280 | local CUTSOUNDS = {"645750958","645747150"} | |
281 | local VICIOUSWOOSH = "658941933" | |
282 | local RELEASESOUND = "565538688" | |
283 | local CHARGESOUND = "565538601" | |
284 | local UNANCHOR = true | |
285 | local MAGICPARTICLE = "341277531" | |
286 | ||
287 | --//=================================\\ | |
288 | --\\=================================// | |
289 | - | local MAGICPARTICLE = "1278569371" |
289 | + | |
290 | --//=================================\\ | |
291 | --|| STATS | |
292 | --\\=================================// | |
293 | ||
294 | if Character:FindFirstChild("Stats") ~= nil then | |
295 | Character:FindFirstChild("Stats").Parent = nil | |
296 | end | |
297 | ||
298 | local Stats = IT("Folder", nil) | |
299 | Stats.Name = "Stats" | |
300 | local ChangeStat = IT("Folder", Stats) | |
301 | ChangeStat.Name = "ChangeStat" | |
302 | local Defense = IT("NumberValue", Stats) | |
303 | Defense.Name = "Defense" | |
304 | Defense.Value = 1 | |
305 | local Movement = IT("NumberValue", Stats) | |
306 | Movement.Name = "Movement" | |
307 | Movement.Value = 1 | |
308 | local Damage = IT("NumberValue", Stats) | |
309 | Damage.Name = "Damage" | |
310 | Damage.Value = 1 | |
311 | local Mana = IT("NumberValue", Stats) | |
312 | Mana.Name = "Mana" | |
313 | Mana.Value = 0 | |
314 | local SecondaryMana = IT("NumberValue", Stats) | |
315 | SecondaryMana.Name = "SecondaryMana" | |
316 | SecondaryMana.Value = 0 | |
317 | local CanCrit = IT("BoolValue", Stats) | |
318 | CanCrit.Name = "CanCrit" | |
319 | CanCrit.Value = false | |
320 | local CritChance = IT("NumberValue", Stats) | |
321 | CritChance.Name = "CritChance" | |
322 | CritChance.Value = 20 | |
323 | local CanPenetrateArmor = IT("BoolValue", Stats) | |
324 | CanPenetrateArmor.Name = "CanPenetrateArmor" | |
325 | CanPenetrateArmor.Value = false | |
326 | local AntiTeamKill = IT("BoolValue", Stats) | |
327 | AntiTeamKill.Name = "AntiTeamKill" | |
328 | AntiTeamKill.Value = false | |
329 | local Rooted = IT("BoolValue", Stats) | |
330 | Rooted.Name = "Rooted" | |
331 | Rooted.Value = false | |
332 | local Block = IT("BoolValue", Stats) | |
333 | Block.Name = "Block" | |
334 | Block.Value = false | |
335 | local RecentEnemy = IT("ObjectValue", Stats) | |
336 | RecentEnemy.Name = "RecentEnemy" | |
337 | RecentEnemy.Value = nil | |
338 | local StaggerHit = IT("BoolValue", Stats) | |
339 | StaggerHit.Name = "StaggerHit" | |
340 | StaggerHit.Value = false | |
341 | local Stagger = IT("BoolValue", Stats) | |
342 | Stagger.Name = "Stagger" | |
343 | Stagger.Value = false | |
344 | local Stun = IT("BoolValue", Stats) | |
345 | Stun.Name = "Stun" | |
346 | Stun.Value = false | |
347 | local StunValue = IT("NumberValue", Stats) | |
348 | StunValue.Name = "StunValue" | |
349 | StunValue.Value = 0 | |
350 | ||
351 | ||
352 | --//=================================\\ | |
353 | --\\=================================// | |
354 | ||
355 | ||
356 | ||
357 | ||
358 | ||
359 | --//=================================\\ | |
360 | --|| DEBUFFS / BUFFS | |
361 | --\\=================================// | |
362 | ||
363 | local DEFENSECHANGE1 = IT("NumberValue", ChangeStat) | |
364 | DEFENSECHANGE1.Name = "ChangeDefense" | |
365 | DEFENSECHANGE1.Value = 0 | |
366 | ||
367 | local MOVEMENTCHANGE1 = IT("NumberValue", nil) | |
368 | MOVEMENTCHANGE1.Name = "ChangeMovement" | |
369 | MOVEMENTCHANGE1.Value = 0 | |
370 | ||
371 | --//=================================\\ | |
372 | --\\=================================// | |
373 | ||
374 | ||
375 | ||
376 | ||
377 | ||
378 | --//=================================\\ | |
379 | --|| SAZERENOS' ARTIFICIAL HEARTBEAT | |
380 | --\\=================================// | |
381 | ||
382 | ArtificialHB = Instance.new("BindableEvent", script) | |
383 | ArtificialHB.Name = "ArtificialHB" | |
384 | ||
385 | script:WaitForChild("ArtificialHB") | |
386 | ||
387 | frame = Frame_Speed | |
388 | tf = 0 | |
389 | allowframeloss = false | |
390 | tossremainder = false | |
391 | lastframe = tick() | |
392 | script.ArtificialHB:Fire() | |
393 | ||
394 | game:GetService("RunService").Heartbeat:connect(function(s, p) | |
395 | tf = tf + s | |
396 | if tf >= frame then | |
397 | if allowframeloss then | |
398 | script.ArtificialHB:Fire() | |
399 | lastframe = tick() | |
400 | else | |
401 | for i = 1, math.floor(tf / frame) do | |
402 | script.ArtificialHB:Fire() | |
403 | end | |
404 | lastframe = tick() | |
405 | end | |
406 | if tossremainder then | |
407 | tf = 0 | |
408 | else | |
409 | tf = tf - frame * math.floor(tf / frame) | |
410 | end | |
411 | end | |
412 | end) | |
413 | ||
414 | --//=================================\\ | |
415 | --\\=================================// | |
416 | ||
417 | ||
418 | ||
419 | ||
420 | ||
421 | --//=================================\\ | |
422 | --|| SOME FUNCTIONS | |
423 | --\\=================================// | |
424 | ||
425 | function Raycast(POSITION, DIRECTION, RANGE, IGNOREDECENDANTS) | |
426 | return workspace:FindPartOnRay(Ray.new(POSITION, DIRECTION.unit * RANGE), IGNOREDECENDANTS) | |
427 | end | |
428 | ||
429 | function PositiveAngle(NUMBER) | |
430 | if NUMBER >= 0 then | |
431 | NUMBER = 0 | |
432 | end | |
433 | return NUMBER | |
434 | end | |
435 | ||
436 | function NegativeAngle(NUMBER) | |
437 | if NUMBER <= 0 then | |
438 | NUMBER = 0 | |
439 | end | |
440 | return NUMBER | |
441 | end | |
442 | ||
443 | function Swait(NUMBER) | |
444 | if NUMBER == 0 or NUMBER == nil then | |
445 | ArtificialHB.Event:wait() | |
446 | else | |
447 | for i = 1, NUMBER do | |
448 | ArtificialHB.Event:wait() | |
449 | end | |
450 | end | |
451 | end | |
452 | ||
453 | function QuaternionFromCFrame(cf) | |
454 | local mx, my, mz, m00, m01, m02, m10, m11, m12, m20, m21, m22 = cf:components() | |
455 | local trace = m00 + m11 + m22 | |
456 | if trace > 0 then | |
457 | local s = math.sqrt(1 + trace) | |
458 | local recip = 0.5 / s | |
459 | return (m21 - m12) * recip, (m02 - m20) * recip, (m10 - m01) * recip, s * 0.5 | |
460 | else | |
461 | local i = 0 | |
462 | if m11 > m00 then | |
463 | i = 1 | |
464 | end | |
465 | if m22 > (i == 0 and m00 or m11) then | |
466 | i = 2 | |
467 | end | |
468 | if i == 0 then | |
469 | local s = math.sqrt(m00 - m11 - m22 + 1) | |
470 | local recip = 0.5 / s | |
471 | return 0.5 * s, (m10 + m01) * recip, (m20 + m02) * recip, (m21 - m12) * recip | |
472 | elseif i == 1 then | |
473 | local s = math.sqrt(m11 - m22 - m00 + 1) | |
474 | local recip = 0.5 / s | |
475 | return (m01 + m10) * recip, 0.5 * s, (m21 + m12) * recip, (m02 - m20) * recip | |
476 | elseif i == 2 then | |
477 | local s = math.sqrt(m22 - m00 - m11 + 1) | |
478 | local recip = 0.5 / s return (m02 + m20) * recip, (m12 + m21) * recip, 0.5 * s, (m10 - m01) * recip | |
479 | end | |
480 | end | |
481 | end | |
482 | ||
483 | function QuaternionToCFrame(px, py, pz, x, y, z, w) | |
484 | local xs, ys, zs = x + x, y + y, z + z | |
485 | local wx, wy, wz = w * xs, w * ys, w * zs | |
486 | local xx = x * xs | |
487 | local xy = x * ys | |
488 | local xz = x * zs | |
489 | local yy = y * ys | |
490 | local yz = y * zs | |
491 | local zz = z * zs | |
492 | 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)) | |
493 | end | |
494 | ||
495 | function QuaternionSlerp(a, b, t) | |
496 | local cosTheta = a[1] * b[1] + a[2] * b[2] + a[3] * b[3] + a[4] * b[4] | |
497 | local startInterp, finishInterp; | |
498 | if cosTheta >= 0.0001 then | |
499 | if (1 - cosTheta) > 0.0001 then | |
500 | local theta = ACOS(cosTheta) | |
501 | local invSinTheta = 1 / SIN(theta) | |
502 | startInterp = SIN((1 - t) * theta) * invSinTheta | |
503 | finishInterp = SIN(t * theta) * invSinTheta | |
504 | else | |
505 | startInterp = 1 - t | |
506 | finishInterp = t | |
507 | end | |
508 | else | |
509 | if (1 + cosTheta) > 0.0001 then | |
510 | local theta = ACOS(-cosTheta) | |
511 | local invSinTheta = 1 / SIN(theta) | |
512 | startInterp = SIN((t - 1) * theta) * invSinTheta | |
513 | finishInterp = SIN(t * theta) * invSinTheta | |
514 | else | |
515 | startInterp = t - 1 | |
516 | finishInterp = t | |
517 | end | |
518 | end | |
519 | 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 | |
520 | end | |
521 | ||
522 | function Clerp(a, b, t) | |
523 | local qa = {QuaternionFromCFrame(a)} | |
524 | local qb = {QuaternionFromCFrame(b)} | |
525 | local ax, ay, az = a.x, a.y, a.z | |
526 | local bx, by, bz = b.x, b.y, b.z | |
527 | local _t = 1 - t | |
528 | return QuaternionToCFrame(_t * ax + t * bx, _t * ay + t * by, _t * az + t * bz, QuaternionSlerp(qa, qb, t)) | |
529 | end | |
530 | ||
531 | function CreateFrame(PARENT, TRANSPARENCY, BORDERSIZEPIXEL, POSITION, SIZE, COLOR, BORDERCOLOR, NAME) | |
532 | local frame = IT("Frame") | |
533 | frame.BackgroundTransparency = TRANSPARENCY | |
534 | frame.BorderSizePixel = BORDERSIZEPIXEL | |
535 | frame.Position = POSITION | |
536 | frame.Size = SIZE | |
537 | frame.BackgroundColor3 = COLOR | |
538 | frame.BorderColor3 = BORDERCOLOR | |
539 | frame.Name = NAME | |
540 | frame.Parent = PARENT | |
541 | return frame | |
542 | end | |
543 | ||
544 | function CreateLabel(PARENT, TEXT, TEXTCOLOR, TEXTFONTSIZE, TEXTFONT, TRANSPARENCY, BORDERSIZEPIXEL, STROKETRANSPARENCY, NAME) | |
545 | local label = IT("TextLabel") | |
546 | label.BackgroundTransparency = 1 | |
547 | label.Size = UD2(1, 0, 1, 0) | |
548 | label.Position = UD2(0, 0, 0, 0) | |
549 | label.TextColor3 = C3(255, 255, 255) | |
550 | label.TextStrokeTransparency = STROKETRANSPARENCY | |
551 | label.TextTransparency = TRANSPARENCY | |
552 | label.FontSize = TEXTFONTSIZE | |
553 | label.Font = TEXTFONT | |
554 | label.BorderSizePixel = BORDERSIZEPIXEL | |
555 | label.TextScaled = true | |
556 | label.Text = TEXT | |
557 | label.Name = NAME | |
558 | label.Parent = PARENT | |
559 | return label | |
560 | end | |
561 | ||
562 | function NoOutlines(PART) | |
563 | PART.TopSurface, PART.BottomSurface, PART.LeftSurface, PART.RightSurface, PART.FrontSurface, PART.BackSurface = 10, 10, 10, 10, 10, 10 | |
564 | end | |
565 | ||
566 | ||
567 | function CreateWeldOrSnapOrMotor(TYPE, PARENT, PART0, PART1, C0, C1) | |
568 | local NEWWELD = IT(TYPE) | |
569 | NEWWELD.Part0 = PART0 | |
570 | NEWWELD.Part1 = PART1 | |
571 | NEWWELD.C0 = C0 | |
572 | NEWWELD.C1 = C1 | |
573 | NEWWELD.Parent = PARENT | |
574 | return NEWWELD | |
575 | end | |
576 | ||
577 | function CreateSound(ID, PARENT, VOLUME, PITCH, DOESLOOP) | |
578 | local NEWSOUND = nil | |
579 | coroutine.resume(coroutine.create(function() | |
580 | NEWSOUND = IT("Sound", PARENT) | |
581 | NEWSOUND.Volume = VOLUME | |
582 | NEWSOUND.Pitch = PITCH | |
583 | NEWSOUND.SoundId = "http://www.roblox.com/asset/?id="..ID | |
584 | --Swait() | |
585 | NEWSOUND:play() | |
586 | if DOESLOOP == false then | |
587 | repeat Swait() until NEWSOUND.Playing == false | |
588 | NEWSOUND:remove() | |
589 | elseif DOESLOOP == true then | |
590 | NEWSOUND.Looped = true | |
591 | end | |
592 | end)) | |
593 | return NEWSOUND | |
594 | end | |
595 | ||
596 | function CFrameFromTopBack(at, top, back) | |
597 | local right = top:Cross(back) | |
598 | 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) | |
599 | end | |
600 | ||
601 | function CreateWave(inair,size,doesrotate,rotatedirection,waitt,part,offset,color) | |
602 | local wave = CreatePart(3, Effects, "Neon", 0, 0.5, BRICKC(color), "Effect", VT(0,0,0)) | |
603 | local mesh = IT("SpecialMesh",wave) | |
604 | mesh.MeshType = "FileMesh" | |
605 | wave.Anchored = true | |
606 | mesh.MeshId = "http://www.roblox.com/asset/?id=20329976" | |
607 | mesh.Scale = VT(size,size,size) | |
608 | mesh.Offset = VT(0,0,-size/8) | |
609 | wave.CFrame = CF(part.p) * CF(0,offset,0) * ANGLES(RAD(inair),RAD(0),RAD(0)) | |
610 | coroutine.resume(coroutine.create(function(PART) | |
611 | for i = 1, waitt do | |
612 | Swait() | |
613 | mesh.Scale = mesh.Scale + VT(size/5,0,size/5) | |
614 | mesh.Offset = VT(0,0,-(mesh.Scale.X/8)) | |
615 | if doesrotate == true then | |
616 | wave.CFrame = wave.CFrame * CFrame.fromEulerAnglesXYZ(0, rotatedirection, 0) | |
617 | end | |
618 | wave.Transparency = wave.Transparency + (0.5/waitt) | |
619 | if wave.Transparency > 0.99 then | |
620 | wave:remove() | |
621 | end | |
622 | end | |
623 | end)) | |
624 | end | |
625 | ||
626 | function CreateSwirl(inair,size,doesrotate,rotatedirection,waitt,part,offset,color) | |
627 | local wave = CreatePart(3, Effects, "Neon", 0, 0.5, BRICKC(color), "Effect", VT(0,0,0)) | |
628 | local mesh = IT("SpecialMesh",wave) | |
629 | mesh.MeshType = "FileMesh" | |
630 | wave.Anchored = true | |
631 | mesh.MeshId = "http://www.roblox.com/asset/?id=1051557" | |
632 | mesh.Scale = VT(size,size,size) | |
633 | wave.CFrame = CF(part.Position) * CF(0,offset,0) * ANGLES(RAD(inair),RAD(0),RAD(0)) | |
634 | coroutine.resume(coroutine.create(function(PART) | |
635 | for i = 1, waitt do | |
636 | Swait() | |
637 | mesh.Scale = mesh.Scale + VT(size/5,size/5,size/5) | |
638 | if doesrotate == true then | |
639 | wave.CFrame = wave.CFrame * CFrame.fromEulerAnglesXYZ(0, rotatedirection, 0) | |
640 | end | |
641 | wave.Transparency = wave.Transparency + (0.5/waitt) | |
642 | if wave.Transparency > 0.99 then | |
643 | wave:remove() | |
644 | end | |
645 | end | |
646 | end)) | |
647 | end | |
648 | ||
649 | function CreateTornado(inair,size,doesrotate,rotatedirection,waitt,part,offset,color) | |
650 | local wave = CreatePart(3, Effects, "Neon", 0, 0.5, BRICKC(color), "Effect", VT(0,0,0)) | |
651 | local mesh = IT("SpecialMesh",wave) | |
652 | mesh.MeshType = "FileMesh" | |
653 | wave.Anchored = true | |
654 | mesh.MeshId = "http://www.roblox.com/asset/?id=102638417" | |
655 | mesh.Scale = VT(size,size,size) | |
656 | wave.CFrame = CF(part.Position) * CF(0,offset,0) * ANGLES(RAD(inair),RAD(0),RAD(0)) | |
657 | coroutine.resume(coroutine.create(function(PART) | |
658 | for i = 1, waitt do | |
659 | Swait() | |
660 | mesh.Scale = mesh.Scale + VT(size/5,0,size/5) | |
661 | if doesrotate == true then | |
662 | wave.CFrame = wave.CFrame * CFrame.fromEulerAnglesXYZ(0, rotatedirection, 0) | |
663 | end | |
664 | wave.Transparency = wave.Transparency + (0.5/waitt) | |
665 | if wave.Transparency > 0.99 then | |
666 | wave:remove() | |
667 | end | |
668 | end | |
669 | end)) | |
670 | end | |
671 | ||
672 | function CreateRing(inair,size,doesrotate,rotatedirection,waitt,part,offset,spin1,spin2,color) | |
673 | local wave = CreatePart(3, Effects, "Neon", 0, 0.5, BRICKC(color), "Effect", VT(0,0,0)) | |
674 | local mesh = IT("SpecialMesh",wave) | |
675 | mesh.MeshType = "FileMesh" | |
676 | mesh.MeshId = "http://www.roblox.com/asset/?id=3270017" | |
677 | mesh.Scale = VT(size,size,size) | |
678 | wave.Anchored = true | |
679 | mesh.Offset = VT(0,0,0) | |
680 | wave.CFrame = CF(part.Position) * CF(0,offset,0) * ANGLES(RAD(inair),RAD(0),RAD(0)) | |
681 | coroutine.resume(coroutine.create(function(PART) | |
682 | for i = 1, waitt do | |
683 | Swait() | |
684 | mesh.Scale = mesh.Scale + VT(size/5,size/5,size/5) | |
685 | if doesrotate == true then | |
686 | wave.CFrame = wave.CFrame * CFrame.fromEulerAnglesXYZ(spin2, rotatedirection, spin1) | |
687 | end | |
688 | wave.Transparency = wave.Transparency + (0.5/waitt) | |
689 | if wave.Transparency > 0.99 then | |
690 | wave:remove() | |
691 | end | |
692 | end | |
693 | end)) | |
694 | end | |
695 | ||
696 | function MagicSphere(size,waitt,part,color) | |
697 | local wave = CreatePart(3, Effects, "Neon", 0, 0, BRICKC(color), "Effect", VT(0,0,0)) | |
698 | local mesh = IT("SpecialMesh",wave) | |
699 | mesh.MeshType = "Sphere" | |
700 | wave.Anchored = true | |
701 | mesh.Scale = VT(size,size,size) | |
702 | mesh.Offset = VT(0,0,0) | |
703 | wave.CFrame = part * ANGLES(RAD(0),RAD(0),RAD(0)) | |
704 | coroutine.resume(coroutine.create(function(PART) | |
705 | for i = 1, waitt do | |
706 | Swait() | |
707 | mesh.Scale = mesh.Scale + VT(size/5,size/5,size/5) | |
708 | wave.Transparency = wave.Transparency + (1/waitt) | |
709 | if wave.Transparency > 0.99 then | |
710 | wave:remove() | |
711 | end | |
712 | end | |
713 | end)) | |
714 | end | |
715 | ||
716 | function MagicBlock(size,waitt,part,offset,color) | |
717 | local wave = CreatePart(3, Effects, "Neon", 0, 0, BRICKC(color), "Effect", VT(size,size,size)) | |
718 | local mesh = IT("BlockMesh",wave) | |
719 | wave.Anchored = true | |
720 | wave.CFrame = CF(part.Position) * CF(0,offset,0) * ANGLES(RAD(0),RAD(0),RAD(0)) | |
721 | coroutine.resume(coroutine.create(function(PART) | |
722 | for i = 1, waitt do | |
723 | Swait() | |
724 | mesh.Scale = mesh.Scale + VT(size/5,size/5,size/5) | |
725 | wave.CFrame = CF(wave.Position) * ANGLES(RAD(math(-360,360)),RAD(math(-360,360)),RAD(math(-360,360))) | |
726 | wave.Transparency = wave.Transparency + (1/waitt) | |
727 | if wave.Transparency > 0.99 then | |
728 | wave:remove() | |
729 | end | |
730 | end | |
731 | end)) | |
732 | end | |
733 | ||
734 | local EyeSizes={ | |
735 | NumberSequenceKeypoint.new(0,0.5,0), | |
736 | NumberSequenceKeypoint.new(1,0.2,0) | |
737 | } | |
738 | local EyeTrans={ | |
739 | NumberSequenceKeypoint.new(0,0,0), | |
740 | NumberSequenceKeypoint.new(1,1,0) | |
741 | } | |
742 | local PE=Instance.new("ParticleEmitter") | |
743 | PE.LightEmission=0.3 | |
744 | PE.Size=NumberSequence.new(EyeSizes) | |
745 | PE.Transparency=NumberSequence.new(EyeTrans) | |
746 | PE.Rotation=NumberRange.new(0,360) | |
747 | PE.LockedToPart = false | |
748 | PE.Speed = NumberRange.new(0,0,0) | |
749 | PE.ZOffset = 0.3 | |
750 | PE.Rate = 999 | |
751 | PE.Name = "Particles" | |
752 | ||
753 | function CreateParticles(art,text,accel,drag,lifetime,type,isenabledbydefault,locked) | |
754 | local particle = nil | |
755 | coroutine.resume(coroutine.create(function(PART) | |
756 | particle = PE:Clone() | |
757 | Swait() | |
758 | particle.Rate = 999 | |
759 | particle.Parent = art | |
760 | particle.Acceleration = accel | |
761 | if type == "Fire" then | |
762 | local EyeSizes={ | |
763 | NumberSequenceKeypoint.new(0,0.5,0.3), | |
764 | NumberSequenceKeypoint.new(1,0.2,0.2) | |
765 | } | |
766 | particle.Size = NumberSequence.new(EyeSizes) | |
767 | elseif type == "Smoke" then | |
768 | local EyeSizes={ | |
769 | NumberSequenceKeypoint.new(0,0.5,0), | |
770 | NumberSequenceKeypoint.new(1,5,0.5) | |
771 | } | |
772 | particle.Size = NumberSequence.new(EyeSizes) | |
773 | elseif type == "Solid" then | |
774 | local EyeSizes={ | |
775 | NumberSequenceKeypoint.new(0,0.5,0), | |
776 | NumberSequenceKeypoint.new(1,0.5,0) | |
777 | } | |
778 | particle.Size = NumberSequence.new(EyeSizes) | |
779 | end | |
780 | particle.Lifetime=NumberRange.new(lifetime) | |
781 | particle.Drag = drag | |
782 | if locked == true then | |
783 | particle.LockedToPart = true | |
784 | end | |
785 | particle.Texture = "http://www.roblox.com/asset/?id="..text | |
786 | particle.Enabled = isenabledbydefault | |
787 | end)) | |
788 | return particle | |
789 | end | |
790 | ||
791 | local EyeSizes={ | |
792 | NumberSequenceKeypoint.new(0,0.5,0), | |
793 | NumberSequenceKeypoint.new(1,0.2,0) | |
794 | } | |
795 | local EyeTrans={ | |
796 | NumberSequenceKeypoint.new(0,0,0), | |
797 | NumberSequenceKeypoint.new(1,1,0) | |
798 | } | |
799 | local PE2=Instance.new("ParticleEmitter") | |
800 | PE2.LightEmission=0.8 | |
801 | PE2.Size=NumberSequence.new(EyeSizes) | |
802 | PE2.Transparency=NumberSequence.new(EyeTrans) | |
803 | PE2.Rotation=NumberRange.new(0,360) | |
804 | PE2.LockedToPart = false | |
805 | PE2.Speed = NumberRange.new(0,0,0) | |
806 | PE2.ZOffset = 0.3 | |
807 | PE2.Rate = 999 | |
808 | PE2.VelocitySpread = 90000 | |
809 | PE2.Name = "Particles" | |
810 | ||
811 | function CreateParticles2(art,accel,drag,lifetime,type,isenabledbydefault,locked,size,speed) | |
812 | local particle = nil | |
813 | coroutine.resume(coroutine.create(function(PART) | |
814 | particle = PE2:Clone() | |
815 | Swait() | |
816 | particle.Rate = 999 | |
817 | particle.Parent = art | |
818 | particle.Acceleration = accel | |
819 | if type == "Fire" then | |
820 | local EyeSizes={ | |
821 | NumberSequenceKeypoint.new(0,size,size/2), | |
822 | NumberSequenceKeypoint.new(1,size/4,size/8) | |
823 | } | |
824 | particle.Size = NumberSequence.new(EyeSizes) | |
825 | elseif type == "Smoke" then | |
826 | local EyeSizes={ | |
827 | NumberSequenceKeypoint.new(0,0.5,0), | |
828 | NumberSequenceKeypoint.new(1,5,0.5) | |
829 | } | |
830 | particle.Size = NumberSequence.new(EyeSizes) | |
831 | elseif type == "Solid" then | |
832 | local EyeSizes={ | |
833 | NumberSequenceKeypoint.new(0,0.5,0), | |
834 | NumberSequenceKeypoint.new(1,0.5,0) | |
835 | } | |
836 | particle.Size = NumberSequence.new(EyeSizes) | |
837 | end | |
838 | particle.Lifetime=NumberRange.new(lifetime) | |
839 | particle.Drag = drag | |
840 | if locked == true then | |
841 | particle.LockedToPart = true | |
842 | end | |
843 | particle.Speed = NumberRange.new(speed,speed,speed) | |
844 | particle.Texture = "http://www.roblox.com/asset/?id=12417396"..MAGICPARTICLE | |
845 | particle.Enabled = isenabledbydefault | |
846 | end)) | |
847 | return particle | |
848 | - | particle.Texture = "http://www.roblox.com/asset/?id="..MAGICPARTICLE |
848 | + | |
849 | local Decal = IT("Decal") | |
850 | - | --particle.Color = ColorSequence.new(Color3.new(255, 255, 255)) |
850 | + | |
851 | function CreateMagicCircle(size,doesrotate,rotatedirection,waitt,cframe,alwaysfade) | |
852 | local sinkhole = IT("Part") | |
853 | sinkhole.Size = VT(size,0,size) | |
854 | sinkhole.CFrame = cframe | |
855 | --sinkhole.Orientation = VT(0,0,0) | |
856 | sinkhole.Parent = Effects | |
857 | sinkhole.Material = "Neon" | |
858 | sinkhole.Color = C3(255, 255, 255) | |
859 | sinkhole.Anchored = true | |
860 | sinkhole.CanCollide = false | |
861 | sinkhole.Transparency = 1 | |
862 | local decal = Decal:Clone() | |
863 | decal.Parent = sinkhole | |
864 | decal.Face = "Top" | |
865 | decal.Texture = "http://www.roblox.com/asset/?id=1531669882" | |
866 | local decal2 = Decal:Clone() | |
867 | decal2.Parent = sinkhole | |
868 | decal2.Face = "Bottom" | |
869 | decal2.Texture = "http://www.roblox.com/asset/?id=1531669882" | |
870 | - | decal.Texture = "http://www.roblox.com/asset/?id=154449245" |
870 | + | |
871 | for i = 1, waitt do | |
872 | Swait() | |
873 | if doesrotate == true then | |
874 | - | decal2.Texture = "http://www.roblox.com/asset/?id=154449245" |
874 | + | |
875 | end | |
876 | if alwaysfade == true then | |
877 | decal.Transparency = decal.Transparency + (1/waitt) | |
878 | decal2.Transparency = decal.Transparency + (1/waitt) | |
879 | end | |
880 | if i > waitt-11 and (alwaysfade ~= true) then | |
881 | decal.Transparency = decal.Transparency + 0.1 | |
882 | decal2.Transparency = decal.Transparency + 0.1 | |
883 | end | |
884 | end | |
885 | sinkhole.Parent = nil | |
886 | end)) | |
887 | return sinkhole | |
888 | end | |
889 | ||
890 | --//=================================\\ | |
891 | --\\=================================// | |
892 | ||
893 | ||
894 | - | |
894 | + | |
895 | --|| WEAPON CREATION | |
896 | --\\=================================// | |
897 | ||
898 | if Player_Size ~= 1 then | |
899 | for _, v in pairs (Weapon:GetChildren()) do | |
900 | if v.ClassName == "Motor" or v.ClassName == "Weld" or v.ClassName == "Snap" then | |
901 | local p1 = v.Part1 | |
902 | v.Part1 = nil | |
903 | local cf1, cf2, cf3, cf4, cf5, cf6, cf7, cf8, cf9, cf10, cf11, cf12 = v.C1:components() | |
904 | v.C1 = CF(cf1 * Player_Size, cf2 * Player_Size, cf3 * Player_Size, cf4, cf5, cf6, cf7, cf8, cf9, cf10, cf11, cf12) | |
905 | v.Part1 = p1 | |
906 | elseif v.ClassName == "Part" then | |
907 | for _, b in pairs (v:GetChildren()) do | |
908 | if b.ClassName == "SpecialMesh" or b.ClassName == "BlockMesh" then | |
909 | b.Scale = VT(b.Scale.x * Player_Size, b.Scale.y * Player_Size, b.Scale.z * Player_Size) | |
910 | end | |
911 | end | |
912 | end | |
913 | end | |
914 | end | |
915 | ||
916 | Swait() | |
917 | ||
918 | local Plate = IT("Part",Weapon) | |
919 | Plate.Size = VT(1,0.1,1) | |
920 | Plate.Transparency = 1 | |
921 | Plate.CanCollide = false | |
922 | Plate.CFrame = LeftLeg.CFrame * CF(0,-1.1,0) | |
923 | CreateParticles(Plate,MAGICPARTICLE,VT(0,2,0),2,2,"Fire",true,true) | |
924 | weldBetween(LeftLeg,Plate) | |
925 | ||
926 | local Plate = IT("Part",Weapon) | |
927 | Plate.Size = VT(1,0.1,1) | |
928 | Plate.Transparency = 1 | |
929 | Plate.CanCollide = false | |
930 | Plate.CFrame = RightLeg.CFrame * CF(0,-1.1,0) | |
931 | CreateParticles(Plate,MAGICPARTICLE,VT(0,2,0),2,2,"Fire",true,true) | |
932 | weldBetween(RightLeg,Plate) | |
933 | ||
934 | local Plate = IT("Part",Weapon) | |
935 | Plate.Size = VT(1,0.1,1) | |
936 | Plate.Transparency = 1 | |
937 | Plate.CanCollide = false | |
938 | Plate.CFrame = RightArm.CFrame * CF(0,-1.1,0) | |
939 | CreateParticles(Plate,MAGICPARTICLE,VT(0,2,0),2,2,"Fire",true,true) | |
940 | weldBetween(RightArm,Plate) | |
941 | ||
942 | local Plate = IT("Part",Weapon) | |
943 | Plate.Size = VT(1,0.1,1) | |
944 | Plate.Transparency = 1 | |
945 | Plate.CanCollide = false | |
946 | Plate.CFrame = LeftArm.CFrame * CF(0,-1.1,0) | |
947 | CreateParticles(Plate,MAGICPARTICLE,VT(0,2,0),2,2,"Fire",true,true) | |
948 | weldBetween(LeftArm,Plate) | |
949 | ||
950 | local eye = IT("Part",Weapon) | |
951 | eye.Size = VT(0.2,0.2,0.2) | |
952 | eye.Shape = "Ball" | |
953 | eye.CFrame = Head.CFrame * CF(0.125,0.2,-0.55) | |
954 | eye.Material = "Neon" | |
955 | eye.BrickColor = BRICKC("Really black") | |
956 | weldBetween(Head,eye) | |
957 | ||
958 | ||
959 | ||
960 | - | eye.BrickColor = BRICKC("Bright blue") |
960 | + | |
961 | for _, c in pairs(Weapon:GetChildren()) do | |
962 | if c.ClassName == "Part" then | |
963 | c.CustomPhysicalProperties = PhysicalProperties.new(0, 0, 0, 0, 0) | |
964 | end | |
965 | end | |
966 | ||
967 | Weapon.Parent = Character | |
968 | ||
969 | Humanoid.Died:connect(function() | |
970 | ATTACK = true | |
971 | end) | |
972 | ||
973 | print(Class_Name.." loaded.") | |
974 | ||
975 | --//=================================\\ | |
976 | --\\=================================// | |
977 | ||
978 | ||
979 | ||
980 | ||
981 | ||
982 | --//=================================\\ | |
983 | --|| DAMAGE FUNCTIONS | |
984 | --\\=================================// | |
985 | ||
986 | function StatLabel(LABELTYPE, CFRAME, TEXT, COLOR) | |
987 | local STATPART = CreatePart(3, Effects, "Neon", 0, 1, "Toothpaste", "Effect", VT()) | |
988 | STATPART.CFrame = CF(CFRAME.p + VT(0, 1.5, 0)) | |
989 | local BODYGYRO = IT("BodyGyro", STATPART) | |
990 | local BODYPOSITION = IT("BodyPosition", STATPART) | |
991 | BODYPOSITION.P = 2000 | |
992 | BODYPOSITION.D = 100 | |
993 | BODYPOSITION.maxForce = VT(math.huge, math.huge, math.huge) | |
994 | if LABELTYPE == "Normal" then | |
995 | BODYPOSITION.position = STATPART.Position + VT(MRANDOM(-2, 2), 6, MRANDOM(-2, 2)) | |
996 | elseif LABELTYPE == "Debuff" then | |
997 | BODYPOSITION.position = STATPART.Position + VT(MRANDOM(-2, 2), 8, MRANDOM(-2, 2)) | |
998 | elseif LABELTYPE == "Interruption" then | |
999 | BODYPOSITION.position = STATPART.Position + VT(MRANDOM(-2,2), 8, MRANDOM(-2, 2)) | |
1000 | end | |
1001 | game:GetService("Debris"):AddItem(STATPART ,5) | |
1002 | local BILLBOARDGUI = Instance.new("BillboardGui", STATPART) | |
1003 | BILLBOARDGUI.Adornee = STATPART | |
1004 | BILLBOARDGUI.Size = UD2(2.5, 0, 2.5 ,0) | |
1005 | BILLBOARDGUI.StudsOffset = VT(-2, 2, 0) | |
1006 | BILLBOARDGUI.AlwaysOnTop = false | |
1007 | local TEXTLABEL = Instance.new("TextLabel", BILLBOARDGUI) | |
1008 | TEXTLABEL.BackgroundTransparency = 1 | |
1009 | TEXTLABEL.Size = UD2(2.5, 0, 2.5, 0) | |
1010 | TEXTLABEL.Text = TEXT | |
1011 | TEXTLABEL.Font = "SciFi" | |
1012 | TEXTLABEL.FontSize="Size42" | |
1013 | TEXTLABEL.TextColor3 = COLOR | |
1014 | TEXTLABEL.TextStrokeTransparency = 1 | |
1015 | TEXTLABEL.TextScaled = true | |
1016 | TEXTLABEL.TextWrapped = true | |
1017 | coroutine.resume(coroutine.create(function(THEPART, THEBODYPOSITION, THETEXTLABEL) | |
1018 | wait(0.2) | |
1019 | for i=1, 5 do | |
1020 | wait() | |
1021 | THEBODYPOSITION.Position = THEPART.Position - VT(0, 0.5 ,0) | |
1022 | end | |
1023 | wait(1.2) | |
1024 | for i=1, 5 do | |
1025 | wait() | |
1026 | THETEXTLABEL.TextTransparency = THETEXTLABEL.TextTransparency + 0.2 | |
1027 | THETEXTLABEL.TextStrokeTransparency = THETEXTLABEL.TextStrokeTransparency + 0.2 | |
1028 | THEBODYPOSITION.position = THEPART.Position + VT(0, 0.5, 0) | |
1029 | end | |
1030 | THEPART.Parent = nil | |
1031 | end),STATPART, BODYPOSITION, TEXTLABEL) | |
1032 | end | |
1033 | ||
1034 | ||
1035 | --//=================================\\ | |
1036 | --|| DAMAGING | |
1037 | --\\=================================// | |
1038 | ||
1039 | function dealdamage(hit,min,max,maxstrength,beserk,critrate,critmultiplier) | |
1040 | if hit.Parent:FindFirstChildOfClass("Humanoid") and hit.Parent:FindFirstChild("HitBy"..Player.Name) == nil then | |
1041 | local humanoid = hit.Parent:FindFirstChildOfClass("Humanoid") | |
1042 | local dmg = math.random(min,max) | |
1043 | if humanoid.Health > 0 then | |
1044 | if beserk == true then | |
1045 | humanoid.Health = 0 | |
1046 | else | |
1047 | CreateSound("260430060", hit, 1.2, MRANDOM(7, 12) / 10) | |
1048 | hit.Velocity = CFrame.new(Torso.Position,hit.Position).lookVector*5*maxstrength | |
1049 | if math.random(1,100) < critrate+1 then | |
1050 | humanoid.Health = humanoid.Health - dmg*critmultiplier | |
1051 | StatLabel("Normal", hit.CFrame * CF(0, 0 + (hit.Size.z - 1), 0), "CRIT/"..dmg*critmultiplier, C3(255/255, 0, 0)) | |
1052 | else | |
1053 | humanoid.Health = humanoid.Health - dmg | |
1054 | StatLabel("Normal", hit.CFrame * CF(0, 0 + (hit.Size.z - 1), 0), dmg, C3(0, 0, 0)) | |
1055 | end | |
1056 | local defence = Instance.new("BoolValue",hit.Parent) | |
1057 | defence.Name = ("HitBy"..Player.Name) | |
1058 | game:GetService("Debris"):AddItem(defence, 0.5) | |
1059 | end | |
1060 | end | |
1061 | end | |
1062 | end | |
1063 | ||
1064 | function AoEDamage(position,radius,min,max,maxstrength,beserk,critrate,critmultiplier,CanBeDodgedByJumping) | |
1065 | local dmg = math.random(min,max) | |
1066 | for i,v in ipairs(workspace:GetChildren()) do | |
1067 | if v:FindFirstChild("HitBy"..Player.Name) == nil then | |
1068 | local body = v:GetChildren() | |
1069 | for part = 1, #body do | |
1070 | if(v:FindFirstChild("HitBy"..Player.Name) == nil and (body[part].ClassName == "Part" or body[part].ClassName == "MeshPart") and v ~= Character) then | |
1071 | if(body[part].Position - position).Magnitude < radius then | |
1072 | if v.ClassName == "Model" then | |
1073 | if v:FindFirstChild("Humanoid") then | |
1074 | if v.Humanoid.Health ~= 0 then | |
1075 | if CanBeDodgedByJumping == true then | |
1076 | if body[part].Position.Y < position.Y+5 then | |
1077 | if math.random(1,100) < critrate+1 then | |
1078 | v.Humanoid.Health = v.Humanoid.Health - dmg*critmultiplier | |
1079 | StatLabel("Normal", body[part].CFrame * CF(0, 0 + (body[part].Size.z - 1), 0), "CRIT/"..dmg*critmultiplier, C3(255/255, 0, 0)) | |
1080 | else | |
1081 | v.Humanoid.Health = v.Humanoid.Health - dmg | |
1082 | StatLabel("Normal", body[part].CFrame * CF(0, 0 + (body[part].Size.z - 1), 0), dmg, C3(0, 0, 0)) | |
1083 | end | |
1084 | local defence = Instance.new("BoolValue",v) | |
1085 | defence.Name = ("HitBy"..Player.Name) | |
1086 | game:GetService("Debris"):AddItem(defence, 0.5) | |
1087 | end | |
1088 | else | |
1089 | if beserk == true then | |
1090 | v.Humanoid.Health = 0 | |
1091 | end | |
1092 | if math.random(1,100) < critrate+1 then | |
1093 | v.Humanoid.Health = v.Humanoid.Health - dmg*critmultiplier | |
1094 | StatLabel("Normal", body[part].CFrame * CF(0, 0 + (body[part].Size.z - 1), 0), "CRIT/"..dmg*critmultiplier, C3(255/255, 0, 0)) | |
1095 | else | |
1096 | v.Humanoid.Health = v.Humanoid.Health - dmg | |
1097 | StatLabel("Normal", body[part].CFrame * CF(0, 0 + (body[part].Size.z - 1), 0), dmg, C3(0, 0, 0)) | |
1098 | end | |
1099 | local defence = Instance.new("BoolValue",v) | |
1100 | defence.Name = ("HitBy"..Player.Name) | |
1101 | game:GetService("Debris"):AddItem(defence, 0.5) | |
1102 | end | |
1103 | end | |
1104 | end | |
1105 | end | |
1106 | body[part].Velocity = CFrame.new(position,body[part].Position).lookVector*5*maxstrength | |
1107 | end | |
1108 | end | |
1109 | end | |
1110 | if v.ClassName == "Part" then | |
1111 | if v.Anchored == false and (v.Position - position).Magnitude < radius then | |
1112 | v.Velocity = CFrame.new(position,v.Position).lookVector*5*maxstrength | |
1113 | end | |
1114 | end | |
1115 | end | |
1116 | end | |
1117 | end | |
1118 | ||
1119 | function attractnearest(postype,position,range,maxstrength,last) | |
1120 | if postype == "Vector" then | |
1121 | for i,v in ipairs(workspace:GetChildren()) do | |
1122 | local body = v:GetChildren() | |
1123 | for part = 1, #body do | |
1124 | if((body[part].ClassName == "Part" or body[part].ClassName == "MeshPart") and v ~= Character) then | |
1125 | if(body[part].Position - position).Magnitude < range then | |
1126 | if body[part]:FindFirstChild("ATTRACT") == nil then | |
1127 | local bv = Instance.new("BodyVelocity") | |
1128 | bv.maxForce = Vector3.new(1e9, 1e9, 1e9) | |
1129 | bv.velocity = CF(body[part].Position,position).lookVector*maxstrength | |
1130 | bv.Parent = body[part] | |
1131 | bv.Name = "ATTRACT" | |
1132 | else | |
1133 | coroutine.resume(coroutine.create(function() | |
1134 | for i = 1, last/5 do | |
1135 | Swait(5) | |
1136 | body[part].ATTRACT.velocity = CF(body[part].Position,position).lookVector*maxstrength | |
1137 | end | |
1138 | body[part].ATTRACT:remove() | |
1139 | end)) | |
1140 | end | |
1141 | end | |
1142 | end | |
1143 | end | |
1144 | if v.ClassName == "Part" then | |
1145 | if v.Anchored == false and (v.Position - position).Magnitude < range then | |
1146 | if v:FindFirstChild("ATTRACT") == nil then | |
1147 | local bv = Instance.new("BodyVelocity") | |
1148 | bv.maxForce = Vector3.new(1e9, 1e9, 1e9) | |
1149 | bv.velocity = CF(v.Position,position).lookVector*maxstrength | |
1150 | bv.Parent = v | |
1151 | bv.Name = "ATTRACT" | |
1152 | else | |
1153 | coroutine.resume(coroutine.create(function() | |
1154 | for i = 1, last/5 do | |
1155 | Swait(5) | |
1156 | v.ATTRACT.velocity = CF(v.Position,position).lookVector*maxstrength | |
1157 | end | |
1158 | v.ATTRACT:remove() | |
1159 | end)) | |
1160 | end | |
1161 | end | |
1162 | end | |
1163 | end | |
1164 | elseif postype == "Part" then | |
1165 | for i,v in ipairs(workspace:GetChildren()) do | |
1166 | local body = v:GetChildren() | |
1167 | for part = 1, #body do | |
1168 | if((body[part].ClassName == "Part" or body[part].ClassName == "MeshPart") and v ~= Character) then | |
1169 | if(body[part].Position - position.Position).Magnitude < range then | |
1170 | if body[part]:FindFirstChild("ATTRACT") == nil then | |
1171 | local bv = Instance.new("BodyVelocity") | |
1172 | bv.maxForce = Vector3.new(1e9, 1e9, 1e9) | |
1173 | bv.velocity = CF(body[part].Position,position.Position).lookVector*maxstrength | |
1174 | bv.Parent = body[part] | |
1175 | bv.Name = "ATTRACT" | |
1176 | else | |
1177 | coroutine.resume(coroutine.create(function() | |
1178 | for i = 1, last/5 do | |
1179 | Swait(5) | |
1180 | body[part].ATTRACT.velocity = CF(body[part].Position,position.Position).lookVector*maxstrength | |
1181 | end | |
1182 | body[part].ATTRACT:remove() | |
1183 | end)) | |
1184 | end | |
1185 | end | |
1186 | end | |
1187 | end | |
1188 | if v.ClassName == "Part" then | |
1189 | if v.Anchored == false and (v.Position - position.Position).Magnitude < range then | |
1190 | if v:FindFirstChild("ATTRACT") == nil then | |
1191 | local bv = Instance.new("BodyVelocity") | |
1192 | bv.maxForce = Vector3.new(1e9, 1e9, 1e9) | |
1193 | bv.velocity = CF(v.Position,position.Position).lookVector*maxstrength | |
1194 | bv.Parent = v | |
1195 | bv.Name = "ATTRACT" | |
1196 | else | |
1197 | coroutine.resume(coroutine.create(function() | |
1198 | for i = 1, last/5 do | |
1199 | Swait(5) | |
1200 | v.ATTRACT.velocity = CF(v.Position,position.Position).lookVector*maxstrength | |
1201 | end | |
1202 | v.ATTRACT:remove() | |
1203 | end)) | |
1204 | end | |
1205 | end | |
1206 | end | |
1207 | end | |
1208 | end | |
1209 | end | |
1210 | ||
1211 | function killnearest(position,range,maxstrength,candestroy) | |
1212 | for i,v in ipairs(workspace:GetChildren()) do | |
1213 | local body = v:GetChildren() | |
1214 | for part = 1, #body do | |
1215 | if((body[part].ClassName == "Part" or body[part].ClassName == "MeshPart") and v ~= Character) then | |
1216 | if(body[part].Position - position).Magnitude < range then | |
1217 | if v.ClassName == "Model" then | |
1218 | v:BreakJoints() | |
1219 | end | |
1220 | if candestroy == true then | |
1221 | table.insert(Effects2,{body[part],"Disappear",0.02,2,2,2,2}) | |
1222 | end | |
1223 | body[part].Velocity = CFrame.new(position,body[part].Position).lookVector*5*maxstrength | |
1224 | end | |
1225 | end | |
1226 | end | |
1227 | if v.ClassName == "Part" then | |
1228 | if v.Anchored == false and (v.Position - position).Magnitude < range then | |
1229 | if candestroy == true then | |
1230 | table.insert(Effects2,{v,"Disappear",0.02,2,2,2,2}) | |
1231 | end | |
1232 | v.Velocity = CFrame.new(position,v.Position).lookVector*5*maxstrength | |
1233 | end | |
1234 | end | |
1235 | end | |
1236 | end | |
1237 | ||
1238 | --//=================================\\ | |
1239 | --|| ATTACK FUNCTIONS AND STUFF | |
1240 | --\\=================================// | |
1241 | ||
1242 | function CheckTableForString(Table, String) | |
1243 | for i, v in pairs(Table) do | |
1244 | if string.find(string.lower(String), string.lower(v)) then | |
1245 | return true | |
1246 | end | |
1247 | end | |
1248 | return false | |
1249 | end | |
1250 | ||
1251 | function CheckIntangible(Hit) | |
1252 | local ProjectileNames = {"Water", "Arrow", "Projectile", "Effect", "Rail", "Lightning", "Bullet"} | |
1253 | if Hit and Hit.Parent then | |
1254 | if ((not Hit.CanCollide or CheckTableForString(ProjectileNames, Hit.Name)) and not Hit.Parent:FindFirstChild("Humanoid")) then | |
1255 | return true | |
1256 | end | |
1257 | end | |
1258 | return false | |
1259 | end | |
1260 | ||
1261 | Debris = game:GetService("Debris") | |
1262 | ||
1263 | function CastZapRay(StartPos, Vec, Length, Ignore, DelayIfHit) | |
1264 | local Direction = CFrame.new(StartPos, Vec).lookVector | |
1265 | local Ignore = ((type(Ignore) == "table" and Ignore) or {Ignore}) | |
1266 | local RayHit, RayPos, RayNormal = game:GetService("Workspace"):FindPartOnRayWithIgnoreList(Ray.new(StartPos, Direction * Length), Ignore) | |
1267 | if RayHit and CheckIntangible(RayHit) then | |
1268 | if DelayIfHit then | |
1269 | wait() | |
1270 | end | |
1271 | RayHit, RayPos, RayNormal = CastZapRay((RayPos + (Vec * 0.01)), Vec, (Length - ((StartPos - RayPos).magnitude)), Ignore, DelayIfHit) | |
1272 | end | |
1273 | return RayHit, RayPos, RayNormal | |
1274 | end | |
1275 | ||
1276 | function turnto(pos) | |
1277 | RootPart.CFrame = CF(RootPart.Position,VT(pos.X,RootPart.Position.Y,pos.Z)) | |
1278 | end | |
1279 | ||
1280 | function GraviBomb() | |
1281 | ATTACK = true | |
1282 | for i=0, 1, 0.1 / Animation_Speed do | |
1283 | Swait() | |
1284 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0 * Player_Size, 0 * Player_Size, 0.7 * Player_Size) * ANGLES(RAD(5), RAD(0), RAD(-40)), 0.4 / Animation_Speed) | |
1285 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0 * Player_Size, 0 * Player_Size, 0 + ((1 * Player_Size) - 1)) * ANGLES(RAD(0), RAD(0), RAD(35)) * ANGLES(RAD(2.5), RAD(0), RAD(0)), 0.4 / Animation_Speed) | |
1286 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5 * Player_Size, 0.5 * Player_Size, 0 * Player_Size) * ANGLES(RAD(70), RAD(0), RAD(45)) * RIGHTSHOULDERC0, 0.4 / Animation_Speed) | |
1287 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5 * Player_Size, 0.75 * Player_Size, -0.5 * Player_Size) * ANGLES(RAD(90), RAD(0), RAD(50)) * ANGLES(RAD(80), RAD(-20), RAD(-30)) * LEFTSHOULDERC0, 0.4 / Animation_Speed) | |
1288 | RightHip.C0 = Clerp(RightHip.C0, CF(1 * Player_Size, -0.3 * Player_Size, -1 * Player_Size) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(-20)), 0.2 / Animation_Speed) | |
1289 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1 * Player_Size, -1 * Player_Size, 0 * Player_Size) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(10)), 0.2 / Animation_Speed) | |
1290 | end | |
1291 | MagicSphere(25,25,LeftArm.CFrame*CF(0,-1,0),"Toothpaste") | |
1292 | MagicSphere(20,25,LeftArm.CFrame*CF(0,-1,0),"Toothpaste") | |
1293 | coroutine.resume(coroutine.create(function() | |
1294 | local cframe = CF(Mouse.Hit.p) | |
1295 | local circle = CreateMagicCircle(75,true,0.05,120,cframe,false) | |
1296 | - | MagicSphere(25,25,LeftArm.CFrame*CF(0,-1,0),"Bright blue") |
1296 | + | |
1297 | - | MagicSphere(20,25,LeftArm.CFrame*CF(0,-1,0),"Bright blue") |
1297 | + | |
1298 | local sphere = IT("Part",Effects) | |
1299 | sphere.Shape = "Ball" | |
1300 | sphere.Size = VT(50,50,50) | |
1301 | sphere.Anchored = true | |
1302 | sphere.CanCollide = false | |
1303 | sphere.Material = "Neon" | |
1304 | sphere.BrickColor = BRICKC("Toothpaste") | |
1305 | sphere.Transparency = 0 | |
1306 | sphere.CFrame = cframe | |
1307 | for i = 1, 10 do | |
1308 | Swait(2) | |
1309 | - | sphere.BrickColor = BRICKC("Bright blue") |
1309 | + | |
1310 | sphere.CFrame = cframe | |
1311 | sphere.Size = sphere.Size - VT(5,5,5) | |
1312 | sphere.CFrame = cframe | |
1313 | end | |
1314 | sphere:remove() | |
1315 | end | |
1316 | local scale = 5 | |
1317 | coroutine.resume(coroutine.create(function() | |
1318 | CreateSound(RELEASESOUND, Effects, 2, 1) | |
1319 | MagicSphere(100,125,cframe,"Toothpaste") | |
1320 | MagicSphere(75,125,cframe,"Toothpaste") | |
1321 | CreateSwirl(180,6,true,0.3,225,circle,0,"Toothpaste") | |
1322 | CreateSwirl(180,4,true,0.3,225,circle,0,"Toothpaste") | |
1323 | CreateSwirl(180,2,true,0.3,225,circle,0,"Toothpaste") | |
1324 | - | MagicSphere(100,125,cframe,"Really black") |
1324 | + | |
1325 | - | MagicSphere(75,125,cframe,"Really black") |
1325 | + | |
1326 | - | CreateSwirl(180,6,true,0.3,225,circle,0,"Bright blue") |
1326 | + | |
1327 | - | CreateSwirl(180,4,true,0.3,225,circle,0,"Bright blue") |
1327 | + | |
1328 | - | CreateSwirl(180,2,true,0.3,225,circle,0,"Bright blue") |
1328 | + | |
1329 | end)) | |
1330 | for i=0, 1, 0.1 / Animation_Speed do | |
1331 | Swait() | |
1332 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0 * Player_Size, 0 * Player_Size, 0.7 * Player_Size) * ANGLES(RAD(5), RAD(0), RAD(-30)), 0.4 / Animation_Speed) | |
1333 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0 * Player_Size, 0 * Player_Size, 0 + ((1 * Player_Size) - 1)) * ANGLES(RAD(0), RAD(0), RAD(25)) * ANGLES(RAD(5), RAD(0), RAD(0)), 0.4 / Animation_Speed) | |
1334 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5 * Player_Size, 0.5 * Player_Size, 0 * Player_Size) * ANGLES(RAD(70), RAD(0), RAD(45)) * RIGHTSHOULDERC0, 0.4 / Animation_Speed) | |
1335 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5 * Player_Size, 0.25 * Player_Size, -0.25 * Player_Size) * ANGLES(RAD(90), RAD(0), RAD(-20 + MRANDOM(-2.5, 2.5))) * ANGLES(RAD(70 + MRANDOM(-2.5, 2.5)), RAD(40), RAD(0)) * LEFTSHOULDERC0, 0.4 / Animation_Speed) | |
1336 | RightHip.C0 = Clerp(RightHip.C0, CF(1 * Player_Size, -0.3 * Player_Size, -1 * Player_Size) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(-20)), 0.2 / Animation_Speed) | |
1337 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1 * Player_Size, -1 * Player_Size, 0 * Player_Size) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(10)), 0.2 / Animation_Speed) | |
1338 | end | |
1339 | ATTACK = false | |
1340 | end | |
1341 | ||
1342 | function GraviSpear() | |
1343 | ATTACK = true | |
1344 | for i=0, 1.5, 0.1 / Animation_Speed do | |
1345 | Swait() | |
1346 | turnto(Mouse.Hit.p) | |
1347 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0 * Player_Size, 0 * Player_Size, 0.7 * Player_Size) * ANGLES(RAD(0), RAD(0), RAD(75)), 0.4 / Animation_Speed) | |
1348 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0 * Player_Size, 0 * Player_Size, 0 + ((1 * Player_Size) - 1)) * ANGLES(RAD(0), RAD(0), RAD(-75)), 0.2 / Animation_Speed) | |
1349 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5 * Player_Size, 0.5 * Player_Size, 0 * Player_Size) * ANGLES(RAD(0), RAD(0), RAD(90)) * RIGHTSHOULDERC0, 0.15 / Animation_Speed) | |
1350 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5 * Player_Size, 0.5 * Player_Size, 0 * Player_Size) * ANGLES(RAD(0), RAD(25), RAD(-25)) * LEFTSHOULDERC0, 0.15 / Animation_Speed) | |
1351 | RightHip.C0 = Clerp(RightHip.C0, CF(1 * Player_Size, -0.3 * Player_Size, -1 * Player_Size) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(-20)), 0.2 / Animation_Speed) | |
1352 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1 * Player_Size, -1 * Player_Size, 0 * Player_Size) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(10)), 0.2 / Animation_Speed) | |
1353 | end | |
1354 | local spear = IT("Part",Effects) | |
1355 | spear.Anchored = true | |
1356 | spear.CanCollide = false | |
1357 | spear.Shape = "Ball" | |
1358 | spear.Size = VT(0,0,0) | |
1359 | spear.Material = "Neon" | |
1360 | spear.Transparency = 0.2 | |
1361 | spear.BrickColor = BRICKC("Toothpaste") | |
1362 | spear.CFrame = RightArm.CFrame * CF(0,-4,0) | |
1363 | local inner = spear:Clone() | |
1364 | inner.Parent = spear | |
1365 | inner.Size = VT(0,0,0) | |
1366 | - | spear.BrickColor = BRICKC("Bright blue") |
1366 | + | inner.BrickColor = BRICKC("Toothpaste") |
1367 | inner.CFrame = spear.CFrame | |
1368 | for i = 1, 10 do | |
1369 | Swait() | |
1370 | turnto(Mouse.Hit.p) | |
1371 | - | inner.BrickColor = BRICKC("Bright blue") |
1371 | + | |
1372 | inner.CFrame = spear.CFrame | |
1373 | spear.Size = spear.Size + VT(0.4,0.4,0.4) | |
1374 | inner.Size = inner.Size + VT(0.35,0.35,0.35) | |
1375 | end | |
1376 | CreateParticles2(inner,VT(0,255,255),5,1,"Fire",true,true,1,8) | |
1377 | MagicSphere(25,25,RightArm.CFrame*CF(0,-1,0),"Toothpaste") | |
1378 | MagicSphere(20,25,RightArm.CFrame*CF(0,-1,0),"Toothpaste") | |
1379 | CreateSound(CUTSOUNDS[MRANDOM(1, #CUTSOUNDS)], RightArm, 6, 1) | |
1380 | local bv = Instance.new("BodyVelocity") | |
1381 | bv.maxForce = Vector3.new(1e9, 1e9, 1e9) | |
1382 | - | MagicSphere(25,25,RightArm.CFrame*CF(0,-1,0),"Bright blue") |
1382 | + | |
1383 | - | MagicSphere(20,25,RightArm.CFrame*CF(0,-1,0),"Bright blue") |
1383 | + | |
1384 | bv.Name = "MOVE" | |
1385 | weldBetween(spear,inner) | |
1386 | spear.Anchored = false | |
1387 | inner.Anchored = false | |
1388 | local harm = spear.Touched:Connect(function(hit) | |
1389 | if hit.Parent ~= Character and hit.Parent ~= Weapon and hit.Parent ~= Effects then | |
1390 | local cframe = spear.CFrame | |
1391 | coroutine.resume(coroutine.create(function() | |
1392 | spear.Parent = nil | |
1393 | coroutine.resume(coroutine.create(function() | |
1394 | CreateSound(RELEASESOUND, Effects, 2, 1) | |
1395 | MagicSphere(60,125,cframe,"Toothpaste") | |
1396 | MagicSphere(50,125,cframe,"Toothpaste") | |
1397 | CreateSwirl(0,6,true,0.3,125,spear,0,"Toothpaste") | |
1398 | CreateSwirl(0,4,true,0.3,125,spear,0,"Toothpaste") | |
1399 | CreateSwirl(0,2,true,0.3,125,spear,0,"Toothpaste") | |
1400 | - | MagicSphere(60,125,cframe,"Really black") |
1400 | + | |
1401 | - | MagicSphere(50,125,cframe,"Really black") |
1401 | + | |
1402 | - | CreateSwirl(0,6,true,0.3,125,spear,0,"Bright blue") |
1402 | + | |
1403 | - | CreateSwirl(0,4,true,0.3,125,spear,0,"Bright blue") |
1403 | + | |
1404 | - | CreateSwirl(0,2,true,0.3,125,spear,0,"Bright blue") |
1404 | + | |
1405 | end)) | |
1406 | end | |
1407 | end) | |
1408 | coroutine.resume(coroutine.create(function() | |
1409 | repeat | |
1410 | Swait() | |
1411 | CreateSwirl(0,2,true,0.3,25,spear,0,"Toothpaste") | |
1412 | attractnearest("Part",spear,65,70,5) | |
1413 | until spear.Parent == nil | |
1414 | end)) | |
1415 | ATTACK = false | |
1416 | - | CreateSwirl(0,2,true,0.3,25,spear,0,"Bright blue") |
1416 | + | |
1417 | ||
1418 | function WarpSpear() | |
1419 | ATTACK = true | |
1420 | for i=0, 1.5, 0.1 / Animation_Speed do | |
1421 | Swait() | |
1422 | turnto(Mouse.Hit.p) | |
1423 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0 * Player_Size, 0 * Player_Size, 0.7 * Player_Size) * ANGLES(RAD(0), RAD(0), RAD(75)), 0.4 / Animation_Speed) | |
1424 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0 * Player_Size, 0 * Player_Size, 0 + ((1 * Player_Size) - 1)) * ANGLES(RAD(0), RAD(0), RAD(-75)), 0.2 / Animation_Speed) | |
1425 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5 * Player_Size, 0.5 * Player_Size, 0 * Player_Size) * ANGLES(RAD(0), RAD(0), RAD(90)) * RIGHTSHOULDERC0, 0.15 / Animation_Speed) | |
1426 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5 * Player_Size, 0.5 * Player_Size, 0 * Player_Size) * ANGLES(RAD(0), RAD(25), RAD(-25)) * LEFTSHOULDERC0, 0.15 / Animation_Speed) | |
1427 | RightHip.C0 = Clerp(RightHip.C0, CF(1 * Player_Size, -0.3 * Player_Size, -1 * Player_Size) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(-20)), 0.2 / Animation_Speed) | |
1428 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1 * Player_Size, -1 * Player_Size, 0 * Player_Size) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(10)), 0.2 / Animation_Speed) | |
1429 | end | |
1430 | local spear = IT("Part",Effects) | |
1431 | spear.Anchored = true | |
1432 | spear.CanCollide = false | |
1433 | spear.Shape = "Ball" | |
1434 | spear.Size = VT(0,0,0) | |
1435 | spear.Material = "Neon" | |
1436 | spear.Transparency = 0.2 | |
1437 | spear.BrickColor = BRICKC("Toothpaste") | |
1438 | spear.CFrame = RightArm.CFrame * CF(0,-4,0) | |
1439 | local inner = spear:Clone() | |
1440 | inner.Parent = spear | |
1441 | inner.Size = VT(0,0,0) | |
1442 | - | spear.BrickColor = BRICKC("Bright blue") |
1442 | + | inner.BrickColor = BRICKC("Toothpaste") |
1443 | inner.CFrame = spear.CFrame | |
1444 | for i = 1, 5 do | |
1445 | Swait() | |
1446 | turnto(Mouse.Hit.p) | |
1447 | - | inner.BrickColor = BRICKC("Bright blue") |
1447 | + | |
1448 | inner.CFrame = spear.CFrame | |
1449 | spear.Size = spear.Size + VT(0.4,0.4,0.4) | |
1450 | inner.Size = inner.Size + VT(0.35,0.35,0.35) | |
1451 | end | |
1452 | MagicSphere(25,25,RightArm.CFrame*CF(0,-1,0),"Toothpaste") | |
1453 | MagicSphere(20,25,RightArm.CFrame*CF(0,-1,0),"Toothpaste") | |
1454 | CreateSound(CUTSOUNDS[MRANDOM(1, #CUTSOUNDS)], RightArm, 6, 1) | |
1455 | local bv = Instance.new("BodyVelocity") | |
1456 | bv.maxForce = Vector3.new(1e9, 1e9, 1e9) | |
1457 | - | MagicSphere(25,25,RightArm.CFrame*CF(0,-1,0),"Bright blue") |
1457 | + | |
1458 | - | MagicSphere(20,25,RightArm.CFrame*CF(0,-1,0),"Bright blue") |
1458 | + | |
1459 | bv.Name = "MOVE" | |
1460 | weldBetween(spear,inner) | |
1461 | spear.Anchored = false | |
1462 | inner.Anchored = false | |
1463 | local HIT = false | |
1464 | local harm = spear.Touched:Connect(function(hit) | |
1465 | if HIT == false and hit.Parent ~= Character and hit.Parent ~= Weapon and hit.Parent ~= Effects then | |
1466 | local cframe = spear.CFrame | |
1467 | HIT = true | |
1468 | coroutine.resume(coroutine.create(function() | |
1469 | spear.Parent = nil | |
1470 | RootPart.CFrame = CF(spear.Position,Mouse.Hit.p) | |
1471 | coroutine.resume(coroutine.create(function() | |
1472 | CreateSound(RELEASESOUND, Effects, 2, 1.5) | |
1473 | MagicSphere(30,105,cframe,"Toothpaste") | |
1474 | MagicSphere(25,105,cframe,"Toothpaste") | |
1475 | for i = 1, 15 do | |
1476 | Swait() | |
1477 | killnearest(cframe.p,7.5,150) | |
1478 | - | MagicSphere(30,105,cframe,"Bright blue") |
1478 | + | |
1479 | - | MagicSphere(25,105,cframe,"Bright blue") |
1479 | + | |
1480 | end)) | |
1481 | end | |
1482 | end) | |
1483 | coroutine.resume(coroutine.create(function() | |
1484 | Swait(75) | |
1485 | if HIT == false then | |
1486 | local cframe = spear.CFrame | |
1487 | HIT = true | |
1488 | coroutine.resume(coroutine.create(function() | |
1489 | spear.Parent = nil | |
1490 | RootPart.CFrame = CF(spear.Position,Mouse.Hit.p) | |
1491 | coroutine.resume(coroutine.create(function() | |
1492 | CreateSound(RELEASESOUND, Effects, 2, 1.5) | |
1493 | MagicSphere(30,105,cframe,"Toothpaste") | |
1494 | MagicSphere(25,105,cframe,"Toothpaste") | |
1495 | for i = 1, 15 do | |
1496 | Swait() | |
1497 | killnearest(cframe.p,7.5,150) | |
1498 | - | MagicSphere(30,105,cframe,"Bright blue") |
1498 | + | |
1499 | - | MagicSphere(25,105,cframe,"Bright blue") |
1499 | + | |
1500 | end)) | |
1501 | end | |
1502 | end)) | |
1503 | coroutine.resume(coroutine.create(function() | |
1504 | local loop = 0 | |
1505 | repeat | |
1506 | Swait() | |
1507 | loop = loop + 1 | |
1508 | if loop == 4 then | |
1509 | MagicSphere(25,15,spear.CFrame,"Toothpaste") | |
1510 | end | |
1511 | if loop == 7 then | |
1512 | loop = 0 | |
1513 | MagicSphere(25,15,spear.CFrame,"Toothpaste") | |
1514 | - | MagicSphere(25,15,spear.CFrame,"Bright blue") |
1514 | + | |
1515 | attractnearest("Part",spear,12.5,50,5) | |
1516 | until spear.Parent == nil | |
1517 | end)) | |
1518 | - | MagicSphere(25,15,spear.CFrame,"Bright blue") |
1518 | + | |
1519 | end | |
1520 | ||
1521 | function GravityGlobe() | |
1522 | ATTACK = true | |
1523 | Rooted = true | |
1524 | for i=0, 1, 0.1 / Animation_Speed do | |
1525 | Swait() | |
1526 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0 * Player_Size, 0 * Player_Size, 0.7 * Player_Size) * ANGLES(RAD(5), RAD(0), RAD(-40)), 0.4 / Animation_Speed) | |
1527 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0 * Player_Size, 0 * Player_Size, 0 + ((1 * Player_Size) - 1)) * ANGLES(RAD(0), RAD(0), RAD(35)) * ANGLES(RAD(2.5), RAD(0), RAD(0)), 0.4 / Animation_Speed) | |
1528 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5 * Player_Size, 0.5 * Player_Size, 0 * Player_Size) * ANGLES(RAD(70), RAD(0), RAD(45)) * RIGHTSHOULDERC0, 0.4 / Animation_Speed) | |
1529 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5 * Player_Size, 0.75 * Player_Size, -0.5 * Player_Size) * ANGLES(RAD(90), RAD(0), RAD(50)) * ANGLES(RAD(80), RAD(-20), RAD(-30)) * LEFTSHOULDERC0, 0.4 / Animation_Speed) | |
1530 | RightHip.C0 = Clerp(RightHip.C0, CF(1 * Player_Size, -0.3 * Player_Size, -1 * Player_Size) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(-20)), 0.2 / Animation_Speed) | |
1531 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1 * Player_Size, -1 * Player_Size, 0 * Player_Size) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(10)), 0.2 / Animation_Speed) | |
1532 | end | |
1533 | coroutine.resume(coroutine.create(function() | |
1534 | CreateMagicCircle(100,true,0.02,50,CF(RootPart.Position) * CF(0,-2.8,0),true) | |
1535 | local cframe = RootPart.CFrame | |
1536 | CreateSound(RELEASESOUND, Effects, 2, 1) | |
1537 | local sphere = IT("Part",Effects) | |
1538 | sphere.Shape = "Ball" | |
1539 | sphere.Size = VT(0,0,0) | |
1540 | sphere.Anchored = true | |
1541 | sphere.CanCollide = false | |
1542 | sphere.Material = "Neon" | |
1543 | sphere.Transparency = 0.5 | |
1544 | sphere.BrickColor = BRICKC("Toothpaste") | |
1545 | sphere.CFrame = cframe | |
1546 | local sphere2 = IT("Part",Effects) | |
1547 | sphere2.Shape = "Ball" | |
1548 | sphere2.Size = VT(0,0,0) | |
1549 | - | sphere.BrickColor = BRICKC("Bright blue") |
1549 | + | |
1550 | sphere2.CanCollide = false | |
1551 | sphere2.Material = "Neon" | |
1552 | sphere2.Transparency = 0.3 | |
1553 | sphere2.BrickColor = BRICKC("Toothpaste") | |
1554 | sphere2.CFrame = cframe | |
1555 | for i = 1, 10 do | |
1556 | Swait(2) | |
1557 | attractnearest("Vector",cframe.p,50,50,10) | |
1558 | - | sphere2.BrickColor = BRICKC("Bright blue") |
1558 | + | |
1559 | sphere.Size = sphere.Size + VT(4,4,4) | |
1560 | sphere2.CFrame = cframe | |
1561 | sphere2.Size = sphere2.Size + VT(3.5,3.5,3.5) | |
1562 | killnearest(cframe.p,15,0) | |
1563 | end | |
1564 | local scale = 0.2 | |
1565 | local mode = "shrink" | |
1566 | for i = 1, 350 do | |
1567 | Swait() | |
1568 | if mode == "shrink" then | |
1569 | scale = scale + scale | |
1570 | if scale >= - 65 then | |
1571 | mode = "grow" | |
1572 | end | |
1573 | elseif mode == "grow" then | |
1574 | scale = scale + -scale*2 | |
1575 | if scale <= - 65 then | |
1576 | mode = "shrink" | |
1577 | end | |
1578 | end | |
1579 | CreateRing(180,5,true,0,50,sphere,0,scale,scale,"Toothpaste") | |
1580 | sphere.Size = sphere.Size + VT(scale,scale,scale) | |
1581 | attractnearest("Vector",cframe.p,50,50,5) | |
1582 | killnearest(cframe.p,15,0) | |
1583 | end | |
1584 | for i = 1, 10 do | |
1585 | Swait(2) | |
1586 | sphere.CFrame = cframe | |
1587 | sphere.Size = sphere.Size - VT(5,5,5) | |
1588 | sphere.CFrame = cframe | |
1589 | sphere2.CFrame = cframe | |
1590 | sphere2.Size = sphere2.Size - VT(3.5,3.5,3.5) | |
1591 | end | |
1592 | sphere:remove() | |
1593 | sphere2:remove() | |
1594 | end)) | |
1595 | for i=0, 1, 0.1 / Animation_Speed do | |
1596 | Swait() | |
1597 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0 * Player_Size, 0 * Player_Size, 0.7 * Player_Size) * ANGLES(RAD(5), RAD(0), RAD(-30)), 0.4 / Animation_Speed) | |
1598 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0 * Player_Size, 0 * Player_Size, 0 + ((1 * Player_Size) - 1)) * ANGLES(RAD(0), RAD(0), RAD(25)) * ANGLES(RAD(5), RAD(0), RAD(0)), 0.4 / Animation_Speed) | |
1599 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5 * Player_Size, 0.5 * Player_Size, 0 * Player_Size) * ANGLES(RAD(70), RAD(0), RAD(45)) * RIGHTSHOULDERC0, 0.4 / Animation_Speed) | |
1600 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5 * Player_Size, 0.25 * Player_Size, -0.25 * Player_Size) * ANGLES(RAD(90), RAD(0), RAD(-20 + MRANDOM(-2.5, 2.5))) * ANGLES(RAD(70 + MRANDOM(-2.5, 2.5)), RAD(40), RAD(0)) * LEFTSHOULDERC0, 0.4 / Animation_Speed) | |
1601 | RightHip.C0 = Clerp(RightHip.C0, CF(1 * Player_Size, -0.3 * Player_Size, -1 * Player_Size) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(-20)), 0.2 / Animation_Speed) | |
1602 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1 * Player_Size, -1 * Player_Size, 0 * Player_Size) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(10)), 0.2 / Animation_Speed) | |
1603 | end | |
1604 | Rooted = false | |
1605 | ATTACK = false | |
1606 | end | |
1607 | ||
1608 | function GravityBeam() | |
1609 | ATTACK = true | |
1610 | Rooted = true | |
1611 | for i=0, 1.5, 0.1 / Animation_Speed do | |
1612 | Swait() | |
1613 | turnto(Mouse.Hit.p) | |
1614 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0 * Player_Size, 0 * Player_Size, 0.7 * Player_Size) * ANGLES(RAD(0), RAD(0), RAD(75)), 0.4 / Animation_Speed) | |
1615 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0 * Player_Size, 0 * Player_Size, 0 + ((1 * Player_Size) - 1)) * ANGLES(RAD(0), RAD(0), RAD(-75)), 0.2 / Animation_Speed) | |
1616 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5 * Player_Size, 0.5 * Player_Size, 0 * Player_Size) * ANGLES(RAD(0), RAD(0), RAD(90)) * RIGHTSHOULDERC0, 0.15 / Animation_Speed) | |
1617 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5 * Player_Size, 0.5 * Player_Size, 0 * Player_Size) * ANGLES(RAD(0), RAD(25), RAD(-25)) * LEFTSHOULDERC0, 0.15 / Animation_Speed) | |
1618 | RightHip.C0 = Clerp(RightHip.C0, CF(1 * Player_Size, -0.3 * Player_Size, -1 * Player_Size) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(-20)), 0.2 / Animation_Speed) | |
1619 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1 * Player_Size, -1 * Player_Size, 0 * Player_Size) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(10)), 0.2 / Animation_Speed) | |
1620 | end | |
1621 | local startpos = RightArm.CFrame*CF(0,-1.5,0).p | |
1622 | local loop = 0 | |
1623 | local loopsound = CreateSound(CHARGESOUND, RightArm, 10, 1, true) | |
1624 | local loopsound2 = CreateSound("487214658", Effects, 1, 0, true) | |
1625 | local pos = nil | |
1626 | repeat | |
1627 | if loop < 150 then | |
1628 | Swait() | |
1629 | loop = loop + 1 | |
1630 | turnto(Mouse.Hit.p) | |
1631 | MagicSphere(15,25,RightArm.CFrame*CF(0,-1,0),"Toothpaste") | |
1632 | MagicSphere(12,25,RightArm.CFrame*CF(0,-1,0),"Toothpaste") | |
1633 | else | |
1634 | loopsound2.Pitch = 1 | |
1635 | loopsound:Stop() | |
1636 | - | MagicSphere(15,25,RightArm.CFrame*CF(0,-1,0),"Bright blue") |
1636 | + | |
1637 | - | MagicSphere(12,25,RightArm.CFrame*CF(0,-1,0),"Bright blue") |
1637 | + | |
1638 | MagicSphere(35,25,CF(startpos),"Toothpaste") | |
1639 | MagicSphere(32,25,CF(startpos),"Toothpaste") | |
1640 | local RayHit, RayPos, RayNormal = CastZapRay(startpos, Mouse.Hit.p, 150, Character, false) | |
1641 | local distance = (startpos - RayPos).magnitude | |
1642 | local laser = Instance.new("Part",Effects) | |
1643 | - | MagicSphere(35,25,CF(startpos),"Bright blue") |
1643 | + | |
1644 | - | MagicSphere(32,25,CF(startpos),"Bright blue") |
1644 | + | |
1645 | laser.Anchored = true | |
1646 | laser.BrickColor = BrickColor.new("Toothpaste") | |
1647 | laser.Material = "Neon" | |
1648 | laser.formFactor = Enum.FormFactor.Custom | |
1649 | laser.Size = Vector3.new(2.5, 2.5, distance) | |
1650 | laser.CFrame = CFrame.new(startpos, RayPos) * CFrame.new(0, 0, -distance/2) | |
1651 | - | laser.BrickColor = BrickColor.new("Bright blue") |
1651 | + | |
1652 | laser2.Transparency = 0 | |
1653 | laser2.CanCollide = false | |
1654 | laser2.Anchored = true | |
1655 | laser2.BrickColor = BrickColor.new("Toothpaste") | |
1656 | laser2.Material = "Neon" | |
1657 | laser2.formFactor = Enum.FormFactor.Custom | |
1658 | laser2.Size = Vector3.new(2, 2, distance) | |
1659 | laser2.CFrame = CFrame.new(startpos, RayPos) * CFrame.new(0, 0, -distance/2) | |
1660 | - | laser2.BrickColor = BrickColor.new("Bright blue") |
1660 | + | |
1661 | MagicSphere(350,2,CF(RayPos),"Toothpaste") | |
1662 | MagicSphere(320,2,CF(RayPos),"Toothpaste") | |
1663 | if RayHit ~= nil then | |
1664 | CreateWave(0,5,false,0,25,CF(RayPos),0,"Toothpaste") | |
1665 | end | |
1666 | - | MagicSphere(350,2,CF(RayPos),"Really black") |
1666 | + | |
1667 | - | MagicSphere(320,2,CF(RayPos),"Really black") |
1667 | + | |
1668 | Swait() | |
1669 | - | CreateWave(0,5,false,0,25,CF(RayPos),0,"Bright blue") |
1669 | + | |
1670 | laser:remove() | |
1671 | end | |
1672 | until KEYHOLD == false | |
1673 | if loop == 150 then | |
1674 | local cframe = CF(pos) | |
1675 | coroutine.resume(coroutine.create(function() | |
1676 | coroutine.resume(coroutine.create(function() | |
1677 | CreateSound(RELEASESOUND, Effects, 2, 1) | |
1678 | MagicSphere(500,55,cframe,"Toothpaste") | |
1679 | MagicSphere(450,55,cframe,"Toothpaste") | |
1680 | for i = 1, 15 do | |
1681 | Swait() | |
1682 | killnearest(cframe.p,75,150) | |
1683 | - | MagicSphere(500,55,cframe,"Bright blue") |
1683 | + | |
1684 | - | MagicSphere(450,55,cframe,"Bright blue") |
1684 | + | |
1685 | end)) | |
1686 | end | |
1687 | loopsound2:remove() | |
1688 | loopsound:remove() | |
1689 | Rooted = false | |
1690 | ATTACK = false | |
1691 | end | |
1692 | ||
1693 | --//=================================\\ | |
1694 | --|| ASSIGN THINGS TO KEYS | |
1695 | --\\=================================// | |
1696 | ||
1697 | Humanoid.Changed:connect(function(Jump) | |
1698 | if Jump == "Jump" and (Disable_Jump == true or DISABLEJUMPING == true) then | |
1699 | Humanoid.Jump = false | |
1700 | end | |
1701 | end) | |
1702 | ||
1703 | function MouseDown(Mouse) | |
1704 | if ATTACK == false then | |
1705 | end | |
1706 | end | |
1707 | ||
1708 | function MouseUp(Mouse) | |
1709 | HOLD = false | |
1710 | end | |
1711 | ||
1712 | function KeyDown(Key) | |
1713 | KEYHOLD = true | |
1714 | if Key == "q" and ATTACK == false then | |
1715 | GraviBomb() | |
1716 | end | |
1717 | ||
1718 | if Key == "e" and ATTACK == false then | |
1719 | GraviSpear() | |
1720 | end | |
1721 | ||
1722 | if Key == "r" and ATTACK == false then | |
1723 | GravityGlobe() | |
1724 | end | |
1725 | ||
1726 | if Key == "g" and ATTACK == false then | |
1727 | GravityBeam() | |
1728 | end | |
1729 | ||
1730 | if Key == "x" and ATTACK == false then | |
1731 | end | |
1732 | ||
1733 | if Key == "c" and ATTACK == false then | |
1734 | WarpSpear() | |
1735 | end | |
1736 | ||
1737 | if Key == "t" and ATTACK == false then | |
1738 | CreateSound("305685800", Head, 10, 1 ,false) | |
1739 | end | |
1740 | end | |
1741 | ||
1742 | function KeyUp(Key) | |
1743 | KEYHOLD = false | |
1744 | end | |
1745 | ||
1746 | Mouse.Button1Down:connect(function(NEWKEY) | |
1747 | MouseDown(NEWKEY) | |
1748 | end) | |
1749 | Mouse.Button1Up:connect(function(NEWKEY) | |
1750 | MouseUp(NEWKEY) | |
1751 | end) | |
1752 | Mouse.KeyDown:connect(function(NEWKEY) | |
1753 | KeyDown(NEWKEY) | |
1754 | end) | |
1755 | Mouse.KeyUp:connect(function(NEWKEY) | |
1756 | KeyUp(NEWKEY) | |
1757 | end) | |
1758 | ||
1759 | --//=================================\\ | |
1760 | --\\=================================// | |
1761 | ||
1762 | ||
1763 | function unanchor() | |
1764 | if UNANCHOR == true then | |
1765 | g = Character:GetChildren() | |
1766 | for i = 1, #g do | |
1767 | if g[i].ClassName == "Part" then | |
1768 | g[i].Anchored = false | |
1769 | end | |
1770 | end | |
1771 | end | |
1772 | end | |
1773 | ||
1774 | ||
1775 | --//=================================\\ | |
1776 | --|| WRAP THE WHOLE SCRIPT UP | |
1777 | --\\=================================// | |
1778 | ||
1779 | Humanoid.Changed:connect(function(Jump) | |
1780 | if Jump == "Jump" and (Disable_Jump == true or DISABLEJUMPING == true) then | |
1781 | Humanoid.Jump = false | |
1782 | end | |
1783 | end) | |
1784 | ||
1785 | ANIMATE.Parent = nil | |
1786 | local IDLEANIMATION = Humanoid:LoadAnimation(ROBLOXIDLEANIMATION) | |
1787 | IDLEANIMATION:Play() | |
1788 | ||
1789 | while true do | |
1790 | Swait() | |
1791 | SINE = SINE + CHANGE | |
1792 | local TORSOVELOCITY = (RootPart.Velocity * VT(1, 0, 1)).magnitude | |
1793 | local TORSOVERTICALVELOCITY = RootPart.Velocity.y | |
1794 | local LV = Torso.CFrame:pointToObjectSpace(Torso.Velocity - Torso.Position) | |
1795 | local HITFLOOR = Raycast(RootPart.Position, (CF(RootPart.Position, RootPart.Position + VT(0, -1, 0))).lookVector, 4 * Player_Size, Character) | |
1796 | local WALKSPEEDVALUE = 6 / (Humanoid.WalkSpeed / 16) | |
1797 | if ANIM == "Walk" and TORSOVELOCITY > 1 then | |
1798 | RootJoint.C1 = Clerp(RootJoint.C1, ROOTC0 * CF(0, 0, -0.1 * COS(SINE / (WALKSPEEDVALUE / 2)) * Player_Size) * ANGLES(RAD(0), RAD(0) - RootPart.RotVelocity.Y / 75, RAD(0)), 0.2 * (Humanoid.WalkSpeed / 16) / Animation_Speed) | |
1799 | Neck.C1 = Clerp(Neck.C1, CF(0 * Player_Size, -0.5 * Player_Size, 0 * Player_Size) * ANGLES(RAD(-90), RAD(0), RAD(180)) * ANGLES(RAD(2.5 * SIN(SINE / (WALKSPEEDVALUE / 2))), RAD(0), RAD(0) - Head.RotVelocity.Y / 30), 0.2 * (Humanoid.WalkSpeed / 16) / Animation_Speed) | |
1800 | --RightHip.C1 = Clerp(RightHip.C1, CF(0.5 * Player_Size, 0.875 * Player_Size - 0.125 * SIN(SINE / WALKSPEEDVALUE) * Player_Size, -0.125 * COS(SINE / WALKSPEEDVALUE) * Player_Size) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0) - RightLeg.RotVelocity.Y / 75, RAD(0), RAD(60 * COS(SINE / WALKSPEEDVALUE))), 0.2 * (Humanoid.WalkSpeed / 16) / Animation_Speed) | |
1801 | --LeftHip.C1 = Clerp(LeftHip.C1, CF(-0.5 * Player_Size, 0.875 * Player_Size + 0.125 * SIN(SINE / WALKSPEEDVALUE) * Player_Size, 0.125 * COS(SINE / WALKSPEEDVALUE) * Player_Size) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0) + LeftLeg.RotVelocity.Y / 75, RAD(0), RAD(60 * COS(SINE / WALKSPEEDVALUE))), 0.2 * (Humanoid.WalkSpeed / 16) / Animation_Speed) | |
1802 | elseif (ANIM ~= "Walk") or (TORSOVELOCITY < 1) then | |
1803 | RootJoint.C1 = Clerp(RootJoint.C1, ROOTC0 * CF(0, 0, 0) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.2 / Animation_Speed) | |
1804 | Neck.C1 = Clerp(Neck.C1, CF(0 * Player_Size, -0.5 * Player_Size, 0 * Player_Size) * ANGLES(RAD(-90), RAD(0), RAD(180)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.2 / Animation_Speed) | |
1805 | --RightHip.C1 = Clerp(RightHip.C1, CF(0.5 * Player_Size, 1 * Player_Size, 0 * Player_Size) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.2 / Animation_Speed) | |
1806 | ----LeftHip.C1 = Clerp(LeftHip.C1, CF(-0.5 * Player_Size, 1 * Player_Size, 0 * Player_Size) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.2 / Animation_Speed) | |
1807 | end | |
1808 | if TORSOVERTICALVELOCITY > 1 and HITFLOOR == nil then | |
1809 | ANIM = "Jump" | |
1810 | if ATTACK == false then | |
1811 | RootJoint.C0 = Clerp(RootJoint.C0, ROOTC0 * CF(0 * Player_Size, 0 * Player_Size, 0.7 * Player_Size) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.2 / Animation_Speed) | |
1812 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0 * Player_Size, 0 * Player_Size, 0 + ((1 * Player_Size) - 1)) * ANGLES(RAD(-20), RAD(0), RAD(0)), 0.2 / Animation_Speed) | |
1813 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5 * Player_Size, 0.5 * Player_Size, 0 * Player_Size) * ANGLES(RAD(-40), RAD(0), RAD(20)) * RIGHTSHOULDERC0, 0.2 / Animation_Speed) | |
1814 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5 * Player_Size, 0.5 * Player_Size, 0 * Player_Size) * ANGLES(RAD(-40), RAD(0), RAD(-20)) * LEFTSHOULDERC0, 0.2 / Animation_Speed) | |
1815 | RightHip.C0 = Clerp(RightHip.C0, CF(1 * Player_Size, -1 * Player_Size, -0.3 * Player_Size) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(-5), RAD(0), RAD(-20)), 0.2 / Animation_Speed) | |
1816 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1 * Player_Size, -1 * Player_Size, -0.3 * Player_Size) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(-5), RAD(0), RAD(20)), 0.2 / Animation_Speed) | |
1817 | end | |
1818 | elseif TORSOVERTICALVELOCITY < -1 and HITFLOOR == nil then | |
1819 | ANIM = "Fall" | |
1820 | if ATTACK == false then | |
1821 | RootJoint.C0 = Clerp(RootJoint.C0, ROOTC0 * CF(0 * Player_Size, 0 * Player_Size, 0.7 * Player_Size) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.2 / Animation_Speed) | |
1822 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0 * Player_Size, 0 * Player_Size, 0 + ((1 * Player_Size) - 1)) * ANGLES(RAD(20), RAD(0), RAD(0)), 0.2 / Animation_Speed) | |
1823 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5 * Player_Size, 0.5 * Player_Size, 0 * Player_Size) * ANGLES(RAD(0), RAD(0), RAD(60)) * RIGHTSHOULDERC0, 0.2 / Animation_Speed) | |
1824 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5 * Player_Size, 0.5 * Player_Size, 0 * Player_Size) * ANGLES(RAD(0), RAD(0), RAD(-60)) * LEFTSHOULDERC0, 0.2 / Animation_Speed) | |
1825 | RightHip.C0 = Clerp(RightHip.C0, CF(1 * Player_Size, -1 * Player_Size, 0 * Player_Size) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(20)), 0.2 / Animation_Speed) | |
1826 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1 * Player_Size, -1 * Player_Size, 0 * Player_Size) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(10)), 0.2 / Animation_Speed) | |
1827 | end | |
1828 | elseif TORSOVELOCITY < 1 and HITFLOOR ~= nil then | |
1829 | ANIM = "Idle" | |
1830 | if ATTACK == false then | |
1831 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0 * Player_Size, 0 * Player_Size, 0.7 * Player_Size + 0.05 * COS(SINE / 12) * Player_Size) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed) | |
1832 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0 * Player_Size, 0 * Player_Size, 0 + ((1 * Player_Size) - 1)) * ANGLES(RAD(15 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 0.15 / Animation_Speed) | |
1833 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5 * Player_Size, 0.5 * Player_Size, 0 * Player_Size) * ANGLES(RAD(0), RAD(0), RAD(12)) * RIGHTSHOULDERC0, 0.15 / Animation_Speed) | |
1834 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5 * Player_Size, 0.5 * Player_Size, 0 * Player_Size) * ANGLES(RAD(0), RAD(0), RAD(-12)) * LEFTSHOULDERC0, 0.15 / Animation_Speed) | |
1835 | RightHip.C0 = Clerp(RightHip.C0, CF(1 * Player_Size, -0.3 * Player_Size - 0 * Player_Size, -0.2 * Player_Size) * ANGLES(RAD(0), RAD(70), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 0.15 / Animation_Speed) | |
1836 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1 * Player_Size, -0.8 * Player_Size - 0.2 * COS(SINE / 12) * Player_Size, -0.01 * Player_Size) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 0.15 / Animation_Speed) | |
1837 | end | |
1838 | elseif TORSOVELOCITY > 1 and HITFLOOR ~= nil then | |
1839 | ANIM = "Walk" | |
1840 | WALK = WALK + 1 / Animation_Speed | |
1841 | if WALK >= 15 - (5 * (Humanoid.WalkSpeed / 16 / Player_Size)) then | |
1842 | WALK = 0 | |
1843 | if WALKINGANIM == true then | |
1844 | WALKINGANIM = false | |
1845 | elseif WALKINGANIM == false then | |
1846 | WALKINGANIM = true | |
1847 | end | |
1848 | end | |
1849 | --RightHip.C1 = Clerp(RightHip.C1, CF(0.5 * Player_Size, 0.875 * Player_Size - 0.125 * SIN(SINE / WALKSPEEDVALUE) * Player_Size, -0.125 * COS(SINE / WALKSPEEDVALUE) * Player_Size) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0) - RightLeg.RotVelocity.Y / 75, RAD(0), RAD(60 * COS(SINE / WALKSPEEDVALUE))), 0.2 * (Humanoid.WalkSpeed / 16) / Animation_Speed) | |
1850 | --LeftHip.C1 = Clerp(LeftHip.C1, CF(-0.5 * Player_Size, 0.875 * Player_Size + 0.125 * SIN(SINE / WALKSPEEDVALUE) * Player_Size, 0.125 * COS(SINE / WALKSPEEDVALUE) * Player_Size) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0) + LeftLeg.RotVelocity.Y / 75, RAD(0), RAD(60 * COS(SINE / WALKSPEEDVALUE))), 0.2 * (Humanoid.WalkSpeed / 16) / Animation_Speed) | |
1851 | if ATTACK == false then | |
1852 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0 * Player_Size, 0 * Player_Size, 0.7 * Player_Size) * ANGLES(RAD(25), RAD(0), RAD(0)), 0.15 / Animation_Speed*3) | |
1853 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0 * Player_Size, 0 * Player_Size, 0 + ((1 * Player_Size) - 1)) * ANGLES(RAD(-5 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 0.15 / Animation_Speed) | |
1854 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5 * Player_Size, 0.5 * Player_Size, 0 * Player_Size) * ANGLES(RAD(-40), RAD(0), RAD(20)) * RIGHTSHOULDERC0, 0.2 / Animation_Speed) | |
1855 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5 * Player_Size, 0.5 * Player_Size, 0 * Player_Size) * ANGLES(RAD(-40), RAD(0), RAD(-20)) * LEFTSHOULDERC0, 0.2 / Animation_Speed) | |
1856 | RightHip.C0 = Clerp(RightHip.C0, CF(1 * Player_Size, -0.3 * Player_Size - 0 * Player_Size, -0.2 * Player_Size) * ANGLES(RAD(0), RAD(70), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 0.15 / Animation_Speed) | |
1857 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1 * Player_Size, -0.8 * Player_Size - 0.2 * COS(SINE / 12) * Player_Size, -0.01 * Player_Size) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 0.15 / Animation_Speed) | |
1858 | end | |
1859 | end | |
1860 | if #Effects2>0 then | |
1861 | for e=1,#Effects2 do | |
1862 | if Effects2[e]~=nil then | |
1863 | local Thing=Effects2[e] | |
1864 | if Thing~=nil then | |
1865 | local Part=Thing[1] | |
1866 | local Mode=Thing[2] | |
1867 | local Delay=Thing[3] | |
1868 | local IncX=Thing[4] | |
1869 | local IncY=Thing[5] | |
1870 | local IncZ=Thing[6] | |
1871 | local Part2=Thing[8] | |
1872 | if Thing[1].Transparency<=1 then | |
1873 | if Thing[2]=="Block1" then | |
1874 | Thing[1].CFrame=Thing[1].CFrame | |
1875 | Mesh=Thing[1].Mesh | |
1876 | Mesh.Scale=Mesh.Scale+VT(Thing[4],Thing[5],Thing[6]) | |
1877 | Thing[1].Transparency=Thing[1].Transparency+Thing[3] | |
1878 | elseif Thing[2]=="Cylinder" then | |
1879 | Mesh=Thing[1].Mesh | |
1880 | Mesh.Scale=Mesh.Scale+VT(Thing[4],Thing[5],Thing[6]) | |
1881 | Thing[1].Transparency=Thing[1].Transparency+Thing[3] | |
1882 | elseif Thing[2]=="Blood" then | |
1883 | Mesh=Thing[7] | |
1884 | Thing[1].CFrame=Thing[1].CFrame*CF(0,.5,0) | |
1885 | Mesh.Scale=Mesh.Scale+VT(Thing[4],Thing[5],Thing[6]) | |
1886 | Thing[1].Transparency=Thing[1].Transparency+Thing[3] | |
1887 | elseif Thing[2]=="Elec" then | |
1888 | Mesh=Thing[1].Mesh | |
1889 | Mesh.Scale=Mesh.Scale+VT(Thing[7],Thing[8],Thing[9]) | |
1890 | Thing[1].Transparency=Thing[1].Transparency+Thing[3] | |
1891 | elseif Thing[2]=="Disappear" then | |
1892 | Thing[1].Transparency=Thing[1].Transparency+Thing[3] | |
1893 | end | |
1894 | else | |
1895 | Part.Parent=nil | |
1896 | table.remove(Effects2,e) | |
1897 | end | |
1898 | end | |
1899 | end | |
1900 | end | |
1901 | end | |
1902 | unanchor() | |
1903 | Humanoid.MaxHealth = "inf" | |
1904 | Humanoid.Health = "inf" | |
1905 | if Rooted == false then | |
1906 | Disable_Jump = false | |
1907 | Humanoid.WalkSpeed = Speed | |
1908 | elseif Rooted == true then | |
1909 | Disable_Jump = true | |
1910 | Humanoid.WalkSpeed = 0 | |
1911 | end | |
1912 | ||
1913 | --CreateMagicCircle(2 ,false,0,3,LeftLeg.CFrame * CF(0,-1.2,0),true) | |
1914 | end | |
1915 | ||
1916 | --//=================================\\ | |
1917 | --\\=================================// | |
1918 | ||
1919 | ||
1920 | ||
1921 | ||
1922 | ||
1923 | --//====================================================\\-- | |
1924 | --|| END OF SCRIPT | |
1925 | --\\====================================================//-- |