Advertisement
HenloMyDude

test

Nov 1st, 2019
301
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 18.98 KB | None | 0 0
  1.  
  2. if game:GetService("RunService"):IsClient() then error("Script must be server-side in order to work; use h/ and not hl/") end
  3. local Player,Mouse,mouse,UserInputService,ContextActionService = owner
  4. local RealPlayer = Player
  5. do print("FE Compatibility code by Mokiros")local a=RealPlayer;script.Parent=a.Character;local b=Instance.new("RemoteEvent")b.Name="UserInput_Event"local function c()local d={_fakeEvent=true,Functions={},Connect=function(self,e)table.insert(self.Functions,e)end}d.connect=d.Connect;return d end;local f={Target=nil,Hit=CFrame.new(),KeyUp=c(),KeyDown=c(),Button1Up=c(),Button1Down=c(),Button2Up=c(),Button2Down=c()}local g={InputBegan=c(),InputEnded=c()}local CAS={Actions={},BindAction=function(self,h,i,j,...)CAS.Actions[h]=i and{Name=h,Function=i,Keys={...}}or nil end}CAS.UnbindAction=CAS.BindAction;local function k(self,l,...)local d=f[l]if d and d._fakeEvent then for m,e in pairs(d.Functions)do e(...)end end end;f.TrigEvent=k;g.TrigEvent=k;b.OnServerEvent:Connect(function(n,o)if n~=a then return end;f.Target=o.Target;f.Hit=o.Hit;if not o.isMouse then local p=o.UserInputState==Enum.UserInputState.Begin;if o.UserInputType==Enum.UserInputType.MouseButton1 then return f:TrigEvent(p and"Button1Down"or"Button1Up")end;if o.UserInputType==Enum.UserInputType.MouseButton2 then return f:TrigEvent(p and"Button2Down"or"Button2Up")end;for m,d in pairs(CAS.Actions)do for m,q in pairs(d.Keys)do if q==o.KeyCode then d.Function(d.Name,o.UserInputState,o)end end end;f:TrigEvent(p and"KeyDown"or"KeyUp",o.KeyCode.Name:lower())g:TrigEvent(p and"InputBegan"or"InputEnded",o,false)end end)b.Parent=NLS([==[local a=game:GetService("Players").LocalPlayer;local b=script:WaitForChild("UserInput_Event")local c=a:GetMouse()local d=game:GetService("UserInputService")local e=function(f,g)if g then return end;b:FireServer({KeyCode=f.KeyCode,UserInputType=f.UserInputType,UserInputState=f.UserInputState,Hit=c.Hit,Target=c.Target})end;d.InputBegan:Connect(e)d.InputEnded:Connect(e)local h,i;while wait(1/30)do if h~=c.Hit or i~=c.Target then h,i=c.Hit,c.Target;b:FireServer({isMouse=true,Target=i,Hit=h})end end]==],Player.Character)local r=game;local s={__index=function(self,q)local t=rawget(self,"_RealService")if t then return typeof(t[q])=="function"and function(m,...)return t[q](t,...)end or t[q]end end,__newindex=function(self,q,u)local t=rawget(self,"_RealService")if t then t[q]=u end end}local function v(d,w)d._RealService=typeof(w)=="string"and r:GetService(w)or w;return setmetatable(d,s)end;local x={GetService=function(self,t)return rawget(self,t)or r:GetService(t)end,Players=v({LocalPlayer=v({GetMouse=function(self)return f end},Player)},"Players"),UserInputService=v(g,"UserInputService"),ContextActionService=v(CAS,"ContextActionService"),RunService=v({_btrs={},RenderStepped=r:GetService("RunService").Heartbeat,BindToRenderStep=function(self,h,m,i)self._btrs[h]=self.Heartbeat:Connect(i)end,UnbindFromRenderStep=function(self,h)self._btrs[h]:Disconnect()end},"RunService")}rawset(x.Players,"localPlayer",x.Players.LocalPlayer)x.service=x.GetService;v(x,game)game,owner=x,x.Players.LocalPlayer end
  6.  
  7. local plr = owner
  8. local mouse = plr:GetMouse()
  9. local char = plr.Character
  10. local hum = char:FindFirstChildOfClass'Humanoid'
  11. local hed = char.Head
  12. local root = char:FindFirstChild'HumanoidRootPart'
  13. local rootj = root.RootJoint
  14. local tors = char.Torso
  15. local ra = char["Right Arm"]
  16. local la = char["Left Arm"]
  17. local rl = char["Right Leg"]
  18. local ll = char["Left Leg"]
  19. local neck = tors["Neck"]
  20. local mouse = plr:GetMouse()
  21. local RootCF = CFrame.fromEulerAnglesXYZ(-1.57, 0, 3.14)
  22. local RHCF = CFrame.fromEulerAnglesXYZ(0, 1.6, 0)
  23. local LHCF = CFrame.fromEulerAnglesXYZ(0, -1.6, 0)
  24. local maincolor = BrickColor.new("Really black")
  25. local disach = false
  26. local epicmode = false
  27.  
  28. cam = game.Workspace.CurrentCamera
  29. CF = CFrame.new
  30. angles = CFrame.Angles
  31. attack = false
  32. Euler = CFrame.fromEulerAnglesXYZ
  33. Rad = math.rad
  34. IT = Instance.new
  35. BrickC = BrickColor.new
  36. Cos = math.cos
  37. Acos = math.acos
  38. Sin = math.sin
  39. Asin = math.asin
  40. Abs = math.abs
  41. Mrandom = math.random
  42. Floor = math.floor
  43.  
  44. necko = CF(0, 1, 0, -1, -0, -0, 0, 0, 1, 0, 1, 0)
  45. RW = Instance.new("Weld")
  46. LW = Instance.new("Weld")
  47. RH = tors["Right Hip"]
  48. LH = tors["Left Hip"]
  49. RW.Name = "RW"
  50. RW.Part0 = tors
  51. RW.C0 = CF(1.5, 0.5, 0)
  52. RW.C1 = CF(0, 0.5, 0)
  53. RW.Part1 = ra
  54. RW.Parent = tors
  55. LW.Name = "LW"
  56. LW.Part0 = tors
  57. LW.C0 = CF(-1.5, 0.5, 0)
  58. LW.C1 = CF(0, 0.5, 0)
  59. LW.Part1 = la
  60. LW.Parent = tors
  61. Effects = {}
  62. newWeld = function(wp0, wp1, wc0x, wc0y, wc0z)
  63. local wld = Instance.new("Weld", wp1)
  64. wld.Part0 = wp0
  65. wld.Part1 = wp1
  66. wld.C0 = CFrame.new(wc0x, wc0y, wc0z)
  67. end
  68. newWeld(tors, ll, -0.5, -1, 0)
  69. ll.Weld.C1 = CFrame.new(0, 1, 0)
  70. newWeld(tors, rl, 0.5, -1, 0)
  71. rl.Weld.C1 = CFrame.new(0, 1, 0)
  72.  
  73. ArtificialHB = Instance.new("BindableEvent", script)
  74. ArtificialHB.Name = "Heartbeat"
  75. script:WaitForChild("Heartbeat")
  76.  
  77. frame = 1 / 60
  78. tf = 0
  79. allowframeloss = false
  80. tossremainder = false
  81.  
  82.  
  83. lastframe = tick()
  84. script.Heartbeat:Fire()
  85.  
  86.  
  87. game:GetService("RunService").Heartbeat:connect(function(s, p)
  88. tf = tf + s
  89. if tf >= frame then
  90. if allowframeloss then
  91. script.Heartbeat:Fire()
  92. lastframe = tick()
  93. else
  94. for i = 1, math.floor(tf / frame) do
  95. script.Heartbeat:Fire()
  96. end
  97. lastframe = tick()
  98. end
  99. if tossremainder then
  100. tf = 0
  101. else
  102. tf = tf - frame * math.floor(tf / frame)
  103. end
  104. end
  105. end)
  106.  
  107. function swait(num)
  108. if num == 0 or num == nil then
  109. game:service("RunService").Stepped:wait(0)
  110. else
  111. for i = 0, num do
  112. game:service("RunService").Stepped:wait(0)
  113. end
  114. end
  115. end
  116. function thread(f)
  117. coroutine.resume(coroutine.create(f))
  118. end
  119. function clerp(a, b, t)
  120. local qa = {
  121. QuaternionFromCFrame(a)
  122. }
  123. local qb = {
  124. QuaternionFromCFrame(b)
  125. }
  126. local ax, ay, az = a.x, a.y, a.z
  127. local bx, by, bz = b.x, b.y, b.z
  128. local _t = 1 - t
  129. return QuaternionToCFrame(_t * ax + t * bx, _t * ay + t * by, _t * az + t * bz, QuaternionSlerp(qa, qb, t))
  130. end
  131. function QuaternionFromCFrame(cf)
  132. local mx, my, mz, m00, m01, m02, m10, m11, m12, m20, m21, m22 = cf:components()
  133. local trace = m00 + m11 + m22
  134. if trace > 0 then
  135. local s = math.sqrt(1 + trace)
  136. local recip = 0.5 / s
  137. return (m21 - m12) * recip, (m02 - m20) * recip, (m10 - m01) * recip, s * 0.5
  138. else
  139. local i = 0
  140. if m00 < m11 then
  141. i = 1
  142. end
  143. if m22 > (i == 0 and m00 or m11) then
  144. i = 2
  145. end
  146. if i == 0 then
  147. local s = math.sqrt(m00 - m11 - m22 + 1)
  148. local recip = 0.5 / s
  149. return 0.5 * s, (m10 + m01) * recip, (m20 + m02) * recip, (m21 - m12) * recip
  150. elseif i == 1 then
  151. local s = math.sqrt(m11 - m22 - m00 + 1)
  152. local recip = 0.5 / s
  153. return (m01 + m10) * recip, 0.5 * s, (m21 + m12) * recip, (m02 - m20) * recip
  154. elseif i == 2 then
  155. local s = math.sqrt(m22 - m00 - m11 + 1)
  156. local recip = 0.5 / s
  157. return (m02 + m20) * recip, (m12 + m21) * recip, 0.5 * s, (m10 - m01) * recip
  158. end
  159. end
  160. end
  161. function QuaternionToCFrame(px, py, pz, x, y, z, w)
  162. local xs, ys, zs = x + x, y + y, z + z
  163. local wx, wy, wz = w * xs, w * ys, w * zs
  164. local xx = x * xs
  165. local xy = x * ys
  166. local xz = x * zs
  167. local yy = y * ys
  168. local yz = y * zs
  169. local zz = z * zs
  170. 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))
  171. end
  172. function QuaternionSlerp(a, b, t)
  173. local cosTheta = a[1] * b[1] + a[2] * b[2] + a[3] * b[3] + a[4] * b[4]
  174. local startInterp, finishInterp
  175. if cosTheta >= 1.0E-4 then
  176. if 1 - cosTheta > 1.0E-4 then
  177. local theta = math.acos(cosTheta)
  178. local invSinTheta = 1 / Sin(theta)
  179. startInterp = Sin((1 - t) * theta) * invSinTheta
  180. finishInterp = Sin(t * theta) * invSinTheta
  181. else
  182. startInterp = 1 - t
  183. finishInterp = t
  184. end
  185. elseif 1 + cosTheta > 1.0E-4 then
  186. local theta = math.acos(-cosTheta)
  187. local invSinTheta = 1 / Sin(theta)
  188. startInterp = Sin((t - 1) * theta) * invSinTheta
  189. finishInterp = Sin(t * theta) * invSinTheta
  190. else
  191. startInterp = t - 1
  192. finishInterp = t
  193. end
  194. 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
  195. end
  196. function rayCast(Position, Direction, Range, Ignore)
  197. return game:service("Workspace"):FindPartOnRay(Ray.new(Position, Direction.unit * (Range or 999.999)), Ignore)
  198. end
  199. local RbxUtility = LoadLibrary("RbxUtility")
  200. local Create = RbxUtility.Create
  201. change = 1
  202. sine = 0
  203. movelegs = false
  204. rK = false
  205. DBT = false
  206. Speed = 16
  207.  
  208. local function round(n)
  209. return math.floor(n + 0.5)
  210. end
  211.  
  212. local wall = Instance.new("Part",script)
  213. wall.Transparency = 0.5
  214. wall.BrickColor = BrickColor.new("Cyan")
  215. wall.Anchored = true
  216. wall.CanCollide = false
  217. wall.CFrame = CFrame.new(round(root.CFrame.x), round(root.CFrame.y), round(root.CFrame.z * 5))
  218. wall.Orientation = Vector3.new(round(root.Orientation.x),round(root.Orientation.y),round(root.Orientation.z))
  219.  
  220. local wallHeight = 4
  221. local brickSpeed = 0.04
  222. local wallWidth = 12
  223.  
  224. function placeBrick(cf, pos, color)
  225. local brick = Instance.new("Part")
  226. brick.BrickColor = color
  227. brick.CFrame = cf * CFrame.new(pos + brick.Size / 2)
  228. game:GetService("Debris"):AddItem(brick, 24)
  229. brick.Parent = game.Workspace
  230. brick:MakeJoints()
  231. return brick, pos + brick.Size
  232. end
  233.  
  234. function buildWall(cf)
  235.  
  236. local color = BrickColor.Random()
  237. local bricks = {}
  238.  
  239. assert(wallWidth>0)
  240. local y = 0
  241. while y < wallHeight do
  242. local p
  243. local x = -wallWidth/2
  244. while x < wallWidth/2 do
  245. local brick
  246. brick, p = placeBrick(cf, Vector3.new(x, y, 0), color)
  247. x = p.x
  248. table.insert(bricks, brick)
  249. wait(brickSpeed)
  250. end
  251. y = p.y
  252. end
  253.  
  254. return bricks
  255.  
  256. end
  257.  
  258.  
  259. function snap(v)
  260. if math.abs(v.x)>math.abs(v.z) then
  261. if v.x>0 then
  262. return Vector3.new(1,0,0)
  263. else
  264. return Vector3.new(-1,0,0)
  265. end
  266. else
  267. if v.z>0 then
  268. return Vector3.new(0,0,1)
  269. else
  270. return Vector3.new(0,0,-1)
  271. end
  272. end
  273. end
  274.  
  275. local MouseLoc = Instance.new("RemoteFunction",char)
  276. MouseLoc.Name = "MouseLoc"
  277.  
  278. local Client = NLS([[
  279.  
  280. local char = script.Parent
  281. script.Name = "Client"
  282.  
  283. local MouseLoc = char:WaitForChild("MouseLoc",10)
  284.  
  285. function MouseLoc.OnClientInvoke()
  286. return game:GetService("Players").LocalPlayer:GetMouse().Hit.p
  287. end
  288.  
  289. ]],char)
  290.  
  291. mouse.Button1Down:connect(function()
  292.  
  293. local targetPos = MouseLoc:InvokeClient(game:GetService("Players"):GetPlayerFromCharacter(char))
  294. local lookAt = snap( (targetPos - char.Head.Position).unit )
  295. local cf = CFrame.new(targetPos, targetPos + lookAt)
  296.  
  297. buildWall(cf)
  298.  
  299. end)
  300.  
  301. while true do
  302. swait()
  303. sine = sine + change
  304. --wall.CFrame = CFrame.new(round(root.CFrame.x), round(root.CFrame.y), round(root.CFrame.z))
  305. wall.Position = mouse.Hit.p
  306. --wall.Orientation = Vector3.new(round(root.Orientation.x),round(root.Orientation.y),round(root.Orientation.z))
  307. local torvel = (root.Velocity * Vector3.new(1, 0, 1)).magnitude
  308. local velderp = root.Velocity.y
  309. hitfloor, posfloor = rayCast(root.Position, CFrame.new(root.Position, root.Position - Vector3.new(0, 1, 0)).lookVector, 4, char)
  310. neartouch = game:service("Workspace"):FindPartOnRay(Ray.new(root.Position, (CFrame.new(root.Position, root.Position - Vector3.new(0, 1, 0))).lookVector.unit * 6), char)
  311. local Walking = (math.abs(root.Velocity.x) > 1 or math.abs(root.Velocity.z) > 1)
  312. local State = (hum.PlatformStand and 'Paralyzed' or hum.Sit and 'Sit' or not hitfloor and root.Velocity.y < -1 and "Fall" or not hitfloor and root.Velocity.y > 1 and "Jump" or hitfloor and Walking and "Walk" or hitfloor and "Idle")
  313. local WALKSPEEDVALUE = 6 / (hum.WalkSpeed / 16)
  314. local TiltVelocity = CFrame.new(root.CFrame:vectorToObjectSpace(root.Velocity/1.6))
  315. if (State == 'Idle') then
  316. --local hell = GetClientProperty(MUSIC,'PlaybackLoudness')/15
  317. if attack == false and epicmode == false then
  318. change = 0.5 --+ hell/35
  319. rootj.C0 = clerp(rootj.C0, RootCF * CF(0, 0, 0), 0.05)
  320. neck.C0 = clerp(neck.C0, necko, 0.05)
  321. RW.C0 = clerp(RW.C0, CF(1.5, 0.5, 0) * angles(Rad(90), Rad(0), Rad(0)), 0.05)
  322. LW.C0 = clerp(LW.C0, CF(-1.5, 0.5, 0), 0.05)
  323. rl.Weld.C0 = clerp(rl.Weld.C0, CF(0.5, -1, 0), 0.05)
  324. ll.Weld.C0 = clerp(ll.Weld.C0, CF(-0.5, -1, 0), 0.05)
  325. elseif attack == false and epicmode == true then
  326. change = 1.15 --+ hell/35
  327. rootj.C0 = RootCF * CF(0, 0, -1 + 1 * Cos(sine / 1))
  328. neck.C0 = clerp(neck.C0, necko * CF(0, 0, 0 + ((1) - 1)) * angles(Rad(0 - 6 * Cos(sine / 8)), Rad(0 - 10 * Sin(sine / 12)), Rad(-0 + 5 * Cos(sine / 16))), 0.05)
  329. RW.C0 = clerp(RW.C0, CF(1.5, 0.5, 0) * angles(Rad(90), Rad(0), Rad(0)), 0.05)
  330. LW.C0 = clerp(LW.C0, CF(-1.5, 0.5 + 0.1 * Cos(sine / 8), -0.0) * angles(Rad(0 + 8.5 * Sin(sine / 16)), Rad(-7), Rad(-10 - 5 * Cos(sine / 8))), 0.05)
  331. rl.Weld.C0 = clerp(rl.Weld.C0, CF(0.5, 0 - 1 * Cos(sine / 1), -0.5) * angles(Rad(0), Rad(-6), Rad(0)) * angles(Rad(0), Rad(0), Rad(2)), 1)
  332. ll.Weld.C0 = clerp(ll.Weld.C0, CF(-0.5, 0 - 1 * Cos(sine / 1), -0.5) * angles(Rad(0), Rad(10), Rad(0)) * angles(Rad(0), Rad(0), Rad(-2)), 1)
  333. end
  334. elseif (State == 'Jump') then
  335. if attack == false then
  336. rootj.C0 = clerp(rootj.C0, RootCF * CF(0, 0, -0.1 + 0.1 * Cos(sine / 20)) * angles(Rad(10 + 3 * Cos(sine / 20)), Rad(0), Rad(0)), 0.1)
  337. neck.C0 = clerp(neck.C0, necko * CF(0, 0, ((1) - 1)) * angles(Rad(-50 + 6 * Sin(sine / 20)), Rad(0), Rad(0 + 9 * Cos(sine / 38))), 0.1)
  338. rl.Weld.C0 = clerp(rl.Weld.C0, CF(0.5, -0.8 - 0.1 * Cos(sine / 20) - Rad(0) , -0.3) * angles(Rad(-27 + 3 * Cos(sine / 20)), Rad(-20 + 1 * Cos(sine / 20)), Rad(0)) * angles(Rad(0 + 1 * Cos(sine / 20)), Rad(0), Rad(5)), 0.1)
  339. ll.Weld.C0 = clerp(ll.Weld.C0, CF(-0.5, -0.5 - 0.1 * Cos(sine / 20) + Rad(0) , -0.7) * angles(Rad(-27 + 3 * Cos(sine / 20)), Rad(20 + 1 * Cos(sine / 20)), Rad(0)) * angles(Rad(0 - 1 * Cos(sine / 20)), Rad(0), Rad(-5)), 0.1)
  340. RW.C0 = clerp(RW.C0, CF(1.5, 0.5 + 0.1 * Cos(sine / 20), 0) * angles(Rad(170 + 10 * Cos(sine / 20)), Rad(10), Rad(10 + 6 * Sin(sine / 20))), 0.2)
  341. LW.C0 = clerp(LW.C0, CF(-1.5, 0.5 + 0.1 * Cos(sine / 20), 0) * angles(Rad(170 + 10 * Cos(sine / 20)), Rad(-10), Rad(-10 - 6 * Sin(sine / 20))), 0.2)
  342. end
  343. elseif (State == 'Fall') then
  344. if neartouch ~= nil and attack == false then
  345. end
  346. if attack == false then
  347. rootj.C0 = clerp(rootj.C0, RootCF * CF(0, 0, -0.1 + 0.1 * Cos(sine / 20)) * angles(Rad(-27 + 3 * Cos(sine / 20)), Rad(0), Rad(0)), 0.1)
  348. neck.C0 = clerp(neck.C0, necko * CF(0, 0, ((1) - 1)) * angles(Rad(20 + 6 * Sin(sine / 20)), Rad(0), Rad(0 + 9 * Cos(sine / 38))), 0.1)
  349. rl.Weld.C0 = clerp(rl.Weld.C0, CF(0.5, -0.9 - 0.1 * Cos(sine / 20) - Rad(0) , 0) * angles(Rad(-27 + 3 * Cos(sine / 20)), Rad(-20 + 1 * Cos(sine / 20)), Rad(0)) * angles(Rad(0 + 1 * Cos(sine / 20)), Rad(0), Rad(5)), 0.1)
  350. ll.Weld.C0 = clerp(ll.Weld.C0, CF(-0.5, -0.9 - 0.1 * Cos(sine / 20) + Rad(0) , 0) * angles(Rad(-27 + 3 * Cos(sine / 20)), Rad(20 + 1 * Cos(sine / 20)), Rad(0)) * angles(Rad(0 - 1 * Cos(sine / 20)), Rad(0), Rad(-5)), 0.1)
  351. RW.C0 = clerp(RW.C0, CF(1.5, 0.5 + 0.1 * Cos(sine / 20), 0) * angles(Rad(100 + 10 * Cos(sine / 20)), Rad(10), Rad(45 + 6 * Sin(sine / 20))), 0.1)
  352. LW.C0 = clerp(LW.C0, CF(-1.5, 0.5 + 0.1 * Cos(sine / 20), 0) * angles(Rad(100 + 10 * Cos(sine / 20)), Rad(-10), Rad(-45 - 6 * Sin(sine / 20))), 0.1)
  353. end
  354. elseif (State == 'Walk') then
  355. change = 0.9
  356. if attack == false then
  357. rootj.C0 = clerp(rootj.C0, RootCF * CF(0, 0, 0) * angles(Rad(0 + 0 * Sin(sine / (WALKSPEEDVALUE / 2))) -Rad(TiltVelocity.z) * 1, Rad(0) -Rad(TiltVelocity.x) * 0.4, Rad(0 - 0 * Cos(sine / WALKSPEEDVALUE )) + root.RotVelocity.Y / 75), 0.1)
  358. neck.C0 = clerp(neck.C0, necko * CF(0, 0, 0 + ((1) - 1)) * angles(Rad(0) +Rad(TiltVelocity.z), Rad(0), Rad(0) -Rad(TiltVelocity.x) * 3), 0.1)
  359. rl.Weld.C0 = clerp(rl.Weld.C0, CF(0.5, -0.9 - 0.35 * Cos(sine / WALKSPEEDVALUE) / 2, 0) * angles(Rad(-5 - 10 * Cos(sine / WALKSPEEDVALUE)) - root.RotVelocity.Y / 75 + -Sin(sine / WALKSPEEDVALUE) / 2.5 * -Rad(TiltVelocity.z) * 10, Rad(0 - 5 * Cos(sine / WALKSPEEDVALUE)), Rad(0)) * angles(Rad(0 + 2 * Cos(sine / WALKSPEEDVALUE)), Rad(0), Rad(0 + 25 * math.sin(sine / WALKSPEEDVALUE)*-math.rad(TiltVelocity.x)*5.5)), 0.3)
  360. ll.Weld.C0 = clerp(ll.Weld.C0, CF(-0.5, -0.9 + 0.35 * Cos(sine / WALKSPEEDVALUE) / 2, 0) * angles(Rad(-5 + 10 * Cos(sine / WALKSPEEDVALUE)) + root.RotVelocity.Y / -75 + Sin(sine / WALKSPEEDVALUE) / 2.5 * -Rad(TiltVelocity.z) * 10, Rad(0 - 5 * Cos(sine / WALKSPEEDVALUE)), Rad(0)) * angles(Rad(0 - 2 * Cos(sine / WALKSPEEDVALUE)), Rad(0), Rad(0 + 25 * math.sin(sine / WALKSPEEDVALUE)*math.rad(TiltVelocity.x)*5.5)), 0.3)
  361. RW.C0 = clerp(RW.C0, CF(1.5, 0.5, 0) * angles(Rad(90), Rad(0), Rad(0)), 0.05)
  362. LW.C0 = clerp(LW.C0, CF(-1.5, 0.5 + 0.05 * Sin(sine / WALKSPEEDVALUE), 0) * angles(Rad(-2.5 - 5 * Cos(sine / WALKSPEEDVALUE)) - root.RotVelocity.Y / -50 + -Sin(sine / WALKSPEEDVALUE) / 2.5 * -Rad(TiltVelocity.z) * 10, Rad(0 - 5 * Cos(sine / WALKSPEEDVALUE)), Rad(0)) * angles(Rad(0 - 2 * Cos(sine / WALKSPEEDVALUE)), Rad(0), Rad(0 + 25 * math.sin(sine / WALKSPEEDVALUE)*math.rad(TiltVelocity.x)*5.5)), 0.3)
  363. elseif attack == true and movelegs == true then
  364. rl.Weld.C0 = clerp(rl.Weld.C0, CF(0.5, -0.9 - 0.35 * Cos(sine / WALKSPEEDVALUE) / 2, 0) * angles(Rad(-5 - 10 * Cos(sine / WALKSPEEDVALUE)) - root.RotVelocity.Y / 75 + -Sin(sine / WALKSPEEDVALUE) / 2.5 * -Rad(TiltVelocity.z) * 10, Rad(0 - 5 * Cos(sine / WALKSPEEDVALUE)), Rad(0)) * angles(Rad(0 + 2 * Cos(sine / WALKSPEEDVALUE)), Rad(0), Rad(0 + 25 * math.sin(sine / WALKSPEEDVALUE)*-math.rad(TiltVelocity.x)*5.5)), 0.3)
  365. ll.Weld.C0 = clerp(ll.Weld.C0, CF(-0.5, -0.9 + 0.35 * Cos(sine / WALKSPEEDVALUE) / 2, 0) * angles(Rad(-5 + 10 * Cos(sine / WALKSPEEDVALUE)) + root.RotVelocity.Y / -75 + Sin(sine / WALKSPEEDVALUE) / 2.5 * -Rad(TiltVelocity.z) * 10, Rad(0 - 5 * Cos(sine / WALKSPEEDVALUE)), Rad(0)) * angles(Rad(0 - 2 * Cos(sine / WALKSPEEDVALUE)), Rad(0), Rad(0 + 25 * math.sin(sine / WALKSPEEDVALUE)*math.rad(TiltVelocity.x)*5.5)), 0.3)
  366. end
  367. end
  368. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement