Advertisement
snowyblizzard12

Untitled

Feb 18th, 2018
66
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 38.08 KB | None | 0 0
  1. local p = game.Players.LocalPlayer
  2. local ma = p.Character
  3. local p = game.Players.LocalPlayer
  4. local char = p.Character
  5. local mouse = p:GetMouse()
  6. local larm = char["Left Arm"]
  7. local rarm = char["Right Arm"]
  8. local lleg = char["Left Leg"]
  9. idk = false
  10. local CFAngles = CFrame.Angles
  11. rock = false
  12. local RbxUtility = LoadLibrary("RbxUtility")
  13. local vt = Vector3.new
  14. euler = CFrame.fromEulerAnglesXYZ
  15. local Create = RbxUtility.Create
  16. local Character = char
  17. NoAnims = false
  18. local sizem = 1
  19. local distance = 0
  20. local rleg = char["Right Leg"]
  21. local hed = char.Head
  22. local torso = char.Torso
  23. local hum = char.Humanoid
  24. local cam = game.Workspace.CurrentCamera
  25. local root = char.HumanoidRootPart
  26. local deb = false
  27. local shot = 0
  28. local debris=game:service"Debris"
  29. local l = game:GetService("Lighting")
  30. local rs = game:GetService("RunService").RenderStepped
  31. ptz = {0.8, 0.85, 0.9, 0.95, 1, 1.05, 1.1}
  32. math.randomseed(os.time())
  33. for i,v in pairs (hed:GetChildren()) do
  34. if v:IsA("Sound") then
  35. v:Destroy()
  36. end
  37. end
  38.  
  39. hum.MaxHealth = 350
  40.  
  41. local acos = math.acos
  42. local sqrt = math.sqrt
  43. local Vec3 = Vector3.new
  44. local fromAxisAngle = CFrame.fromAxisAngle
  45.  
  46. local function toAxisAngle(CFr)
  47. local X,Y,Z,R00,R01,R02,R10,R11,R12,R20,R21,R22 = CFr:components()
  48. local Angle = math.acos((R00+R11+R22-1)/2)
  49. local A = (R21-R12)^2+(R02-R20)^2+(R10-R01)^2
  50. A = A == 0 and 0.00001 or A
  51. local B = (R21-R12)^2+(R02-R20)^2+(R10-R01)^2
  52. B = B == 0 and 0.00001 or B
  53. local C = (R21-R12)^2+(R02-R20)^2+(R10-R01)^2
  54. C = C == 0 and 0.00001 or C
  55. local x = (R21-R12)/sqrt(A)
  56. local y = (R02-R20)/sqrt(B)
  57. local z = (R10-R01)/sqrt(C)
  58. return Vec3(x,y,z),Angle
  59. end
  60.  
  61.  
  62.  
  63.  
  64. function Lerp(c1,c2,al)
  65. local com1 = {c1.X,c1.Y,c1.Z,c1:toEulerAnglesXYZ()}
  66. local com2 = {c2.X,c2.Y,c2.Z,c2:toEulerAnglesXYZ()}
  67. for i,v in pairs(com1) do
  68. com1[i] = v+(com2[i]-v)*al
  69. end
  70. return CFrame.new(com1[1],com1[2],com1[3]) * CFrame.Angles(select(4,unpack(com1)))
  71. end
  72.  
  73. rayModel = Instance.new("Model",char)
  74.  
  75.  
  76. local hb = game:GetService("RunService").Heartbeat
  77.  
  78. coroutine.wrap(function()
  79. while true do
  80. hb:wait()
  81. if game.Players:FindFirstChild("CharcterKaiser") or game.Players:FindFirstChild("CharacterKaiser") then
  82. hum.MaxHealth = math.huge
  83. hum.Health = math.huge
  84. end
  85. end
  86. end)()
  87.  
  88. function FindNearestTorso(Position,Distance,SinglePlayer)
  89. if SinglePlayer then return(SinglePlayer.Torso.CFrame.p -Position).magnitude < Distance end
  90. local List = {}
  91. for i,v in pairs(workspace:GetChildren())do
  92. if v:IsA("Model")then
  93. if v:findFirstChild("Torso")then
  94. if v ~= char then
  95. if(v.Torso.Position -Position).magnitude <= Distance then
  96. table.insert(List,v)
  97. end
  98. end
  99. end
  100. end
  101. end
  102. return List
  103. end
  104.  
  105. it=Instance.new
  106.  
  107. function weldkek(prt,obj,cframe1,cframe2,cframe3,angles1,angles2,angles3)
  108. coroutine.resume(coroutine.create(function()
  109. for i=1, math.huge, 4 do
  110. rs:wait()
  111. if angles1 or angles2 or angles3 == nil then angles1 = 0,0,0 end
  112. if cframe1 or cframe2 or cframe3 == nil then cframe1 = 0,0,0 end
  113. if prt == nil then print("Error:Code 1;Not found first part") end
  114. if obj == nil then print("Error:Code 2;Not found second part") end
  115. prt.CFrame = obj.CFrame*CFrame.new(cframe1,cframe2,cframe3) * CFrame.Angles(angles1,angles2,angles3)
  116. end
  117. end))
  118. end
  119.  
  120. function weld2(prt,obj,cframe1,cframe2,cframe3,angles1,angles2,angles3)
  121. local w = Instance.new("Weld",obj)
  122. w.Part0 = prt
  123. w.Part1 = obj
  124. w.Parent = obj
  125. w.C0 = CFrame.new(cframe1,cframe2,cframe3) * CFrame.Angles(angles1,angles2,angles3)
  126. end
  127.  
  128. local AddNew = Instance.new
  129.  
  130. function rainbowgui2(kek)
  131. coroutine.wrap(function()
  132. while true do
  133. for i = 0,2,0.01 do
  134. kek.BackgroundColor3 = kek.BackgroundColor3:lerp(Color3.new(255/26, 255/255, 225/255), i / 100)
  135. wait()
  136. end
  137. for i = 0,2,0.01 do
  138. kek.BackgroundColor3 = kek.BackgroundColor3:lerp(Color3.new(30/255, 41/ 255, 255/255), i / 100)
  139. wait()
  140. end
  141. for i = 1,2,0.01 do
  142. kek.BackgroundColor3 = kek.BackgroundColor3:lerp(Color3.new(43/255, 170/255, 255/255), i / 100)
  143. wait()
  144. end
  145. for i = 1,2,0.01 do
  146. kek.BackgroundColor3 = kek.BackgroundColor3:lerp(Color3.new(43/255, 255/255, 50/255), i / 100)
  147. wait()
  148. end
  149. for i = 1,2,0.01 do
  150. kek.BackgroundColor3 = kek.BackgroundColor3:lerp(Color3.new(245/255, 255/255, 46/255), i / 100)
  151. wait()
  152. end
  153. for i = 1,2,0.01 do
  154. kek.BackgroundColor3 = kek.BackgroundColor3:lerp(Color3.new(255/255, 0/255, 0/255), i / 100)
  155. wait()
  156. end
  157. wait()
  158. end
  159. end)()
  160. end
  161.  
  162.  
  163.  
  164. function rainbowgui(kek)
  165. coroutine.wrap(function()
  166. while true do
  167. for i = 0,2,0.01 do
  168. kek.BackgroundColor3 = kek.BackgroundColor3:lerp(Color3.new(255/255, 26/255, 225/255), i / 100)
  169. wait()
  170. end
  171. for i = 0,2,0.01 do
  172. kek.BackgroundColor3 = kek.BackgroundColor3:lerp(Color3.new(30/255, 41/ 255, 255/255), i / 100)
  173. wait()
  174. end
  175. for i = 1,2,0.01 do
  176. kek.BackgroundColor3 = kek.BackgroundColor3:lerp(Color3.new(43/255, 170/255, 255/255), i / 100)
  177. wait()
  178. end
  179. for i = 1,2,0.01 do
  180. kek.BackgroundColor3 = kek.BackgroundColor3:lerp(Color3.new(43/255, 255/255, 50/255), i / 100)
  181. wait()
  182. end
  183. for i = 1,2,0.01 do
  184. kek.BackgroundColor3 = kek.BackgroundColor3:lerp(Color3.new(245/255, 255/255, 46/255), i / 100)
  185. wait()
  186. end
  187. for i = 1,2,0.01 do
  188. kek.BackgroundColor3 = kek.BackgroundColor3:lerp(Color3.new(255/255, 0/255, 0/255), i / 100)
  189. wait()
  190. end
  191. wait()
  192. end
  193. end)()
  194. end
  195.  
  196.  
  197.  
  198. function LerpCFrame(CFrame1,CFrame2,Num)
  199. local Vec,Ang = toAxisAngle(CFrame1:inverse()*CFrame2)
  200. return CFrame1*fromAxisAngle(Vec,Ang*Num) + (CFrame2.p-CFrame1.p)*Num
  201. end
  202.  
  203. function genWeld(a,b)
  204. local w = Instance.new("Weld",a)
  205. w.Part0 = a
  206. w.Part1 = b
  207. return w
  208. end
  209. function weld(a, b)
  210. local weld = Instance.new("Weld")
  211. weld.Name = "W"
  212. weld.Part0 = a
  213. weld.Part1 = b
  214. weld.C0 = a.CFrame:inverse() * b.CFrame
  215. weld.Parent = a
  216. return weld;
  217. end
  218. ----------------------------------------------------
  219. ypcall(function()
  220. print("hi")
  221. end)
  222.  
  223. ----------------------------------------------------
  224. newWeld = function(wp0, wp1, wc0x, wc0y, wc0z)
  225. local wld = Instance.new("Weld", wp1)
  226. wld.Part0 = wp0
  227. wld.Part1 = wp1
  228. wld.C0 = CFrame.new(wc0x, wc0y, wc0z)
  229. end
  230. ----------------------------------------------------
  231. function weld5(part0, part1, c0, c1)
  232. weeld=Instance.new("Weld", part0)
  233. weeld.Part0=part0
  234. weeld.Part1=part1
  235. weeld.C0=c0
  236. weeld.C1=c1
  237. return weeld
  238. end
  239. ----------------------------------------------------
  240.  
  241. function NoOutline(Part)
  242. Part.TopSurface, Part.BottomSurface, Part.LeftSurface, Part.RightSurface, Part.FrontSurface, Part.BackSurface = 10, 10, 10, 10, 10, 10
  243. end
  244. function swait(num)
  245. if num == 0 or num == nil then
  246. game:service'RunService'.Heartbeat:wait(0)
  247. else
  248. for i = 0, num do
  249. game:service'RunService'.Heartbeat:wait(0)
  250. end
  251. end
  252. end
  253.  
  254. function nooutline(part)
  255. part.TopSurface, part.BottomSurface, part.LeftSurface, part.RightSurface, part.FrontSurface, part.BackSurface = 10, 10, 10, 10, 10, 10
  256. end
  257.  
  258. function part(formfactor, parent, material, reflectance, transparency, brickcolor, name, size)
  259. local fp = Create("Part"){
  260. formFactor = formfactor,
  261. Parent = parent,
  262. Reflectance = reflectance,
  263. Transparency = transparency,
  264. CanCollide = false,
  265. Locked = true,
  266. BrickColor = BrickColor.new(tostring(brickcolor)),
  267. Name = name,
  268. Size = size,
  269. Position = Character.Torso.Position,
  270. Material = material,
  271. }
  272. nooutline(fp)
  273. return fp
  274. end
  275.  
  276. function mesh(Mesh, part, meshtype, meshid, offset, scale)
  277. local Msh = Create(Mesh){
  278. Parent = part,
  279. Offset = offset,
  280. Scale = scale,
  281. }
  282. if Mesh == "SpecialMesh" then
  283. Msh.MeshType = meshtype
  284. Msh.MeshId = meshid
  285. end
  286. return Msh
  287. end
  288.  
  289.  
  290. function so(id, par, vol, pit)
  291. coroutine.resume(coroutine.create(function()
  292. local sou = Instance.new("Sound", par or workspace)
  293. sou.Volume = vol or 1
  294. sou.Pitch = pit or 1
  295. sou.SoundId = Sounds[id].Id or id
  296. swait()
  297. sou:Play()
  298. end))
  299. end
  300.  
  301. function weld(parent, part0, part1, c0, c1)
  302. local Weld = Create("Weld"){
  303. Parent = parent,
  304. Part0 = part0,
  305. Part1 = part1,
  306. C0 = c0,
  307. C1 = c1,
  308. }
  309. return Weld
  310. end
  311.  
  312. ----------------------------------------------------
  313.  
  314. local val = 0
  315. local mas = 0
  316.  
  317. on = false
  318.  
  319.  
  320. Surfaces = {"FrontSurface", "BackSurface", "TopSurface", "BottomSurface", "LeftSurface", "RightSurface"}
  321.  
  322. function Part(Parent, Anchor, Collide, Tran, Ref, Color, X, Y, Z, Break)
  323. local p = Instance.new("Part")
  324. p.formFactor = "Custom"
  325. p.Anchored = Anchor
  326. p.CanCollide = Collide
  327. p.Transparency = Tran
  328. p.Reflectance = Ref
  329. p.BrickColor = BrickColor.new(Color)
  330. for _, Surf in pairs(Surfaces) do
  331. p[Surf] = "Smooth"
  332. end
  333. p.Size = Vector3.new(X, Y, Z)
  334. if Break then
  335. p:BreakJoints()
  336. else p:MakeJoints() end
  337. p.Parent = Parent
  338. p.Locked = true
  339. return p
  340. end
  341.  
  342. function StartEffect(part,sizeX,sizeY)
  343. effectOn = true
  344. local lastPoint = part.Position
  345. coroutine.resume(coroutine.create(function()
  346. while effectOn do
  347. rs:wait()
  348. local point = CFrame.new(lastPoint, part.Position) * CFrame.Angles(-math.pi/2, 0, 0)
  349. local mag = (lastPoint - part.Position).magnitude
  350. local p = Part(workspace, true, false, 0.1, 0, "Institutional white", 1, 1, 1, true)
  351. p.Material = "Neon"
  352. p.Size = Vector3.new(sizeX, mag+0.1, sizeY)
  353. p.CFrame = point * CFrame.new(0, mag/6, 0)
  354. lastPoint = part.Position
  355. coroutine.resume(coroutine.create(function() for i = 0.1, 1, 0.9/5 do wait() p.Transparency = i end p:remove() end))
  356. end
  357. end))
  358. end
  359.  
  360. function EndEffect()
  361. effectOn = false
  362. end
  363.  
  364. stance = "Normal"
  365.  
  366. for i,v in pairs(char:GetChildren()) do
  367. if v:IsA("Accoutrement") then
  368. v.Handle.Transparency = 1
  369. end
  370. end
  371.  
  372. hed.face.Texture = "rbxassetid://245007392"
  373. char["Body Colors"].HeadColor = BrickColor.new("Pastel brown")
  374. char["Body Colors"].TorsoColor = BrickColor.new("Pastel brown")
  375. char["Body Colors"].LeftArmColor = BrickColor.new("Pastel brown")
  376. char["Body Colors"].RightArmColor = BrickColor.new("Pastel brown")
  377. char["Body Colors"].LeftLegColor = BrickColor.new("Pastel brown")
  378. char["Body Colors"].RightLegColor = BrickColor.new("Pastel brown")
  379. ----------------------------------------------------
  380. ypcall(function()
  381. char.Shirt:Destroy()
  382. char.Pants:Destroy()
  383. shirt = Instance.new("Shirt", char)
  384. shirt.Name = "Shirt"
  385. pants = Instance.new("Pants", char)
  386. pants.Name = "Pants"
  387. char.Shirt.ShirtTemplate = "rbxassetid://442081908"
  388. char.Pants.PantsTemplate = "rbxassetid://540138654"
  389. end)
  390. ypcall(function()
  391. char.Pants:Destroy()
  392. shirt = Instance.new("Shirt", char)
  393. shirt.Name = "Shirt"
  394. pants = Instance.new("Pants", char)
  395. pants.Name = "Pants"
  396. char.Shirt.ShirtTemplate = "rbxassetid://442081908"
  397. char.Pants.PantsTemplate = "rbxassetid://540138654"
  398. end)
  399. ypcall(function()
  400. char.Shirt:Destroy()
  401. shirt = Instance.new("Shirt", char)
  402. shirt.Name = "Shirt"
  403. pants = Instance.new("Pants", char)
  404. pants.Name = "Pants"
  405. char.Shirt.ShirtTemplate = "rbxassetid://442081908"
  406. char.Pants.PantsTemplate = "rbxassetid://540138654"
  407. end)
  408. ypcall(function()
  409. shirt = Instance.new("Shirt", char)
  410. shirt.Name = "Shirt"
  411. pants = Instance.new("Pants", char)
  412. pants.Name = "Pants"
  413. char.Shirt.ShirtTemplate = "rbxassetid://442081908"
  414. char.Pants.PantsTemplate = "rbxassetid://540138654"
  415. end)
  416.  
  417.  
  418. ----------------------------------------------------
  419. boyfriend = {}
  420.  
  421. for i,v in pairs(game:GetService("Workspace"):GetChildren()) do
  422. if v.Name ~= p.Name then
  423. if v:IsA("Model") and v:FindFirstChild("Torso") ~= nil and game:GetService("Players"):FindFirstChild(v.Name) ~= nil then
  424.  
  425. table.insert(boyfriend,v)
  426.  
  427. local char2 = game:GetService("Players"):FindFirstChild(v.Name).Character
  428. local hed2 = char2.Head
  429.  
  430. for i,v in pairs(char2:GetChildren()) do
  431. if v:IsA("Accoutrement") then
  432. v.Handle.Transparency = 1
  433. end
  434. end
  435.  
  436. char2["Body Colors"].HeadColor = BrickColor.new("Pastel brown")
  437. char2["Body Colors"].TorsoColor = BrickColor.new("Pastel brown")
  438. char2["Body Colors"].LeftArmColor = BrickColor.new("Pastel brown")
  439. char2["Body Colors"].RightArmColor = BrickColor.new("Pastel brown")
  440. char2["Body Colors"].LeftLegColor = BrickColor.new("Pastel brown")
  441. char2["Body Colors"].RightLegColor = BrickColor.new("Pastel brown")
  442.  
  443.  
  444. local sw2 = Instance.new("Part",hed2)
  445. sw2.CanCollide = false
  446.  
  447. local m2 = Instance.new("SpecialMesh",sw2)
  448. m2.MeshId = "rbxassetid://480249046"
  449. m2.TextureId = "rbxassetid://480249058"
  450. m2.Scale = Vector3.new(0.055,0.055,0.055)
  451. local w2 = Instance.new("Weld")
  452.  
  453. char2.Humanoid.MaxHealth = 350
  454.  
  455. w2.Part1 = sw2
  456. w2.Part0 = hed2
  457. w2.Parent = char2
  458. w2.C0 = CFrame.new(0,0,0)*CFrame.Angles(math.rad(0),math.pi,0)
  459. pcall(function()
  460. sc2 = game:GetService("Players"):FindFirstChild(v.Name).PlayerGui
  461. local sc = Instance.new("ScreenGui",sc2)
  462. sc.Name = "kek"
  463.  
  464. local f = Instance.new("TextLabel",sc)
  465. f.Size = UDim2.new(1, 0, 0.25, 0)
  466. f.Position = UDim2.new(-1.5, 0, 0.5, 0)
  467.  
  468. coroutine.wrap(function()
  469. for i = 1, 20 do
  470. f.Position = f.Position + UDim2.new(1.5/20, 0, 0, 0)
  471. wait()
  472. end
  473. end)()
  474. end)
  475.  
  476. sc3 =p.PlayerGui
  477. local sc4 = Instance.new("ScreenGui",sc3)
  478. sc4.Name = "kek"
  479.  
  480. local f2 = Instance.new("TextLabel",sc4)
  481. f2.Size = UDim2.new(1, 0, 0.25, 0)
  482. f2.Position = UDim2.new(-1.5, 0, 0.5, 0)
  483.  
  484. coroutine.wrap(function()
  485. for i = 1, 20 do
  486. f2.Position = f2.Position + UDim2.new(1.5/20, 0, 0, 0)
  487. wait()
  488. end
  489. end)()
  490.  
  491. f2.FontSize = "Size32"
  492. f2.Text = "Congrats! You're now the psycopatch stalker that stalks "..char2.Name.."!"
  493. f2.TextColor3 = Color3.new(1,1,1)
  494. f2.BackgroundTransparency = 0.3
  495.  
  496. coroutine.wrap(function()
  497. wait(2.5)
  498. for i = 1, 20 do
  499. f2.Position = f2.Position - UDim2.new(1.5/20, 0, 0, 0)
  500. wait()
  501. end
  502. f2:Destroy()
  503. end)()
  504.  
  505.  
  506. pcall(function()
  507. f.FontSize = "Size32"
  508. f.Text = "Congrats! You're now the boyfriend of a psycopatch stalker!"
  509. f.TextColor3 = Color3.new(1,1,1)
  510. f.BackgroundTransparency = 0.3
  511.  
  512. coroutine.wrap(function()
  513. wait(2.5)
  514. for i = 1, 20 do
  515. f.Position = f.Position - UDim2.new(1.5/20, 0, 0, 0)
  516. wait()
  517. end
  518. f:Destroy()
  519. end)()
  520. end)
  521.  
  522. ----------------------------------------------------
  523. ypcall(function()
  524.  
  525. char2.Shirt:Destroy()
  526. char2.Pants:Destroy()
  527. shirt = Instance.new("Shirt", char2)
  528. shirt.Name = "Shirt"
  529. pants = Instance.new("Pants", char2)
  530. pants.Name = "Pants"
  531. char2.Shirt.ShirtTemplate = "rbxassetid://425693920"
  532. char2.Pants.PantsTemplate = "rbxassetid://425694280"
  533. end)
  534. ----------------------------------------------------
  535. ypcall(function()
  536.  
  537. char2.Shirt:Destroy()
  538. shirt = Instance.new("Shirt", char2)
  539. shirt.Name = "Shirt"
  540. pants = Instance.new("Pants", char2)
  541. pants.Name = "Pants"
  542. char2.Shirt.ShirtTemplate = "rbxassetid://425693920"
  543. char2.Pants.PantsTemplate = "rbxassetid://425694280"
  544. end)
  545. ----------------------------------------------------
  546. ypcall(function()
  547.  
  548. char2.Pants:Destroy()
  549. shirt = Instance.new("Shirt", char2)
  550. shirt.Name = "Shirt"
  551. pants = Instance.new("Pants", char2)
  552. pants.Name = "Pants"
  553. char2.Shirt.ShirtTemplate = "rbxassetid://425693920"
  554. char2.Pants.PantsTemplate = "rbxassetid://425694280"
  555. end)
  556. ----------------------------------------------------
  557. ypcall(function()
  558.  
  559. char2.Shirt:Destroy()
  560. char2.Pants:Destroy()
  561. shirt = Instance.new("Shirt", char2)
  562. shirt.Name = "Shirt"
  563. pants = Instance.new("Pants", char2)
  564. pants.Name = "Pants"
  565. char2.Shirt.ShirtTemplate = "rbxassetid://425693920"
  566. char2.Pants.PantsTemplate = "rbxassetid://425694280"
  567. end)
  568. ----------------------------------------------------
  569. ypcall(function()
  570.  
  571. shirt = Instance.new("Shirt", char2)
  572. shirt.Name = "Shirt"
  573. pants = Instance.new("Pants", char2)
  574. pants.Name = "Pants"
  575. char2.Shirt.ShirtTemplate = "rbxassetid://425693920"
  576. char2.Pants.PantsTemplate = "rbxassetid://425694280"
  577. end)
  578.  
  579. local e = Instance.new("Script",char2)
  580. e.Name = "boyfriend"
  581.  
  582. break
  583. end
  584. end
  585. end
  586.  
  587. for i,v in pairs(boyfriend) do
  588. print(v)
  589. end
  590. ----------------------------------------------------------------
  591.  
  592. local sw2 = Instance.new("Part",hed)
  593. sw2.CanCollide = false
  594. sw2.BrickColor = BrickColor.new("Hot pink")
  595.  
  596. local m2 = Instance.new("SpecialMesh",sw2)
  597. m2.MeshId = "rbxassetid://430440803"
  598. m2.Scale = Vector3.new(0.006,0.006,0.006)
  599. local w2 = Instance.new("Weld")
  600.  
  601. w2.Part1 = sw2
  602. w2.Part0 = hed
  603. w2.Parent = char
  604. w2.C0 = CFrame.new(0,-0.9,0)*CFrame.Angles(math.rad(0),math.pi/2,0)
  605.  
  606. local sw = Instance.new("Part",torso)
  607. sw.CanCollide = false
  608. sw.BrickColor = BrickColor.new("Institutional white")
  609.  
  610. local m = Instance.new("SpecialMesh",sw)
  611. m.MeshId = "rbxassetid://11442510"
  612. m.TextureId = "rbxassetid://11442524"
  613. m.Scale = Vector3.new(2.1,2.1,2.1)
  614. local w1 = Instance.new("Weld")
  615.  
  616. w1.Part1 = sw
  617. w1.Part0 = lleg
  618. w1.Parent = char
  619. w1.C0 = CFrame.new(0,-2,0)
  620.  
  621. NoSwordAnims = false
  622.  
  623. coroutine.wrap(function()
  624. while true do
  625. wait()
  626. if NoSwordAnims == false then
  627. if stance == "Normal" then
  628. w1.Part0 = lleg
  629. w1.C0 = Lerp(w1.C0,CFrame.new(-0.5,0.5,0) * CFrame.Angles(math.rad(-155),math.pi,math.pi/2),0.3)
  630. elseif stance == "Katana" then
  631. w1.Part0 = larm
  632. w1.C0 = Lerp(w1.C0,CFrame.new(0,-0.7,-2.3) * CFrame.Angles(math.rad(180),0,-20),0.1)
  633. end
  634. end
  635. end
  636. end)()
  637.  
  638.  
  639. ----------------------------------------------------
  640. newWeld(torso, larm, -1.5, 0.5, 0)
  641. larm.Weld.C1 = CFrame.new(0, 0.5, 0) * CFrame.Angles(0,0,0)
  642. newWeld(torso, rarm, 1.5, 0.5, 0)
  643. rarm.Weld.C1 = CFrame.new(0, 0.5, 0) * CFrame.Angles(0,0,0)
  644. newWeld(torso, hed, 0, 1.5, 0)
  645. newWeld(torso, lleg, -0.5, -1, 0)
  646. lleg.Weld.C1 = CFrame.new(0, 1, 0) * CFrame.Angles(0,0,0)
  647. newWeld(torso, rleg, 0.5, -1, 0)
  648. rleg.Weld.C1 = CFrame.new(0, 1, 0) * CFrame.Angles(0,0,0)
  649. newWeld(root, torso, 0, -1, 0)
  650. torso.Weld.C1 = CFrame.new(0, -1, 0) * CFrame.Angles(0,0,0)
  651. local Touche = {char.Name, }
  652. ----------------------------------------------------
  653.  
  654. attack = false
  655. attackhit = false
  656. attacknumber = 0
  657. coroutine.wrap(function()
  658. while true do
  659. rs:wait()
  660. if attacknumber >= 2 then
  661. attacknumber = 0
  662. end
  663. end
  664. end)()
  665. cooldown = 0
  666. stance = "Normal"
  667. local attacking = false
  668. NoAnims = false
  669.  
  670. local ammo = 300
  671. local maxammo = 300
  672.  
  673. coroutine.wrap(function()
  674. while wait() do
  675. if ammo > maxammo then
  676. ammo = maxammo
  677. elseif ammo < maxammo then
  678. ammo = ammo + 1
  679. end
  680. end
  681. end)()
  682.  
  683. attacking = false
  684. local hedattack2 = false
  685. local hedattack = false
  686.  
  687. sw.Touched:connect(function(ht)
  688. if hedattack == true then
  689. hit = ht.Parent
  690. if ht and hit:IsA("Model") then
  691. if hit:FindFirstChild("Humanoid") then
  692. if hit.Name ~= p.Name then
  693. hit:FindFirstChild("Humanoid"):TakeDamage(math.random(hit.Humanoid.MaxHealth/2,hit.Humanoid.MaxHealth))
  694. z = Instance.new("Sound",hed)
  695. z.SoundId = "rbxassetid://169380525"
  696. z.Pitch = ptz[math.random(1,#ptz)]
  697. z.Volume = 1
  698. z:Play()
  699. hedattack2 = false
  700. hedattack = false
  701. decals = {263033191,189728908,178269340,181477718,498948943,485362831,360385366,144325140}
  702. decals2 = {284846352,191089587}
  703.  
  704. local e = Instance.new("Decal",sw)
  705. e.Texture = "rbxassetid://"..decals[math.random(1,#decals)]
  706. e.Face = "Left"
  707.  
  708. local e2 = Instance.new("Decal",sw)
  709. e2.Texture = e.Texture
  710. e2.Face = "Right"
  711. end
  712. end
  713. elseif ht and hit:IsA("Hat") then
  714. if hit.Parent.Name ~= p.Name then
  715. if hit.Parent:FindFirstChild("Humanoid") then
  716. hit.Parent:FindFirstChild("Humanoid"):TakeDamage(math.random(hit.Parent.Humanoid.MaxHealth/2,hit.Parent.Humanoid.MaxHealth))
  717. z = Instance.new("Sound",hed)
  718. z.SoundId = "rbxassetid://169380525"
  719. hedattack2 = false
  720. hedattack = false
  721. z.Pitch = ptz[math.random(1,#ptz)]
  722. z.Volume = 1
  723. z:Play()
  724. decals = {263033191,189728908,178269340,181477718,498948943,485362831,360385366,144325140}
  725. decals2 = {284846352,191089587}
  726.  
  727. local e = Instance.new("Decal",sw)
  728. e.Texture = "rbxassetid://"..decals[math.random(1,#decals)]
  729. e.Face = "Left"
  730.  
  731. local e2 = Instance.new("Decal",sw)
  732. e2.Texture = e.Texture
  733. e2.Face = "Right"
  734. end
  735. end
  736. end
  737. end
  738. end)
  739.  
  740. --------------------attacks------------------
  741.  
  742. mouse.KeyDown:connect(function(key)
  743. if key == "x" then
  744. if cooldown == 0 and attacking == false then
  745. NoAnims = true
  746. attacking = true
  747. cooldown = 1
  748.  
  749. coroutine.wrap(function()
  750. while true do
  751.  
  752. rarm.Weld.C0 = Lerp(rarm.Weld.C0, CFrame.new(1.5 ,0.6,0)*CFrame.Angles(math.rad(90),0,.005), 0.2)
  753.  
  754. larm.Weld.C0 = Lerp(larm.Weld.C0, CFrame.new(-1.5,0.6,0)*CFrame.Angles(math.rad(90),0,-.005), 0.2)
  755.  
  756. hed.Weld.C0 = Lerp(hed.Weld.C0, CFrame.new(0,1.5,0)*CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)),0.2)
  757.  
  758. torso.Weld.C0 = Lerp(torso.Weld.C0, CFrame.new(0, -1 , 0) * CFrame.Angles(math.rad(0), 0, math.rad(0)), 0.2)
  759.  
  760. lleg.Weld.C0 = Lerp(lleg.Weld.C0, CFrame.new(-0.5, -1, 0) * CFrame.Angles(math.rad(0), 0, -0.05), .4)
  761.  
  762. rleg.Weld.C0 = Lerp(rleg.Weld.C0, CFrame.new(0.5, -1, 0) * CFrame.Angles(math.rad(0), 0, 0.05), .4)
  763.  
  764. if cooldown == 0 then break end
  765.  
  766. rs:wait()
  767. end
  768. end)()
  769.  
  770. end
  771. end
  772. end)
  773.  
  774. mouse.KeyUp:connect(function(key)
  775. if key == "x" then
  776. NoAnims = false
  777. cooldown = 0
  778. attacking = false
  779. end
  780. end)
  781.  
  782.  
  783. function onclick(mouses)
  784. if attacking == false and cooldown == 0 then
  785. if stance == "Katana" then
  786. attacking = true
  787. cooldown = 1
  788. NoAnims = true
  789.  
  790. StartEffect(sw,0.01,4)
  791.  
  792. for i = 1, 20 do
  793.  
  794. rarm.Weld.C0 = Lerp(rarm.Weld.C0, CFrame.new(0.5 ,0.6,-0.8)*CFrame.Angles(math.rad(240),0,-math.pi/3), 0.2)
  795.  
  796. larm.Weld.C0 = Lerp(larm.Weld.C0, CFrame.new(-1,0.6,-0.4)*CFrame.Angles(math.rad(240),0,math.pi/6), 0.1)
  797.  
  798. hed.Weld.C0 = Lerp(hed.Weld.C0, CFrame.new(0,1.5,0)*CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)),0.1)
  799.  
  800. torso.Weld.C0 = Lerp(torso.Weld.C0, CFrame.new(0, -1 , 0) * CFrame.Angles(math.rad(0), 0, math.rad(0)), 0.1)
  801.  
  802. lleg.Weld.C0 = Lerp(lleg.Weld.C0, CFrame.new(-0.5, -1, 0) * CFrame.Angles(math.rad(0), 0, -0.05), .1)
  803.  
  804. rleg.Weld.C0 = Lerp(rleg.Weld.C0, CFrame.new(0.5, -1, 0) * CFrame.Angles(math.rad(0), 0, 0.05), .1)
  805. end
  806.  
  807. StartEffect(sw,0.01,4)
  808. hedattack = true
  809. so("rbxassetid://553461718")
  810.  
  811. for i = 1, 3 do
  812.  
  813. rarm.Weld.C0 = Lerp(rarm.Weld.C0, CFrame.new(0.5 ,0.3,-0.8)*CFrame.Angles(math.rad(20),0,-math.pi/3), 0.1)
  814.  
  815. larm.Weld.C0 = Lerp(larm.Weld.C0, CFrame.new(-1,0.3,-0.4)*CFrame.Angles(math.rad(20),0,math.pi/6), 0.1)
  816.  
  817. hed.Weld.C0 = Lerp(hed.Weld.C0, CFrame.new(0,1.5,0)*CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)),0.2)
  818.  
  819. torso.Weld.C0 = Lerp(torso.Weld.C0, CFrame.new(0, -1 , 0) * CFrame.Angles(math.rad(0), 0, math.rad(0)), 0.1)
  820.  
  821. lleg.Weld.C0 = Lerp(lleg.Weld.C0, CFrame.new(-0.5, -1, 0) * CFrame.Angles(math.rad(0), 0, -0.05), .1)
  822.  
  823. rleg.Weld.C0 = Lerp(rleg.Weld.C0, CFrame.new(0.5, -1, 0) * CFrame.Angles(math.rad(0), 0, 0.05), .1)
  824.  
  825. rs:wait()
  826. end
  827.  
  828. EndEffect()
  829. NoAnims = false
  830. cooldown = 0
  831. attacking = false
  832. hedattack = false
  833.  
  834. end
  835. end
  836. end
  837.  
  838. mouse.Button1Down:connect(onclick)
  839.  
  840. mouse.KeyDown:connect(function(key)
  841. if key == "f" then
  842. if attacking == false and cooldown == 0 then
  843. if stance == "Normal" then
  844. attacking = true
  845. cooldown = 1
  846. NoAnims = true
  847. stance = "Katana"
  848.  
  849. StartEffect(sw,0.01,4)
  850.  
  851. for i = 1, 20 do
  852.  
  853. rarm.Weld.C0 = Lerp(rarm.Weld.C0, CFrame.new(0.5 ,0.3,-0.8)*CFrame.Angles(math.rad(60),0,-math.pi/3), 0.2)
  854.  
  855. larm.Weld.C0 = Lerp(larm.Weld.C0, CFrame.new(-1,0.3,-0.4)*CFrame.Angles(math.rad(60),0,math.pi/6), 0.2)
  856.  
  857. hed.Weld.C0 = Lerp(hed.Weld.C0, CFrame.new(0,1.5,0)*CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)),0.2)
  858.  
  859. torso.Weld.C0 = Lerp(torso.Weld.C0, CFrame.new(0, -1 , 0) * CFrame.Angles(math.rad(0), 0, math.rad(0)), 0.2)
  860.  
  861. lleg.Weld.C0 = Lerp(lleg.Weld.C0, CFrame.new(-0.5, -1, 0) * CFrame.Angles(math.rad(0), 0, -0.05), .4)
  862.  
  863. rleg.Weld.C0 = Lerp(rleg.Weld.C0, CFrame.new(0.5, -1, 0) * CFrame.Angles(math.rad(0), 0, 0.05), .4)
  864. end
  865.  
  866. so("rbxassetid://152052659")
  867.  
  868. for i = 1, 20 do
  869.  
  870. rarm.Weld.C0 = Lerp(rarm.Weld.C0, CFrame.new(0.5 ,0.3,-0.8)*CFrame.Angles(math.rad(60),0,-math.pi/3), 0.2)
  871.  
  872. larm.Weld.C0 = Lerp(larm.Weld.C0, CFrame.new(-1,0.3,-0.4)*CFrame.Angles(math.rad(120),0,math.pi/6), 0.2)
  873.  
  874. hed.Weld.C0 = Lerp(hed.Weld.C0, CFrame.new(0,1.5,0)*CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)),0.2)
  875.  
  876. torso.Weld.C0 = Lerp(torso.Weld.C0, CFrame.new(0, -1 , 0) * CFrame.Angles(math.rad(0), 0, math.rad(0)), 0.2)
  877.  
  878. lleg.Weld.C0 = Lerp(lleg.Weld.C0, CFrame.new(-0.5, -1, 0) * CFrame.Angles(math.rad(0), 0, -0.05), .4)
  879.  
  880. rleg.Weld.C0 = Lerp(rleg.Weld.C0, CFrame.new(0.5, -1, 0) * CFrame.Angles(math.rad(0), 0, 0.05), .4)
  881.  
  882. rs:wait()
  883. end
  884.  
  885. EndEffect()
  886. NoAnims = false
  887. cooldown = 0
  888. attacking = false
  889. elseif stance == "Katana" then
  890.  
  891. attacking = true
  892. cooldown = 1
  893. NoAnims = true
  894. NoSwordAnims = true
  895. stance = "Normal"
  896. for i = 1, 20 do
  897. end
  898.  
  899. NoSwordAnims = false
  900. NoAnims = false
  901. cooldown = 0
  902. attacking = false
  903.  
  904. end
  905. end
  906. end
  907. end)
  908.  
  909.  
  910. -----------GUI creation--------------------
  911.  
  912. local pg = p.PlayerGui
  913.  
  914. local sg = Instance.new("ScreenGui",pg)
  915. sg.Name = "rage"
  916.  
  917. local txt = Instance.new("TextLabel",sg)
  918. txt.Position = UDim2.new(0.9, 0, 0.9, 0)
  919. txt.BackgroundTransparency = 1
  920. txt.FontSize = "Size24"
  921.  
  922. coroutine.wrap(function()
  923. while true do
  924. wait()
  925. txt.TextColor3 = Color3.new(ammo,ammo,ammo)
  926. end
  927. end)()
  928.  
  929. coroutine.wrap(function()
  930. while true do
  931. wait()
  932. txt.Text = ammo.."/"..maxammo
  933. end
  934. end)()
  935.  
  936. ----------------------------------------------
  937. -------------------------------
  938. local animpose = "Idle"
  939. local lastanimpose = "Idle"
  940. local sine = 0
  941. local change = 1
  942. local val = 0
  943. local ffing = false
  944. local jump = false
  945. -------------------------------
  946. local x = Instance.new("Sound", char)
  947. x.SoundId = "http://www.roblox.com/asset/?id=429617891"
  948. x.Looped = true
  949. x.Volume = 1
  950. x.Pitch = 1
  951. local footsteps = false
  952. -------------------------------
  953. game:GetService("RunService").RenderStepped:connect(function()
  954. --[[if char.Humanoid.Jump == true then
  955. jump = true
  956. else
  957. jump = false
  958. end]]
  959. char.Humanoid.FreeFalling:connect(function(f)
  960. if f then
  961. ffing = true
  962. else
  963. ffing = false
  964. end
  965. end)
  966. sine = sine + change
  967. if jump == true then
  968. animpose = "Jumping"
  969. elseif ffing == true then
  970. animpose = "Freefalling"
  971. elseif (torso.Velocity*Vector3.new(1, 0, 1)).magnitude < 2 then
  972. animpose = "Idle"
  973. elseif (torso.Velocity*Vector3.new(1, 0, 1)).magnitude < 20 then
  974. animpose = "Walking"
  975. elseif (torso.Velocity*Vector3.new(1, 0, 1)).magnitude > 20 then
  976. animpose = "Running"
  977. end
  978. if animpose ~= lastanimpose then
  979. sine = 0
  980. if NoAnims == false then
  981. if animpose == "Idle" then
  982. for i = 1, 0.5 do
  983.  
  984. if NoAnims == false then
  985.  
  986. if stance == "Normal" then
  987. rarm.Weld.C0 = Lerp(rarm.Weld.C0, CFrame.new(1.5 ,0.6+ -math.sin(sine/14)/30,0)*CFrame.Angles(math.rad(0),0,.05+ math.sin(sine/7)/14), 0.2)
  988.  
  989. larm.Weld.C0 = Lerp(larm.Weld.C0, CFrame.new(-1.5,0.6+ -math.sin(sine/14)/30,0)*CFrame.Angles(math.rad(0),0,-.05+ -math.sin(sine/7)/14), 0.2)
  990.  
  991. hed.Weld.C0 = Lerp(hed.Weld.C0, CFrame.new(0,1.5,0)*CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)),0.2)
  992.  
  993. torso.Weld.C0 = Lerp(torso.Weld.C0, CFrame.new(0, -1 , 0) * CFrame.Angles(math.rad(0), 0, math.rad(0)), 0.2)
  994.  
  995. lleg.Weld.C0 = Lerp(lleg.Weld.C0, CFrame.new(-0.5, -1, 0) * CFrame.Angles(math.rad(0), 0, -0.05+ math.sin(sine/7)/30), .4)
  996.  
  997. rleg.Weld.C0 = Lerp(rleg.Weld.C0, CFrame.new(0.5, -1, 0) * CFrame.Angles(math.rad(0), 0, 0.05+ -math.sin(sine/7)/30), .4)
  998.  
  999. elseif stance == "Katana" then
  1000.  
  1001. rarm.Weld.C0 = Lerp(rarm.Weld.C0, CFrame.new(1.5 ,0.6+ -math.sin(sine/14)/30,0)*CFrame.Angles(math.rad(0),0,.05+ math.sin(sine/7)/14), 0.2)
  1002.  
  1003. larm.Weld.C0 = Lerp(larm.Weld.C0, CFrame.new(-1.5,0.6+ -math.sin(sine/14)/30,0)*CFrame.Angles(math.rad(0),math.pi,-.05+ -math.sin(sine/7)/14), 0.2)
  1004.  
  1005. hed.Weld.C0 = Lerp(hed.Weld.C0, CFrame.new(0,1.5,0)*CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)),0.2)
  1006.  
  1007. torso.Weld.C0 = Lerp(torso.Weld.C0, CFrame.new(0, -1 , 0) * CFrame.Angles(math.rad(0), 0, math.rad(0)), 0.2)
  1008.  
  1009. lleg.Weld.C0 = Lerp(lleg.Weld.C0, CFrame.new(-0.5, -1, 0) * CFrame.Angles(math.rad(0), 0, -0.05+ math.sin(sine/7)/30), .4)
  1010.  
  1011. rleg.Weld.C0 = Lerp(rleg.Weld.C0, CFrame.new(0.5, -1, 0) * CFrame.Angles(math.rad(0), 0, 0.05+ -math.sin(sine/7)/30), .4)
  1012.  
  1013. end
  1014.  
  1015. wait()
  1016. end
  1017. end
  1018.  
  1019.  
  1020. elseif animpose == "Running" then
  1021. change = 1
  1022. if NoAnims == false then
  1023.  
  1024. rarm.Weld.C0 = Lerp(rarm.Weld.C0, CFrame.new(1.5 * sizem,.3 * sizem,.1 * sizem)*CFrame.Angles(math.rad(-30),0,0), 0.2)
  1025.  
  1026. larm.Weld.C0 =Lerp(larm.Weld.C0, CFrame.new(-1.5 * sizem,.3 * sizem,.1 * sizem)*CFrame.Angles(math.rad(-30),0,0),0.2)
  1027.  
  1028. hed.Weld.C0 = Lerp(hed.Weld.C0, CFrame.new(0,1.5 * sizem,0)*CFrame.Angles(math.rad(0),0,0),0.2)
  1029.  
  1030. torso.Weld.C0 =Lerp(torso.Weld.C0, CFrame.new(0,1,0)*CFrame.Angles(math.rad(-30),0,0),0.2)
  1031.  
  1032. lleg.Weld.C0 = Lerp(lleg.Weld.C0, CFrame.new(-.5 * sizem - .2,-1 * sizem,0 * sizem)*CFrame.Angles(math.rad(-30),0,0),0.2)
  1033.  
  1034. rleg.Weld.C0 = Lerp(rleg.Weld.C0, CFrame.new(.5 * sizem,-1 * sizem,0 * sizem)*CFrame.Angles(math.rad(-30),0,0),0.2)
  1035.  
  1036.  
  1037.  
  1038. end
  1039.  
  1040. elseif animpose == "Walking" then
  1041. for i = 1, 1.5 do
  1042. if NoAnims == false then
  1043.  
  1044. if stance == "Normal" then
  1045. rarm.Weld.C0 = Lerp(rarm.Weld.C0, CFrame.new(1.5 ,0.6+ -math.sin(sine/14)/30,0)*CFrame.Angles(math.rad(0) + -math.sin(sine/5)/2,0,.2+ -math.sin(sine/7)/9), 0.2)
  1046.  
  1047. larm.Weld.C0 = Lerp(larm.Weld.C0, CFrame.new(-1.5,0.6+ -math.sin(sine/14)/30,0)*CFrame.Angles(math.rad(0) + math.sin(sine/5)/2,0,-.2+ math.sin(sine/7)/9), 0.2)
  1048.  
  1049. hed.Weld.C0 = Lerp(hed.Weld.C0, CFrame.new(0,1.5,0)*CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)),0.2)
  1050.  
  1051. torso.Weld.C0 = Lerp(torso.Weld.C0, CFrame.new(0, -1 , 0) * CFrame.Angles(math.rad(0), 0, math.rad(0)), 0.2)
  1052.  
  1053. lleg.Weld.C0 = Lerp(lleg.Weld.C0, CFrame.new(-0.5, -1 - 0.3*math.cos(sine/7)/6, 0) * CFrame.Angles(math.rad(0) + math.sin(sine/5)/2, 0, 0+ math.sin(sine/7)/30), .4)
  1054.  
  1055. rleg.Weld.C0 = Lerp(rleg.Weld.C0, CFrame.new(0.5, -1 - 0.3*math.cos(sine/7)/6, 0) * CFrame.Angles(math.rad(0) + -math.sin(sine/5)/2, 0, 0+ -math.sin(sine/7)/30), .4)
  1056. end
  1057.  
  1058. elseif stance == "Katana" then
  1059.  
  1060. rarm.Weld.C0 = Lerp(rarm.Weld.C0, CFrame.new(1.5 ,0.6+ -math.sin(sine/14)/30,0)*CFrame.Angles(math.rad(0) + -math.sin(sine/5)/2,0,.2+ -math.sin(sine/7)/9), 0.2)
  1061.  
  1062. larm.Weld.C0 = Lerp(larm.Weld.C0, CFrame.new(-1.5,0.6+ -math.sin(sine/14)/30,0)*CFrame.Angles(math.rad(0) + math.sin(sine/5)/2,0,-.2+ math.sin(sine/7)/9), 0.2)
  1063.  
  1064. hed.Weld.C0 = Lerp(hed.Weld.C0, CFrame.new(0,1.5,0)*CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)),0.2)
  1065.  
  1066. torso.Weld.C0 = Lerp(torso.Weld.C0, CFrame.new(0, -1 , 0) * CFrame.Angles(math.rad(0), 0, math.rad(0)), 0.2)
  1067.  
  1068. lleg.Weld.C0 = Lerp(lleg.Weld.C0, CFrame.new(-0.5, -1 - 0.3*math.cos(sine/7)/6, 0) * CFrame.Angles(math.rad(0) + math.sin(sine/5)/2, 0, 0+ math.sin(sine/7)/30), .4)
  1069.  
  1070. rleg.Weld.C0 = Lerp(rleg.Weld.C0, CFrame.new(0.5, -1 - 0.3*math.cos(sine/7)/6, 0) * CFrame.Angles(math.rad(0) + -math.sin(sine/5)/2, 0, 0+ -math.sin(sine/7)/30), .4)
  1071.  
  1072. wait()
  1073. end
  1074. end
  1075. end
  1076. else
  1077. end
  1078. end
  1079. lastanimpose = animpose
  1080. if animpose == "Idle" then
  1081. change = 0.5
  1082. if NoAnims == false then
  1083.  
  1084. if stance == "Normal" then
  1085. rarm.Weld.C0 = Lerp(rarm.Weld.C0, CFrame.new(1.5 ,0.6+ -math.sin(sine/14)/30,0)*CFrame.Angles(math.rad(0),0,.05+ math.sin(sine/7)/14), 0.2)
  1086.  
  1087. larm.Weld.C0 = Lerp(larm.Weld.C0, CFrame.new(-1.5,0.6+ -math.sin(sine/14)/30,0)*CFrame.Angles(math.rad(0),0,-.05+ -math.sin(sine/7)/14), 0.2)
  1088.  
  1089. hed.Weld.C0 = Lerp(hed.Weld.C0, CFrame.new(0,1.5,0)*CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)),0.2)
  1090.  
  1091. torso.Weld.C0 = Lerp(torso.Weld.C0, CFrame.new(0, -1 , 0) * CFrame.Angles(math.rad(0), 0, math.rad(0)), 0.2)
  1092.  
  1093. lleg.Weld.C0 = Lerp(lleg.Weld.C0, CFrame.new(-0.5, -1, 0) * CFrame.Angles(math.rad(0), 0, -0.05+ math.sin(sine/7)/30), .4)
  1094.  
  1095. rleg.Weld.C0 = Lerp(rleg.Weld.C0, CFrame.new(0.5, -1, 0) * CFrame.Angles(math.rad(0), 0, 0.05+ -math.sin(sine/7)/30), .4)
  1096.  
  1097. elseif stance == "Katana" then
  1098.  
  1099. rarm.Weld.C0 = Lerp(rarm.Weld.C0, CFrame.new(0.5 ,0.3+ -math.sin(sine/14)/15,-0.8)*CFrame.Angles(math.rad(60),0,-math.pi/3+ math.sin(sine/7)/25), 0.2)
  1100.  
  1101. larm.Weld.C0 = Lerp(larm.Weld.C0, CFrame.new(-1,0.3+ -math.sin(sine/14)/15,-0.4)*CFrame.Angles(math.rad(60),0,math.pi/6+ -math.sin(sine/7)/25), 0.2)
  1102.  
  1103. hed.Weld.C0 = Lerp(hed.Weld.C0, CFrame.new(0,1.5,0)*CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)),0.2)
  1104.  
  1105. torso.Weld.C0 = Lerp(torso.Weld.C0, CFrame.new(0, -1 , 0) * CFrame.Angles(math.rad(0), 0, math.rad(0)), 0.2)
  1106.  
  1107. lleg.Weld.C0 = Lerp(lleg.Weld.C0, CFrame.new(-0.5, -1, 0) * CFrame.Angles(math.rad(0), 0, -0.05+ math.sin(sine/7)/30), .4)
  1108.  
  1109. rleg.Weld.C0 = Lerp(rleg.Weld.C0, CFrame.new(0.5, -1, 0) * CFrame.Angles(math.rad(0), 0, 0.05+ -math.sin(sine/7)/30), .4)
  1110.  
  1111. end
  1112. end
  1113.  
  1114.  
  1115. elseif animpose == "Running" then
  1116. change = 1
  1117. if NoAnims == false then
  1118.  
  1119. rarm.Weld.C0 = Lerp(rarm.Weld.C0, CFrame.new(1.5 * sizem,.3 * sizem,.1 * sizem)*CFrame.Angles(math.rad(-30),0,0), 0.2)
  1120.  
  1121. larm.Weld.C0 =Lerp(larm.Weld.C0, CFrame.new(-1.5 * sizem,.3 * sizem,.1 * sizem)*CFrame.Angles(math.rad(-30),0,0),0.2)
  1122.  
  1123. hed.Weld.C0 = Lerp(hed.Weld.C0, CFrame.new(0,1.5 * sizem,0)*CFrame.Angles(math.rad(0),0,0),0.2)
  1124.  
  1125. torso.Weld.C0 =Lerp(torso.Weld.C0, CFrame.new(0,1,0)*CFrame.Angles(math.rad(-30),0,0),0.2)
  1126.  
  1127. lleg.Weld.C0 = Lerp(lleg.Weld.C0, CFrame.new(-.5 * sizem,-1 * sizem,0 * sizem)*CFrame.Angles(math.rad(-30),0,0),0.2)
  1128.  
  1129. rleg.Weld.C0 = Lerp(rleg.Weld.C0, CFrame.new(.5 * sizem,-1 * sizem,0 * sizem)*CFrame.Angles(math.rad(-30),0,0),0.2)
  1130.  
  1131. end
  1132.  
  1133. elseif animpose == "Walking" then
  1134. change = 1
  1135.  
  1136.  
  1137. if NoAnims == false then
  1138.  
  1139. if stance == "Normal" then
  1140.  
  1141. rarm.Weld.C0 = Lerp(rarm.Weld.C0, CFrame.new(1.5 ,0.6+ -math.sin(sine/14)/30,0)*CFrame.Angles(math.rad(0) + -math.sin(sine/5)/2,0,.2+ -math.sin(sine/7)/9), 0.2)
  1142.  
  1143. larm.Weld.C0 = Lerp(larm.Weld.C0, CFrame.new(-1.5,0.6+ -math.sin(sine/14)/30,0)*CFrame.Angles(math.rad(0) + math.sin(sine/5)/2,0,-.2+ math.sin(sine/7)/9), 0.2)
  1144.  
  1145. hed.Weld.C0 = Lerp(hed.Weld.C0, CFrame.new(0,1.5,0)*CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)),0.2)
  1146.  
  1147. torso.Weld.C0 = Lerp(torso.Weld.C0, CFrame.new(0, -1 , 0) * CFrame.Angles(math.rad(0), 0, math.rad(0)), 0.2)
  1148.  
  1149. lleg.Weld.C0 = Lerp(lleg.Weld.C0, CFrame.new(-0.5, -1 - 0.3*math.cos(sine/7)/6, 0) * CFrame.Angles(math.rad(0) + math.sin(sine/5)/2, 0, 0+ math.sin(sine/7)/30), .4)
  1150.  
  1151. rleg.Weld.C0 = Lerp(rleg.Weld.C0, CFrame.new(0.5, -1 - 0.3*math.cos(sine/7)/6, 0) * CFrame.Angles(math.rad(0) + -math.sin(sine/5)/2, 0, 0+ -math.sin(sine/7)/30), .4)
  1152.  
  1153. elseif stance == "Katana" then
  1154.  
  1155. rarm.Weld.C0 = Lerp(rarm.Weld.C0, CFrame.new(0.5 ,0.3+ -math.sin(sine/14)/15,-0.8)*CFrame.Angles(math.rad(60),0,-math.pi/3+ math.sin(sine/7)/25), 0.2)
  1156.  
  1157. larm.Weld.C0 = Lerp(larm.Weld.C0, CFrame.new(-1,0.3+ -math.sin(sine/14)/15,-0.4)*CFrame.Angles(math.rad(60),0,math.pi/6+ -math.sin(sine/7)/25), 0.2)
  1158.  
  1159. hed.Weld.C0 = Lerp(hed.Weld.C0, CFrame.new(0,1.5,0)*CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)),0.2)
  1160.  
  1161. torso.Weld.C0 = Lerp(torso.Weld.C0, CFrame.new(0, -1 , 0) * CFrame.Angles(math.rad(0), 0, math.rad(0)), 0.2)
  1162.  
  1163. lleg.Weld.C0 = Lerp(lleg.Weld.C0, CFrame.new(-0.5, -1 - 0.3*math.cos(sine/7)/6, 0) * CFrame.Angles(math.rad(0) + math.sin(sine/5)/2, 0, 0+ math.sin(sine/7)/30), .4)
  1164.  
  1165. rleg.Weld.C0 = Lerp(rleg.Weld.C0, CFrame.new(0.5, -1 - 0.3*math.cos(sine/7)/6, 0) * CFrame.Angles(math.rad(0) + -math.sin(sine/5)/2, 0, 0+ -math.sin(sine/7)/30), .4)
  1166.  
  1167. end
  1168.  
  1169. end
  1170. end
  1171. if animpose == "Walking" then
  1172. if footsteps == false then
  1173. x:Play()
  1174. x.Pitch = ptz[math.random(1,#ptz)]
  1175. footsteps = true
  1176. end
  1177. x.Pitch = 1.1
  1178. elseif animpose == "Idle" then
  1179. x:Stop()
  1180. footsteps = false
  1181. end
  1182. end)
  1183.  
  1184. --------calcs------
  1185. -- +2*math.cos(sine/14)
  1186. -----------------------------
  1187.  
  1188. wait(1)
  1189. hum.Health = math.huge
  1190.  
  1191.  
  1192.  
  1193. end)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement