SHOW:
|
|
- or go back to the newest paste.
1 | --//====================================================\\-- | |
2 | --|| CREATED BY SHACKLUSTER | |
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",Head) | |
32 | - | sick.SoundId = "rbxassetid://397874147" |
32 | + | sick.SoundId = "rbxassetid://674973249" |
33 | sick.Looped = true | |
34 | sick.Pitch = 1 | |
35 | sick.Volume = 1 | |
36 | sick:Play() | |
37 | local EFFECT = Instance.new("DistortionSoundEffect",sick) | |
38 | EFFECT.Level = 0 | |
39 | ||
40 | IT = Instance.new | |
41 | CF = CFrame.new | |
42 | VT = Vector3.new | |
43 | RAD = math.rad | |
44 | C3 = Color3.new | |
45 | UD2 = UDim2.new | |
46 | BRICKC = BrickColor.new | |
47 | ANGLES = CFrame.Angles | |
48 | EULER = CFrame.fromEulerAnglesXYZ | |
49 | COS = math.cos | |
50 | ACOS = math.acos | |
51 | SIN = math.sin | |
52 | ASIN = math.asin | |
53 | ABS = math.abs | |
54 | MRANDOM = math.random | |
55 | FLOOR = math.floor | |
56 | ||
57 | function CreateMesh(MESH, PARENT, MESHTYPE, MESHID, TEXTUREID, SCALE, OFFSET) | |
58 | local NEWMESH = IT(MESH) | |
59 | if MESH == "SpecialMesh" then | |
60 | NEWMESH.MeshType = MESHTYPE | |
61 | if MESHID ~= "nil" and MESHID ~= "" then | |
62 | - | NEWMESH.MeshId = "http://www.roblox.com/asset/?id="..MESHID |
62 | + | NEWMESH.MeshId = "http://www.roblox.com/asset/?id=904109290 |
63 | end | |
64 | if TEXTUREID ~= "nil" and TEXTUREID ~= "" then | |
65 | - | NEWMESH.TextureId = "http://www.roblox.com/asset/?id="..TEXTUREID |
65 | + | NEWMESH.TextureId = "http://www.roblox.com/asset/?id=904109303 |
66 | end | |
67 | end | |
68 | NEWMESH.Offset = OFFSET or VT(0, 0, 0) | |
69 | NEWMESH.Scale = SCALE | |
70 | NEWMESH.Parent = PARENT | |
71 | return NEWMESH | |
72 | end | |
73 | ||
74 | function CreatePart(FORMFACTOR, PARENT, MATERIAL, REFLECTANCE, TRANSPARENCY, BRICKCOLOR, NAME, SIZE, ANCHOR) | |
75 | local NEWPART = IT("Part") | |
76 | NEWPART.formFactor = FORMFACTOR | |
77 | NEWPART.Reflectance = REFLECTANCE | |
78 | NEWPART.Transparency = TRANSPARENCY | |
79 | NEWPART.CanCollide = false | |
80 | NEWPART.Locked = true | |
81 | NEWPART.Anchored = true | |
82 | if ANCHOR == false then | |
83 | NEWPART.Anchored = false | |
84 | end | |
85 | NEWPART.BrickColor = BRICKC(tostring(BRICKCOLOR)) | |
86 | NEWPART.Name = NAME | |
87 | NEWPART.Size = SIZE | |
88 | NEWPART.Position = Torso.Position | |
89 | NEWPART.Material = MATERIAL | |
90 | NEWPART:BreakJoints() | |
91 | NEWPART.Parent = PARENT | |
92 | return NEWPART | |
93 | end | |
94 | ||
95 | --//=================================\\ | |
96 | --|| CUSTOMIZATION | |
97 | --\\=================================// | |
98 | ||
99 | Player_Size = 1 --Size of the player. | |
100 | Animation_Speed = 3 | |
101 | Frame_Speed = 1 / 60 -- (1 / 30) OR (1 / 60) | |
102 | ||
103 | local Speed = 16 | |
104 | local Effects2 = {} | |
105 | ||
106 | --//=================================\\ | |
107 | --|| END OF CUSTOMIZATION | |
108 | --\\=================================// | |
109 | ||
110 | local function weldBetween(a, b) | |
111 | local weldd = Instance.new("ManualWeld") | |
112 | weldd.Part0 = a | |
113 | weldd.Part1 = b | |
114 | weldd.C0 = CFrame.new() | |
115 | weldd.C1 = b.CFrame:inverse() * a.CFrame | |
116 | weldd.Parent = a | |
117 | return weldd | |
118 | end | |
119 | ||
120 | function createaccessory(attachmentpart,mesh,texture,scale,offset,color) | |
121 | local acs = Instance.new("Part") | |
122 | acs.CanCollide = false | |
123 | acs.Anchored = false | |
124 | acs.Size = Vector3.new(0,0,0) | |
125 | acs.CFrame = attachmentpart.CFrame | |
126 | acs.Parent = Character | |
127 | acs.BrickColor = color | |
128 | local meshs = Instance.new("SpecialMesh") | |
129 | meshs.MeshId = mesh | |
130 | meshs.TextureId = texture | |
131 | meshs.Parent = acs | |
132 | meshs.Scale = scale | |
133 | meshs.Offset = offset | |
134 | weldBetween(attachmentpart,acs) | |
135 | end | |
136 | ||
137 | function createbodypart(TYPE,COLOR,PART,OFFSET,SIZE) | |
138 | if TYPE == "Gem" then | |
139 | local acs = CreatePart(3, Character, "Plastic", 0, 0, COLOR, "Part", VT(0,0,0)) | |
140 | acs.Anchored = false | |
141 | acs.CanCollide = false | |
142 | acs.CFrame = PART.CFrame | |
143 | local acs2 = CreateMesh("SpecialMesh", acs, "FileMesh", "9756362", "", SIZE, OFFSET) | |
144 | weldBetween(PART,acs) | |
145 | elseif TYPE == "Skull" then | |
146 | local acs = CreatePart(3, Character, "Plastic", 0, 0, COLOR, "Part", VT(0,0,0)) | |
147 | acs.Anchored = false | |
148 | acs.CanCollide = false | |
149 | acs.CFrame = PART.CFrame | |
150 | local acs2 = CreateMesh("SpecialMesh", acs, "FileMesh", "4770583", "", SIZE, OFFSET) | |
151 | weldBetween(PART,acs) | |
152 | elseif TYPE == "Eye" then | |
153 | local acs = CreatePart(3, Character, "Neon", 0, 0, COLOR, "Part", VT(0,0,0)) | |
154 | acs.Anchored = false | |
155 | acs.CanCollide = false | |
156 | acs.CFrame = PART.CFrame | |
157 | local acs2 = CreateMesh("SpecialMesh", acs, "Sphere", "", "", SIZE, OFFSET) | |
158 | weldBetween(PART,acs) | |
159 | end | |
160 | end | |
161 | ||
162 | --//=================================\\ | |
163 | --|| USEFUL VALUES | |
164 | --\\=================================// | |
165 | ||
166 | local ROOTC0 = CF(0, 0, 0) * ANGLES(RAD(-90), RAD(0), RAD(180)) | |
167 | local NECKC0 = CF(0, 1, 0) * ANGLES(RAD(-90), RAD(0), RAD(180)) | |
168 | local RIGHTSHOULDERC0 = CF(-0.5, 0, 0) * ANGLES(RAD(0), RAD(90), RAD(0)) | |
169 | local LEFTSHOULDERC0 = CF(0.5, 0, 0) * ANGLES(RAD(0), RAD(-90), RAD(0)) | |
170 | local CHANGEDEFENSE = 0 | |
171 | local CHANGEDAMAGE = 0 | |
172 | local CHANGEMOVEMENT = 0 | |
173 | local ANIM = "Idle" | |
174 | local ATTACK = false | |
175 | local EQUIPPED = false | |
176 | local HOLD = false | |
177 | local COMBO = 1 | |
178 | local Rooted = false | |
179 | local SINE = 0 | |
180 | local KEYHOLD = false | |
181 | local CHANGE = 2 / Animation_Speed | |
182 | local WALKINGANIM = false | |
183 | local WALK = 0 | |
184 | local VALUE1 = false | |
185 | local VALUE2 = false | |
186 | local ROBLOXIDLEANIMATION = IT("Animation") | |
187 | ROBLOXIDLEANIMATION.Name = "Roblox Idle Animation" | |
188 | ROBLOXIDLEANIMATION.AnimationId = "http://www.roblox.com/asset/?id=180435571" | |
189 | --ROBLOXIDLEANIMATION.Parent = Humanoid | |
190 | local WEAPONGUI = IT("ScreenGui", PlayerGui) | |
191 | WEAPONGUI.Name = "Weapon GUI" | |
192 | local Weapon = IT("Model") | |
193 | Weapon.Name = "Adds" | |
194 | local Effects = IT("Folder", Weapon) | |
195 | Effects.Name = "Effects" | |
196 | local ANIMATOR = Humanoid.Animator | |
197 | local ANIMATE = Character.Animate | |
198 | local HITPLAYERSOUNDS = {--[["199149137", "199149186", "199149221", "199149235", "199149269", "199149297"--]]"263032172", "263032182", "263032200", "263032221", "263032252", "263033191"} | |
199 | local HITARMORSOUNDS = {"199149321", "199149338", "199149367", "199149409", "199149452"} | |
200 | local HITWEAPONSOUNDS = {"199148971", "199149025", "199149072", "199149109", "199149119"} | |
201 | local HITBLOCKSOUNDS = {"199148933", "199148947"} | |
202 | local UNANCHOR = true | |
203 | ||
204 | local SKILLTEXTCOLOR = C3(0,0,0) | |
205 | ||
206 | --//=================================\\ | |
207 | --\\=================================// | |
208 | ||
209 | ||
210 | --//=================================\\ | |
211 | --|| SAZERENOS' ARTIFICIAL HEARTBEAT | |
212 | --\\=================================// | |
213 | ||
214 | ArtificialHB = Instance.new("BindableEvent", script) | |
215 | ArtificialHB.Name = "ArtificialHB" | |
216 | ||
217 | script:WaitForChild("ArtificialHB") | |
218 | ||
219 | frame = Frame_Speed | |
220 | tf = 0 | |
221 | allowframeloss = false | |
222 | tossremainder = false | |
223 | lastframe = tick() | |
224 | script.ArtificialHB:Fire() | |
225 | ||
226 | game:GetService("RunService").Heartbeat:connect(function(s, p) | |
227 | tf = tf + s | |
228 | if tf >= frame then | |
229 | if allowframeloss then | |
230 | script.ArtificialHB:Fire() | |
231 | lastframe = tick() | |
232 | else | |
233 | for i = 1, math.floor(tf / frame) do | |
234 | script.ArtificialHB:Fire() | |
235 | end | |
236 | lastframe = tick() | |
237 | end | |
238 | if tossremainder then | |
239 | tf = 0 | |
240 | else | |
241 | tf = tf - frame * math.floor(tf / frame) | |
242 | end | |
243 | end | |
244 | end) | |
245 | ||
246 | --//=================================\\ | |
247 | --\\=================================// | |
248 | ||
249 | ||
250 | ||
251 | ||
252 | ||
253 | --//=================================\\ | |
254 | --|| SOME FUNCTIONS | |
255 | --\\=================================// | |
256 | ||
257 | function Raycast(POSITION, DIRECTION, RANGE, IGNOREDECENDANTS) | |
258 | return workspace:FindPartOnRay(Ray.new(POSITION, DIRECTION.unit * RANGE), IGNOREDECENDANTS) | |
259 | end | |
260 | ||
261 | function PositiveAngle(NUMBER) | |
262 | if NUMBER >= 0 then | |
263 | NUMBER = 0 | |
264 | end | |
265 | return NUMBER | |
266 | end | |
267 | ||
268 | function NegativeAngle(NUMBER) | |
269 | if NUMBER <= 0 then | |
270 | NUMBER = 0 | |
271 | end | |
272 | return NUMBER | |
273 | end | |
274 | ||
275 | function Swait(NUMBER) | |
276 | if NUMBER == 0 or NUMBER == nil then | |
277 | ArtificialHB.Event:wait() | |
278 | else | |
279 | for i = 1, NUMBER do | |
280 | ArtificialHB.Event:wait() | |
281 | end | |
282 | end | |
283 | end | |
284 | ||
285 | function QuaternionFromCFrame(cf) | |
286 | local mx, my, mz, m00, m01, m02, m10, m11, m12, m20, m21, m22 = cf:components() | |
287 | local trace = m00 + m11 + m22 | |
288 | if trace > 0 then | |
289 | local s = math.sqrt(1 + trace) | |
290 | local recip = 0.5 / s | |
291 | return (m21 - m12) * recip, (m02 - m20) * recip, (m10 - m01) * recip, s * 0.5 | |
292 | else | |
293 | local i = 0 | |
294 | if m11 > m00 then | |
295 | i = 1 | |
296 | end | |
297 | if m22 > (i == 0 and m00 or m11) then | |
298 | i = 2 | |
299 | end | |
300 | if i == 0 then | |
301 | local s = math.sqrt(m00 - m11 - m22 + 1) | |
302 | local recip = 0.5 / s | |
303 | return 0.5 * s, (m10 + m01) * recip, (m20 + m02) * recip, (m21 - m12) * recip | |
304 | elseif i == 1 then | |
305 | local s = math.sqrt(m11 - m22 - m00 + 1) | |
306 | local recip = 0.5 / s | |
307 | return (m01 + m10) * recip, 0.5 * s, (m21 + m12) * recip, (m02 - m20) * recip | |
308 | elseif i == 2 then | |
309 | local s = math.sqrt(m22 - m00 - m11 + 1) | |
310 | local recip = 0.5 / s return (m02 + m20) * recip, (m12 + m21) * recip, 0.5 * s, (m10 - m01) * recip | |
311 | end | |
312 | end | |
313 | end | |
314 | ||
315 | function QuaternionToCFrame(px, py, pz, x, y, z, w) | |
316 | local xs, ys, zs = x + x, y + y, z + z | |
317 | local wx, wy, wz = w * xs, w * ys, w * zs | |
318 | local xx = x * xs | |
319 | local xy = x * ys | |
320 | local xz = x * zs | |
321 | local yy = y * ys | |
322 | local yz = y * zs | |
323 | local zz = z * zs | |
324 | 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)) | |
325 | end | |
326 | ||
327 | function QuaternionSlerp(a, b, t) | |
328 | local cosTheta = a[1] * b[1] + a[2] * b[2] + a[3] * b[3] + a[4] * b[4] | |
329 | local startInterp, finishInterp; | |
330 | if cosTheta >= 0.0001 then | |
331 | if (1 - cosTheta) > 0.0001 then | |
332 | local theta = ACOS(cosTheta) | |
333 | local invSinTheta = 1 / SIN(theta) | |
334 | startInterp = SIN((1 - t) * theta) * invSinTheta | |
335 | finishInterp = SIN(t * theta) * invSinTheta | |
336 | else | |
337 | startInterp = 1 - t | |
338 | finishInterp = t | |
339 | end | |
340 | else | |
341 | if (1 + cosTheta) > 0.0001 then | |
342 | local theta = ACOS(-cosTheta) | |
343 | local invSinTheta = 1 / SIN(theta) | |
344 | startInterp = SIN((t - 1) * theta) * invSinTheta | |
345 | finishInterp = SIN(t * theta) * invSinTheta | |
346 | else | |
347 | startInterp = t - 1 | |
348 | finishInterp = t | |
349 | end | |
350 | end | |
351 | 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 | |
352 | end | |
353 | ||
354 | function Clerp(a, b, t) | |
355 | local qa = {QuaternionFromCFrame(a)} | |
356 | local qb = {QuaternionFromCFrame(b)} | |
357 | local ax, ay, az = a.x, a.y, a.z | |
358 | local bx, by, bz = b.x, b.y, b.z | |
359 | local _t = 1 - t | |
360 | return QuaternionToCFrame(_t * ax + t * bx, _t * ay + t * by, _t * az + t * bz, QuaternionSlerp(qa, qb, t)) | |
361 | end | |
362 | ||
363 | function CreateFrame(PARENT, TRANSPARENCY, BORDERSIZEPIXEL, POSITION, SIZE, COLOR, BORDERCOLOR, NAME) | |
364 | local frame = IT("Frame") | |
365 | frame.BackgroundTransparency = TRANSPARENCY | |
366 | frame.BorderSizePixel = BORDERSIZEPIXEL | |
367 | frame.Position = POSITION | |
368 | frame.Size = SIZE | |
369 | frame.BackgroundColor3 = COLOR | |
370 | frame.BorderColor3 = BORDERCOLOR | |
371 | frame.Name = NAME | |
372 | frame.Parent = PARENT | |
373 | return frame | |
374 | end | |
375 | ||
376 | function CreateLabel(PARENT, TEXT, TEXTCOLOR, TEXTFONTSIZE, TEXTFONT, TRANSPARENCY, BORDERSIZEPIXEL, STROKETRANSPARENCY, NAME) | |
377 | local label = IT("TextLabel") | |
378 | label.BackgroundTransparency = 1 | |
379 | label.Size = UD2(1, 0, 1, 0) | |
380 | label.Position = UD2(0, 0, 0, 0) | |
381 | label.TextColor3 = TEXTCOLOR | |
382 | label.TextStrokeTransparency = STROKETRANSPARENCY | |
383 | label.TextTransparency = TRANSPARENCY | |
384 | label.FontSize = TEXTFONTSIZE | |
385 | label.Font = TEXTFONT | |
386 | label.BorderSizePixel = BORDERSIZEPIXEL | |
387 | label.TextScaled = false | |
388 | label.Text = TEXT | |
389 | label.Name = NAME | |
390 | label.Parent = PARENT | |
391 | return label | |
392 | end | |
393 | ||
394 | function NoOutlines(PART) | |
395 | PART.TopSurface, PART.BottomSurface, PART.LeftSurface, PART.RightSurface, PART.FrontSurface, PART.BackSurface = 10, 10, 10, 10, 10, 10 | |
396 | end | |
397 | ||
398 | ||
399 | function CreateWeldOrSnapOrMotor(TYPE, PARENT, PART0, PART1, C0, C1) | |
400 | local NEWWELD = IT(TYPE) | |
401 | NEWWELD.Part0 = PART0 | |
402 | NEWWELD.Part1 = PART1 | |
403 | NEWWELD.C0 = C0 | |
404 | NEWWELD.C1 = C1 | |
405 | NEWWELD.Parent = PARENT | |
406 | return NEWWELD | |
407 | end | |
408 | ||
409 | function CreateSound(ID, PARENT, VOLUME, PITCH) | |
410 | local NEWSOUND = nil | |
411 | coroutine.resume(coroutine.create(function() | |
412 | NEWSOUND = IT("Sound", PARENT) | |
413 | NEWSOUND.Volume = VOLUME | |
414 | NEWSOUND.Pitch = PITCH | |
415 | NEWSOUND.SoundId = "http://www.roblox.com/asset/?id="..ID | |
416 | Swait() | |
417 | NEWSOUND:play() | |
418 | game:GetService("Debris"):AddItem(NEWSOUND, 10) | |
419 | end)) | |
420 | return NEWSOUND | |
421 | end | |
422 | ||
423 | function CFrameFromTopBack(at, top, back) | |
424 | local right = top:Cross(back) | |
425 | 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) | |
426 | end | |
427 | ||
428 | Debris = game:GetService("Debris") | |
429 | ||
430 | --//=================================\\ | |
431 | --|| WEAPON CREATION | |
432 | --\\=================================// | |
433 | ||
434 | local Gun = CreatePart(3, Weapon, "SmoothPlastic", 0, 0, "Really black", "Handle", VT(0, 0, 0),false) | |
435 | local HandleMesh = CreateMesh("SpecialMesh", Gun, "FileMesh", "430345282", "430345284", VT(0.2,0.2,0.2), VT(0,0, 0)) | |
436 | local Weld = CreateWeldOrSnapOrMotor("Weld", Gun, RightArm, Gun, CF(-0.55, -1.2, 0) * ANGLES(RAD(180), RAD(-90), RAD(0)), CF(0, 0, 0)) | |
437 | ||
438 | for _, c in pairs(Weapon:GetChildren()) do | |
439 | if c.ClassName == "Part" then | |
440 | c.CustomPhysicalProperties = PhysicalProperties.new(0, 0, 0, 0, 0) | |
441 | end | |
442 | end | |
443 | ||
444 | Weapon.Parent = Character | |
445 | ||
446 | Humanoid.Died:connect(function() | |
447 | ATTACK = true | |
448 | end) | |
449 | ||
450 | local SKILL1FRAME = CreateFrame(WEAPONGUI, 0.5, 2, UD2(0.365, 0, 0.90, 0), UD2(0.26, 0, 0.07, 0), C3(0,0,0), C3(0, 0, 0), "Skill 1 Frame") | |
451 | ||
452 | local SKILL1TEXT = CreateLabel(SKILL1FRAME, "[Z] Pizza launcher", SKILLTEXTCOLOR, 6, "Legacy", 0, 2, 1, "Text 1") | |
453 | ||
454 | --//=================================\\ | |
455 | --|| ATTACK FUNCTIONS AND STUFF | |
456 | --\\=================================// | |
457 | ||
458 | function PizzaLauncher() | |
459 | local PIZZA = CreatePart(3, Effects, "SmoothPlastic", 0, 0, "Really black", "Handle", VT(1,1,1),false) | |
460 | PIZZA.CFrame = CF(RootPart.Position,Mouse.Hit.p)*ANGLES(RAD(0),RAD(-90),RAD(0)) | |
461 | local bv = Instance.new("BodyVelocity") | |
462 | bv.maxForce = Vector3.new(1e9, 1e9, 1e9) | |
463 | bv.velocity = CF(PIZZA.Position,Mouse.Hit.p).lookVector*200 | |
464 | bv.Parent = PIZZA | |
465 | bv.Name = "MOVE" | |
466 | CreateSound("1058021195", PIZZA, 10, MRANDOM(8,10)/10) | |
467 | CreateMesh("SpecialMesh", PIZZA, "FileMesh", "22589477", "22589467", VT(1,1,1), VT(0,0, 0)) | |
468 | local HIT = PIZZA.Touched:Connect(function(hit) | |
469 | if hit.Parent ~= Character and hit.Parent ~= Weapon then | |
470 | hit.Parent:BreakJoints() | |
471 | end | |
472 | end) | |
473 | Debris:AddItem(PIZZA,5) | |
474 | end | |
475 | ||
476 | --//=================================\\ | |
477 | --|| ASSIGN THINGS TO KEYS | |
478 | --\\=================================// | |
479 | ||
480 | function MouseDown(Mouse) | |
481 | if ATTACK == false then | |
482 | end | |
483 | end | |
484 | ||
485 | function MouseUp(Mouse) | |
486 | HOLD = false | |
487 | end | |
488 | ||
489 | function KeyDown(Key) | |
490 | KEYHOLD = true | |
491 | if Key == "z" and ATTACK == false then | |
492 | PizzaLauncher() | |
493 | end | |
494 | ||
495 | if Key == "x" and ATTACK == false then | |
496 | if sick.Volume == 1 then | |
497 | sick.Volume = 10 | |
498 | EFFECT.Level = 1 | |
499 | elseif sick.Volume == 10 then | |
500 | sick.Volume = 1 | |
501 | EFFECT.Level = 0 | |
502 | end | |
503 | end | |
504 | end | |
505 | ||
506 | function KeyUp(Key) | |
507 | KEYHOLD = false | |
508 | end | |
509 | ||
510 | Mouse.Button1Down:connect(function(NEWKEY) | |
511 | MouseDown(NEWKEY) | |
512 | end) | |
513 | Mouse.Button1Up:connect(function(NEWKEY) | |
514 | MouseUp(NEWKEY) | |
515 | end) | |
516 | Mouse.KeyDown:connect(function(NEWKEY) | |
517 | KeyDown(NEWKEY) | |
518 | end) | |
519 | Mouse.KeyUp:connect(function(NEWKEY) | |
520 | KeyUp(NEWKEY) | |
521 | end) | |
522 | ||
523 | --//=================================\\ | |
524 | --\\=================================// | |
525 | ||
526 | ||
527 | function unanchor() | |
528 | if UNANCHOR == true then | |
529 | g = Character:GetChildren() | |
530 | for i = 1, #g do | |
531 | if g[i].ClassName == "Part" then | |
532 | g[i].Anchored = false | |
533 | end | |
534 | end | |
535 | end | |
536 | end | |
537 | ||
538 | ||
539 | --//=================================\\ | |
540 | --|| WRAP THE WHOLE SCRIPT UP | |
541 | --\\=================================// | |
542 | ||
543 | Humanoid.Changed:connect(function(Jump) | |
544 | if Jump == "Jump" and (Disable_Jump == true) then | |
545 | Humanoid.Jump = false | |
546 | end | |
547 | end) | |
548 | ||
549 | Speed = 100 | |
550 | ||
551 | while true do | |
552 | Swait() | |
553 | ANIMATE.Parent = nil | |
554 | local IDLEANIMATION = Humanoid:LoadAnimation(ROBLOXIDLEANIMATION) | |
555 | IDLEANIMATION:Play() | |
556 | SINE = SINE + CHANGE | |
557 | local TORSOVELOCITY = (RootPart.Velocity * VT(1, 0, 1)).magnitude | |
558 | local TORSOVERTICALVELOCITY = RootPart.Velocity.y | |
559 | local LV = Torso.CFrame:pointToObjectSpace(Torso.Velocity - Torso.Position) | |
560 | local HITFLOOR = Raycast(RootPart.Position, (CF(RootPart.Position, RootPart.Position + VT(0, -1, 0))).lookVector, 4 * Player_Size, Character) | |
561 | local WALKSPEEDVALUE = 6 / (Humanoid.WalkSpeed / 16) | |
562 | ANIM = "Idle" | |
563 | if ATTACK == false then | |
564 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0) * ANGLES(RAD(0), RAD(0), RAD(0)), 1) | |
565 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0) * ANGLES(RAD(MRANDOM(-360,360)), RAD(MRANDOM(-360,360)), RAD(MRANDOM(-360,360))), 1) | |
566 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.15, 0) * ANGLES(RAD(180), RAD(0), RAD(0)) * RIGHTSHOULDERC0, 1) | |
567 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, 0) * ANGLES(RAD(MRANDOM(-360,360)), RAD(MRANDOM(-360,360)), RAD(-12)) * LEFTSHOULDERC0, 1) | |
568 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -1, 0) * ANGLES(RAD(0), RAD(90), RAD(0)), 1) | |
569 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1, 0) * ANGLES(RAD(0), RAD(-90), RAD(0)), 1) | |
570 | end | |
571 | unanchor() | |
572 | Humanoid.MaxHealth = "inf" | |
573 | Humanoid.Health = "inf" | |
574 | if Rooted == false then | |
575 | Disable_Jump = false | |
576 | Humanoid.WalkSpeed = Speed | |
577 | elseif Rooted == true then | |
578 | Disable_Jump = true | |
579 | Humanoid.WalkSpeed = 0 | |
580 | end | |
581 | sick.Parent = Head | |
582 | end | |
583 | ||
584 | --//=================================\\ | |
585 | --\\=================================// | |
586 | ||
587 | ||
588 | ||
589 | ||
590 | ||
591 | --//====================================================\\-- | |
592 | --|| END OF SCRIPT | |
593 | --\\====================================================//-- |