Advertisement
HenloMyDude

guinea fat piggy

Aug 17th, 2019
393
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 23.38 KB | None | 0 0
  1. if game:GetService("RunService"):IsClient() then error("Script must be server-side in order to work; use h/ and not hl/") end
  2. local Player,game,owner = owner,game
  3. local RealPlayer = Player
  4. do
  5. print("FE Compatibility code V2 by Mokiros")
  6. local RealPlayer = RealPlayer
  7. script.Parent = RealPlayer.Character
  8.  
  9. --Fake event to make stuff like Mouse.KeyDown work
  10. local Disconnect_Function = function(this)
  11. this[1].Functions[this[2]] = nil
  12. end
  13. local Disconnect_Metatable = {__index={disconnect=Disconnect_Function,Disconnect=Disconnect_Function}}
  14. local FakeEvent_Metatable = {__index={
  15. Connect = function(this,f)
  16. local i = tostring(math.random(0,10000))
  17. while this.Functions[i] do
  18. i = tostring(math.random(0,10000))
  19. end
  20. this.Functions[i] = f
  21. return setmetatable({this,i},Disconnect_Metatable)
  22. end
  23. }}
  24. FakeEvent_Metatable.__index.connect = FakeEvent_Metatable.__index.Connect
  25. local function fakeEvent()
  26. return setmetatable({Functions={}},FakeEvent_Metatable)
  27. end
  28.  
  29. --Creating fake input objects with fake variables
  30. local FakeMouse = {Hit=CFrame.new(),KeyUp=fakeEvent(),KeyDown=fakeEvent(),Button1Up=fakeEvent(),Button1Down=fakeEvent(),Button2Up=fakeEvent(),Button2Down=fakeEvent()}
  31. FakeMouse.keyUp = FakeMouse.KeyUp
  32. FakeMouse.keyDown = FakeMouse.KeyDown
  33. local UIS = {InputBegan=fakeEvent(),InputEnded=fakeEvent()}
  34. local CAS = {Actions={},BindAction=function(self,name,fun,touch,...)
  35. CAS.Actions[name] = fun and {Name=name,Function=fun,Keys={...}} or nil
  36. end}
  37. --Merged 2 functions into one by checking amount of arguments
  38. CAS.UnbindAction = CAS.BindAction
  39.  
  40. --This function will trigger the events that have been :Connect()'ed
  41. local function TriggerEvent(self,ev,...)
  42. for _,f in pairs(self[ev].Functions) do
  43. f(...)
  44. end
  45. end
  46. FakeMouse.TriggerEvent = TriggerEvent
  47. UIS.TriggerEvent = TriggerEvent
  48.  
  49. --Client communication
  50. local Event = Instance.new("RemoteEvent")
  51. Event.Name = "UserInput_Event"
  52. Event.OnServerEvent:Connect(function(plr,io)
  53. if plr~=RealPlayer then return end
  54. FakeMouse.Target = io.Target
  55. FakeMouse.Hit = io.Hit
  56. if not io.isMouse then
  57. local b = io.UserInputState == Enum.UserInputState.Begin
  58. if io.UserInputType == Enum.UserInputType.MouseButton1 then
  59. return FakeMouse:TriggerEvent(b and "Button1Down" or "Button1Up")
  60. end
  61. if io.UserInputType == Enum.UserInputType.MouseButton2 then
  62. return FakeMouse:TriggerEvent(b and "Button2Down" or "Button2Up")
  63. end
  64. for _,t in pairs(CAS.Actions) do
  65. for _,k in pairs(t.Keys) do
  66. if k==io.KeyCode then
  67. t.Function(t.Name,io.UserInputState,io)
  68. end
  69. end
  70. end
  71. FakeMouse:TriggerEvent(b and "KeyDown" or "KeyUp",io.KeyCode.Name:lower())
  72. UIS:TriggerEvent(b and "InputBegan" or "InputEnded",io,false)
  73. end
  74. end)
  75. Event.Parent = NLS([==[local Event = script:WaitForChild("UserInput_Event")
  76. local Mouse = owner:GetMouse()
  77. local UIS = game:GetService("UserInputService")
  78. local input = function(io,RobloxHandled)
  79. if RobloxHandled then return end
  80. --Since InputObject is a client-side instance, we create and pass table instead
  81. Event:FireServer({KeyCode=io.KeyCode,UserInputType=io.UserInputType,UserInputState=io.UserInputState,Hit=Mouse.Hit,Target=Mouse.Target})
  82. end
  83. UIS.InputBegan:Connect(input)
  84. UIS.InputEnded:Connect(input)
  85. local h,t
  86. --Give the server mouse data every second frame, but only if the values changed
  87. --If player is not moving their mouse, client won't fire events
  88. local HB = game:GetService("RunService").Heartbeat
  89. while true do
  90. if h~=Mouse.Hit or t~=Mouse.Target then
  91. h,t=Mouse.Hit,Mouse.Target
  92. Event:FireServer({isMouse=true,Target=t,Hit=h})
  93. end
  94. --Wait 2 frames
  95. for i=1,2 do
  96. HB:Wait()
  97. end
  98. end]==],script)
  99.  
  100. ----Sandboxed game object that allows the usage of client-side methods and services
  101. --Real game object
  102. local RealGame = game
  103.  
  104. --Metatable for fake service
  105. local FakeService_Metatable = {
  106. __index = function(self,k)
  107. local s = rawget(self,"_RealService")
  108. if s then
  109. return typeof(s[k])=="function"
  110. and function(_,...)return s[k](s,...)end or s[k]
  111. end
  112. end,
  113. __newindex = function(self,k,v)
  114. local s = rawget(self,"_RealService")
  115. if s then s[k]=v end
  116. end
  117. }
  118. local function FakeService(t,RealService)
  119. t._RealService = typeof(RealService)=="string" and RealGame:GetService(RealService) or RealService
  120. return setmetatable(t,FakeService_Metatable)
  121. end
  122.  
  123. --Fake game object
  124. local FakeGame = {
  125. GetService = function(self,s)
  126. return rawget(self,s) or RealGame:GetService(s)
  127. end,
  128. Players = FakeService({
  129. LocalPlayer = FakeService({GetMouse=function(self)return FakeMouse end},Player)
  130. },"Players"),
  131. UserInputService = FakeService(UIS,"UserInputService"),
  132. ContextActionService = FakeService(CAS,"ContextActionService"),
  133. RunService = FakeService({
  134. _btrs = {},
  135. RenderStepped = RealGame:GetService("RunService").Heartbeat,
  136. BindToRenderStep = function(self,name,_,fun)
  137. self._btrs[name] = self.Heartbeat:Connect(fun)
  138. end,
  139. UnbindFromRenderStep = function(self,name)
  140. self._btrs[name]:Disconnect()
  141. end,
  142. },"RunService")
  143. }
  144. rawset(FakeGame.Players,"localPlayer",FakeGame.Players.LocalPlayer)
  145. FakeGame.service = FakeGame.GetService
  146. FakeService(FakeGame,game)
  147. --Changing owner to fake player object to support owner:GetMouse()
  148. game,owner = FakeGame,FakeGame.Players.LocalPlayer
  149. end
  150.  
  151.  
  152. meshid = "rbxassetid://1719079794"
  153. texid = "rbxassetid://1719079844"
  154. scale = Vector3.new(0.1, 0.1, 0.1)
  155.  
  156. plr = owner
  157. mouse = plr:GetMouse()
  158. char = plr.Character
  159. root = char.HumanoidRootPart
  160.  
  161. for _,v in pairs (char:children()) do
  162. if v:IsA("Part") and v.Name ~= "Head" then
  163. v.Transparency = 1
  164. if v:IsA("Part") then
  165. v.BrickColor = BrickColor.new("Really black")
  166. end
  167. end
  168. char.Head.BrickColor = BrickColor.new("Institutional white")
  169. char.Head.Transparency = 0.9
  170. char.Head.Mesh.Scale = Vector3.new(0.001, 0.001, 0.001)
  171. if v:IsA("Accessory") or v:IsA("Hat") or v:IsA("Hair") then
  172. v:Destroy()
  173. end
  174. if v:IsA("ShirtGraphic") then
  175. v:Destroy()
  176. wait(.1)
  177. char.Torso.roblox:Destroy()
  178. end
  179. end
  180.  
  181. char.Torso.Transparency = 0
  182. sine=0
  183. dance = false
  184.  
  185. Cos = math.cos
  186. Sin = math.sin
  187.  
  188. foota = Instance.new("SpecialMesh",char.Torso)
  189. foota.Scale = scale
  190. foota.MeshId = meshid
  191. foota.TextureId = texid
  192. foota.Offset = Vector3.new(0, -0.75, 0)
  193.  
  194. function swait(num)
  195. if num == 0 or num == nil then
  196. game:service("RunService").Stepped:wait(0)
  197. else
  198. for i = 0, num do
  199. game:service("RunService").Stepped:wait(0)
  200. end
  201. end
  202. end
  203.  
  204. function thread(f)
  205. coroutine.resume(coroutine.create(f))
  206. end
  207. function clerp(a, b, t)
  208. local qa = {
  209. QuaternionFromCFrame(a)
  210. }
  211. local qb = {
  212. QuaternionFromCFrame(b)
  213. }
  214. local ax, ay, az = a.x, a.y, a.z
  215. local bx, by, bz = b.x, b.y, b.z
  216. local _t = 1 - t
  217. return QuaternionToCFrame(_t * ax + t * bx, _t * ay + t * by, _t * az + t * bz, QuaternionSlerp(qa, qb, t))
  218. end
  219. function QuaternionFromCFrame(cf)
  220. local mx, my, mz, m00, m01, m02, m10, m11, m12, m20, m21, m22 = cf:components()
  221. local trace = m00 + m11 + m22
  222. if trace > 0 then
  223. local s = math.sqrt(1 + trace)
  224. local recip = 0.5 / s
  225. return (m21 - m12) * recip, (m02 - m20) * recip, (m10 - m01) * recip, s * 0.5
  226. else
  227. local i = 0
  228. if m00 < m11 then
  229. i = 1
  230. end
  231. if m22 > (i == 0 and m00 or m11) then
  232. i = 2
  233. end
  234. if i == 0 then
  235. local s = math.sqrt(m00 - m11 - m22 + 1)
  236. local recip = 0.5 / s
  237. return 0.5 * s, (m10 + m01) * recip, (m20 + m02) * recip, (m21 - m12) * recip
  238. elseif i == 1 then
  239. local s = math.sqrt(m11 - m22 - m00 + 1)
  240. local recip = 0.5 / s
  241. return (m01 + m10) * recip, 0.5 * s, (m21 + m12) * recip, (m02 - m20) * recip
  242. elseif i == 2 then
  243. local s = math.sqrt(m22 - m00 - m11 + 1)
  244. local recip = 0.5 / s
  245. return (m02 + m20) * recip, (m12 + m21) * recip, 0.5 * s, (m10 - m01) * recip
  246. end
  247. end
  248. end
  249. function QuaternionToCFrame(px, py, pz, x, y, z, w)
  250. local xs, ys, zs = x + x, y + y, z + z
  251. local wx, wy, wz = w * xs, w * ys, w * zs
  252. local xx = x * xs
  253. local xy = x * ys
  254. local xz = x * zs
  255. local yy = y * ys
  256. local yz = y * zs
  257. local zz = z * zs
  258. 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))
  259. end
  260. function QuaternionSlerp(a, b, t)
  261. local cosTheta = a[1] * b[1] + a[2] * b[2] + a[3] * b[3] + a[4] * b[4]
  262. local startInterp, finishInterp
  263. if cosTheta >= 1.0E-4 then
  264. if 1 - cosTheta > 1.0E-4 then
  265. local theta = math.acos(cosTheta)
  266. local invSinTheta = 1 / Sin(theta)
  267. startInterp = Sin((1 - t) * theta) * invSinTheta
  268. finishInterp = Sin(t * theta) * invSinTheta
  269. else
  270. startInterp = 1 - t
  271. finishInterp = t
  272. end
  273. elseif 1 + cosTheta > 1.0E-4 then
  274. local theta = math.acos(-cosTheta)
  275. local invSinTheta = 1 / Sin(theta)
  276. startInterp = Sin((t - 1) * theta) * invSinTheta
  277. finishInterp = Sin(t * theta) * invSinTheta
  278. else
  279. startInterp = t - 1
  280. finishInterp = t
  281. end
  282. 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
  283. end
  284. function rayCast(Position, Direction, Range, Ignore)
  285. return game:service("Workspace"):FindPartOnRay(Ray.new(Position, Direction.unit * (Range or 999.999)), Ignore)
  286. end
  287. local RbxUtility = LoadLibrary("RbxUtility")
  288. local Create = RbxUtility.Create
  289. local insta = true
  290.  
  291. local weld = Instance.new("Weld",char.Torso)
  292. weld.Part0 = char.Torso
  293. weld.Part1 = root
  294.  
  295. mouse.KeyDown:connect(function(key)
  296. key=key:lower()
  297. if key == "e" then
  298. if dance then
  299. dance = false
  300. for _,v in pairs (char.Torso:children()) do
  301. if v:IsA("Sound") then
  302. v:Destroy()
  303. end
  304. end
  305. else
  306. local guin = Instance.new("Sound",char.Torso)
  307. guin.Volume = 10
  308. guin.Looped = true
  309. guin.SoundId = "rbxassetid://598782463"
  310. guin:Play()
  311. dance = true
  312. repeat
  313. for i = 1, 12 ,0.5 do
  314. swait()
  315. weld.C0 = clerp(weld.C0, CFrame.Angles(0, 0, -0.5) * CFrame.new(0, -0.5, 0),0.1)
  316. end
  317. for i = 1, 12 ,0.5 do
  318. swait()
  319. weld.C0 = clerp(weld.C0, CFrame.Angles(0, 0, 0) * CFrame.new(0, -0.5, 0),0.1)
  320. end
  321. for i = 1, 12 ,0.5 do
  322. swait()
  323. weld.C0 = clerp(weld.C0, CFrame.Angles(0, 0, 0.5) * CFrame.new(0, -0.5, 0),0.1)
  324. end
  325. for i = 1, 12 ,0.5 do
  326. swait()
  327. weld.C0 = clerp(weld.C0, CFrame.Angles(0, 0, 0) * CFrame.new(0, -0.5, 0),0.1)
  328. end
  329. until dance == false
  330. end
  331. end
  332. if key == "q" then
  333. if dance then
  334. dance = false
  335. for _,v in pairs (char.Torso:children()) do
  336. if v:IsA("Sound") then
  337. v:Destroy()
  338. end
  339. end
  340. else
  341. recordbaby = 0.25
  342. local guin = Instance.new("Sound",char.Torso)
  343. guin.Volume = 10
  344. guin.Looped = true
  345. guin.SoundId = "rbxassetid://2586219879"
  346. guin:Play()
  347. dance = true
  348. repeat
  349. for i = 1, 12 ,0.5 do
  350. recordbaby = recordbaby + 0.001
  351. swait()
  352. weld.C0 = clerp(weld.C0, CFrame.Angles(90, 0, 0) * CFrame.new(0, 0, 0),0.1)
  353. weld.C0 = weld.C0 * CFrame.Angles(0, recordbaby, 0)
  354. end
  355. until dance == false
  356. end
  357. end
  358. end)
  359.  
  360. Effects = {}
  361.  
  362. EffectModel = Instance.new("Model", char)
  363. Effects = {
  364. Block = {
  365. Create = function(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay, Type)
  366. local prt = CFuncs.Part.Create(EffectModel, "SmoothPlastic", 0, 0, brickcolor, "Effect", Vector3.new())
  367. prt.Anchored = true
  368. prt.CFrame = cframe
  369. local msh = CFuncs.Mesh.Create("BlockMesh", prt, "", "", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
  370. game:GetService("Debris"):AddItem(prt, 10)
  371. if Type == 1 or Type == nil then
  372. table.insert(Effects, {
  373. prt,
  374. "Block1",
  375. delay,
  376. x3,
  377. y3,
  378. z3,
  379. msh
  380. })
  381. elseif Type == 2 then
  382. table.insert(Effects, {
  383. prt,
  384. "Block2",
  385. delay,
  386. x3,
  387. y3,
  388. z3,
  389. msh
  390. })
  391. else
  392. table.insert(Effects, {
  393. prt,
  394. "Block3",
  395. delay,
  396. x3,
  397. y3,
  398. z3,
  399. msh
  400. })
  401. end
  402. end
  403. },
  404. Sphere = {
  405. Create = function(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay)
  406. local prt = CFuncs.Part.Create(EffectModel, "Neon", 0, 0, brickcolor, "Effect", Vector3.new())
  407. prt.Anchored = true
  408. prt.CFrame = cframe
  409. local msh = CFuncs.Mesh.Create("SpecialMesh", prt, "Sphere", "", Vector3.new(0,0,0), Vector3.new(x1, y1, z1))
  410. game:GetService("Debris"):AddItem(prt, 10)
  411. table.insert(Effects, {
  412. prt,
  413. "Cylinder",
  414. delay,
  415. x3,
  416. y3,
  417. z3,
  418. msh
  419. })
  420. end
  421. },
  422. Cylinder = {
  423. Create = function(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay)
  424. local prt = CFuncs.Part.Create(EffectModel, "SmoothPlastic", 0, 0, brickcolor, "Effect", Vector3.new())
  425. prt.Anchored = true
  426. prt.CFrame = cframe
  427. local msh = CFuncs.Mesh.Create("CylinderMesh", prt, "", "", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
  428. game:GetService("Debris"):AddItem(prt, 10)
  429. table.insert(Effects, {
  430. prt,
  431. "Cylinder",
  432. delay,
  433. x3,
  434. y3,
  435. z3,
  436. msh
  437. })
  438. end
  439. },
  440. Wave = {
  441. Create = function(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay)
  442. local prt = CFuncs.Part.Create(EffectModel, "Neon", 0, 0, brickcolor, "Effect", Vector3.new())
  443. prt.Anchored = true
  444. prt.CFrame = cframe
  445. local msh = CFuncs.Mesh.Create("SpecialMesh", prt, "FileMesh", "rbxassetid://20329976", Vector3.new(0, 0, 0), Vector3.new(x1 / 60, y1 / 60, z1 / 60))
  446. game:GetService("Debris"):AddItem(prt, 10)
  447. table.insert(Effects, {
  448. prt,
  449. "Cylinder",
  450. delay,
  451. x3 / 60,
  452. y3 / 60,
  453. z3 / 60,
  454. msh
  455. })
  456. end
  457. },
  458. Ring = {
  459. Create = function(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay)
  460. local prt = CFuncs.Part.Create(EffectModel, "SmoothPlastic", 0, 0, brickcolor, "Effect", Vector3.new())
  461. prt.Anchored = true
  462. prt.CFrame = cframe
  463. local msh = CFuncs.Mesh.Create("SpecialMesh", prt, "FileMesh", "rbxassetid://3270017", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
  464. game:GetService("Debris"):AddItem(prt, 10)
  465. table.insert(Effects, {
  466. prt,
  467. "Cylinder",
  468. delay,
  469. x3,
  470. y3,
  471. z3,
  472. msh
  473. })
  474. end
  475. },
  476. Break = {
  477. Create = function(brickcolor, cframe, x1, y1, z1)
  478. local prt = CFuncs.Part.Create(EffectModel, "Neon", 0, 0, brickcolor, "Effect", Vector3.new(0.5, 0.5, 0.5))
  479. prt.Anchored = true
  480. prt.CFrame = cframe * CFrame.fromEulerAnglesXYZ(math.random(-50, 50), math.random(-50, 50), math.random(-50, 50))
  481. local msh = CFuncs.Mesh.Create("SpecialMesh", prt, "Sphere", "", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
  482. local num = math.random(10, 50) / 1000
  483. game:GetService("Debris"):AddItem(prt, 10)
  484. table.insert(Effects, {
  485. prt,
  486. "Shatter",
  487. num,
  488. prt.CFrame,
  489. math.random() - math.random(),
  490. 0,
  491. math.random(50, 100) / 100
  492. })
  493. end
  494. },
  495. Spiral = {
  496. Create = function(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay)
  497. local prt = CFuncs.Part.Create(EffectModel, "SmoothPlastic", 0, 0, brickcolor, "Effect", Vector3.new())
  498. prt.Anchored = true
  499. prt.CFrame = cframe
  500. local msh = CFuncs.Mesh.Create("SpecialMesh", prt, "FileMesh", "rbxassetid://1051557", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
  501. game:GetService("Debris"):AddItem(prt, 10)
  502. table.insert(Effects, {
  503. prt,
  504. "Cylinder",
  505. delay,
  506. x3,
  507. y3,
  508. z3,
  509. msh
  510. })
  511. end
  512. },
  513. Push = {
  514. Create = function(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay)
  515. local prt = CFuncs.Part.Create(EffectModel, "SmoothPlastic", 0, 0, brickcolor, "Effect", Vector3.new())
  516. prt.Anchored = true
  517. prt.CFrame = cframe
  518. local msh = CFuncs.Mesh.Create("SpecialMesh", prt, "FileMesh", "rbxassetid://437347603", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
  519. game:GetService("Debris"):AddItem(prt, 10)
  520. table.insert(Effects, {
  521. prt,
  522. "Cylinder",
  523. delay,
  524. x3,
  525. y3,
  526. z3,
  527. msh
  528. })
  529. end
  530. }
  531. }
  532.  
  533. local tors = char.Torso
  534. local equipped = false
  535. local idle = 0
  536. local change = 1
  537. local val = 0
  538. local toim = 0
  539. local idleanim = 0.4
  540. char.Humanoid.Animator.Parent = nil
  541. attack = dance
  542. while true do
  543. swait()
  544. sine = sine + change
  545. local torvel = (root.Velocity * Vector3.new(1, 0, 1)).magnitude
  546. local velderp = root.Velocity.y
  547. hitfloor, posfloor = rayCast(root.Position, CFrame.new(root.Position, root.Position - Vector3.new(0, 1, 0)).lookVector, 4, char)
  548. if equipped == true or equipped == false then
  549. if attack == false then
  550. idle = idle + 1
  551. else
  552. idle = 0
  553. end
  554. if 1 < root.Velocity.y and hitfloor == nil then
  555. Anim = "Jump"
  556. if dance == false then
  557. weld.C0 = clerp(weld.C0, CFrame.Angles(0, 0, 0) * CFrame.new(0, 0, 0),0.1)
  558. end
  559. elseif -1 > root.Velocity.y and hitfloor == nil then
  560. Anim = "Fall"
  561. if attack == false then
  562. weld.C0 = clerp(weld.C0, CFrame.Angles(0, 0, 0) * CFrame.new(0, 0, 0),0.1)
  563. end
  564. elseif torvel < 1 and hitfloor ~= nil then
  565. Anim = "Idle"
  566. change = .5
  567. if dance == false then
  568. weld.C0 = clerp(weld.C0, CFrame.Angles(0, 0, 0) * CFrame.new(0, 0, 0),0.1)
  569. end
  570. elseif tors.Velocity.magnitude < 50 and hitfloor ~= nil then
  571. Anim = "Walk"
  572. change = 1
  573. if dance == false then
  574. weld.C0 = clerp(weld.C0, CFrame.Angles(0, 0, 0) * CFrame.new(0, -0.25 - 0.5 * Cos(sine / 6), 0),0.1)
  575. end
  576. end
  577. end
  578. if 0 < #Effects then
  579. for e = 1, #Effects do
  580. if Effects[e] ~= nil then
  581. local Thing = Effects[e]
  582. if Thing ~= nil then
  583. local Part = Thing[1]
  584. local Mode = Thing[2]
  585. local Delay = Thing[3]
  586. local IncX = Thing[4]
  587. local IncY = Thing[5]
  588. local IncZ = Thing[6]
  589. if 1 >= Thing[1].Transparency then
  590. if Thing[2] == "Block1" then
  591. Thing[1].CFrame = Thing[1].CFrame * CFrame.fromEulerAnglesXYZ(math.random(-50, 50), math.random(-50, 50), math.random(-50, 50))
  592. local Mesh = Thing[1].Mesh
  593. Mesh.Scale = Mesh.Scale + Vector3.new(Thing[4], Thing[5], Thing[6])
  594. Thing[1].Transparency = Thing[1].Transparency + Thing[3]
  595. elseif Thing[2] == "Block2" then
  596. Thing[1].CFrame = Thing[1].CFrame + Vector3.new(0, 0, 0)
  597. local Mesh = Thing[7]
  598. Mesh.Scale = Mesh.Scale + Vector3.new(Thing[4], Thing[5], Thing[6])
  599. Thing[1].Transparency = Thing[1].Transparency + Thing[3]
  600. elseif Thing[2] == "Block3" then
  601. Thing[1].CFrame = Thing[1].CFrame * CFrame.fromEulerAnglesXYZ(math.random(-50, 50), math.random(-50, 50), math.random(-50, 50)) + Vector3.new(0, 0.15, 0)
  602. local Mesh = Thing[7]
  603. Mesh.Scale = Mesh.Scale + Vector3.new(Thing[4], Thing[5], Thing[6])
  604. Thing[1].Transparency = Thing[1].Transparency + Thing[3]
  605. elseif Thing[2] == "Cylinder" then
  606. local Mesh = Thing[1].Mesh
  607. Mesh.Scale = Mesh.Scale + Vector3.new(Thing[4], Thing[5], Thing[6])
  608. Thing[1].Transparency = Thing[1].Transparency + Thing[3]
  609. elseif Thing[2] == "Blood" then
  610. local Mesh = Thing[7]
  611. Thing[1].CFrame = Thing[1].CFrame * Vector3.new(0, 0.5, 0)
  612. Mesh.Scale = Mesh.Scale + Vector3.new(Thing[4], Thing[5], Thing[6])
  613. Thing[1].Transparency = Thing[1].Transparency + Thing[3]
  614. elseif Thing[2] == "Elec" then
  615. local Mesh = Thing[1].Mesh
  616. Mesh.Scale = Mesh.Scale + Vector3.new(Thing[7], Thing[8], Thing[9])
  617. Thing[1].Transparency = Thing[1].Transparency + Thing[3]
  618. elseif Thing[2] == "Disappear" then
  619. Thing[1].Transparency = Thing[1].Transparency + Thing[3]
  620. elseif Thing[2] == "Shatter" then
  621. Thing[1].Transparency = Thing[1].Transparency + Thing[3]
  622. Thing[4] = Thing[4] * CFrame.new(0, Thing[7], 0)
  623. Thing[1].CFrame = Thing[4] * CFrame.fromEulerAnglesXYZ(Thing[6], 0, 0)
  624. Thing[6] = Thing[6] + Thing[5]
  625. end
  626. else
  627. Part.Parent = nil
  628. table.remove(Effects, e)
  629. end
  630. end
  631. end
  632. end
  633. end
  634. end
  635. -------------------------------------------------------
  636. --End Animations And Script--
  637. -------------------------------------------------------
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement