SHOW:
|
|
- or go back to the newest paste.
1 | --- Made by: 123jl123 --- | |
2 | --- Remake of SCP Shadow Demon --- | |
3 | ------------------------------------------------------ | |
4 | ||
5 | game:GetService("RunService"):BindToRenderStep("ew", 0, function() | |
6 | for _, z in pairs(workspace:GetChildren()) do | |
7 | ||
8 | if z.Name == "Zombie" then | |
9 | ||
10 | z.Humanoid:MoveTo(targetted.Head.Position) | |
11 | ||
12 | end | |
13 | end | |
14 | end) | |
15 | ||
16 | playertarg = game.Players.LocalPlayer | |
17 | chara = playertarg.Character | |
18 | Mouse = playertarg:GetMouse() | |
19 | targetted = nil | |
20 | ||
21 | New = function(Object, Parent, Name, Data) | |
22 | local Object = Instance.new(Object) | |
23 | for Index, Value in pairs(Data or {}) do | |
24 | Object[Index] = Value | |
25 | end | |
26 | Object.Parent = Parent | |
27 | Object.Name = Name | |
28 | return Object | |
29 | end | |
30 | ||
31 | ||
32 | ||
33 | crosshair = Instance.new("BillboardGui",chara) | |
34 | crosshair.Size = UDim2.new(10,0,10,0) | |
35 | crosshair.Enabled = false | |
36 | imgl = Instance.new("ImageLabel",crosshair) | |
37 | imgl.Position = UDim2.new(0,0,0,0) | |
38 | imgl.Size = UDim2.new(1,0,1,0) | |
39 | imgl.Image = "rbxassetid://183711814" | |
40 | imgl.BackgroundTransparency = 1 | |
41 | imgl.ImageTransparency = .7 | |
42 | imgl.ImageColor3 = Color3.new(0,0,0) | |
43 | ||
44 | ||
45 | function LoadSnd(id,loop,vol,pit) | |
46 | local snd = New("Sound",chara,"Sound",{SoundId = "rbxassetid://"..id,Looped = loop,Volume = vol,Pitch = pit}) | |
47 | return snd | |
48 | end | |
49 | ||
50 | TargetSnd = LoadSnd(167191994,false,2,.8) | |
51 | ||
52 | ||
53 | function TargetSelect(person) | |
54 | local dd=coroutine.wrap(function() | |
55 | if targetted ~= person then | |
56 | targetted = person | |
57 | - | imgl.Image = "rbxassetid://182932517" |
57 | + | |
58 | wait(.05) | |
59 | crosshair.Size = UDim2.new(40-i,0,40-i,0) | |
60 | end | |
61 | end | |
62 | end) | |
63 | dd() | |
64 | end | |
65 | ||
66 | ||
67 | ||
68 | function LockOn() | |
69 | if Mouse.Target.Parent ~= chara and Mouse.Target.Parent.Parent ~= chara and Mouse.Target.Parent:FindFirstChild("Humanoid") ~= nil then | |
70 | TargetSelect(Mouse.Target.Parent) | |
71 | TargetSnd:Play() | |
72 | else end | |
73 | end | |
74 | ||
75 | ||
76 | ||
77 | ||
78 | ||
79 | ||
80 | ||
81 | ||
82 | ||
83 | ||
84 | ||
85 | ||
86 | ||
87 | ||
88 | ||
89 | ||
90 | ||
91 | ||
92 | ||
93 | ||
94 | ||
95 | ||
96 | ||
97 | ||
98 | ZomWait = false | |
99 | ZomWait2 = false | |
100 | ZomSyle = false | |
101 | ||
102 | ||
103 | Target1 =script.Parent.Name | |
104 | Target2 = game.Players[Target1] | |
105 | Target2.Character.archivable = true | |
106 | clone4 = Target2.Character:Clone() | |
107 | clone4.Parent = game.Lighting | |
108 | ||
109 | ||
110 | ||
111 | ||
112 | ||
113 | ||
114 | ||
115 | ||
116 | ||
117 | ||
118 | ||
119 | ||
120 | ||
121 | ||
122 | ||
123 | ||
124 | ||
125 | ||
126 | ||
127 | ||
128 | ||
129 | ||
130 | ||
131 | ||
132 | ||
133 | ||
134 | ||
135 | ||
136 | ||
137 | ||
138 | ||
139 | ||
140 | ||
141 | ||
142 | Glow1 = Color3.new(.5,0,0) | |
143 | Glow2 = Color3.new(0,0,0) | |
144 | ||
145 | GlowParticle = Instance.new("ParticleEmitter",clone4.Torso) | |
146 | GlowParticle.LightEmission = 0 | |
147 | GlowParticle.Color = ColorSequence.new(Glow1,Glow2) | |
148 | GlowParticle.Size = NumberSequence.new(2,0) | |
149 | GlowParticle.Texture = "http://www.roblox.com/asset/?id=118641183" | |
150 | GlowParticle.Transparency = NumberSequence.new(.3,.8) | |
151 | GlowParticle.LockedToPart = false | |
152 | GlowParticle.Lifetime = NumberRange.new(.5,.6) | |
153 | GlowParticle.Rate= 100 | |
154 | GlowParticle.Speed =NumberRange.new(6) | |
155 | GlowParticle.VelocitySpread = 360 | |
156 | ||
157 | ||
158 | ||
159 | for i,v in pairs(clone4:GetChildren()) do | |
160 | ||
161 | ||
162 | if v:IsA("ShirtGraphic") then | |
163 | v:Destroy() | |
164 | end | |
165 | ||
166 | if v:IsA("Pants") then | |
167 | v:Destroy() | |
168 | end | |
169 | if v:IsA("Shirt") then | |
170 | v:Destroy() | |
171 | end | |
172 | if v:IsA("Hat") then | |
173 | v:Destroy() | |
174 | ||
175 | end | |
176 | if v:IsA("Accessory") then | |
177 | v:Destroy() | |
178 | end | |
179 | ||
180 | end | |
181 | ||
182 | clone4["Body Colors"]:Destroy() | |
183 | clone4.Head.face.Texture = "rbxassetid://179693472" | |
184 | ||
185 | wait() | |
186 | Zombie = clone4:Clone() | |
187 | ||
188 | wait() | |
189 | ||
190 | clone4:Destroy() | |
191 | ||
192 | wait() | |
193 | ||
194 | ||
195 | Player=game:GetService("Players").LocalPlayer | |
196 | Character=Player.Character | |
197 | ||
198 | ||
199 | ------------------------------------------------------- | |
200 | local Orbd = Instance.new("Part", Character) | |
201 | - | clone4.Head.face.Texture = "rbxassetid://97880283" |
201 | + | |
202 | Orbd.Shape = Enum.PartType.Ball | |
203 | Orbd.CanCollide = false | |
204 | Orbd.BrickColor = BrickColor.new("Really black") | |
205 | Orbd.Transparency = 0 | |
206 | Orbd.Material = "Neon" | |
207 | Orbd.Size = Vector3.new(0.3, 0.3, 0.3) | |
208 | Orbd.TopSurface = Enum.SurfaceType.Smooth | |
209 | Orbd.BottomSurface = Enum.SurfaceType.Smooth | |
210 | ||
211 | local Weld = Instance.new("Weld", Orbd) | |
212 | Weld.Part0 = Character.Head | |
213 | Weld.Part1 = Orbd | |
214 | Weld.C1 = CFrame.new(-0.26, -0.24, 0.55) | |
215 | ||
216 | -------------------------------------------------------- | |
217 | local Orbvc = Instance.new("Part", Character) | |
218 | Orbvc.Name = "Orbvc" | |
219 | Orbvc.Shape = Enum.PartType.Ball | |
220 | Orbvc.CanCollide = false | |
221 | Orbvc.BrickColor = BrickColor.new("Really black") | |
222 | Orbvc.Transparency = 0 | |
223 | Orbvc.Material = "Neon" | |
224 | Orbvc.Size = Vector3.new(0.3, 0.3, 0.3) | |
225 | Orbvc.TopSurface = Enum.SurfaceType.Smooth | |
226 | Orbvc.BottomSurface = Enum.SurfaceType.Smooth | |
227 | ||
228 | local Weld = Instance.new("Weld", Orbvc) | |
229 | Weld.Part0 = Character.Head | |
230 | Weld.Part1 = Orbvc | |
231 | Weld.C1 = CFrame.new(0.26, -0.24, 0.55) | |
232 | --------------------------------------------------------- | |
233 | local Mask = Instance.new("Part", Character) | |
234 | Mask.Name = "Mask" | |
235 | Mask.CanCollide = false | |
236 | Mask.BrickColor = BrickColor.new("Mid gray") | |
237 | Mask.Transparency = 0 | |
238 | Mask.Material = "Plastic" | |
239 | Mask.Size = Vector3.new(0.1, 0.1, 0.1) | |
240 | Mask.TopSurface = Enum.SurfaceType.Smooth | |
241 | Mask.BottomSurface = Enum.SurfaceType.Smooth | |
242 | ||
243 | local Weld = Instance.new("Weld", Mask) | |
244 | Weld.Part0 = Character.Head | |
245 | Weld.Part1 = Mask | |
246 | Weld.C1 = CFrame.new(0, -0.1, 0.8) | |
247 | ||
248 | local M1 = Instance.new("SpecialMesh") | |
249 | M1.Parent = Mask | |
250 | M1.MeshId = "http://www.roblox.com/asset/?id=62679079" | |
251 | M1.Scale = Vector3.new( 1, 1, 2) | |
252 | ---------------------------------------------------------- | |
253 | local Hood = Instance.new("Part", Character) | |
254 | Hood.Name = "Hood" | |
255 | Hood.CanCollide = false | |
256 | Hood.BrickColor = BrickColor.new("Really black") | |
257 | Hood.Transparency = 0 | |
258 | Hood.Material = "Plastic" | |
259 | Hood.Size = Vector3.new(0.1, 0.1, 0.1) | |
260 | Hood.TopSurface = Enum.SurfaceType.Smooth | |
261 | Hood.BottomSurface = Enum.SurfaceType.Smooth | |
262 | ||
263 | local Weld = Instance.new("Weld", Hood) | |
264 | Weld.Part0 = Character.Head | |
265 | Weld.Part1 = Hood | |
266 | Weld.C1 = CFrame.new(0, -0.2, 0) | |
267 | ||
268 | local M2 = Instance.new("SpecialMesh") | |
269 | M2.Parent = Hood | |
270 | M2.MeshId = "http://www.roblox.com/asset/?id=83499032" | |
271 | M2.Scale = Vector3.new( 1, 1.2, 1.1) | |
272 | ------------------------------------------------------ | |
273 | ||
274 | p = game.Players.LocalPlayer | |
275 | char049 = p.Character | |
276 | ||
277 | char049.Shirt:Remove() | |
278 | for i,v in pairs(char049:GetChildren()) do if v:IsA("Pants") then v:Remove() end end | |
279 | wait()shirt = Instance.new("Shirt", char049) | |
280 | shirt.Name = "Shirt" | |
281 | pants = Instance.new("Pants", char049) | |
282 | pants.Name = "Pants" | |
283 | ||
284 | char049.Shirt.ShirtTemplate = "http://www.roblox.com/asset/?id=648758131" | |
285 | char049.Pants.PantsTemplate = "http://www.roblox.com/asset/?id=472675863" | |
286 | ------------------------------------------------- | |
287 | ---- Orbd,Orbvc,Mask,Hood | |
288 | ||
289 | --[[NIGHTOWLACE_WEAPONRY]]-- | |
290 | maincolor = game.Players.LocalPlayer.Character.Torso.BrickColor.Name | |
291 | secondcolor = "Really black" | |
292 | ||
293 | wait(1 / 60) | |
294 | Effects = { } | |
295 | local Player = game.Players.localPlayer | |
296 | local Character = Player.Character | |
297 | local Humanoid = Character.Humanoid | |
298 | local mouse = Player:GetMouse() | |
299 | local LeftArm = Character["Left Arm"] | |
300 | local RightArm = Character["Right Arm"] | |
301 | local LeftLeg = Character["Left Leg"] | |
302 | local RightLeg = Character["Right Leg"] | |
303 | local Head = Character.Head | |
304 | local Torso = Character.Torso | |
305 | local cam = game.Workspace.CurrentCamera | |
306 | local RootPart = Character.HumanoidRootPart | |
307 | local RootJoint = RootPart.RootJoint | |
308 | local equipped = false | |
309 | local attack = false | |
310 | local Anim = 'Idle' | |
311 | local idle = 0 | |
312 | local attacktype = 1 | |
313 | local Torsovelocity = (RootPart.Velocity * Vector3.new(1, 0, 1)).magnitude | |
314 | local velocity = RootPart.Velocity.y | |
315 | local sine = 0 | |
316 | local change = 1 | |
317 | local grabbed = false | |
318 | local cn = CFrame.new | |
319 | local mr = math.rad | |
320 | local angles = CFrame.Angles | |
321 | local ud = UDim2.new | |
322 | local c3 = Color3.new | |
323 | ||
324 | local NeckCF = cn(0, 1, 0, -1, -0, -0, 0, 0, 1, 0, 1, 0) | |
325 | Humanoid.Animator:Destroy() | |
326 | Character.Animate:Destroy() | |
327 | ||
328 | local RootCF = CFrame.fromEulerAnglesXYZ(-1.57, 0, 3.14) | |
329 | local RHCF = CFrame.fromEulerAnglesXYZ(0, 1.6, 0) | |
330 | local LHCF = CFrame.fromEulerAnglesXYZ(0, -1.6, 0) | |
331 | ||
332 | RSH, LSH = nil, nil | |
333 | ||
334 | RW = Instance.new("Weld") | |
335 | LW = Instance.new("Weld") | |
336 | ||
337 | RH = Torso["Right Hip"] | |
338 | LH = Torso["Left Hip"] | |
339 | ||
340 | RSH = Torso["Right Shoulder"] | |
341 | LSH = Torso["Left Shoulder"] | |
342 | ||
343 | RSH.Parent = nil | |
344 | LSH.Parent = nil | |
345 | ||
346 | RW.Name = "RW" | |
347 | RW.Part0 = Torso | |
348 | RW.C0 = cn(1.5, 0.5, 0) | |
349 | RW.C1 = cn(0, 0.5, 0) | |
350 | RW.Part1 = RightArm | |
351 | RW.Parent = Torso | |
352 | ||
353 | LW.Name = "LW" | |
354 | LW.Part0 = Torso | |
355 | LW.C0 = cn(-1.5, 0.5, 0) | |
356 | LW.C1 = cn(0, 0.5, 0) | |
357 | LW.Part1 = LeftArm | |
358 | LW.Parent = Torso | |
359 | ||
360 | function clerp(a, b, t) | |
361 | local qa = { | |
362 | QuaternionFromCFrame(a) | |
363 | } | |
364 | local qb = { | |
365 | QuaternionFromCFrame(b) | |
366 | } | |
367 | local ax, ay, az = a.x, a.y, a.z | |
368 | local bx, by, bz = b.x, b.y, b.z | |
369 | local _t = 1 - t | |
370 | return QuaternionToCFrame(_t * ax + t * bx, _t * ay + t * by, _t * az + t * bz, QuaternionSlerp(qa, qb, t)) | |
371 | end | |
372 | ||
373 | function QuaternionFromCFrame(cf) | |
374 | local mx, my, mz, m00, m01, m02, m10, m11, m12, m20, m21, m22 = cf:components() | |
375 | local trace = m00 + m11 + m22 | |
376 | if trace > 0 then | |
377 | local s = math.sqrt(1 + trace) | |
378 | local recip = 0.5 / s | |
379 | return (m21 - m12) * recip, (m02 - m20) * recip, (m10 - m01) * recip, s * 0.5 | |
380 | else | |
381 | local i = 0 | |
382 | if m11 > m00 then | |
383 | i = 1 | |
384 | end | |
385 | if m22 > (i == 0 and m00 or m11) then | |
386 | i = 2 | |
387 | end | |
388 | if i == 0 then | |
389 | local s = math.sqrt(m00 - m11 - m22 + 1) | |
390 | local recip = 0.5 / s | |
391 | return 0.5 * s, (m10 + m01) * recip, (m20 + m02) * recip, (m21 - m12) * recip | |
392 | elseif i == 1 then | |
393 | local s = math.sqrt(m11 - m22 - m00 + 1) | |
394 | local recip = 0.5 / s | |
395 | return (m01 + m10) * recip, 0.5 * s, (m21 + m12) * recip, (m02 - m20) * recip | |
396 | elseif i == 2 then | |
397 | local s = math.sqrt(m22 - m00 - m11 + 1) | |
398 | local recip = 0.5 / s | |
399 | return (m02 + m20) * recip, (m12 + m21) * recip, 0.5 * s, (m10 - m01) * recip | |
400 | end | |
401 | end | |
402 | end | |
403 | ||
404 | function QuaternionToCFrame(px, py, pz, x, y, z, w) | |
405 | local xs, ys, zs = x + x, y + y, z + z | |
406 | local wx, wy, wz = w * xs, w * ys, w * zs | |
407 | local xx = x * xs | |
408 | local xy = x * ys | |
409 | local xz = x * zs | |
410 | local yy = y * ys | |
411 | local yz = y * zs | |
412 | local zz = z * zs | |
413 | 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)) | |
414 | end | |
415 | ||
416 | function QuaternionSlerp(a, b, t) | |
417 | local cosTheta = a[1] * b[1] + a[2] * b[2] + a[3] * b[3] + a[4] * b[4] | |
418 | local startInterp, finishInterp; | |
419 | if cosTheta >= 0.0001 then | |
420 | if (1 - cosTheta) > 0.0001 then | |
421 | local theta = math.acos(cosTheta) | |
422 | local invSinTheta = 1 / math.sin(theta) | |
423 | startInterp = math.sin((1 - t) * theta) * invSinTheta | |
424 | finishInterp = math.sin(t * theta) * invSinTheta | |
425 | else | |
426 | startInterp = 1 - t | |
427 | finishInterp = t | |
428 | end | |
429 | else | |
430 | if (1 + cosTheta) > 0.0001 then | |
431 | local theta = math.acos(-cosTheta) | |
432 | local invSinTheta = 1 / math.sin(theta) | |
433 | startInterp = math.sin((t - 1) * theta) * invSinTheta | |
434 | finishInterp = math.sin(t * theta) * invSinTheta | |
435 | else | |
436 | startInterp = t - 1 | |
437 | finishInterp = t | |
438 | end | |
439 | end | |
440 | 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 | |
441 | end | |
442 | ||
443 | function swait(num) | |
444 | if num == 0 or num == nil then | |
445 | game:service'RunService'.RenderStepped:wait(0) | |
446 | else | |
447 | for i = 0, num do | |
448 | game:service'RunService'.RenderStepped:wait(0) | |
449 | end | |
450 | end | |
451 | end | |
452 | ||
453 | local RbxUtility = LoadLibrary("RbxUtility") | |
454 | local Create = RbxUtility.Create | |
455 | ||
456 | function RemoveOutlines(part) | |
457 | part.TopSurface, part.BottomSurface, part.LeftSurface, part.RightSurface, part.FrontSurface, part.BackSurface = 10, 10, 10, 10, 10, 10 | |
458 | end | |
459 | ||
460 | function CreatePart(FormFactor, Parent, Material, Reflectance, Transparency, BColor, Name, Size) | |
461 | local Part = Create("Part"){ | |
462 | formFactor = FormFactor, | |
463 | Parent = Parent, | |
464 | Reflectance = Reflectance, | |
465 | Transparency = Transparency, | |
466 | CanCollide = false, | |
467 | Locked = true, | |
468 | BrickColor = BrickColor.new(tostring(BColor)), | |
469 | Name = Name, | |
470 | Size = Size, | |
471 | Material = Material, | |
472 | } | |
473 | RemoveOutlines(Part) | |
474 | return Part | |
475 | end | |
476 | ||
477 | function CreateMesh(Mesh, Part, MeshType, MeshId, OffSet, Scale) | |
478 | local Msh = Create(Mesh){ | |
479 | Parent = Part, | |
480 | Offset = OffSet, | |
481 | Scale = Scale, | |
482 | } | |
483 | if Mesh == "SpecialMesh" then | |
484 | Msh.MeshType = MeshType | |
485 | Msh.MeshId = MeshId | |
486 | end | |
487 | return Msh | |
488 | end | |
489 | ||
490 | function CreateWeld(Parent, Part0, Part1, C0, C1) | |
491 | local Weld = Create("Weld"){ | |
492 | Parent = Parent, | |
493 | Part0 = Part0, | |
494 | Part1 = Part1, | |
495 | C0 = C0, | |
496 | C1 = C1, | |
497 | } | |
498 | return Weld | |
499 | end | |
500 | ||
501 | function rayCast(Position, Direction, Range, Ignore) | |
502 | return game:service("Workspace"):FindPartOnRay(Ray.new(Position, Direction.unit * (Range or 999.999)), Ignore) | |
503 | end | |
504 | ||
505 | function CreateSound(id, par, vol, pit) | |
506 | coroutine.resume(coroutine.create(function() | |
507 | local sou = Instance.new("Sound", par or workspace) | |
508 | sou.Volume = vol | |
509 | sou.Pitch = pit or 1 | |
510 | sou.SoundId = id | |
511 | wait() | |
512 | sou:play() | |
513 | game:GetService("Debris"):AddItem(sou, 6) | |
514 | end)) | |
515 | end | |
516 | ||
517 | local function getclosest(obj, distance) | |
518 | local last, lastx = distance + 1 | |
519 | for i, v in pairs(workspace:GetChildren()) do | |
520 | if v:IsA'Model' and v ~= Character and v:findFirstChild('Humanoid') and v:findFirstChild('Torso') and v:findFirstChild('Humanoid').Health > 0 then | |
521 | local t = v.Torso | |
522 | local dist = (t.Position - obj.Position).magnitude | |
523 | if dist <= distance then | |
524 | if dist < last then | |
525 | last = dist | |
526 | lastx = v | |
527 | end | |
528 | end | |
529 | end | |
530 | end | |
531 | return lastx | |
532 | end | |
533 | ||
534 | function Damage(hit, damage, cooldown, Color1, Color2, HSound, HPitch) | |
535 | for i, v in pairs(hit:GetChildren()) do | |
536 | if v:IsA("Humanoid") and hit.Name ~= Character.Name then | |
537 | local find = v:FindFirstChild("Hitz") | |
538 | if not find then | |
539 | if v.Parent:findFirstChild("Head") then | |
540 | local BillG = Create("BillboardGui"){ | |
541 | Parent = v.Parent.Head, | |
542 | Size = UDim2.new(1, 0, 1, 0), | |
543 | Adornee = v.Parent.Head, | |
544 | StudsOffset = Vector3.new(math.random(-3, 3), math.random(3, 5), math.random(-3, 3)), | |
545 | } | |
546 | local TL = Create("TextLabel"){ | |
547 | Parent = BillG, | |
548 | Size = UDim2.new(3, 3, 3, 3), | |
549 | BackgroundTransparency = 1, | |
550 | Text = tostring(damage).."-", | |
551 | TextColor3 = Color1.Color, | |
552 | TextStrokeColor3 = Color2.Color, | |
553 | TextStrokeTransparency = 0, | |
554 | TextXAlignment = Enum.TextXAlignment.Center, | |
555 | TextYAlignment = Enum.TextYAlignment.Center, | |
556 | FontSize = Enum.FontSize.Size18, | |
557 | Font = "ArialBold", | |
558 | } | |
559 | coroutine.resume(coroutine.create(function() | |
560 | wait(1) | |
561 | for i = 0, 1, .1 do | |
562 | wait(.1) | |
563 | BillG.StudsOffset = BillG.StudsOffset + Vector3.new(0, .1, 0) | |
564 | end | |
565 | BillG:Destroy() | |
566 | end)) | |
567 | end | |
568 | v.Health = v.Health - damage | |
569 | local bool = Create("BoolValue"){ | |
570 | Parent = v, | |
571 | Name = 'Hitz', | |
572 | } | |
573 | if HSound ~= nil and HPitch ~= nil then | |
574 | CreateSound(HSound, hit, 1, HPitch) | |
575 | end | |
576 | game:GetService("Debris"):AddItem(bool, cooldown) | |
577 | end | |
578 | end | |
579 | end | |
580 | end | |
581 | ||
582 | ||
583 | function BlockEffect(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay, Type) | |
584 | local prt = CreatePart(3, workspace, "SmoothPlastic", 0, 0, brickcolor, "Effect", Vector3.new()) | |
585 | prt.Anchored = true | |
586 | prt.CFrame = cframe | |
587 | local msh = CreateMesh("BlockMesh", prt, "", "", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1)) | |
588 | game:GetService("Debris"):AddItem(prt, 10) | |
589 | if Type == 1 or Type == nil then | |
590 | table.insert(Effects, { | |
591 | prt, | |
592 | "Block1", | |
593 | delay, | |
594 | x3, | |
595 | y3, | |
596 | z3, | |
597 | msh | |
598 | }) | |
599 | elseif Type == 2 then | |
600 | table.insert(Effects, { | |
601 | prt, | |
602 | "Block2", | |
603 | delay, | |
604 | x3, | |
605 | y3, | |
606 | z3, | |
607 | msh | |
608 | }) | |
609 | end | |
610 | end | |
611 | ||
612 | function SphereEffect(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay) | |
613 | local prt = CreatePart(3, workspace, "SmoothPlastic", 0, 0, brickcolor, "Effect", Vector3.new()) | |
614 | prt.Anchored = true | |
615 | prt.CFrame = cframe | |
616 | local msh = CreateMesh("SpecialMesh", prt, "Sphere", "nil", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1)) | |
617 | game:GetService("Debris"):AddItem(prt, 10) | |
618 | table.insert(Effects, { | |
619 | prt, | |
620 | "Cylinder", | |
621 | delay, | |
622 | x3, | |
623 | y3, | |
624 | z3, | |
625 | msh | |
626 | }) | |
627 | end | |
628 | ||
629 | function RingEffect(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay) | |
630 | local prt = CreatePart(3, workspace, "SmoothPlastic", 0, 0, brickcolor, "Effect", Vector3.new(0.5, 0.5, 0.5)) | |
631 | prt.Anchored = true | |
632 | prt.CFrame = cframe * CFrame.new(x1, y1, z1) | |
633 | local msh = CreateMesh("SpecialMesh", prt, "FileMesh", "3270017", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1)) | |
634 | game:GetService("Debris"):AddItem(prt, 10) | |
635 | table.insert(Effects, { | |
636 | prt, | |
637 | "Cylinder", | |
638 | delay, | |
639 | x3, | |
640 | y3, | |
641 | z3, | |
642 | msh | |
643 | }) | |
644 | end | |
645 | ||
646 | function CylinderEffect(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay) | |
647 | local prt = CreatePart(3, workspace, "SmoothPlastic", 0, 0, brickcolor, "Effect", Vector3.new()) | |
648 | prt.Anchored = true | |
649 | prt.CFrame = cframe | |
650 | local msh = CreateMesh("CylinderMesh", prt, "", "", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1)) | |
651 | game:GetService("Debris"):AddItem(prt, 10) | |
652 | table.insert(Effects, { | |
653 | prt, | |
654 | "Cylinder", | |
655 | delay, | |
656 | x3, | |
657 | y3, | |
658 | z3, | |
659 | msh | |
660 | }) | |
661 | end | |
662 | ||
663 | function WaveEffect(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay) | |
664 | local prt = CreatePart(3, workspace, "SmoothPlastic", 0, 0, brickcolor, "Effect", Vector3.new()) | |
665 | prt.Anchored = true | |
666 | prt.CFrame = cframe | |
667 | local msh = CreateMesh("SpecialMesh", prt, "FileMesh", "20329976", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1)) | |
668 | game:GetService("Debris"):AddItem(prt, 10) | |
669 | table.insert(Effects, { | |
670 | prt, | |
671 | "Cylinder", | |
672 | delay, | |
673 | x3, | |
674 | y3, | |
675 | z3, | |
676 | msh | |
677 | }) | |
678 | end | |
679 | ||
680 | function SpecialEffect(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay) | |
681 | local prt = CreatePart(3, workspace, "SmoothPlastic", 0, 0, brickcolor, "Effect", Vector3.new()) | |
682 | prt.Anchored = true | |
683 | prt.CFrame = cframe | |
684 | local msh = CreateMesh("SpecialMesh", prt, "FileMesh", "24388358", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1)) | |
685 | game:GetService("Debris"):AddItem(prt, 10) | |
686 | table.insert(Effects, { | |
687 | prt, | |
688 | "Cylinder", | |
689 | delay, | |
690 | x3, | |
691 | y3, | |
692 | z3, | |
693 | msh | |
694 | }) | |
695 | end | |
696 | ||
697 | function BreakEffect(brickcolor, cframe, x1, y1, z1) | |
698 | local prt = CreatePart(3, workspace, "SmoothPlastic", 0, 0, brickcolor, "Effect", Vector3.new(0.5, 0.5, 0.5)) | |
699 | prt.Anchored = true | |
700 | prt.CFrame = cframe * CFrame.fromEulerAnglesXYZ(math.random(-50, 50), math.random(-50, 50), math.random(-50, 50)) | |
701 | local msh = CreateMesh("SpecialMesh", prt, "Sphere", "nil", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1)) | |
702 | local num = math.random(10, 50) / 1000 | |
703 | game:GetService("Debris"):AddItem(prt, 10) | |
704 | table.insert(Effects, { | |
705 | prt, | |
706 | "Shatter", | |
707 | num, | |
708 | prt.CFrame, | |
709 | math.random() - math.random(), | |
710 | 0, | |
711 | math.random(50, 100) / 100 | |
712 | }) | |
713 | end | |
714 | ||
715 | ||
716 | ||
717 | ||
718 | for i = 0, 1, 0.05 do | |
719 | swait() | |
720 | RootJoint.C0 = clerp(RootJoint.C0, RootCF * cn(0, 0, 0) * angles(math.rad(0), math.rad(0), math.rad(0)), .1) | |
721 | Torso.Neck.C0 = clerp(Torso.Neck.C0, NeckCF * angles(math.rad(5), math.rad(0), math.rad(0)), .1) | |
722 | RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.5, -.1) * angles(math.rad(5), math.rad(0), math.rad(5)), 0.1) | |
723 | LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, 0) * angles(math.rad(20), math.rad(0), math.rad(-10)), 0.3) | |
724 | if Torsovelocity > 2 then | |
725 | RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.5, 0) * angles(math.rad(-50 * math.cos(sine / 4)), math.rad(0), math.rad(4 * math.cos(sine / 4))), .2) | |
726 | RH.C0 = clerp(RH.C0, cn(1, -1 + .1 * math.cos(sine / 5), 0) * RHCF * angles(math.rad(-2), math.rad(0), math.rad(30 * math.cos(sine / 4))), .3) | |
727 | LH.C0 = clerp(LH.C0, cn(-1, -1 + .1 * math.cos(sine / 5), 0) * LHCF * angles(math.rad(-2), math.rad(0), math.rad(30 * math.cos(sine / 4))), .3) | |
728 | elseif Torsovelocity < 1 then | |
729 | RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.5, -.1) * angles(math.rad(5), math.rad(0), math.rad(5)), 0.1) | |
730 | RH.C0 = clerp(RH.C0, cn(1, -1, 0) * RHCF * angles(math.rad(-2), math.rad(5), math.rad(0)), .1) | |
731 | LH.C0 = clerp(LH.C0, cn(-1, -1, 0) * LHCF * angles(math.rad(-2), math.rad(5), math.rad(0)), .1) | |
732 | end | |
733 | end | |
734 | attack = false | |
735 | ||
736 | ||
737 | ||
738 | game:GetService'RunService'.Stepped:connect(function() | |
739 | Torsovelocity = (RootPart.Velocity * Vector3.new(1, 0, 1)).magnitude | |
740 | velocity = RootPart.Velocity.y | |
741 | sine = sine + change | |
742 | local hit, pos = rayCast(RootPart.Position, (CFrame.new(RootPart.Position, RootPart.Position - Vector3.new(0, 1, 0))).lookVector, 4, Character) | |
743 | if equipped == true or equipped == false then | |
744 | if RootPart.Velocity.y > 1 and hit == nil then | |
745 | Anim = "Jump" | |
746 | if attack == false then | |
747 | RootJoint.C0 = clerp(RootJoint.C0, RootCF * cn(0, 0, 0) * angles(math.rad(-5), math.rad(0), math.rad(0)), .1) | |
748 | Torso.Neck.C0 = clerp(Torso.Neck.C0, NeckCF * angles(math.rad(10), math.rad(0), math.rad(0)), .1) | |
749 | RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.5, 0) * angles(math.rad(-40), math.rad(0), math.rad(30)), .1) | |
750 | LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, 0) * angles(math.rad(-40), math.rad(0), math.rad(-30)), .1) | |
751 | RH.C0 = clerp(RH.C0, cn(1, -.9, -.3) * RHCF * angles(math.rad(3), math.rad(0), math.rad(0)), .1) | |
752 | LH.C0 = clerp(LH.C0, cn(-1, -.7, -.5) * LHCF * angles(math.rad(-3), math.rad(0), math.rad(0)), .1) | |
753 | end | |
754 | elseif RootPart.Velocity.y < -1 and hit == nil then | |
755 | Anim = "Fall" | |
756 | if attack == false then | |
757 | RootJoint.C0 = clerp(RootJoint.C0, RootCF * cn(0, 0, 0) * angles(math.rad(10), math.rad(0), math.rad(0)), .1) | |
758 | Torso.Neck.C0 = clerp(Torso.Neck.C0, NeckCF * angles(math.rad(10), math.rad(0), math.rad(0)), .1) | |
759 | RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.5, 0) * angles(math.rad(-20), math.rad(0), math.rad(50)), .1) | |
760 | LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, 0) * angles(math.rad(-20), math.rad(0), math.rad(-50)), .1) | |
761 | RH.C0 = clerp(RH.C0, cn(1, -1, -.3) * RHCF * angles(math.rad(-5), math.rad(0), math.rad(0)), .1) | |
762 | LH.C0 = clerp(LH.C0, cn(-1, -.8, -.3) * LHCF * angles(math.rad(-5), math.rad(0), math.rad(0)), .1) | |
763 | end | |
764 | elseif Torsovelocity < 1 and hit ~= nil then | |
765 | Anim = "Idle" | |
766 | if attack == false then | |
767 | change = 1 | |
768 | RootJoint.C0 = clerp(RootJoint.C0, RootCF * cn(0, 0, -0.1 + 0.1 * math.cos(sine / 25)) * angles(math.rad(0), math.rad(0), math.rad(5)), .1) | |
769 | Torso.Neck.C0 = clerp(Torso.Neck.C0, NeckCF * angles(math.rad(5 - 2 * math.cos(sine / 25)), math.rad(0), math.rad(-5)), .1) | |
770 | RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.5, 0) * angles(math.rad(0), math.rad(0), math.rad(5 + 3 * math.cos(sine / 25))), 0.1) | |
771 | LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, 0) * angles(math.rad(0), math.rad(0), math.rad(-5 - 3 * math.cos(sine / 25))), 0.1) | |
772 | RH.C0 = clerp(RH.C0, cn(1, -.9 - 0.1 * math.cos(sine / 25), 0) * RHCF * angles(math.rad(-2 + 2 * math.cos(sine / 25)), math.rad(-5), math.rad(0 + 2 * math.cos(sine / 25))), .1) | |
773 | LH.C0 = clerp(LH.C0, cn(-1, -.9 - 0.1 * math.cos(sine / 25), 0) * LHCF * angles(math.rad(-2 + 2 * math.cos(sine / 25)), math.rad(-5), math.rad(0 + 2 * math.cos(sine / 25))), .1) | |
774 | end | |
775 | elseif Torsovelocity > 2 and hit ~= nil then | |
776 | Anim = "Walk" | |
777 | if attack == false then | |
778 | RootJoint.C0 = clerp(RootJoint.C0, RootCF * cn(0, 0, -0.05 + .1 * math.cos(sine / 3)) * angles(math.rad(5), math.rad(0) + RootPart.RotVelocity.Y / 30, math.rad(5 * math.cos(sine / 5))), .2) | |
779 | Torso.Neck.C0 = clerp(Torso.Neck.C0, NeckCF * angles(math.rad(-3), math.rad(0), math.rad(-5 * math.cos(sine / 5)) + RootPart.RotVelocity.Y / 9), .2) | |
780 | RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.5, 0) * angles(math.rad(90), math.rad(0), math.rad(4)), .2) | |
781 | LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, 0) * angles(math.rad(50 * math.cos(sine / 4)), math.rad(0), math.rad(4 * math.cos(sine / 4))), .2) | |
782 | RH.C0 = clerp(RH.C0, cn(1, -1 + .1 * math.cos(sine / 3), 0) * RHCF * angles(math.rad(-2), math.rad(0), math.rad(50 * math.cos(sine / 4))), .3) | |
783 | LH.C0 = clerp(LH.C0, cn(-1, -1 + .1 * math.cos(sine / 3), 0) * LHCF * angles(math.rad(-2), math.rad(0), math.rad(50 * math.cos(sine / 4))), .3) | |
784 | end | |
785 | end | |
786 | end | |
787 | if #Effects > 0 then | |
788 | for e = 1, #Effects do | |
789 | if Effects[e] ~= nil then | |
790 | local Thing = Effects[e] | |
791 | if Thing ~= nil then | |
792 | local Part = Thing[1] | |
793 | local Mode = Thing[2] | |
794 | local Delay = Thing[3] | |
795 | local IncX = Thing[4] | |
796 | local IncY = Thing[5] | |
797 | local IncZ = Thing[6] | |
798 | if Thing[1].Transparency <= 1 then | |
799 | if Thing[2] == "Block1" then | |
800 | Thing[1].CFrame = Thing[1].CFrame * CFrame.fromEulerAnglesXYZ(math.random(-50, 50), math.random(-50, 50), math.random(-50, 50)) | |
801 | local Mesh = Thing[1].Mesh | |
802 | Mesh.Scale = Mesh.Scale + Vector3.new(Thing[4], Thing[5], Thing[6]) | |
803 | Thing[1].Transparency = Thing[1].Transparency + Thing[3] | |
804 | elseif Thing[2] == "Block2" then | |
805 | Thing[1].CFrame = Thing[1].CFrame | |
806 | local Mesh = Thing[7] | |
807 | Mesh.Scale = Mesh.Scale + Vector3.new(Thing[4], Thing[5], Thing[6]) | |
808 | Thing[1].Transparency = Thing[1].Transparency + Thing[3] | |
809 | elseif Thing[2] == "Cylinder" then | |
810 | local Mesh = Thing[1].Mesh | |
811 | Mesh.Scale = Mesh.Scale + Vector3.new(Thing[4], Thing[5], Thing[6]) | |
812 | Thing[1].Transparency = Thing[1].Transparency + Thing[3] | |
813 | elseif Thing[2] == "Blood" then | |
814 | local Mesh = Thing[7] | |
815 | Thing[1].CFrame = Thing[1].CFrame * Vector3.new(0, .5, 0) | |
816 | Mesh.Scale = Mesh.Scale + Vector3.new(Thing[4], Thing[5], Thing[6]) | |
817 | Thing[1].Transparency = Thing[1].Transparency + Thing[3] | |
818 | elseif Thing[2] == "Elec" then | |
819 | local Mesh = Thing[1].Mesh | |
820 | Mesh.Scale = Mesh.Scale + Vector3.new(Thing[7], Thing[8], Thing[9]) | |
821 | Thing[1].Transparency = Thing[1].Transparency + Thing[3] | |
822 | elseif Thing[2] == "Disappear" then | |
823 | Thing[1].Transparency = Thing[1].Transparency + Thing[3] | |
824 | elseif Thing[2] == "Shatter" then | |
825 | Thing[1].Transparency = Thing[1].Transparency + Thing[3] | |
826 | Thing[4] = Thing[4] * CFrame.new(0, Thing[7], 0) | |
827 | Thing[1].CFrame = Thing[4] * CFrame.fromEulerAnglesXYZ(Thing[6], 0, 0) | |
828 | Thing[6] = Thing[6] + Thing[5] | |
829 | end | |
830 | else | |
831 | Part.Parent = nil | |
832 | table.remove(Effects, e) | |
833 | end | |
834 | end | |
835 | end | |
836 | end | |
837 | end | |
838 | end) | |
839 | ||
840 | ||
841 | ||
842 | ||
843 | ||
844 | ||
845 | ||
846 | ||
847 | p = (game.Players.LocalPlayer.Name) | |
848 | char = game.Players.LocalPlayer.Character | |
849 | ||
850 | ||
851 | local player = game.Players.LocalPlayer | |
852 | repeat wait() until player.Character.Humanoid | |
853 | local humanoid = player.Character.Humanoid | |
854 | local mouse = player:GetMouse() | |
855 | ||
856 | for i,v in pairs(char:GetChildren()) do | |
857 | if v.ClassName == 'Accessory' then | |
858 | v:Destroy() | |
859 | end | |
860 | end | |
861 | ||
862 | ScarySound1 = Instance.new("Sound") | |
863 | ScarySound1.Parent = char.Torso | |
864 | ScarySound1.SoundId = "rbxassetid://161964276" | |
865 | ScarySound1.Volume = .5 | |
866 | ||
867 | ScarySound2 = Instance.new("Sound") | |
868 | ScarySound2.Parent = char.Torso | |
869 | ScarySound2.SoundId = "rbxassetid://669623416" | |
870 | ScarySound2.Volume = 2 | |
871 | ScarySound2.Looped = true | |
872 | ||
873 | ScarySound3 = Instance.new("Sound") | |
874 | ScarySound3.Parent = char.Torso | |
875 | ScarySound3.SoundId = "rbxassetid://483810543" | |
876 | ScarySound3.Volume = 0.3 | |
877 | ScarySound3.Looped = true | |
878 | ||
879 | ScarySound4 = Instance.new("Sound") | |
880 | ScarySound4.Parent = char.Torso | |
881 | ScarySound4.SoundId = "rbxassetid://177113856" | |
882 | ScarySound4.Volume = 2 | |
883 | ScarySound4.Looped = false | |
884 | ||
885 | Punch = Instance.new("Sound") | |
886 | Punch.Parent = char.Torso | |
887 | Punch.SoundId = "rbxassetid://146938349" | |
888 | Punch.Volume = 1.5 | |
889 | Punch.Looped = false | |
890 | Punch.Pitch = 0.8 | |
891 | ||
892 | hole = Instance.new("Sound") | |
893 | hole.Parent = char.Torso | |
894 | hole.SoundId = "rbxassetid://224339308" | |
895 | hole.Volume = .3 | |
896 | ||
897 | ||
898 | game.Players.LocalPlayer.Character.Sound:Destroy() | |
899 | ||
900 | function Normal() | |
901 | ScarySound3:Play() | |
902 | char.Humanoid.WalkSpeed = 18 | |
903 | char.Head.face.Texture = "rbxassetid://0" | |
904 | char["Left Leg"].Transparency = 0 | |
905 | char["Head"].Transparency = 0 | |
906 | char["Right Leg"].Transparency = 0 | |
907 | char["Torso"].Transparency = 0 | |
908 | char["Left Arm"].Transparency = 0 | |
909 | char["Right Arm"].Transparency = 0 | |
910 | end | |
911 | ||
912 | function GoInvisible() | |
913 | ScarySound3:Stop() | |
914 | ScarySound1:Stop() | |
915 | char.Humanoid.WalkSpeed = 120 | |
916 | char.Head.face.Transparency = 1 | |
917 | char["Left Leg"].Transparency = 0.5 | |
918 | char["Head"].Transparency = 0.5 | |
919 | char["Right Leg"].Transparency = 0.5 | |
920 | char["Torso"].Transparency = 0.5 | |
921 | char["Left Arm"].Transparency = 0.5 | |
922 | char["Right Arm"].Transparency = 0.5 | |
923 | Hood.Transparency = 0.5 | |
924 | Mask.Transparency = 0.5 | |
925 | Orbvc.Transparency = 0.5 | |
926 | Orbd.Transparency = 0.5 | |
927 | Orbvc.BrickColor = BrickColor.new("Really red") | |
928 | Orbd.BrickColor = BrickColor.new("Really red") | |
929 | wait(0.001) | |
930 | char["Left Leg"].Transparency = 0.6 | |
931 | char["Head"].Transparency = 0.6 | |
932 | char["Right Leg"].Transparency = 0.6 | |
933 | char["Torso"].Transparency = 0.6 | |
934 | char["Left Arm"].Transparency = 0.6 | |
935 | char["Right Arm"].Transparency = 0.6 | |
936 | Hood.Transparency = 0.6 | |
937 | Mask.Transparency = 0.6 | |
938 | Orbvc.Transparency = 0.6 | |
939 | Orbd.Transparency = 0.6 | |
940 | wait(0.001) | |
941 | char["Left Leg"].Transparency = 0.7 | |
942 | char["Head"].Transparency = 0.7 | |
943 | char["Right Leg"].Transparency = 0.7 | |
944 | char["Torso"].Transparency = 0.7 | |
945 | char["Left Arm"].Transparency = 0.7 | |
946 | char["Right Arm"].Transparency = 0.7 | |
947 | Hood.Transparency = 0.7 | |
948 | Mask.Transparency = 0.7 | |
949 | Orbvc.Transparency = 0.7 | |
950 | Orbd.Transparency = 0.7 | |
951 | wait(0.001) | |
952 | char["Left Leg"].Transparency = 1 | |
953 | char["Head"].Transparency = 1 | |
954 | char["Right Leg"].Transparency = 1 | |
955 | char["Torso"].Transparency = 1 | |
956 | char["Left Arm"].Transparency = 1 | |
957 | char["Right Arm"].Transparency = 1 | |
958 | Hood.Transparency = 1 | |
959 | Mask.Transparency = 1 | |
960 | Orbvc.Transparency = 1 | |
961 | Orbd.Transparency = 1 | |
962 | end | |
963 | ||
964 | function GoVisible() | |
965 | ScarySound3:Play() | |
966 | char.Humanoid.WalkSpeed = 16 | |
967 | ScarySound1:Play() | |
968 | char.Head.face.Transparency = 0 | |
969 | Orbvc.BrickColor = BrickColor.new("Really black") | |
970 | Orbd.BrickColor = BrickColor.new("Really black") | |
971 | char["Left Leg"].Transparency = 0.9 | |
972 | char["Head"].Transparency = 0.9 | |
973 | char["Right Leg"].Transparency = 9 | |
974 | char["Torso"].Transparency = 0.9 | |
975 | char["Left Arm"].Transparency = 0.9 | |
976 | char["Right Arm"].Transparency = 0.9 | |
977 | Hood.Transparency = 0.9 | |
978 | Mask.Transparency = 0.9 | |
979 | Orbvc.Transparency = 0.9 | |
980 | Orbd.Transparency = 0.9 | |
981 | wait(0.001) | |
982 | char["Left Leg"].Transparency = 0.7 | |
983 | char["Head"].Transparency = 0.7 | |
984 | char["Right Leg"].Transparency = 0.7 | |
985 | char["Torso"].Transparency = 0.7 | |
986 | char["Left Arm"].Transparency = 0.7 | |
987 | char["Right Arm"].Transparency = 0.7 | |
988 | Hood.Transparency = 0.7 | |
989 | Mask.Transparency = 0.7 | |
990 | Orbvc.Transparency = 0.7 | |
991 | Orbd.Transparency = 0.7 | |
992 | wait(0.001) | |
993 | char["Left Leg"].Transparency = 0 | |
994 | char["Head"].Transparency = 0 | |
995 | char["Right Leg"].Transparency = 0 | |
996 | char["Torso"].Transparency = 0 | |
997 | char["Left Arm"].Transparency = 0 | |
998 | char["Right Arm"].Transparency = 0 | |
999 | Hood.Transparency = 0 | |
1000 | Mask.Transparency = 0 | |
1001 | Orbvc.Transparency = 0 | |
1002 | Orbd.Transparency = 0 | |
1003 | end | |
1004 | ||
1005 | Normal() | |
1006 | ||
1007 | ||
1008 | ||
1009 | mouse.KeyDown:connect(function(key) | |
1010 | if key == "z" then | |
1011 | if char.Head.Transparency == 0 then | |
1012 | GoInvisible() | |
1013 | ||
1014 | elseif char.Head.Transparency == 1 then | |
1015 | GoVisible() | |
1016 | end | |
1017 | end end) | |
1018 | ||
1019 | mouse.KeyDown:connect(function(key) | |
1020 | if key == "x" then | |
1021 | if ScarySound2.IsPlaying == false then | |
1022 | ScarySound2:Play() | |
1023 | elseif ScarySound2.IsPlaying == true then | |
1024 | ScarySound2:Stop() | |
1025 | ||
1026 | ||
1027 | end | |
1028 | end end) | |
1029 | ||
1030 | mouse.KeyDown:connect(function(key) | |
1031 | if key == "r" then | |
1032 | if ScarySound4.IsPlaying == false then | |
1033 | ScarySound4:Play() | |
1034 | elseif ScarySound2.IsPlaying == true then | |
1035 | ScarySound4:Stop() | |
1036 | ||
1037 | ||
1038 | end | |
1039 | end end) | |
1040 | mouse.KeyDown:connect(function(key) | |
1041 | if key == "u" then | |
1042 | for _, z in pairs(workspace:GetChildren()) do | |
1043 | ||
1044 | if z.Name == "Zombie" then | |
1045 | ||
1046 | z:Destroy() | |
1047 | ||
1048 | end | |
1049 | end | |
1050 | end | |
1051 | end) | |
1052 | ||
1053 | ||
1054 | ||
1055 | mouse.KeyDown:connect(function(key) | |
1056 | if key == "h" then | |
1057 | for _, z in pairs(workspace:GetChildren()) do | |
1058 | ||
1059 | if z.Name == "Zombie" then | |
1060 | ||
1061 | ||
1062 | ||
1063 | end | |
1064 | end | |
1065 | end | |
1066 | end) | |
1067 | ||
1068 | ||
1069 | function SpawnZombie() | |
1070 | ||
1071 | ||
1072 | if ZomWait == false and ZomWait2 == false then | |
1073 | Zombie.Parent = game.Lighting | |
1074 | Zombie2 = Zombie:Clone() | |
1075 | Zombie3 = Zombie:Clone() | |
1076 | ||
1077 | Zombie:Destroy() | |
1078 | ---------------------------- | |
1079 | ZomWait2 = true | |
1080 | wait() | |
1081 | ZomWait = true | |
1082 | end | |
1083 | ||
1084 | ||
1085 | ||
1086 | if ZomWait == true and ZomWait2 == false then | |
1087 | Zombie3.Parent = game.Lighting | |
1088 | Zombie2 = Zombie3:Clone() | |
1089 | Zombie = Zombie3:Clone() | |
1090 | ||
1091 | Zombie3:Destroy() | |
1092 | ---------------------------- | |
1093 | ZomWait2 = true | |
1094 | wait() | |
1095 | ZomWait = false | |
1096 | end | |
1097 | Zombie2.Parent = game.Workspace | |
1098 | ||
1099 | end | |
1100 | ||
1101 | ||
1102 | ||
1103 | ||
1104 | function ResetZombie() | |
1105 | wait(4) | |
1106 | ZomSyle = false | |
1107 | ZomWait2 = false | |
1108 | ||
1109 | end | |
1110 | ||
1111 | function onTouch(part) | |
1112 | ||
1113 | local humanoid = part.Parent:findFirstChild("Humanoid") | |
1114 | local model = part.Parent | |
1115 | local torso = part.Parent:findFirstChild("Torso") | |
1116 | local head = part.Parent:findFirstChild("Head") | |
1117 | local leftleg = part.Parent:findFirstChild("Left Leg") | |
1118 | local rightleg = part.Parent:findFirstChild("Right Leg") | |
1119 | local leftarm = part.Parent:findFirstChild("Left Arm") | |
1120 | local rightarm = part.Parent:findFirstChild("Right Arm") | |
1121 | if model.Name == 'Zombie' == false then | |
1122 | ||
1123 | ||
1124 | if (humanoid ~=nil) then | |
1125 | ||
1126 | --humanoid.Health = 0 | |
1127 | ||
1128 | ||
1129 | ||
1130 | ||
1131 | head.BrickColor = BrickColor.new("Really black") | |
1132 | torso.BrickColor = BrickColor.new("Really black") | |
1133 | leftleg.BrickColor = BrickColor.new("Really black") | |
1134 | rightleg.BrickColor = BrickColor.new("Really black") | |
1135 | rightarm.BrickColor = BrickColor.new("Really black") | |
1136 | leftarm.BrickColor = BrickColor.new("Really black") | |
1137 | humanoid.Sit = true | |
1138 | wait(0.5) | |
1139 | torso.Anchored = true | |
1140 | wait(.3) | |
1141 | zomchar = humanoid.Parent | |
1142 | e=Instance.new('Part', model) | |
1143 | e.Size = Vector3.new(2.25,2.25,2.25) | |
1144 | e.Transparency = 1 | |
1145 | e.Anchored = true | |
1146 | e.CFrame = CFrame.new(torso.Position) | |
1147 | ||
1148 | ||
1149 | ||
1150 | wait(1) | |
1151 | torso:Destroy() | |
1152 | q=Instance.new('ParticleEmitter', e) | |
1153 | q.Size = NumberSequence.new(2,.0) | |
1154 | q.Rate = 500 | |
1155 | q.Transparency = NumberSequence.new(0,1) | |
1156 | q.Speed = NumberRange.new(7) | |
1157 | q.VelocitySpread = 100 | |
1158 | q.Lifetime = NumberRange.new(0.1,1) | |
1159 | q.Texture = 'rbxassetid://164417280' | |
1160 | wait(.1) | |
1161 | torso.Anchored = true | |
1162 | rightleg.Anchored = true | |
1163 | leftleg.Anchored = true | |
1164 | rightarm.Anchored = true | |
1165 | leftarm.Anchored = true | |
1166 | ded = Instance.new("Sound") | |
1167 | ded.Parent = e | |
1168 | ded.SoundId = "rbxassetid://130976109" | |
1169 | ded.Volume = 3 | |
1170 | ded.Looped = false | |
1171 | wait() | |
1172 | ||
1173 | ded:Play() | |
1174 | ||
1175 | wait(1) | |
1176 | leftleg.Transparency = 0.5 | |
1177 | head.Transparency = 0.5 | |
1178 | rightleg.Transparency = 0.5 | |
1179 | torso.Transparency = 0.5 | |
1180 | leftarm.Transparency = 0.5 | |
1181 | rightarm.Transparency = 0.5 | |
1182 | ||
1183 | ||
1184 | wait(0.001) | |
1185 | leftleg.Transparency = 0.6 | |
1186 | head.Transparency = 0.6 | |
1187 | rightleg.Transparency = 0.6 | |
1188 | torso.Transparency = 0.6 | |
1189 | leftarm.Transparency = 0.6 | |
1190 | rightarm.Transparency = 0.6 | |
1191 | ||
1192 | wait(0.001) | |
1193 | leftleg.Transparency = 0.7 | |
1194 | head.Transparency = 0.7 | |
1195 | rightleg.Transparency = 0.7 | |
1196 | torso.Transparency = 0.7 | |
1197 | leftarm.Transparency = 0.7 | |
1198 | rightarm.Transparency = 0.7 | |
1199 | ||
1200 | ||
1201 | ||
1202 | ||
1203 | ||
1204 | ||
1205 | wait(0.001) | |
1206 | leftleg.Transparency = 1 | |
1207 | head.Transparency = 1 | |
1208 | rightleg.Transparency = 1 | |
1209 | torso.Transparency = 1 | |
1210 | leftarm.Transparency = 1 | |
1211 | rightarm.Transparency = 1 | |
1212 | wait() | |
1213 | ||
1214 | SpawnZombie() | |
1215 | Zombie2.Name = 'Zombie' | |
1216 | ||
1217 | wait() | |
1218 | Zombie2:MoveTo(zomchar.Head.Position + Vector3.new(math.random(0,1),0,math.random(0,1))) | |
1219 | ---------------------- | |
1220 | ||
1221 | if ZomSyle == false then | |
1222 | ZomSyle = true | |
1223 | ||
1224 | ||
1225 | ||
1226 | ||
1227 | ||
1228 | ||
1229 | ||
1230 | ||
1231 | Zombie2.archivable = false | |
1232 | ||
1233 | ||
1234 | skin = zomchar["Body Colors"]:Clone() | |
1235 | skin.Parent = Zombie2 | |
1236 | wait() | |
1237 | ||
1238 | ||
1239 | Character= Zombie2 | |
1240 | plr = Zombie2 | |
1241 | Headmaker = Character.Head | |
1242 | Headcol1 = Headmaker.BrickColor | |
1243 | Headmat = Headmaker.Material | |
1244 | Headsize = Headmaker.Size | |
1245 | Headsize2 = Headmaker.Mesh.Scale | |
1246 | hed = Character.Head | |
1247 | hed.Transparency = 1 | |
1248 | ||
1249 | local Headnr1 = Instance.new("Model",Character.Head) | |
1250 | Headnr1.Name = "Lmao" | |
1251 | local Headnr2 = Instance.new("Model",Headnr1) | |
1252 | Headnr2.Name = ""..zomchar.Name | |
1253 | ||
1254 | ||
1255 | ---------------------------------------------------------- | |
1256 | wait() | |
1257 | local Mask = Instance.new("Part", Headnr2) | |
1258 | Mask.Name = "Head" | |
1259 | Mask.CanCollide = false | |
1260 | Mask.BrickColor = Headcol1 | |
1261 | Mask.Transparency = 0 | |
1262 | Mask.Material = Headmat | |
1263 | Mask.Size = Headsize | |
1264 | Mask.TopSurface = Enum.SurfaceType.Smooth | |
1265 | Mask.BottomSurface = Enum.SurfaceType.Smooth | |
1266 | local Weld = Instance.new("Weld", Mask) | |
1267 | Weld.Part0 = Character.Head | |
1268 | Weld.Part1 = Mask | |
1269 | Weld.C1 = CFrame.new(0,0,0) | |
1270 | ||
1271 | local M1 = Instance.new("SpecialMesh") | |
1272 | M1.Parent = Mask | |
1273 | M1.MeshType='Head' | |
1274 | M1.Scale = Headsize2 | |
1275 | ---------------------------------------------------------- | |
1276 | local Name2 = Instance.new("Humanoid",Headnr2) | |
1277 | Zombie2.Torso.Touched:connect(onTouch) | |
1278 | wait() | |
1279 | ||
1280 | for i,v in pairs(zomchar:GetChildren()) do | |
1281 | if v:IsA("CharacterMesh") then | |
1282 | v:clone().Parent = Zombie2 | |
1283 | end | |
1284 | ||
1285 | if v:IsA("ShirtGraphic") then | |
1286 | v:clone().Parent = Zombie2 | |
1287 | end | |
1288 | ||
1289 | if v:IsA("Pants") then | |
1290 | v:clone().Parent = Zombie2 | |
1291 | end | |
1292 | if v:IsA("Shirt") then | |
1293 | v:clone().Parent = Zombie2 | |
1294 | ||
1295 | end | |
1296 | ||
1297 | ||
1298 | if v:IsA("Accessory") then | |
1299 | v:clone().Parent = Zombie2 | |
1300 | end | |
1301 | ||
1302 | if v:IsA("Hat") then | |
1303 | v:clone().Parent = Zombie2 | |
1304 | end | |
1305 | ||
1306 | end | |
1307 | ||
1308 | ||
1309 | ||
1310 | end | |
1311 | ||
1312 | ||
1313 | ||
1314 | ||
1315 | ||
1316 | ||
1317 | ||
1318 | ---------------------- | |
1319 | wait() | |
1320 | leftleg:Destroy() | |
1321 | head:Destroy() | |
1322 | rightleg:Destroy() | |
1323 | leftarm:Destroy() | |
1324 | rightarm:Destroy() | |
1325 | ResetZombie() | |
1326 | end | |
1327 | end | |
1328 | end | |
1329 | ||
1330 | ||
1331 | ||
1332 | char.Torso.Touched:connect(onTouch) | |
1333 | ||
1334 | mouse.KeyDown:connect(function(key) | |
1335 | if key == "c" then | |
1336 | ||
1337 | LockOn() | |
1338 | ||
1339 | ||
1340 | ||
1341 | ||
1342 | ||
1343 | end | |
1344 | end) | |
1345 | ||
1346 | ||
1347 | debounce = false | |
1348 | ||
1349 | function onTouched(hit) | |
1350 | hole:Play() | |
1351 | hit.CanCollide=false | |
1352 | wait(.5) | |
1353 | hit.CanCollide = true | |
1354 | debounce = true | |
1355 | ||
1356 | end | |
1357 | game.Players.LocalPlayer.Character.Torso.Touched:connect(onTouched) | |
1358 | ||
1359 | ||
1360 | while wait() do | |
1361 | char["Left Leg"].BrickColor = BrickColor.new("Really black") | |
1362 | char["Head"].BrickColor = BrickColor.new("Really black") | |
1363 | char["Right Leg"].BrickColor = BrickColor.new("Really black") | |
1364 | char["Torso"].BrickColor = BrickColor.new("Really black") | |
1365 | char["Left Arm"].BrickColor = BrickColor.new("Black") | |
1366 | char["Right Arm"].BrickColor = BrickColor.new("Black") | |
1367 | imgl.Rotation = imgl.Rotation + 1 | |
1368 | if targetted ~= nil then | |
1369 | crosshair.Adornee = targetted:FindFirstChild("Torso") or targetted:FindFirstChild("UpperTorso") | |
1370 | crosshair.Enabled = true | |
1371 | elseif targetted == nil then | |
1372 | crosshair.Adornee = nil | |
1373 | crosshair.Enabled = false | |
1374 | end | |
1375 | ||
1376 | ||
1377 | ||
1378 | ||
1379 | ||
1380 | end | |
1381 | ||
1382 | ||
1383 | ------------------------------------------------------------------------ |