Mitko1223tm

boss

Sep 14th, 2018
155
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 31.79 KB | None | 0 0
  1. --Created by Adelpvp123#8551
  2. local runDummyScript = function(f,scri)
  3. local oldenv = getfenv(f)
  4. local newenv = setmetatable({}, {
  5. __index = function(_, k)
  6. if k:lower() == 'script' then
  7. return scri
  8. else
  9. return oldenv[k]
  10. end
  11. end
  12. })
  13. setfenv(f, newenv)
  14. ypcall(function() f() end)
  15. end
  16. cors = {}
  17. mas = Instance.new("Model",game:GetService("Lighting"))
  18. mas.Name = "CompiledModel"
  19. o1 = Instance.new("Model")
  20. o2 = Instance.new("Part")
  21. o3 = Instance.new("Part")
  22. o4 = Instance.new("Weld")
  23. o5 = Instance.new("Part")
  24. o6 = Instance.new("Part")
  25. o7 = Instance.new("Part")
  26. o8 = Instance.new("Decal")
  27. o9 = Instance.new("Motor")
  28. o10 = Instance.new("Motor")
  29. o11 = Instance.new("Motor")
  30. o12 = Instance.new("Motor")
  31. o13 = Instance.new("Motor")
  32. o14 = Instance.new("Sparkles")
  33. o15 = Instance.new("PointLight")
  34. o16 = Instance.new("Part")
  35. o17 = Instance.new("SpecialMesh")
  36. o18 = Instance.new("Decal")
  37. o19 = Instance.new("BodyColors")
  38. o20 = Instance.new("Humanoid")
  39. o21 = Instance.new("Script")
  40. o22 = Instance.new("Script")
  41. o23 = Instance.new("Script")
  42. o24 = Instance.new("Tool")
  43. o25 = Instance.new("Part")
  44. o26 = Instance.new("SpecialMesh")
  45. o27 = Instance.new("Sound")
  46. o28 = Instance.new("Script")
  47. o30 = Instance.new("Script")
  48. o31 = Instance.new("StringValue")
  49. o32 = Instance.new("StringValue")
  50. o33 = Instance.new("StringValue")
  51. o34 = Instance.new("StringValue")
  52. o35 = Instance.new("StringValue")
  53. o36 = Instance.new("StringValue")
  54. o37 = Instance.new("StringValue")
  55. o38 = Instance.new("StringValue")
  56. o39 = Instance.new("StringValue")
  57. o40 = Instance.new("StringValue")
  58. o41 = Instance.new("StringValue")
  59. o42 = Instance.new("StringValue")
  60. o43 = Instance.new("StringValue")
  61. o44 = Instance.new("StringValue")
  62. o45 = Instance.new("StringValue")
  63. o46 = Instance.new("StringValue")
  64. o47 = Instance.new("StringValue")
  65. o48 = Instance.new("StringValue")
  66. o49 = Instance.new("StringValue")
  67. o50 = Instance.new("StringValue")
  68. o51 = Instance.new("StringValue")
  69. o52 = Instance.new("StringValue")
  70. o53 = Instance.new("StringValue")
  71. o54 = Instance.new("StringValue")
  72. o55 = Instance.new("StringValue")
  73. o56 = Instance.new("StringValue")
  74. o57 = Instance.new("StringValue")
  75. o58 = Instance.new("StringValue")
  76. o59 = Instance.new("StringValue")
  77. o60 = Instance.new("StringValue")
  78. o61 = Instance.new("StringValue")
  79. o62 = Instance.new("StringValue")
  80. o63 = Instance.new("StringValue")
  81. o64 = Instance.new("StringValue")
  82. o65 = Instance.new("StringValue")
  83. o66 = Instance.new("StringValue")
  84. o67 = Instance.new("StringValue")
  85. o68 = Instance.new("StringValue")
  86. o69 = Instance.new("StringValue")
  87. o70 = Instance.new("StringValue")
  88. o71 = Instance.new("StringValue")
  89. o72 = Instance.new("StringValue")
  90. o73 = Instance.new("StringValue")
  91. o74 = Instance.new("StringValue")
  92. o75 = Instance.new("StringValue")
  93. o76 = Instance.new("StringValue")
  94. o77 = Instance.new("StringValue")
  95. o78 = Instance.new("StringValue")
  96. o79 = Instance.new("StringValue")
  97. o80 = Instance.new("StringValue")
  98. o81 = Instance.new("StringValue")
  99. o82 = Instance.new("StringValue")
  100. o83 = Instance.new("StringValue")
  101. o84 = Instance.new("StringValue")
  102. o85 = Instance.new("StringValue")
  103. o86 = Instance.new("StringValue")
  104. o87 = Instance.new("StringValue")
  105. o88 = Instance.new("BoolValue")
  106. o89 = Instance.new("ObjectValue")
  107. o1.Name = "(BOSS) RAIGING NOOB!!"
  108. o1.Parent = mas
  109. o1.PrimaryPart = o16
  110. o2.Name = "Right Leg"
  111. o2.Parent = o1
  112. o2.BrickColor = BrickColor.new("Bright red")
  113. o2.Position = Vector3.new(-7.96908188, 1.00003004, 87.977356)
  114. o2.Rotation = Vector3.new(-180, -16.25, -180)
  115. o2.CanCollide = false
  116. o2.FormFactor = Enum.FormFactor.Symmetric
  117. o2.Size = Vector3.new(1, 2, 1)
  118. o2.CFrame = CFrame.new(-7.96908188, 1.00003004, 87.977356, -0.960035264, 0, -0.279879063, 0, 1, 0, 0.279879063, 0, -0.960035264)
  119. o2.BottomSurface = Enum.SurfaceType.Smooth
  120. o2.Color = Color3.new(0.768628, 0.156863, 0.109804)
  121. o2.Position = Vector3.new(-7.96908188, 1.00003004, 87.977356)
  122. o3.Name = "Right Arm"
  123. o3.Parent = o1
  124. o3.BrickColor = BrickColor.new("Bright red")
  125. o3.Position = Vector3.new(-8.9291172, 3.00003004, 88.2572327)
  126. o3.Rotation = Vector3.new(-180, -16.25, -180)
  127. o3.CanCollide = false
  128. o3.FormFactor = Enum.FormFactor.Symmetric
  129. o3.Size = Vector3.new(1, 2, 1)
  130. o3.CFrame = CFrame.new(-8.9291172, 3.00003004, 88.2572327, -0.960035264, 0, -0.279879063, 0, 1, 0, 0.279879063, 0, -0.960035264)
  131. o3.Color = Color3.new(0.768628, 0.156863, 0.109804)
  132. o3.Position = Vector3.new(-8.9291172, 3.00003004, 88.2572327)
  133. o4.Name = "RightGrip"
  134. o4.Parent = o3
  135. o4.C0 = CFrame.new(0, -1, 0, 1, 0, -0, 0, 0, 1, 0, -1, -0)
  136. o4.C1 = CFrame.new(0, 0, 0.300000012, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  137. o4.Part0 = o3
  138. o4.Part1 = o25
  139. o5.Name = "Left Leg"
  140. o5.Parent = o1
  141. o5.BrickColor = BrickColor.new("Really red")
  142. o5.Position = Vector3.new(-7.00904655, 1.00003004, 87.6974792)
  143. o5.Rotation = Vector3.new(-180, -16.25, -180)
  144. o5.CanCollide = false
  145. o5.FormFactor = Enum.FormFactor.Symmetric
  146. o5.Size = Vector3.new(1, 2, 1)
  147. o5.CFrame = CFrame.new(-7.00904655, 1.00003004, 87.6974792, -0.960035264, 0, -0.279879063, 0, 1, 0, 0.279879063, 0, -0.960035264)
  148. o5.BottomSurface = Enum.SurfaceType.Smooth
  149. o5.Color = Color3.new(1, 0, 0)
  150. o5.Position = Vector3.new(-7.00904655, 1.00003004, 87.6974792)
  151. o6.Name = "Left Arm"
  152. o6.Parent = o1
  153. o6.BrickColor = BrickColor.new("Bright red")
  154. o6.Position = Vector3.new(-6.04901123, 3.00003004, 87.4176025)
  155. o6.Rotation = Vector3.new(-180, -16.25, -180)
  156. o6.CanCollide = false
  157. o6.FormFactor = Enum.FormFactor.Symmetric
  158. o6.Size = Vector3.new(1, 2, 1)
  159. o6.CFrame = CFrame.new(-6.04901123, 3.00003004, 87.4176025, -0.960035264, 0, -0.279879063, 0, 1, 0, 0.279879063, 0, -0.960035264)
  160. o6.Color = Color3.new(0.768628, 0.156863, 0.109804)
  161. o6.Position = Vector3.new(-6.04901123, 3.00003004, 87.4176025)
  162. o7.Name = "Torso"
  163. o7.Parent = o1
  164. o7.BrickColor = BrickColor.new("Really red")
  165. o7.Position = Vector3.new(-7.48906422, 3.00003004, 87.8374176)
  166. o7.Rotation = Vector3.new(-180, -16.25, -180)
  167. o7.FormFactor = Enum.FormFactor.Symmetric
  168. o7.Friction = 0
  169. o7.Size = Vector3.new(2, 2, 1)
  170. o7.CFrame = CFrame.new(-7.48906422, 3.00003004, 87.8374176, -0.960035264, 0, -0.279879063, 0, 1, 0, 0.279879063, 0, -0.960035264)
  171. o7.LeftSurface = Enum.SurfaceType.Weld
  172. o7.RightSurface = Enum.SurfaceType.Weld
  173. o7.Color = Color3.new(1, 0, 0)
  174. o7.Position = Vector3.new(-7.48906422, 3.00003004, 87.8374176)
  175. o8.Name = "roblox"
  176. o8.Parent = o7
  177. o9.Name = "Right Shoulder"
  178. o9.Parent = o7
  179. o9.C0 = CFrame.new(1, 0.5, 0, 0, 0, 1, 0, 1, -0, -1, 0, 0)
  180. o9.C1 = CFrame.new(-0.5, 0.5, 0, 0, 0, 1, 0, 1, -0, -1, 0, 0)
  181. o9.Part0 = o7
  182. o9.Part1 = o3
  183. o9.DesiredAngle = 1.5700000524521
  184. o9.MaxVelocity = 0.15000000596046
  185. o10.Name = "Left Shoulder"
  186. o10.Parent = o7
  187. o10.C0 = CFrame.new(-1, 0.5, 0, 0, 0, -1, 0, 1, 0, 1, 0, 0)
  188. o10.C1 = CFrame.new(0.5, 0.5, 0, 0, 0, -1, 0, 1, 0, 1, 0, 0)
  189. o10.Part0 = o7
  190. o10.Part1 = o6
  191. o10.DesiredAngle = -0.82280361652374
  192. o10.MaxVelocity = 0.15000000596046
  193. o11.Name = "Right Hip"
  194. o11.Parent = o7
  195. o11.C0 = CFrame.new(1, -1, 0, 0, 0, 1, 0, 1, -0, -1, 0, 0)
  196. o11.C1 = CFrame.new(0.5, 1, 0, 0, 0, 1, 0, 1, -0, -1, 0, 0)
  197. o11.Part0 = o7
  198. o11.Part1 = o2
  199. o11.DesiredAngle = 0.82280361652374
  200. o11.MaxVelocity = 0.10000000149012
  201. o12.Name = "Left Hip"
  202. o12.Parent = o7
  203. o12.C0 = CFrame.new(-1, -1, 0, 0, 0, -1, 0, 1, 0, 1, 0, 0)
  204. o12.C1 = CFrame.new(-0.5, 1, 0, 0, 0, -1, 0, 1, 0, 1, 0, 0)
  205. o12.Part0 = o7
  206. o12.Part1 = o5
  207. o12.DesiredAngle = 0.82280361652374
  208. o12.MaxVelocity = 0.10000000149012
  209. o13.Name = "Neck"
  210. o13.Parent = o7
  211. o13.C0 = CFrame.new(0, 1, 0, -1, 0, 0, 0, 0, 1, 0, 1, -0)
  212. o13.C1 = CFrame.new(0, -0.5, 0, -1, 0, 0, 0, 0, 1, 0, 1, -0)
  213. o13.Part0 = o7
  214. o13.Part1 = o16
  215. o13.MaxVelocity = 0.10000000149012
  216. o14.Parent = o7
  217. o14.Color = Color3.new(0.618056, 0.32, 0.0196078)
  218. o14.SparkleColor = Color3.new(0.34902, 0.0313726, 0.0196078)
  219. o15.Parent = o7
  220. o15.Color = Color3.new(0.835294, 0.0862745, 0.0196078)
  221. o15.Brightness = 20
  222. o15.Range = 10
  223. o16.Name = "Head"
  224. o16.Parent = o1
  225. o16.BrickColor = BrickColor.new("Really red")
  226. o16.Position = Vector3.new(-7.48906422, 4.50003004, 87.8374176)
  227. o16.Rotation = Vector3.new(-180, -16.25, -180)
  228. o16.FormFactor = Enum.FormFactor.Symmetric
  229. o16.Friction = 0
  230. o16.Size = Vector3.new(2, 1, 1)
  231. o16.CFrame = CFrame.new(-7.48906422, 4.50003004, 87.8374176, -0.960035264, 0, -0.279879063, 0, 1, 0, 0.279879063, 0, -0.960035264)
  232. o16.TopSurface = Enum.SurfaceType.Smooth
  233. o16.Color = Color3.new(1, 0, 0)
  234. o16.Position = Vector3.new(-7.48906422, 4.50003004, 87.8374176)
  235. o17.Parent = o16
  236. o17.Scale = Vector3.new(1.25, 1.25, 1.25)
  237. o18.Parent = o16
  238. o18.Texture = "http://www.roblox.com/asset/?id=109676489"
  239. o19.Parent = o1
  240. o19.HeadColor = BrickColor.new("Bright yellow")
  241. o19.LeftArmColor = BrickColor.new("Bright yellow")
  242. o19.LeftLegColor = BrickColor.new("Bright green")
  243. o19.RightArmColor = BrickColor.new("Bright yellow")
  244. o19.RightLegColor = BrickColor.new("Bright green")
  245. o19.TorsoColor = BrickColor.new("Deep blue")
  246. o20.Parent = o1
  247. o20.NameOcclusion = Enum.NameOcclusion.NoOcclusion
  248. o20.RightLeg = o2
  249. o20.LeftLeg = o5
  250. o20.Torso = o7
  251. o20.Health = 500
  252. o20.MaxHealth = 500
  253. o21.Name = "Animate"
  254. o21.Parent = o1
  255. table.insert(cors,coroutine.create(function()
  256. wait()
  257. runDummyScript(function()
  258. local Model = script.Parent
  259. local Backup = Model:clone()
  260.  
  261. function Respawn()
  262. local f=Instance.new("ForceField")
  263. Model:breakJoints()
  264.  
  265. wait(5)
  266.  
  267. script.Parent = Model.Parent
  268.  
  269. Model:remove()
  270. Model = Backup:clone()
  271. Model.Parent = script.Parent
  272. Model:makeJoints()
  273. f.Parent=Model
  274. wait(5)
  275. f.Parent=nil
  276.  
  277. script:remove()
  278. end
  279.  
  280. Model.Humanoid.Died:connect(Respawn)
  281.  
  282. function waitForChild(parent, childName)
  283. local child = parent:findFirstChild(childName)
  284.  
  285. if child then
  286. return child
  287. end
  288.  
  289. while true do
  290. print(childName)
  291.  
  292. child = parent.ChildAdded:wait()
  293.  
  294. if child.Name==childName then
  295. return child
  296. end
  297. end
  298. end
  299.  
  300. -- declarations
  301.  
  302. local Figure = script.Parent
  303. local Head = waitForChild(Figure, "Head")
  304. local Humanoid = waitForChild(Figure, "Humanoid")
  305.  
  306. Figure.PrimaryPart = Head
  307.  
  308. -- ANIMATION
  309.  
  310. function Joint(Name, Part0, Part1, C0, C1, MaxVelocity)
  311. local Motor = Instance.new("Motor")
  312.  
  313. Motor.C0 = C0
  314. Motor.C1 = C1
  315. Motor.MaxVelocity = MaxVelocity
  316. Motor.Name = Name
  317. Motor.Parent = Part0
  318. Motor.Part0 = Part0
  319. Motor.Part1 = Part1
  320. end
  321.  
  322. -- declarations
  323.  
  324. local Torso = waitForChild(Figure, "Torso")
  325. local LeftArm = waitForChild(Figure, "Left Arm")
  326. local LeftLeg = waitForChild(Figure, "Left Leg")
  327. local RightArm = waitForChild(Figure, "Right Arm")
  328. local RightLeg = waitForChild(Figure, "Right Leg")
  329.  
  330. local Joints = {
  331. {"Right Shoulder", Torso, RightArm, CFrame.new(1, 0.5, 0, 0, 0, 1, 0, 1, 0, -1, -0, -0), CFrame.new(-0.5, 0.5, 0, 0, 0, 1, 0, 1, 0, -1, -0, -0), 0.5},
  332. {"Left Shoulder", Torso, LeftArm, CFrame.new(-1, 0.5, 0, -0, -0, -1, 0, 1, 0, 1, 0, 0), CFrame.new(0.5, 0.5, 0, -0, -0, -1, 0, 1, 0, 1, 0, 0), 0.5},
  333. {"Right Hip", Torso, RightLeg, CFrame.new(1, -1, 0, 0, 0, 1, 0, 1, 0, -1, -0, -0), CFrame.new(0.5, 1, 0, 0, 0, 1, 0, 1, 0, -1, -0, -0), 0.10000000149012},
  334. {"Left Hip", Torso, LeftLeg, CFrame.new(-1, -1, 0, -0, -0, -1, 0, 1, 0, 1, 0, 0), CFrame.new(-0.5, 1, 0, -0, -0, -1, 0, 1, 0, 1, 0, 0), 0.10000000149012},
  335. {"Neck", Torso, Head, CFrame.new(0, 1, 0, -1, -0, -0, 0, 0, 1, 0, 1, 0), CFrame.new(0, -0.5, 0, -1, -0, -0, 0, 0, 1, 0, 1, 0), 0.10000000149012}}
  336.  
  337. Torso:breakJoints()
  338.  
  339. for _, v in pairs(Joints) do
  340. Joint(unpack(v))
  341. end
  342.  
  343. local RightShoulder = waitForChild(Torso, "Right Shoulder")
  344. local LeftShoulder = waitForChild(Torso, "Left Shoulder")
  345. local RightHip = waitForChild(Torso, "Right Hip")
  346. local LeftHip = waitForChild(Torso, "Left Hip")
  347. local Neck = waitForChild(Torso, "Neck")
  348. local Humanoid = waitForChild(Figure, "Humanoid")
  349. local pose = "Standing"
  350.  
  351. local toolAnim = "None"
  352. local toolAnimTime = 0
  353.  
  354. -- functions
  355.  
  356. function onRunning(speed)
  357. if speed>0 then
  358. pose = "Running"
  359. else
  360. pose = "Standing"
  361. end
  362. end
  363.  
  364. function onDied()
  365. pose = "Dead"
  366. end
  367.  
  368. function onJumping()
  369. pose = "Jumping"
  370. end
  371.  
  372. function onClimbing()
  373. pose = "Climbing"
  374. end
  375.  
  376. function onGettingUp()
  377. pose = "GettingUp"
  378. end
  379.  
  380. function onFreeFall()
  381. pose = "FreeFall"
  382. end
  383.  
  384. function onFallingDown()
  385. pose = "FallingDown"
  386. end
  387.  
  388. function onSeated()
  389. pose = "Seated"
  390. end
  391.  
  392. function onPlatformStanding()
  393. pose = "PlatformStanding"
  394. end
  395.  
  396. function moveJump()
  397. RightShoulder.MaxVelocity = 0.5
  398. LeftShoulder.MaxVelocity = 0.5
  399. RightShoulder.DesiredAngle = 3.14
  400. LeftShoulder.DesiredAngle = -3.14
  401. RightHip.DesiredAngle = 0
  402. LeftHip.DesiredAngle = 0
  403. end
  404.  
  405.  
  406. -- same as jump for now
  407.  
  408. function moveFreeFall()
  409. RightShoulder.MaxVelocity = 0.5
  410. LeftShoulder.MaxVelocity = 0.5
  411. RightShoulder.DesiredAngle = 3.14
  412. LeftShoulder.DesiredAngle = -3.14
  413. RightHip.DesiredAngle = 0
  414. LeftHip.DesiredAngle = 0
  415. end
  416.  
  417. function moveSit()
  418. RightShoulder.MaxVelocity = 0.15
  419. LeftShoulder.MaxVelocity = 0.15
  420. RightShoulder.DesiredAngle = 3.14 /2
  421. LeftShoulder.DesiredAngle = -3.14 /2
  422. RightHip.DesiredAngle = 3.14 /2
  423. LeftHip.DesiredAngle = -3.14 /2
  424. end
  425.  
  426. function getTool()
  427. for _, kid in ipairs(Figure:GetChildren()) do
  428. if kid.className == "Tool" then return kid end
  429. end
  430. return nil
  431. end
  432.  
  433. function getToolAnim(tool)
  434. for _, c in ipairs(tool:GetChildren()) do
  435. if c.Name == "toolanim" and c.className == "StringValue" then
  436. return c
  437. end
  438. end
  439. return nil
  440. end
  441.  
  442. function animateTool()
  443.  
  444. if (toolAnim == "None") then
  445. RightShoulder.DesiredAngle = 1.57
  446. return
  447. end
  448.  
  449. if (toolAnim == "Slash") then
  450. RightShoulder.MaxVelocity = 0.5
  451. RightShoulder.DesiredAngle = 0
  452. return
  453. end
  454.  
  455. if (toolAnim == "Lunge") then
  456. RightShoulder.MaxVelocity = 0.5
  457. LeftShoulder.MaxVelocity = 0.5
  458. RightHip.MaxVelocity = 0.5
  459. LeftHip.MaxVelocity = 0.5
  460. RightShoulder.DesiredAngle = 1.57
  461. LeftShoulder.DesiredAngle = 1.0
  462. RightHip.DesiredAngle = 1.57
  463. LeftHip.DesiredAngle = 1.0
  464. return
  465. end
  466. end
  467.  
  468. function move(time)
  469. local amplitude
  470. local frequency
  471.  
  472. if (pose == "Jumping") then
  473. moveJump()
  474. return
  475. end
  476.  
  477. if (pose == "FreeFall") then
  478. moveFreeFall()
  479. return
  480. end
  481.  
  482. if (pose == "Seated") then
  483. moveSit()
  484. return
  485. end
  486.  
  487. local climbFudge = 0
  488.  
  489. if (pose == "Running") then
  490. RightShoulder.MaxVelocity = 0.15
  491. LeftShoulder.MaxVelocity = 0.15
  492. amplitude = 1
  493. frequency = 9
  494. elseif (pose == "Climbing") then
  495. RightShoulder.MaxVelocity = 0.5
  496. LeftShoulder.MaxVelocity = 0.5
  497. amplitude = 1
  498. frequency = 9
  499. climbFudge = 3.14
  500. else
  501. amplitude = 0.1
  502. frequency = 1
  503. end
  504.  
  505. desiredAngle = amplitude * math.sin(time*frequency)
  506.  
  507. RightShoulder.DesiredAngle = desiredAngle + climbFudge
  508. LeftShoulder.DesiredAngle = desiredAngle - climbFudge
  509. RightHip.DesiredAngle = -desiredAngle
  510. LeftHip.DesiredAngle = -desiredAngle
  511.  
  512.  
  513. local tool = getTool()
  514.  
  515. if tool then
  516.  
  517. animStringValueObject = getToolAnim(tool)
  518.  
  519. if animStringValueObject then
  520. toolAnim = animStringValueObject.Value
  521. -- message recieved, delete StringValue
  522. animStringValueObject.Parent = nil
  523. toolAnimTime = time + .3
  524. end
  525.  
  526. if time > toolAnimTime then
  527. toolAnimTime = 0
  528. toolAnim = "None"
  529. end
  530.  
  531. animateTool()
  532.  
  533.  
  534. else
  535. toolAnim = "None"
  536. toolAnimTime = 0
  537. end
  538. end
  539.  
  540.  
  541. -- connect events
  542.  
  543. Humanoid.Died:connect(onDied)
  544. Humanoid.Running:connect(onRunning)
  545. Humanoid.Jumping:connect(onJumping)
  546. Humanoid.Climbing:connect(onClimbing)
  547. Humanoid.GettingUp:connect(onGettingUp)
  548. Humanoid.FreeFalling:connect(onFreeFall)
  549. Humanoid.FallingDown:connect(onFallingDown)
  550. Humanoid.Seated:connect(onSeated)
  551. Humanoid.PlatformStanding:connect(onPlatformStanding)
  552.  
  553. -- util
  554.  
  555. function waitForChild(parent, childName)
  556. local child = parent:findFirstChild(childName)
  557. if child then return child end
  558. while true do
  559. child = parent.ChildAdded:wait()
  560. if child.Name==childName then return child end
  561. end
  562. end
  563.  
  564. function newSound(id)
  565. local sound = Instance.new("Sound")
  566. sound.SoundId = id
  567. sound.archivable = false
  568. sound.Parent = script.Parent.Head
  569. return sound
  570. end
  571.  
  572. -- declarations
  573.  
  574. local sDied = newSound("rbxasset://sounds/uuhhh.wav")
  575. local sFallingDown = newSound("rbxasset://sounds/splat.wav")
  576. local sFreeFalling = newSound("rbxasset://sounds/swoosh.wav")
  577. local sGettingUp = newSound("rbxasset://sounds/hit.wav")
  578. local sJumping = newSound("rbxasset://sounds/button.wav")
  579. local sRunning = newSound("rbxasset://sounds/bfsl-minifigfoots1.mp3")
  580. sRunning.Looped = true
  581.  
  582. -- functions
  583.  
  584. function onSoundDied()
  585. sDied:Play()
  586. end
  587.  
  588. function onState(state, sound)
  589. if state then
  590. sound:Play()
  591. else
  592. sound:Pause()
  593. end
  594. end
  595.  
  596. function onSoundRunning(speed)
  597. if speed>0 then
  598. sRunning:Play()
  599. else
  600. sRunning:Pause()
  601. end
  602. end
  603.  
  604. -- connect up
  605.  
  606. Humanoid.Died:connect(onSoundDied)
  607. Humanoid.Running:connect(onSoundRunning)
  608. Humanoid.Jumping:connect(function(state) onState(state, sJumping) end)
  609. Humanoid.GettingUp:connect(function(state) onState(state, sGettingUp) end)
  610. Humanoid.FreeFalling:connect(function(state) onState(state, sFreeFalling) end)
  611. Humanoid.FallingDown:connect(function(state) onState(state, sFallingDown) end)
  612.  
  613. local runService = game:service("RunService");
  614.  
  615. delay(0, function()
  616. while Figure.Parent~=nil do
  617. local _, time = wait(0.1)
  618. move(time)
  619. end
  620. end)
  621.  
  622. -- regeneration
  623. while true do
  624. local s = wait(1)
  625. local health = Humanoid.Health
  626.  
  627. if health > 0 and health < Humanoid.MaxHealth then
  628. health = health + 0.01 * s * Humanoid.MaxHealth
  629.  
  630. if health * 1.05 < Humanoid.MaxHealth then
  631. Humanoid.Health = health
  632. else
  633. Humanoid.Health = Humanoid.MaxHealth
  634. end
  635. end
  636. end
  637. end,o21)
  638. end))
  639. o22.Name = "Sound"
  640. o22.Parent = o1
  641. table.insert(cors,coroutine.create(function()
  642. wait()
  643. runDummyScript(function()
  644. -- util
  645.  
  646. function waitForChild(parent, childName)
  647. local child = parent:findFirstChild(childName)
  648. if child then return child end
  649. while true do
  650. child = parent.ChildAdded:wait()
  651. if child.Name==childName then return child end
  652. end
  653. end
  654.  
  655. function newSound(id)
  656. local sound = Instance.new("Sound")
  657. sound.SoundId = id
  658. sound.archivable = false
  659. sound.Parent = script.Parent.Head
  660. return sound
  661. end
  662.  
  663. -- declarations
  664.  
  665. local sDied = newSound("rbxasset://sounds/uuhhh.wav")
  666. local sFallingDown = newSound("rbxasset://sounds/splat.wav")
  667. local sFreeFalling = newSound("rbxasset://sounds/swoosh.wav")
  668. local sGettingUp = newSound("rbxasset://sounds/hit.wav")
  669. local sJumping = newSound("rbxasset://sounds/button.wav")
  670. local sRunning = newSound("rbxasset://sounds/bfsl-minifigfoots1.mp3")
  671. sRunning.Looped = true
  672.  
  673. local Figure = script.Parent
  674. local Head = waitForChild(Figure, "Head")
  675. local Humanoid = waitForChild(Figure, "Humanoid")
  676.  
  677. -- functions
  678.  
  679. function onDied()
  680. sDied:Play()
  681. end
  682.  
  683. function onState(state, sound)
  684. if state then
  685. sound:Play()
  686. else
  687. sound:Pause()
  688. end
  689. end
  690.  
  691. function onRunning(speed)
  692. if speed>0 then
  693. sRunning:Play()
  694. else
  695. sRunning:Pause()
  696. end
  697. end
  698.  
  699. -- connect up
  700.  
  701. Humanoid.Died:connect(onDied)
  702. Humanoid.Running:connect(onRunning)
  703. Humanoid.Jumping:connect(function(state) onState(state, sJumping) end)
  704. Humanoid.GettingUp:connect(function(state) onState(state, sGettingUp) end)
  705. Humanoid.FreeFalling:connect(function(state) onState(state, sFreeFalling) end)
  706. Humanoid.FallingDown:connect(function(state) onState(state, sFallingDown) end)
  707.  
  708. end,o22)
  709. end))
  710. o23.Name = "Follow"
  711. o23.Parent = o1
  712. table.insert(cors,coroutine.create(function()
  713. wait()
  714. runDummyScript(function()
  715. local larm = script.Parent:FindFirstChild("Left Arm")
  716. local rarm = script.Parent:FindFirstChild("Right Arm")
  717. object=script.Parent["ThatTable"]
  718.  
  719. function findNearestTorso(pos)
  720. local list = game.Workspace:children()
  721. local torso = nil
  722. local dist = 10000
  723. local temp = nil
  724. local human = nil
  725. local temp2 = nil
  726. for x = 1, #list do
  727. temp2 = list[x]
  728. if (temp2.className == "Model") and (temp2 ~= script.Parent) then
  729. temp = temp2:findFirstChild("Torso")
  730. human = temp2:findFirstChild("Humanoid")
  731. if (temp ~= nil) and (human ~= nil) and (human.Health > 0) then
  732. if (temp.Position - pos).magnitude < dist then
  733. torso = temp
  734. dist = (temp.Position - pos).magnitude
  735. end
  736. end
  737. if dist<30 then
  738. script.Parent.Attack.Value=true
  739. script.Parent.Humanoid.WalkSpeed=0.01
  740. else
  741. script.Parent.Attack.Value=false
  742. script.Parent.Humanoid.WalkSpeed=16
  743. end
  744. end
  745. end
  746. return torso
  747. end
  748.  
  749. while true do
  750. wait(0.1)
  751. local target = findNearestTorso(script.Parent.Torso.Position)
  752. if target ~= nil then
  753. script.Parent.Humanoid:MoveTo(target.Position, target)
  754. end
  755. end
  756. end,o23)
  757. end))
  758. o24.Name = "RageTable"
  759. o24.Parent = o1
  760. o24.TextureId = "http://www.roblox.com/asset/?id=111900204"
  761. o24.GripPos = Vector3.new(0, 0, 0.300000012)
  762. o24.ToolTip = "Flip Out"
  763. o25.Name = "Handle"
  764. o25.Parent = o24
  765. o25.Position = Vector3.new(-8.9291172, 1.70003009, 88.2572327)
  766. o25.Rotation = Vector3.new(-90, 0, -163.75)
  767. o25.CanCollide = false
  768. o25.FormFactor = Enum.FormFactor.Custom
  769. o25.Size = Vector3.new(1.20000005, 0.669994831, 0.669994712)
  770. o25.CFrame = CFrame.new(-8.9291172, 1.70003009, 88.2572327, -0.960035264, 0.279879063, 0, 0, 0, 1, 0.279879063, 0.960035264, 0)
  771. o25.BottomSurface = Enum.SurfaceType.Smooth
  772. o25.TopSurface = Enum.SurfaceType.Smooth
  773. o25.Position = Vector3.new(-8.9291172, 1.70003009, 88.2572327)
  774. o26.Parent = o25
  775. o26.MeshId = "http://www.roblox.com/asset/?id=111868131"
  776. o26.Scale = Vector3.new(0.200000003, 0.200000003, 0.200000003)
  777. o26.TextureId = "http://www.roblox.com/asset/?id=111867655"
  778. o26.MeshType = Enum.MeshType.FileMesh
  779. o27.Parent = o25
  780. o27.SoundId = "http://www.roblox.com/asset/?id=111896685"
  781. o27.Volume = 1
  782. o28.Parent = o24
  783. table.insert(cors,coroutine.create(function()
  784. wait()
  785. runDummyScript(function()
  786. function FindAttachedHumanoid(part)
  787. local tpart = part
  788. while tpart.Parent do
  789. if tpart.Parent:FindFirstChild('Humanoid') then return tpart.Parent.Humanoid end
  790. tpart = tpart.Parent
  791. end
  792. return nil
  793. end
  794.  
  795. function MakeValue(class,name,value,parent)
  796. local temp = Instance.new(class)
  797. temp.Name = name
  798. temp.Value = value
  799. temp.Parent = parent
  800. return temp
  801. end
  802.  
  803. local Tool = script.Parent
  804. local Handle = Tool:WaitForChild('Handle')
  805. local YellSound = Handle:WaitForChild('Sound')
  806. local AniScript = Tool:WaitForChild('AnimationPlayerScript')
  807. --http://www.roblox.com/Asset?ID=111898513'--http://www.roblox.com/Asset?ID=111880514'
  808. local ThrowAnimation = 'http://www.roblox.com/Asset?ID=111898867'
  809.  
  810. local ThrowFace = 'http://www.roblox.com/asset?id=111882478'
  811.  
  812. local ThrowTable= Instance.new('Part')
  813. do
  814. --ThrowTable.Shape = 'Ball'
  815. ThrowTable.FormFactor='Custom'
  816. ThrowTable.Size = Vector3.new(4.8, 2.43, 3.63)
  817. ThrowTable.CanCollide = true
  818. ThrowTable.Name="ThrownTable"
  819. local tmesh = Instance.new('SpecialMesh')
  820. tmesh.MeshId = 'http://www.roblox.com/asset/?id=111868131'
  821. tmesh.TextureId = 'http://www.roblox.com/asset/?id=111867655'
  822. tmesh.Parent = ThrowTable
  823. end
  824.  
  825. local LookGyro= Instance.new('BodyGyro')
  826. LookGyro.maxTorque = Vector3.new(0,math.huge,0)
  827.  
  828. local ActivateLock=false
  829.  
  830. function onActivated()
  831. Tool.Parent.Follow.Disabled=true
  832. if ActivateLock then return end
  833. ActivateLock = true
  834. local character = Tool.Parent
  835. local humanoid = character:WaitForChild('Humanoid')
  836. local torso = character:WaitForChild('Torso')
  837. local head = character:WaitForChild('Head')
  838. local face = head:FindFirstChild('face')
  839. local oldFace =''
  840. if face then oldFace = face.Texture end
  841. humanoid.WalkSpeed = 0
  842. LookGyro.cframe = torso.CFrame - torso.CFrame.p
  843. LookGyro.Parent = torso
  844.  
  845. local ntable = ThrowTable:Clone()
  846. ntable.CFrame = torso.CFrame+(torso.CFrame.lookVector*3)
  847. ntable.Parent = Workspace
  848.  
  849. MakeValue('StringValue','aniId',ThrowAnimation,AniScript)
  850. wait(.5)
  851. YellSound:play()
  852. wait(.5)
  853. if face then
  854. face.Texture=ThrowFace
  855. end
  856.  
  857.  
  858.  
  859. local bAVel = Instance.new('BodyAngularVelocity')
  860. bAVel.maxTorque = Vector3.new(math.huge,math.huge,math.huge)
  861. bAVel.angularvelocity = ((torso.CFrame*CFrame.Angles(0,math.pi/2,0)).lookVector*10)
  862. bAVel.Parent = ntable
  863.  
  864. local bVel = Instance.new('BodyVelocity')
  865. bVel.maxForce = Vector3.new(math.huge,0,math.huge)
  866. bVel.velocity = (torso.CFrame.lookVector*25)
  867. bVel.Parent = ntable
  868.  
  869. ntable.Touched:connect(function(part)
  870. --print('GotTouched:' .. part.Name)
  871. Spawn(function()
  872. if part.Name == 'Terrain' then return end
  873. if part.Anchored then return end
  874. local hitHumanoid = FindAttachedHumanoid(part)
  875. if hitHumanoid then
  876. --print('HumanoidParent:'..hitHumanoid.Parent.Name)
  877. if hitHumanoid==humanoid then return end
  878. hitHumanoid.PlatformStand =true
  879. end
  880. if part.Size.x*part.Size.y*part.Size.z<=5*9*5 then
  881. part.Velocity = (Vector3.new((math.random()-.5)*2,math.random(),(math.random()-.5)*2).unit)*150
  882. end
  883. wait(3)
  884. print('got past wait')
  885. if hitHumanoid then
  886. print('unplatformstanding')
  887. hitHumanoid.PlatformStand=false
  888. hitHumanoid.Jump = true
  889. end
  890. end)
  891. end)
  892. Tool.Parent.ThatTable.Value=ThrowTable
  893.  
  894. wait(6)
  895. LookGyro.Parent = nil
  896. humanoid.WalkSpeed = 16
  897. Tool.Parent.Attack.Value=false
  898. Tool.Parent.Follow.Disabled=false
  899. if face then
  900. face.Texture=oldFace
  901. end
  902. ntable.CanCollide = false
  903. game.Debris:AddItem(ntable,5)
  904. ActivateLock = false
  905. end
  906.  
  907. while true do
  908. wait(1)
  909. if Tool.Parent.Attack.Value==true then
  910. onActivated()
  911. end
  912. end
  913. end,o28)
  914. end))
  915. o30.Name = "AnimationPlayerScript"
  916. o30.Parent = o24
  917. table.insert(cors,coroutine.create(function()
  918. wait()
  919. runDummyScript(function()
  920. function FindAttachedHumanoid(part)
  921. local tpart = part
  922. while tpart.Parent do
  923. if tpart.Parent:FindFirstChild('Humanoid') then return tpart.Parent.Humanoid end
  924. tpart = tpart.Parent
  925. end
  926. return nil
  927. end
  928.  
  929. script.ChildAdded:connect(function(nchild)
  930. local humanoid = FindAttachedHumanoid(script)
  931. local ani = Instance.new('Animation')
  932. ani.AnimationId= nchild.Value
  933. local aniTrack=humanoid:LoadAnimation(ani)
  934. aniTrack:Play()
  935. end)
  936. end,o30)
  937. end))
  938. o31.Name = "aniId"
  939. o31.Parent = o30
  940. o32.Name = "aniId"
  941. o32.Parent = o30
  942. o32.Value = "http://www.roblox.com/Asset?ID=111898867"
  943. o33.Name = "aniId"
  944. o33.Parent = o30
  945. o33.Value = "http://www.roblox.com/Asset?ID=111898867"
  946. o34.Name = "aniId"
  947. o34.Parent = o30
  948. o34.Value = "http://www.roblox.com/Asset?ID=111898867"
  949. o35.Name = "aniId"
  950. o35.Parent = o30
  951. o35.Value = "http://www.roblox.com/Asset?ID=111898867"
  952. o36.Name = "aniId"
  953. o36.Parent = o30
  954. o36.Value = "http://www.roblox.com/Asset?ID=111898867"
  955. o37.Name = "aniId"
  956. o37.Parent = o30
  957. o37.Value = "http://www.roblox.com/Asset?ID=111898867"
  958. o38.Name = "aniId"
  959. o38.Parent = o30
  960. o38.Value = "http://www.roblox.com/Asset?ID=111898867"
  961. o39.Name = "aniId"
  962. o39.Parent = o30
  963. o39.Value = "http://www.roblox.com/Asset?ID=111898867"
  964. o40.Name = "aniId"
  965. o40.Parent = o30
  966. o40.Value = "http://www.roblox.com/Asset?ID=111898867"
  967. o41.Name = "aniId"
  968. o41.Parent = o30
  969. o41.Value = "http://www.roblox.com/Asset?ID=111898867"
  970. o42.Name = "aniId"
  971. o42.Parent = o30
  972. o42.Value = "http://www.roblox.com/Asset?ID=111898867"
  973. o43.Name = "aniId"
  974. o43.Parent = o30
  975. o43.Value = "http://www.roblox.com/Asset?ID=111898867"
  976. o44.Name = "aniId"
  977. o44.Parent = o30
  978. o44.Value = "http://www.roblox.com/Asset?ID=111898867"
  979. o45.Name = "aniId"
  980. o45.Parent = o30
  981. o45.Value = "http://www.roblox.com/Asset?ID=111898867"
  982. o46.Name = "aniId"
  983. o46.Parent = o30
  984. o46.Value = "http://www.roblox.com/Asset?ID=111898867"
  985. o47.Name = "aniId"
  986. o47.Parent = o30
  987. o47.Value = "http://www.roblox.com/Asset?ID=111898867"
  988. o48.Name = "aniId"
  989. o48.Parent = o30
  990. o48.Value = "http://www.roblox.com/Asset?ID=111898867"
  991. o49.Name = "aniId"
  992. o49.Parent = o30
  993. o49.Value = "http://www.roblox.com/Asset?ID=111898867"
  994. o50.Name = "aniId"
  995. o50.Parent = o30
  996. o50.Value = "http://www.roblox.com/Asset?ID=111898867"
  997. o51.Name = "aniId"
  998. o51.Parent = o30
  999. o51.Value = "http://www.roblox.com/Asset?ID=111898867"
  1000. o52.Name = "aniId"
  1001. o52.Parent = o30
  1002. o52.Value = "http://www.roblox.com/Asset?ID=111898867"
  1003. o53.Name = "aniId"
  1004. o53.Parent = o30
  1005. o53.Value = "http://www.roblox.com/Asset?ID=111898867"
  1006. o54.Name = "aniId"
  1007. o54.Parent = o30
  1008. o54.Value = "http://www.roblox.com/Asset?ID=111898867"
  1009. o55.Name = "aniId"
  1010. o55.Parent = o30
  1011. o55.Value = "http://www.roblox.com/Asset?ID=111898867"
  1012. o56.Name = "aniId"
  1013. o56.Parent = o30
  1014. o56.Value = "http://www.roblox.com/Asset?ID=111898867"
  1015. o57.Name = "aniId"
  1016. o57.Parent = o30
  1017. o57.Value = "http://www.roblox.com/Asset?ID=111898867"
  1018. o58.Name = "aniId"
  1019. o58.Parent = o30
  1020. o58.Value = "http://www.roblox.com/Asset?ID=111898867"
  1021. o59.Name = "aniId"
  1022. o59.Parent = o30
  1023. o59.Value = "http://www.roblox.com/Asset?ID=111898867"
  1024. o60.Name = "aniId"
  1025. o60.Parent = o30
  1026. o60.Value = "http://www.roblox.com/Asset?ID=111898867"
  1027. o61.Name = "aniId"
  1028. o61.Parent = o30
  1029. o61.Value = "http://www.roblox.com/Asset?ID=111898867"
  1030. o62.Name = "aniId"
  1031. o62.Parent = o30
  1032. o62.Value = "http://www.roblox.com/Asset?ID=111898867"
  1033. o63.Name = "aniId"
  1034. o63.Parent = o30
  1035. o63.Value = "http://www.roblox.com/Asset?ID=111898867"
  1036. o64.Name = "aniId"
  1037. o64.Parent = o30
  1038. o64.Value = "http://www.roblox.com/Asset?ID=111898867"
  1039. o65.Name = "aniId"
  1040. o65.Parent = o30
  1041. o65.Value = "http://www.roblox.com/Asset?ID=111898867"
  1042. o66.Name = "aniId"
  1043. o66.Parent = o30
  1044. o66.Value = "http://www.roblox.com/Asset?ID=111898867"
  1045. o67.Name = "aniId"
  1046. o67.Parent = o30
  1047. o67.Value = "http://www.roblox.com/Asset?ID=111898867"
  1048. o68.Name = "aniId"
  1049. o68.Parent = o30
  1050. o68.Value = "http://www.roblox.com/Asset?ID=111898867"
  1051. o69.Name = "aniId"
  1052. o69.Parent = o30
  1053. o69.Value = "http://www.roblox.com/Asset?ID=111898867"
  1054. o70.Name = "aniId"
  1055. o70.Parent = o30
  1056. o70.Value = "http://www.roblox.com/Asset?ID=111898867"
  1057. o71.Name = "aniId"
  1058. o71.Parent = o30
  1059. o71.Value = "http://www.roblox.com/Asset?ID=111898867"
  1060. o72.Name = "aniId"
  1061. o72.Parent = o30
  1062. o72.Value = "http://www.roblox.com/Asset?ID=111898867"
  1063. o73.Name = "aniId"
  1064. o73.Parent = o30
  1065. o73.Value = "http://www.roblox.com/Asset?ID=111898867"
  1066. o74.Name = "aniId"
  1067. o74.Parent = o30
  1068. o74.Value = "http://www.roblox.com/Asset?ID=111898867"
  1069. o75.Name = "aniId"
  1070. o75.Parent = o30
  1071. o75.Value = "http://www.roblox.com/Asset?ID=111898867"
  1072. o76.Name = "aniId"
  1073. o76.Parent = o30
  1074. o76.Value = "http://www.roblox.com/Asset?ID=111898867"
  1075. o77.Name = "aniId"
  1076. o77.Parent = o30
  1077. o77.Value = "http://www.roblox.com/Asset?ID=111898867"
  1078. o78.Name = "aniId"
  1079. o78.Parent = o30
  1080. o78.Value = "http://www.roblox.com/Asset?ID=111898867"
  1081. o79.Name = "aniId"
  1082. o79.Parent = o30
  1083. o79.Value = "http://www.roblox.com/Asset?ID=111898867"
  1084. o80.Name = "aniId"
  1085. o80.Parent = o30
  1086. o80.Value = "http://www.roblox.com/Asset?ID=111898867"
  1087. o81.Name = "aniId"
  1088. o81.Parent = o30
  1089. o81.Value = "http://www.roblox.com/Asset?ID=111898867"
  1090. o82.Name = "aniId"
  1091. o82.Parent = o30
  1092. o82.Value = "http://www.roblox.com/Asset?ID=111898867"
  1093. o83.Name = "aniId"
  1094. o83.Parent = o30
  1095. o83.Value = "http://www.roblox.com/Asset?ID=111898867"
  1096. o84.Name = "aniId"
  1097. o84.Parent = o30
  1098. o84.Value = "http://www.roblox.com/Asset?ID=111898867"
  1099. o85.Name = "aniId"
  1100. o85.Parent = o30
  1101. o85.Value = "http://www.roblox.com/Asset?ID=111898867"
  1102. o86.Name = "aniId"
  1103. o86.Parent = o30
  1104. o86.Value = "http://www.roblox.com/Asset?ID=111898867"
  1105. o87.Name = "aniId"
  1106. o87.Parent = o30
  1107. o87.Value = "http://www.roblox.com/Asset?ID=111898867"
  1108. o88.Name = "Attack"
  1109. o88.Parent = o1
  1110. o89.Name = "ThatTable"
  1111. o89.Parent = o1
  1112. mas.Parent = workspace
  1113. mas:MakeJoints()
  1114. local mas1 = mas:GetChildren()
  1115. for i=1,#mas1 do
  1116. mas1[i].Parent = workspace
  1117. ypcall(function() mas1[i]:MakeJoints() end)
  1118. end
  1119. mas:Destroy()
  1120. for i=1,#cors do
  1121. coroutine.resume(cors[i])
  1122. end
  1123.  
  1124. game:GetService("Lighting").Ambient = Color3.new(0, 0, 0)
  1125. game:GetService("Lighting").Brightness = 1
  1126. game:GetService("Lighting").ColorShift_Bottom = Color3.new(0, 0, 0)
  1127. game:GetService("Lighting").ColorShift_Top = Color3.new(0, 0, 0)
  1128. game:GetService("Lighting").GlobalShadows = true
  1129. game:GetService("Lighting").OutdoorAmbient = Color3.new(0.5, 0.5, 0.5)
  1130. game:GetService("Lighting").Outlines = false
  1131. game:GetService("Lighting").GeographicLatitude = 41.733299255371
  1132. game:GetService("Lighting").TimeOfDay = "14:00:00"
  1133. game:GetService("Lighting").FogColor = Color3.new(0.75, 0.75, 0.75)
  1134. game:GetService("Lighting").FogEnd = 100000
  1135. game:GetService("Lighting").FogStart = 0
Add Comment
Please, Sign In to add comment