assholeIhateyou

Untitled

Jun 27th, 2017
47
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 22.12 KB | None | 0 0
  1. --Remember, This is local so say Create/1/local!
  2. --Made by ic3w0lf589
  3. --Don't ask 4 this script
  4.  
  5.  
  6. Players = game:GetService("Players")
  7. Me = Players.LocalPlayer
  8. Char = Me.Character
  9. Neck0 = CFrame.new(0, 1, 0, -1, -0, -0, 0, 0, 1, 0, 1, 0)
  10. Neck1 = CFrame.new(0, -0.5, 0, -1, -0, -0, 0, 0, 1, 0, 1, 0)
  11. Selected = false
  12. Attacking = false
  13. Running = false
  14. Debounce = true
  15. Hurt = false
  16. ModelName = "Weapon"
  17. ToolName = "Weapon"
  18. Speed = 25
  19. Attacks = {"q", "e"}
  20. Find = function(tab, arg)
  21. for _,v in pairs(tab) do
  22. if v==arg then
  23. return true
  24. end
  25. end
  26. return false
  27. end
  28. ContentProvider = game:GetService("ContentProvider")
  29. V3 = Vector3.new
  30. C3 = Color3.new
  31. BN = BrickColor.new
  32. CN = CFrame.new
  33. CA = CFrame.Angles
  34. MR = math.rad
  35. MRA = math.random
  36. MP = math.pi
  37. MH = math.huge
  38. UD = UDim2.new
  39. function RC(Pos, Dir, Max, Ignore)
  40. return workspace:FindPartOnRay(Ray.new(Pos, Dir.unit * (Max or 999)), Ignore)
  41. end
  42. function RayC(Start, En, MaxDist, Ignore)
  43. return RC(Start, (En - Start), MaxDist, Ignore)
  44. end
  45. function ComputePos(pos1, pos2)
  46. return CN(pos1, V3(pos2.x, pos1.y, pos2.z))
  47. end
  48. function DetectSurface(pos, part)
  49. local surface = nil
  50. local pospos = part.CFrame
  51. local pos2 = pospos:pointToObjectSpace(pos)
  52. local siz = part.Size
  53. local shaep = part.Shape
  54. if shaep == Enum.PartType.Ball or shaep == Enum.PartType.Cylinder then
  55. surface = {"Anything", CN(pospos.p, pos)*CN(0, 0, -(pospos.p - pos).magnitude)*CA(MR(-90), 0, 0)}
  56. else
  57. if pos2.Y > ((siz.Y/2)-0.04) then
  58. surface = {"Top", CA(0, 0, 0)}
  59. elseif pos2.Y < -((siz.Y/2)-0.04) then
  60. surface = {"Bottom", CA(-MP, 0, 0)}
  61. elseif pos2.X > ((siz.X/2)-0.04) then
  62. surface = {"Right", CA(0, 0, MR(-90))}
  63. elseif pos2.X < -((siz.X/2)-0.04) then
  64. surface = {"Left", CA(0, 0, MR(90))}
  65. elseif pos2.Z > ((siz.Z/2)-0.04) then
  66. surface = {"Back", CA(MR(90), 0, 0)}
  67. elseif pos2.Z < -((siz.Z/2)-0.04) then
  68. surface = {"Front", CA(MR(-90), 0, 0)}
  69. end
  70. end
  71. return surface
  72. end
  73. function Compute(pos1, pos2)
  74. local pos3 = Vector3.new(pos2.x, pos1.y, pos2.z)
  75. return CN(pos1, pos3)
  76. end
  77. function waitChild(n, p)
  78. local c = p:findFirstChild(n)
  79. if c then return c end
  80. while true do
  81. c = p.ChildAdded:wait()
  82. if c.Name == n then return c end
  83. end
  84. end
  85. function Notime(func)
  86. coroutine.resume(coroutine.create(function()
  87. func()
  88. end))
  89. end
  90. Torso = waitChild("Torso", Char)
  91. Head = waitChild("Head", Char)
  92. Rarm = waitChild("Right Arm", Char)
  93. Larm = waitChild("Left Arm", Char)
  94. Rleg = waitChild("Right Leg", Char)
  95. Lleg = waitChild("Left Leg", Char)
  96. Neck = waitChild("Neck", Torso)
  97. Hum = waitChild("Humanoid", Char)
  98. RSH = waitChild("Right Shoulder", Torso)
  99. LSH = waitChild("Left Shoulder", Torso)
  100. RH = waitChild("Right Hip", Torso)
  101. LH = waitChild("Left Hip", Torso)
  102. RSH.Part0 = Torso
  103. LSH.Part0 = Torso
  104. RH.Part0 = Torso
  105. LH.Part0 = Torso
  106. Add = {
  107. Mesh = function(P, Type, ID, Scale, Tex)
  108. local m = Instance.new("SpecialMesh")
  109. m.MeshType = Type or "Head"
  110. m.MeshId = ID or ""
  111. m.Scale = Scale or V3(1, 1, 1)
  112. m.TextureId = Tex or ""
  113. m.Parent = P
  114. return m
  115. end,
  116. Cylinder = function(P, Scale)
  117. local m = Instance.new("CylinderMesh")
  118. m.Scale = Scale or V3(1, 1, 1)
  119. m.Parent = P
  120. return m
  121. end,
  122. Block = function(P, Scale)
  123. local m = Instance.new("BlockMesh")
  124. m.Scale = Scale or V3(1, 1, 1)
  125. m.Parent = P
  126. return m
  127. end,
  128. BP = function(P, Pos, Power)
  129. local bp = Instance.new("BodyPosition")
  130. bp.P = Power
  131. bp.position = Pos
  132. bp.maxForce = V3(MH, MH, MH)
  133. bp.Parent = P
  134. return bp
  135. end,
  136. }
  137. Sounds = {
  138. Shoot = {Id = "http://www.roblox.com/asset/?id=2697431", Pitch = 0.3, Volume = 0.5},
  139. Boom = {Id = "http://www.roblox.com/asset/?id=2692806", Pitch = 0.55, Volume = 0.4},
  140. Slash = {Id = "rbxasset://sounds//swordslash.wav", Pitch = 0.5, Volume = 0.5},
  141. Hit = {Id = "http://www.roblox.com/asset/?id=2801263", Pitch = 0.85, Volume = 0.35},
  142. Reload = {Id = "rbxasset://sounds\\metal.ogg", Pitch = 1, Volume = 0.45},
  143. }
  144. for _,v in pairs(Sounds) do
  145. ContentProvider:Preload(v.Id)
  146. end
  147. function PlaySound(Sound, l)
  148. local s = Instance.new("Sound")
  149. s.Looped = false
  150. s.Volume = Sound.Volume
  151. s.SoundId = Sound.Id
  152. if l then
  153. s.Pitch = MRA((Sound.Pitch*0.75)*1000, (Sound.Pitch*1.15)*1000)/1000
  154. else
  155. s.Pitch = Sound.Pitch
  156. end
  157. s.PlayOnRemove = true
  158. s.Parent = Torso
  159. Notime(function()
  160. wait()
  161. s.Parent = nil
  162. end)
  163. end
  164. function GetParts(pos, dist)
  165. local parts = {}
  166. local function o(p)
  167. for _,v in pairs(p:children()) do
  168. if v:IsA("BasePart") then
  169. if (pos - v.Position).magnitude <= dist then
  170. table.insert(parts, {v, (pos - v.Position).magnitude, v.Anchored})
  171. end
  172. end
  173. o(v)
  174. end
  175. end
  176. o(workspace)
  177. return parts
  178. end
  179. function GetHum(P)
  180. for _,v in pairs(P:children()) do
  181. if v:IsA("Humanoid") then
  182. if v.Health > 0 then
  183. return v
  184. end
  185. end
  186. end
  187. end
  188. function GetGroup(Pos, Distance, Hit)
  189. local tab = {}
  190. for _,v in pairs(workspace:children()) do
  191. local h = GetHum(v)
  192. local t = v:findFirstChild("Torso")
  193. if h and t and v ~= Hit.Parent then
  194. if (t.Position - Pos).magnitude <= Distance then
  195. table.insert(tab, {h, v, (t.Position - Pos).magnitude})
  196. end
  197. end
  198. end
  199. if Hit then
  200. local h = GetHum(Hit.Parent)
  201. if h then
  202. table.insert(tab, {h, Hit.Parent, 0})
  203. end
  204. end
  205. return tab
  206. end
  207. function Part(Par, Anc, Colli, Tran, Ref, Col, Siz)
  208. local p = Instance.new("Part")
  209. p.formFactor = "Custom"
  210. p.TopSurface = 0
  211. p.BottomSurface = 0
  212. p.Transparency = Tran
  213. p.Reflectance = Ref
  214. p.Anchored = Anc
  215. p.CanCollide = Colli
  216. p.BrickColor = Col
  217. p.Size = Siz
  218. p.Locked = true
  219. p.Parent = Par
  220. p:BreakJoints()
  221. return p
  222. end
  223. function Weld(P0, P1, C0, C1)
  224. local w = Instance.new("Weld")
  225. w.Part0 = P0
  226. w.Part1 = P1
  227. if C0 then
  228. w.C0 = C0
  229. end
  230. if C1 then
  231. w.C1 = C1
  232. end
  233. w.Parent = P0
  234. return w
  235. end
  236. for _,v in pairs(Char:children()) do
  237. if v.Name == ModelName then
  238. v:remove()
  239. end
  240. end
  241. Model = Instance.new("Model")
  242. Model.Name = ModelName
  243. FTorso = Part(Model, false, false, 1, 0, Torso.BrickColor, V3(2, 2, 1))
  244. FW = Weld(Torso, FTorso)
  245. RAB = Part(Model, false, false, 1, 0, BN("White"), V3(0.2, 0.2, 0.2))
  246. LAB = Part(Model, false, false, 1, 0, BN("White"), V3(0.2, 0.2, 0.2))
  247. RLB = Part(Model, false, false, 1, 0, BN("White"), V3(0.2, 0.2, 0.2))
  248. LLB = Part(Model, false, false, 1, 0, BN("White"), V3(0.2, 0.2, 0.2))
  249. RABW = Weld(Torso, RAB, CN(), CN(-1.5, -0.5, 0))
  250. LABW = Weld(Torso, LAB, CN(), CN(1.5, -0.5, 0))
  251. RLBW = Weld(Torso, RLB, CN(), CN(-0.5, 1, 0))
  252. LLBW = Weld(Torso, LLB, CN(), CN(0.5, 1, 0))
  253. RAW = Weld(RAB, nil, CN(), CN(0, 0.5, 0))
  254. LAW = Weld(LAB, nil, CN(), CN(0, 0.5, 0))
  255. RLW = Weld(RLB, nil, CN(), CN(0, 1, 0))
  256. LLW = Weld(LLB, nil, CN(), CN(0, 1, 0))
  257. FNeck = Weld(FTorso, nil, CN(0, 1, 0, -1, -0, -0, 0, 0, 1, 0, 1, 0), CN(0, -0.5, 0, -1, -0, -0, 0, 0, 1, 0, 1, 0))
  258. TW = Weld(Torso, nil, CN(0.7, 0.8, 1.2), CA(0, MR(180), MR(55)))
  259. Weapon = Instance.new("Model")
  260. Weapon.Name = "Weapon"
  261. HBR = Part(Weapon, false, false, 1, 0, BN("White"), V3(0.2, 0.2, 0.2))
  262. HBWR = Weld(Rarm, HBR, CN(0, -0.9, 0), CA(MR(90), 0, 0))
  263. HWR = Weld(HBR, nil)
  264. HBL = Part(Weapon, false, false, 1, 0, BN("White"), V3(0.2, 0.2, 0.2))
  265. HBWL = Weld(Larm, HBL, CN(0, -0.9, 0), CA(MR(90), 0, 0))
  266. HWL = Weld(HBL, nil)
  267. Limbs = {Rarm = {RAW, Rarm}, Larm = {LAW, Larm}, Rleg = {RLW, Rleg}, Lleg = {LLW, Lleg}, }
  268. function Atta(Lol)
  269. Lol[1].Part1 = Lol[2]
  270. end
  271. function MakeKnife(Arm)
  272. local Parts = {}
  273. local Handle = Part(Weapon, false, false, 0, 0, BN("Navy blue"), V3(0.35, 1.1, 0.35))
  274. local Derp = Part(Weapon, false, false, 0, 0, BN("Really black"), V3(0.6, 0.2, 0.6))
  275. local Blade1 = Part(Weapon, false, false, 0, 0, BN("Deep orange"), V3(0.2, 0.5, 0.3))
  276. local Blade2 = Part(Weapon, false, false, 0, 0, BN("Deep orange"), V3(0.2, 0.4, 0.4))
  277. local Blade3 = Part(Weapon, false, false, 0, 0, BN("Deep orange"), V3(0.2, 0.8, 0.4))
  278. local Blade4 = Part(Weapon, false, false, 0, 0, BN("Deep orange"), V3(0.2, 0.7, 0.4))
  279. Add.Mesh(Handle)
  280. Add.Cylinder(Derp)
  281. Add.Block(Blade1)
  282. Add.Block(Blade2)
  283. Add.Block(Blade3)
  284. Add.Mesh(Blade4, "Wedge")
  285. Arm.Part1 = Handle
  286. Weld(Handle, Derp, CN(0, -0.5, 0))
  287. Weld(Derp, Blade1, CN(0, -0.25, 0))
  288. Weld(Blade1, Blade2, CN(0, -0.25, -0.04), CA(MR(5), 0, 0))
  289. Weld(Blade2, Blade3, CN(0, -0.55, 0.08), CA(MR(12), 0, 0))
  290. Weld(Blade3, Blade4, CN(0, -0.68, 0.075), CA(MR(-15)+MP, MP, 0))
  291. Parts.Handle = Handle
  292. Parts.Derp = Derp
  293. Parts.Blades = {Blade1, Blade2, Blade3, Blade4}
  294. return Parts
  295. end
  296. MakeKnife(HWR)
  297. MakeKnife(HWL)
  298. function Show_Damage(P, D)
  299. local mo = Instance.new("Model")
  300. mo.Name = D
  301. local p = Part(mo, false, false, 0, 0, BN("Bright red"), V3(0.2, 0.2, 0.2))
  302. p.Name = "Head"
  303. local m = Instance.new("SpecialMesh")
  304. m.MeshType = "Brick"
  305. m.Scale = Vector3.new(4.5, 2.3, 4.5)
  306. m.Parent = p
  307. local bp = Instance.new("BodyPosition", p)
  308. bp.maxForce = V3(MH, MH, MH)
  309. bp.P = 9001
  310. bp.position = CN(P) * CN(0, 1.5, 0).p
  311. local h = Instance.new("Humanoid")
  312. h.Health = 0
  313. h.MaxHealth = 0
  314. h.Name = "asd"
  315. h.Parent = mo
  316. local nah = true
  317. mo.Parent = workspace
  318. p.CFrame = CN(P)
  319. Notime(function()
  320. wait(1.5)
  321. for i = 0, 1, 0.05 do
  322. p.Transparency = i
  323. if nah then mo.Name = "" nah = false else mo.Name = "- "..D nah = true end
  324. wait()
  325. end
  326. mo:remove()
  327. end)
  328. end
  329. Weapon.Parent = Model
  330. Model.Parent = Char
  331. if script.Parent.className ~= "HopperBin" then
  332. h = Instance.new("HopperBin", Me.Backpack)
  333. h.Name = ToolName
  334. script.Parent = h
  335. end
  336. bin = script.Parent
  337. function Attach(t)
  338. RSH.Part0 = t
  339. LSH.Part0 = t
  340. RH.Part0 = t
  341. LH.Part0 = t
  342. RABW.Part0 = t
  343. LABW.Part0 = t
  344. LLBW.Part0 = t
  345. RLBW.Part0 = t
  346. if t == Torso then
  347. FTorso.Transparency = 1
  348. FNeck.Part1 = nil
  349. else
  350. Torso.Transparency = 1
  351. FNeck.Part1 = Head
  352. end
  353. t.Transparency = 0
  354. end
  355. function Idle()
  356. local SpeedAtm = Torso.Velocity.magnitude
  357. for i = 0.02, 1, 0.03 do
  358. SpeedAtm = Torso.Velocity.magnitude
  359. if Attacking == true or Selected == false or SpeedAtm > 0.1 then return end
  360. RAW.C0 = CA(MR(-15-6*i), MR(20-2*i), MR(20-3*i))
  361. LAW.C0 = CA(MR(-15-4*i), MR(-20+3*i), MR(-20+4*i))
  362. RLW.C0 = CA(MR(15+4*i), 0, 0) * CN(0.02, 0.4+0.05*i, -0.75)
  363. LLW.C0 = CA(MR(-50-5*i), 0, 0) * CN(-0.02, 0.45, -0.5)
  364. FW.C0 = CN(0, -0.5-0.1*i, 0) * CA(MR(-10-4*i), 0, 0)
  365. FNeck.C0 = Neck0 * CA(MR(20+4*i), 0, 0)
  366. wait()
  367. end
  368. for i = 0.05, 1, 0.05 do
  369. SpeedAtm = Torso.Velocity.magnitude
  370. if Attacking == true or Selected == false or SpeedAtm > 0.1 then return end
  371. RAW.C0 = CA(MR(-21-2*i), MR(18-1*i), MR(17-1*i))
  372. LAW.C0 = CA(MR(-19-1*i), MR(-17+1*i), MR(-16+1*i))
  373. RLW.C0 = CA(MR(19+1*i), 0, 0) * CN(0.02, 0.45+0.02*i, -0.75)
  374. LLW.C0 = CA(MR(-55-2*i), 0, 0) * CN(-0.02, 0.45, -0.5)
  375. FW.C0 = CN(0, -0.6-0.025*i, 0) * CA(MR(-14-1*i), 0, 0)
  376. FNeck.C0 = Neck0 * CA(MR(24+1*i), 0, 0)
  377. wait()
  378. end
  379. for i = 0.04, 1, 0.04 do
  380. SpeedAtm = Torso.Velocity.magnitude
  381. if Attacking == true or Selected == false or SpeedAtm > 0.1 then return end
  382. RAW.C0 = CA(MR(-23+2*i), MR(17+1*i), MR(16+1*i))
  383. LAW.C0 = CA(MR(-20+1*i), MR(-16-1*i), MR(-15-1*i))
  384. RLW.C0 = CA(MR(20-1*i), 0, 0) * CN(0.02, 0.47-0.02*i, -0.75)
  385. LLW.C0 = CA(MR(-57+2*i), 0, 0) * CN(-0.02, 0.45, -0.5)
  386. FW.C0 = CN(0, -0.625+0.025*i, 0) * CA(MR(-15+1*i), 0, 0)
  387. FNeck.C0 = Neck0 * CA(MR(25-1*i), 0, 0)
  388. wait()
  389. end
  390. for i = 0.03, 1, 0.03 do
  391. SpeedAtm = Torso.Velocity.magnitude
  392. if Attacking == true or Selected == false or SpeedAtm > 0.1 then return end
  393. RAW.C0 = CA(MR(-21+4*i), MR(18+2*i), MR(17+2*i))
  394. LAW.C0 = CA(MR(-19+2*i), MR(-17-3*i), MR(-16-3*i))
  395. RLW.C0 = CA(MR(19-3*i), 0, 0) * CN(0.02, 0.45-0.05*i, -0.75)
  396. LLW.C0 = CA(MR(-55+4*i), 0, 0) * CN(-0.02, 0.45, -0.5)
  397. FW.C0 = CN(0, -0.6+0.06*i, 0) * CA(MR(-14+3*i), 0, 0)
  398. FNeck.C0 = Neck0 * CA(MR(24-3*i), 0, 0)
  399. wait()
  400. end
  401. for i = 0.07, 1, 0.07 do
  402. SpeedAtm = Torso.Velocity.magnitude
  403. if Attacking == true or Selected == false or SpeedAtm >= 0.1 then return end
  404. RAW.C0 = CA(MR(-17+2*i), MR(20), MR(19+1*i))
  405. LAW.C0 = CA(MR(-17+2*i), MR(-20), MR(-19-1*i))
  406. RLW.C0 = CA(MR(16-1*i), 0, 0) * CN(0.02, 0.4, -0.75)
  407. LLW.C0 = CA(MR(-51+1*i), 0, 0) * CN(-0.02, 0.45, -0.5)
  408. FW.C0 = CN(0, -0.54+0.04*i, 0) * CA(MR(-11+1*i), 0, 0)
  409. FNeck.C0 = Neck0 * CA(MR(21-1*i), 0, 0)
  410. wait()
  411. end
  412. wait()
  413. end
  414. function RunStart()
  415. for i = 0.33, 1, 0.33 do
  416. RAW.C0 = CA(MR(-15-5*i), MR(20-3*i), MR(20-3*i))
  417. LAW.C0 = CA(MR(-15-5*i), MR(-20+3*i), MR(-20+3*i))
  418. wait()
  419. end
  420. for i = 0.2, 1, 0.2 do
  421. RAW.C0 = CA(MR(-20-15*i), MR(17-5*i), MR(17-7*i))
  422. LAW.C0 = CA(MR(-20-15*i), MR(-17+5*i), MR(-17+7*i))
  423. wait()
  424. end
  425. for i = 0.5, 1, 0.5 do
  426. RAW.C0 = CA(MR(-35-5*i), MR(12-2*i), MR(10-2*i))
  427. LAW.C0 = CA(MR(-35-5*i), MR(-12+2*i), MR(-10+2*i))
  428. wait()
  429. end
  430. end
  431. function RunEnd()
  432. for i = 0.5, 1, 0.5 do
  433. RAW.C0 = CA(MR(-40+5*i), MR(10+2*i), MR(8+2*i))
  434. LAW.C0 = CA(MR(-40+5*i), MR(-10-2*i), MR(-8-2*i))
  435. wait()
  436. end
  437. for i = 0.2, 1, 0.2 do
  438. RAW.C0 = CA(MR(-35+15*i), MR(12+5*i), MR(10+7*i))
  439. LAW.C0 = CA(MR(-35+15*i), MR(-12-5*i), MR(-10-7*i))
  440. wait()
  441. end
  442. for i = 0.33, 1, 0.33 do
  443. RAW.C0 = CA(MR(-20+5*i), MR(17+3*i), MR(17+3*i))
  444. LAW.C0 = CA(MR(-20+5*i), MR(-17-3*i), MR(-17-3*i))
  445. wait()
  446. end
  447. end
  448. function Run()
  449. local SpeedAtm = Torso.Velocity.magnitude
  450. for i = 0.33, 1, 0.33 do
  451. SpeedAtm = Torso.Velocity.magnitude
  452. if Attacking == true or Selected == false or SpeedAtm < 0.1 or Torso.Velocity.Y > 0.5 or Torso.Velocity.Y < -0.5 then return end
  453. RLW.C0 = CA(MR(15-15*i), 0, 0) * CN(0.02, 0.4-0.1*i, -0.75+0.25*i)
  454. LLW.C0 = CA(MR(-50+15*i), 0, 0) * CN(-0.02, 0.45+0.3*i, -0.5)
  455. FW.C0 = CN(0, -0.5+0.2*i, 0) * CA(MR(-10+2*i), 0, 0)
  456. wait()
  457. end
  458. for i = 0.25, 1, 0.25 do
  459. SpeedAtm = Torso.Velocity.magnitude
  460. if Attacking == true or Selected == false or SpeedAtm < 0.1 or Torso.Velocity.Y > 0.5 or Torso.Velocity.Y < -0.5 then return end
  461. RLW.C0 = CA(MR(-60*i), 0, 0) * CN(0.02, 0.3-0.25*i, -0.5+0.75*i)
  462. LLW.C0 = CA(MR(-35+45*i), 0, 0) * CN(-0.02, 0.75+0.4*i, -0.5-0.2*i)
  463. FW.C0 = CN(0, -0.3+0.2*i, 0) * CA(MR(-8+1*i), 0, 0)
  464. wait()
  465. end
  466. for i = 0.5, 1, 0.5 do
  467. SpeedAtm = Torso.Velocity.magnitude
  468. if Attacking == true or Selected == false or SpeedAtm < 0.1 or Torso.Velocity.Y > 0.5 or Torso.Velocity.Y < -0.5 then return end
  469. RLW.C0 = CA(MR(-60-5*i), 0, 0) * CN(0.02, 0.05-0.1*i, 0.25+0.1*i)
  470. LLW.C0 = CA(MR(10+5*i), 0, 0) * CN(-0.02, 1.15-0.15*i, -0.7-0.05*i)
  471. FW.C0 = CN(0, -0.1+0.05*i, 0) * CA(MR(-7+1*i), 0, 0)
  472. wait()
  473. end
  474. for i = 0.33, 1, 0.33 do
  475. SpeedAtm = Torso.Velocity.magnitude
  476. if Attacking == true or Selected == false or SpeedAtm < 0.1 or Torso.Velocity.Y > 0.5 or Torso.Velocity.Y < -0.5 then return end
  477. RLW.C0 = CA(MR(-65+30*i), 0, 0) * CN(0.02, -0.05+0.5*i, 0.35-0.2*i)
  478. LLW.C0 = CA(MR(15-10*i), 0, 0) * CN(-0.02, 1-0.5*i, -0.75+0.1*i)
  479. FW.C0 = CN(0, -0.05-0.6*i, 0) * CA(MR(-6-3*i), 0, 0)
  480. wait()
  481. end
  482. for i = 0.25, 1, 0.25 do
  483. SpeedAtm = Torso.Velocity.magnitude
  484. if Attacking == true or Selected == false or SpeedAtm < 0.1 or Torso.Velocity.Y > 0.5 or Torso.Velocity.Y < -0.5 then return end
  485. RLW.C0 = CA(MR(-35+40*i), 0, 0) * CN(0.02, 0.45+0.9*i, 0.15-0.6*i)
  486. LLW.C0 = CA(MR(5-55*i), 0, 0) * CN(-0.02, 0.5-0.6*i, -0.65+0.8*i)
  487. FW.C0 = CN(0, -0.65+0.4*i, 0) * CA(MR(-9-3*i), 0, 0)
  488. wait()
  489. end
  490. for i = 0.33, 1, 0.33 do
  491. SpeedAtm = Torso.Velocity.magnitude
  492. if Attacking == true or Selected == false or SpeedAtm < 0.1 or Torso.Velocity.Y > 0.1 then return end
  493. RLW.C0 = CA(MR(5+10*i), 0, 0) * CN(0.02, 1.35-0.95*i, -0.45-0.3*i)
  494. LLW.C0 = CA(MR(-50), 0, 0) * CN(-0.02, -0.1+0.55*i, 0.15-0.7*i)
  495. FW.C0 = CN(0, -0.25-0.35*i, 0) * CA(MR(-12+2*i), 0, 0)
  496. wait()
  497. end
  498. end
  499. coroutine.resume(coroutine.create(function()
  500. while true do
  501. local SpeedAtm = Torso.Velocity.magnitude
  502. if Attacking == false and Selected or Torso.Velocity.Y > 0.5 or Torso.Velocity.Y < -0.5 then
  503. if SpeedAtm < 0.1 then
  504. Idle()
  505. RAW.C0 = CA(MR(-15), MR(20), MR(20))
  506. LAW.C0 = CA(MR(-15), MR(-20), MR(-20))
  507. RLW.C0 = CA(MR(15), 0, 0) * CN(0.02, 0.4, -0.75)
  508. LLW.C0 = CA(MR(-50), 0, 0) * CN(-0.02, 0.45, -0.5)
  509. HWR.C0 = CN()
  510. HWL.C0 = CN()
  511. FW.C0 = CN(0, -0.5, 0) * CA(MR(-10), 0, 0)
  512. FNeck.C0 = Neck0 * CA(MR(20), 0, 0)
  513. else
  514. Run()
  515. end
  516. end
  517. wait()
  518. end
  519. end))
  520. Notime(function()
  521. local Last = Torso.Velocity.magnitude > 0.1
  522. while true do
  523. Running = Torso.Velocity.magnitude > 0.1
  524. if Torso.Velocity.Y < 0.5 or Torso.Velocity.Y > -0.5 and Attacking == false and Selected then
  525. if Running ~= Last then
  526. Last = Running
  527. if Running then
  528. RunStart()
  529. else
  530. RunEnd()
  531. end
  532. end
  533. end
  534. wait()
  535. end
  536. end)
  537. function Jump()
  538. Attacking = true
  539. --Hum.PlatformStand = true
  540. for i = 0.5, 1, 0.5 do
  541. RAW.C0 = CA(MR(-15+10*i), MR(20-5*i), MR(20-3*i))
  542. LAW.C0 = CA(MR(-15+10*i), MR(-20+5*i), MR(-20+3*i))
  543. RLW.C0 = CA(MR(15-10*i), 0, 0) * CN(0.02, 0.4-0.2*i, -0.75+0.35*i)
  544. LLW.C0 = CA(MR(-50+20*i), 0, 0) * CN(-0.02, 0.45-0.3*i, -0.5+0.5*i)
  545. HWR.C0 = CA(MR(10*i), 0, 0)
  546. HWL.C0 = CA(MR(10*i), 0, 0)
  547. FW.C0 = CN(0, -0.5+0.05*i, 0) * CA(MR(-10-2*i), 0, 0)
  548. FNeck.C0 = Neck0 * CA(MR(20), 0, 0)
  549. wait()
  550. end
  551. local bp = Add.BP(Torso, Torso.Position, 10000)
  552. local Face = Compute(Torso.Position, Torso.CFrame * CN(0, 0, -10).p)
  553. local Dist = 13
  554. local Center = Face * CN(0, 0, -Dist) + V3(0, -Dist/2, 0)
  555. --bp.position = Center * CA(MR(150-120*i), 0, 0) * CN(0, 0, -Dist).p
  556. for i = 0.33, 1, 0.33 do
  557. RAW.C0 = CA(MR(-5+80*i), MR(15-20*i), MR(17-12*i))
  558. LAW.C0 = CA(MR(-5+80*i), MR(-15+20*i), MR(-17+12*i))
  559. RLW.C0 = CA(MR(10-10*i), 0, 0) * CN(0.02, 0.2-0.2*i, -0.45+0.45*i)
  560. LLW.C0 = CA(MR(-40+40*i), 0, 0) * CN(-0.02, 0.15-0.15*i, -0.25+0.25*i)
  561. HWR.C0 = CA(MR(10+25*i), 0, 0)
  562. HWL.C0 = CA(MR(10+25*i), 0, 0)
  563. FW.C0 = CN(0, -0.45+0.45*i, 0) * CA(MR(-12-13*i), 0, 0)
  564. FNeck.C0 = Neck0 * CA(MR(20), 0, 0)
  565. bp.position = Center * CA(MR(150-10*i), 0, 0) * CN(0, 0, -Dist).p
  566. wait()
  567. end
  568. for i = 0.2, 1, 0.2 do
  569. RAW.C0 = CA(MR(75+60*i), MR(-5), MR(5))
  570. LAW.C0 = CA(MR(75+60*i), MR(5), MR(-5))
  571. RLW.C0 = CA(0, 0, 0) * CN(0.02, 0.25*i, 0)
  572. LLW.C0 = CA(0, 0, 0) * CN(-0.02, 0.25*i, 0)
  573. HWR.C0 = CA(MR(35+20*i), 0, 0)
  574. HWL.C0 = CA(MR(35+20*i), 0, 0)
  575. FW.C0 = CA(MR(-25-35*i), 0, 0)
  576. FNeck.C0 = Neck0 * CA(MR(20), 0, 0)
  577. bp.position = Center * CA(MR(140-50*i), 0, 0) * CN(0, 0, -Dist).p
  578. wait()
  579. end
  580. for i = 0.5, 1, 0.5 do
  581. RAW.C0 = CA(MR(135+15*i), MR(-5), MR(5))
  582. LAW.C0 = CA(MR(135+15*i), MR(5), MR(-5))
  583. RLW.C0 = CA(MR(-5*i), 0, 0) * CN(0.02, 0.25+0.4*i, -0.45*i)
  584. LLW.C0 = CA(MR(-5*i), 0, 0) * CN(-0.02, 0.25+0.4*i, -0.45*i)
  585. FW.C0 = CA(MR(-60-15*i), 0, 0)
  586. FNeck.C0 = Neck0 * CA(MR(20), 0, 0)
  587. bp.position = Center * CA(MR(90-10*i), 0, 0) * CN(0, 0, -Dist).p
  588. wait()
  589. end
  590. Hurt = true
  591. Deb = true
  592. for i = 0.15, 1, 0.15 do
  593. RAW.C0 = CA(MR(150-120*i), MR(-5), MR(5))
  594. LAW.C0 = CA(MR(150-120*i), MR(5), MR(-5))
  595. RLW.C0 = CA(MR(-5-20*i), 0, 0) * CN(0.02, 0.65+0.6*i, -0.45-0.45*i)
  596. LLW.C0 = CA(MR(-5-20*i), 0, 0) * CN(-0.02, 0.65+0.5*i, -0.45-0.45*i)
  597. HWR.C0 = CA(MR(55-60*i), 0, 0)
  598. HWL.C0 = CA(MR(55-60*i), 0, 0)
  599. FW.C0 = CA(MR(-75-130*i), 0, 0)
  600. FNeck.C0 = Neck0 * CA(MR(20), 0, 0)
  601. bp.position = Center * CA(MR(80-30*i), 0, 0) * CN(0, 0, -Dist).p
  602. wait()
  603. end
  604. Hurt = false
  605. Hum.PlatformStand = false
  606. bp:remove()
  607. Attacking = false
  608. end
  609. function SelectAnim()
  610. Atta(Limbs.Rarm)
  611. Atta(Limbs.Larm)
  612. Attach(FTorso)
  613. for i = 0.33, 1, 0.33 do
  614. RAW.C0 = CA(MR(10*i), MR(4*i), MR(3*i))
  615. LAW.C0 = CA(MR(10*i), MR(-4*i), MR(-3*i))
  616. HWR.C0 = CN(0.15*i, 0, 0) * CA(MR(-35*i), 0, 0)
  617. HWL.C0 = CN(-0.15*i, 0, 0) * CA(MR(-35*i), 0, 0)
  618. FW.C0 = CA(MR(3*i), 0, 0)
  619. FNeck.C0 = Neck0 * CA(MR(-5*i), 0, 0)
  620. wait()
  621. end
  622. for i = 0.2, 1, 0.2 do
  623. RAW.C0 = CA(MR(10+50*i), MR(4+16*i), MR(3+7*i))
  624. LAW.C0 = CA(MR(10+50*i), MR(-4-16*i), MR(-3-7*i))
  625. HWR.C0 = CN(0.15+0.25*i, 0, 0) * CA(MR(-35-180*i), 0, 0)
  626. HWL.C0 = CN(-0.15-0.25*i, 0, 0) * CA(MR(-35-180*i), 0, 0)
  627. FW.C0 = CA(MR(3+7*i), 0, 0)
  628. FNeck.C0 = Neck0 * CA(MR(-5-15*i), 0, 0)
  629. wait()
  630. end
  631. for i = 0.25, 1, 0.25 do
  632. RAW.C0 = CA(MR(60+12*i), MR(20), MR(10+3*i))
  633. LAW.C0 = CA(MR(60+12*i), MR(-20), MR(-10-3*i))
  634. HWR.C0 = CN(0.4+0.05*i, 0, 0) * CA(MR(-215-180*i), 0, 0)
  635. HWL.C0 = CN(-0.4-0.05*i, 0, 0) * CA(MR(-215-180*i), 0, 0)
  636. FW.C0 = CA(MR(10+2*i), 0, 0)
  637. FNeck.C0 = Neck0 * CA(MR(-20-2*i), 0, 0)
  638. wait()
  639. end
  640. Atta(Limbs.Rleg)
  641. Atta(Limbs.Lleg)
  642. for i = 0.2, 1, 0.2 do
  643. RAW.C0 = CA(MR(72-80*i), MR(20), MR(13+7*i))
  644. LAW.C0 = CA(MR(72-80*i), MR(-20), MR(-13-7*i))
  645. RLW.C0 = CA(MR(10*i), 0, 0) * CN(0, 0.3*i, -0.7*i)
  646. LLW.C0 = CA(MR(-40*i), 0, 0) * CN(0, 0.4*i, -0.4*i)
  647. HWR.C0 = CN(0.45-0.35*i, 0, 0) * CA(MR(-35-290*i), 0, 0)
  648. HWL.C0 = CN(-0.45+0.35*i, 0, 0) * CA(MR(-35-290*i), 0, 0)
  649. FW.C0 = CN(0, -0.4*i, 0) * CA(MR(12-18*i), 0, 0)
  650. FNeck.C0 = Neck0 * CA(MR(-22+18*i), 0, 0)
  651. wait()
  652. end
  653. for i = 0.5, 1, 0.5 do
  654. RAW.C0 = CA(MR(-8-7*i), MR(20), MR(20))
  655. LAW.C0 = CA(MR(-8-7*i), MR(-20), MR(-20))
  656. RLW.C0 = CA(MR(10+5*i), 0, 0) * CN(0.02*i, 0.3+0.1*i, -0.7-0.05*i)
  657. LLW.C0 = CA(MR(-40-10*i), 0, 0) * CN(-0.02*i, 0.4+0.05*i, -0.4-0.1*i)
  658. HWR.C0 = CN(0.1-0.1*i, 0, 0) * CA(MR(-325-35*i), 0, 0)
  659. HWL.C0 = CN(-0.1+0.1*i, 0, 0) * CA(MR(-325-35*i), 0, 0)
  660. FW.C0 = CN(0, -0.4-0.1*i, 0) * CA(MR(-6-4*i), 0, 0)
  661. FNeck.C0 = Neck0 * CA(MR(-4+16*i), 0, 0)
  662. wait()
  663. end
  664. RAW.C0 = CA(MR(-15), MR(20), MR(20))
  665. LAW.C0 = CA(MR(-15), MR(-20), MR(-20))
  666. RLW.C0 = CA(MR(15), 0, 0) * CN(0.02, 0.4, -0.75)
  667. LLW.C0 = CA(MR(-50), 0, 0) * CN(-0.02, 0.45, -0.5)
  668. HWR.C0 = CN()
  669. HWL.C0 = CN()
  670. FW.C0 = CN(0, -0.5, 0) * CA(MR(-10), 0, 0)
  671. FNeck.C0 = Neck0 * CA(MR(20), 0, 0)
  672. end
  673. function DeselAnim()
  674. for i = 0.25, 1, 0.25 do
  675. RAW.C0 = CA(MR(-15+4*i), MR(20-5*i), MR(20-3*i))
  676. LAW.C0 = CA(MR(-15+4*i), MR(-20+5*i), MR(-20+3*i))
  677. RLW.C0 = CA(MR(15-5*i), 0, 0) * CN(0.02-0.02*i, 0.4-0.1*i, -0.75+0.25*i)
  678. LLW.C0 = CA(MR(-50+15*i), 0, 0) * CN(-0.02+0.02*i, 0.45-0.1*i, -0.5+0.2*i)
  679. FW.C0 = CN(0, -0.5+0.15*i, 0) * CA(MR(-10+3*i), 0, 0)
  680. FNeck.C0 = Neck0 * CA(MR(20-15*i), 0, 0)
  681. wait()
  682. end
  683. for i = 0.2, 1, 0.2 do
  684. RAW.C0 = CA(MR(-11+11*i), MR(15-15*i), MR(17-17*i))
  685. LAW.C0 = CA(MR(-11+11*i), MR(-15+15*i), MR(-17+17*i))
  686. RLW.C0 = CA(MR(10-10*i), 0, 0) * CN(0, 0.3-0.3*i, -0.5+0.5*i)
  687. LLW.C0 = CA(MR(-35+35*i), 0, 0) * CN(0, 0.35-0.35*i, -0.3+0.3*i)
  688. FW.C0 = CN(0, -0.35+0.35*i, 0) * CA(MR(-7+7*i), 0, 0)
  689. FNeck.C0 = Neck0 * CA(MR(5-5*i), 0, 0)
  690. wait()
  691. end
  692. RAW.Part1 = nil
  693. LAW.Part1 = nil
  694. RLW.Part1 = nil
  695. LLW.Part1 = nil
  696. Attach(Torso)
  697. end
  698. function onSelected(mouse)
  699. SelectAnim()
  700. Hum.WalkSpeed = Speed
  701. Selected = true
  702. mouse.Button1Down:connect(function()
  703. end)
  704. mouse.KeyDown:connect(function(key)
  705. key = key:lower()
  706. if Find(Attacks, key) then
  707. if key == "q" then
  708. Jump()
  709. end
  710. RAW.C0 = CA(MR(-15), MR(20), MR(20))
  711. LAW.C0 = CA(MR(-15), MR(-20), MR(-20))
  712. RLW.C0 = CA(MR(15), 0, 0) * CN(0.02, 0.4, -0.75)
  713. LLW.C0 = CA(MR(-50), 0, 0) * CN(-0.02, 0.45, -0.5)
  714. HWR.C0 = CN()
  715. HWL.C0 = CN()
  716. FW.C0 = CN(0, -0.5, 0) * CA(MR(-10), 0, 0)
  717. FNeck.C0 = Neck0 * CA(MR(20), 0, 0)
  718. end
  719. end)
  720. end
  721. function onDeselected(mouse)
  722. Selected = false
  723. Hum.WalkSpeed = 16
  724. DeselAnim()
  725. end
  726. bin.Selected:connect(onSelected)
  727. bin.Deselected:connect(onDeselected)
Add Comment
Please, Sign In to add comment