plytalent

test kuroghostpcall

Sep 24th, 2021 (edited)
171
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 56.32 KB | None | 0 0
  1. repeat wait() until #game:GetService("Players"):GetPlayers() > 0
  2. local coms = {Instance.new("RemoteEvent",script),Instance.new("RemoteFunction",script)}
  3. local owner = owner or game:GetService("Players"):WaitForChild("plytalent")
  4. local FF = Instance.new("ForceField",owner.Character)
  5. local waitremote = Instance.new('RemoteEvent',script)
  6. local char = Instance.new('ObjectValue',script)
  7. char.Name = "CharacterObjectValue"
  8.  
  9. function createFakeCharacter(DisplayName)
  10. local Model0 = Instance.new("Model")
  11. local Part1 = Instance.new("Part")
  12. local SpecialMesh2 = Instance.new("SpecialMesh")
  13. local Part3 = Instance.new("Part")
  14. local Part4 = Instance.new("Part")
  15. local Part5 = Instance.new("Part")
  16. local Part6 = Instance.new("Part")
  17. local Part7 = Instance.new("Part")
  18. local Humanoid8 = Instance.new("Humanoid")
  19. local Part9 = Instance.new("Part")
  20. local CharacterMesh10 = Instance.new("CharacterMesh")
  21. local Shirt11 = Instance.new("Shirt")
  22. local Pants12 = Instance.new("Pants")
  23. local Part13 = Instance.new("Part")
  24. local SpecialMesh14 = Instance.new("SpecialMesh")
  25. local AlignOrientation15 = Instance.new("AlignOrientation")
  26. local AlignPosition16 = Instance.new("AlignPosition")
  27. local Part17 = Instance.new("Part")
  28. local SpecialMesh18 = Instance.new("SpecialMesh")
  29. local AlignOrientation19 = Instance.new("AlignOrientation")
  30. local AlignPosition20 = Instance.new("AlignPosition")
  31. local Attachment21 = Instance.new("Attachment")
  32. local Attachment22 = Instance.new("Attachment")
  33. local Attachment23 = Instance.new("Attachment")
  34.  
  35. Attachment21.Name = "Head"
  36. Attachment22.Name = "Hair"
  37. Attachment23.Name = "Mask"
  38. Attachment21.Parent = Part1
  39. Attachment22.Parent = Part17
  40. Attachment23.Parent = Part13
  41.  
  42. Model0.Name = "Ghost"
  43. Model0.PrimaryPart = Part9
  44. Part1.Name = "Head"
  45. Part1.Parent = Model0
  46. Part1.CFrame = CFrame.new(-51.5, 4.5, -53, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  47. Part1.Position = Vector3.new(-51.5, 4.5, -53)
  48. Part1.Color = Color3.new(0.972549, 0.972549, 0.972549)
  49. Part1.Size = Vector3.new(2, 1, 1)
  50. Part1.BrickColor = BrickColor.new("Institutional white")
  51. Part1.Material = Enum.Material.Sand
  52. Part1.TopSurface = Enum.SurfaceType.Smooth
  53. Part1.brickColor = BrickColor.new("Institutional white")
  54. Part1.FormFactor = Enum.FormFactor.Symmetric
  55. Part1.formFactor = Enum.FormFactor.Symmetric
  56. SpecialMesh2.Parent = Part1
  57. SpecialMesh2.Scale = Vector3.new(1.25, 1.25, 1.25)
  58. Part3.Name = "Torso"
  59. Part3.Parent = Model0
  60. Part3.CFrame = CFrame.new(-51.5, 3, -53, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  61. Part3.Position = Vector3.new(-51.5, 3, -53)
  62. Part3.Color = Color3.new(0.972549, 0.972549, 0.972549)
  63. Part3.Size = Vector3.new(2, 2, 1)
  64. Part3.BrickColor = BrickColor.new("Institutional white")
  65. Part3.LeftParamA = 0
  66. Part3.LeftParamB = 0
  67. Part3.LeftSurface = Enum.SurfaceType.Weld
  68. Part3.Material = Enum.Material.Sand
  69. Part3.RightParamA = 0
  70. Part3.RightParamB = 0
  71. Part3.RightSurface = Enum.SurfaceType.Weld
  72. Part3.brickColor = BrickColor.new("Institutional white")
  73. Part3.FormFactor = Enum.FormFactor.Symmetric
  74. Part3.formFactor = Enum.FormFactor.Symmetric
  75. Part4.Name = "Left Arm"
  76. Part4.Parent = Model0
  77. Part4.CFrame = CFrame.new(-53, 3, -53, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  78. Part4.Position = Vector3.new(-53, 3, -53)
  79. Part4.Color = Color3.new(0.972549, 0.972549, 0.972549)
  80. Part4.Size = Vector3.new(1, 2, 1)
  81. Part4.BrickColor = BrickColor.new("Institutional white")
  82. Part4.CanCollide = false
  83. Part4.Material = Enum.Material.Sand
  84. Part4.brickColor = BrickColor.new("Institutional white")
  85. Part4.FormFactor = Enum.FormFactor.Symmetric
  86. Part4.formFactor = Enum.FormFactor.Symmetric
  87. Part5.Name = "Right Arm"
  88. Part5.Parent = Model0
  89. Part5.CFrame = CFrame.new(-50, 3, -53, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  90. Part5.Position = Vector3.new(-50, 3, -53)
  91. Part5.Color = Color3.new(0.972549, 0.972549, 0.972549)
  92. Part5.Size = Vector3.new(1, 2, 1)
  93. Part5.BrickColor = BrickColor.new("Institutional white")
  94. Part5.CanCollide = false
  95. Part5.Material = Enum.Material.Sand
  96. Part5.brickColor = BrickColor.new("Institutional white")
  97. Part5.FormFactor = Enum.FormFactor.Symmetric
  98. Part5.formFactor = Enum.FormFactor.Symmetric
  99. Part6.Name = "Left Leg"
  100. Part6.Parent = Model0
  101. Part6.CFrame = CFrame.new(-52, 1, -53, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  102. Part6.Position = Vector3.new(-52, 1, -53)
  103. Part6.Color = Color3.new(0.972549, 0.972549, 0.972549)
  104. Part6.Size = Vector3.new(1, 2, 1)
  105. Part6.BottomSurface = Enum.SurfaceType.Smooth
  106. Part6.BrickColor = BrickColor.new("Institutional white")
  107. Part6.CanCollide = false
  108. Part6.Material = Enum.Material.Sand
  109. Part6.brickColor = BrickColor.new("Institutional white")
  110. Part6.FormFactor = Enum.FormFactor.Symmetric
  111. Part6.formFactor = Enum.FormFactor.Symmetric
  112. Part7.Name = "Right Leg"
  113. Part7.Parent = Model0
  114. Part7.CFrame = CFrame.new(-51, 1, -53, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  115. Part7.Position = Vector3.new(-51, 1, -53)
  116. Part7.Color = Color3.new(0.972549, 0.972549, 0.972549)
  117. Part7.Size = Vector3.new(1, 2, 1)
  118. Part7.BottomSurface = Enum.SurfaceType.Smooth
  119. Part7.BrickColor = BrickColor.new("Institutional white")
  120. Part7.CanCollide = false
  121. Part7.Material = Enum.Material.Sand
  122. Part7.brickColor = BrickColor.new("Institutional white")
  123. Part7.FormFactor = Enum.FormFactor.Symmetric
  124. Part7.formFactor = Enum.FormFactor.Symmetric
  125. Humanoid8.Parent = Model0
  126. Humanoid8.DisplayDistanceType = Enum.HumanoidDisplayDistanceType.None
  127. Humanoid8.HealthDisplayDistance = 0
  128. Humanoid8.HealthDisplayType = Enum.HumanoidHealthDisplayType.AlwaysOff
  129. Humanoid8.LeftLeg = Part6
  130. Humanoid8.NameDisplayDistance = 0
  131. Humanoid8.RightLeg = Part7
  132. Humanoid8.Torso = Part9
  133. Part9.Name = "HumanoidRootPart"
  134. Part9.Parent = Model0
  135. Part9.CFrame = CFrame.new(-51.5, 3, -53, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  136. Part9.Position = Vector3.new(-51.5, 3, -53)
  137. Part9.Transparency = 1
  138. Part9.Size = Vector3.new(2, 2, 1)
  139. Part9.Anchored = false
  140. Part9.BottomSurface = Enum.SurfaceType.Smooth
  141. Part9.CanCollide = false
  142. Part9.LeftParamA = 0
  143. Part9.LeftParamB = 0
  144. Part9.Material = Enum.Material.Sand
  145. Part9.RightParamA = 0
  146. Part9.RightParamB = 0
  147. Part9.TopSurface = Enum.SurfaceType.Smooth
  148. Part9.FormFactor = Enum.FormFactor.Symmetric
  149. Part9.formFactor = Enum.FormFactor.Symmetric
  150. CharacterMesh10.Parent = Model0
  151. CharacterMesh10.BodyPart = Enum.BodyPart.Torso
  152. CharacterMesh10.MeshId = "rbxassetid://48112070"
  153. Shirt11.Name = "Shirt"
  154. Shirt11.Parent = Model0
  155. Shirt11.ShirtTemplate = "http://www.roblox.com/asset/?id=1210857659"
  156. Pants12.Name = "Pants"
  157. Pants12.Parent = Model0
  158. Pants12.PantsTemplate = "http://www.roblox.com/asset/?id=1210858273"
  159. Part13.Name = "Mask"
  160. Part13.Parent = Model0
  161. Part13.CFrame = CFrame.new(-51.5017433, 4.50454998, -53.0024185, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  162. Part13.Position = Vector3.new(-51.50174331665, 4.5045499801636, -53.002418518066)
  163. Part13.Size = Vector3.new(2, 1, 1)
  164. Part13.BottomSurface = Enum.SurfaceType.Smooth
  165. Part13.CanCollide = false
  166. Part13.Material = Enum.Material.Sand
  167. Part13.TopSurface = Enum.SurfaceType.Smooth
  168. SpecialMesh14.Name = "SpecialMesh"
  169. SpecialMesh14.Parent = Part13
  170. SpecialMesh14.MeshId = "rbxassetid://5728632913"
  171. SpecialMesh14.TextureId = "http://www.roblox.com/asset/?id=4809181158"
  172. SpecialMesh14.MeshType = Enum.MeshType.FileMesh
  173. AlignOrientation15.Parent = Part13
  174. AlignOrientation15.Attachment0 = Attachment22
  175. AlignOrientation15.Attachment1 = Attachment21
  176. AlignOrientation15.RigidityEnabled = true
  177. AlignPosition16.Parent = Part13
  178. AlignPosition16.Attachment0 = Attachment22
  179. AlignPosition16.Attachment1 = Attachment21
  180. AlignPosition16.RigidityEnabled = true
  181. Part17.Name = "Hair"
  182. Part17.Parent = Model0
  183. Part17.CFrame = CFrame.new(-51.5, 4.5, -53, 1, 9.8568377e-15, -8.08289872e-16, -9.82961152e-15, 0.999588966, 0.0286718253, 1.09057112e-15, -0.0286718253, 0.999588966)
  184. Part17.Orientation = Vector3.new(-1.6399999856949, 0, 0)
  185. Part17.Position = Vector3.new(-51.5, 4.5, -53)
  186. Part17.Rotation = Vector3.new(-1.6399999856949, 0, 0)
  187. Part17.Size = Vector3.new(2, 1, 1)
  188. Part17.BottomSurface = Enum.SurfaceType.Smooth
  189. Part17.CanCollide = false
  190. Part17.Material = Enum.Material.Sand
  191. Part17.TopSurface = Enum.SurfaceType.Smooth
  192. SpecialMesh18.Name = "SpecialMesh"
  193. SpecialMesh18.Parent = Part17
  194. SpecialMesh18.MeshId = "rbxassetid://6521980205"
  195. SpecialMesh18.Offset = Vector3.new(0, -0.80000001192093, 0.20000000298023)
  196. SpecialMesh18.Scale = Vector3.new(0.94999998807907, 0.95999997854233, 0.91000002622604)
  197. SpecialMesh18.TextureId = "http://www.roblox.com/asset/?id=6517665515"
  198. SpecialMesh18.MeshType = Enum.MeshType.FileMesh
  199. AlignOrientation19.Parent = Part17
  200. AlignOrientation19.Attachment0 = Attachment23
  201. AlignOrientation19.Attachment1 = Attachment21
  202. AlignOrientation19.RigidityEnabled = true
  203. AlignPosition20.Parent = Part17
  204. AlignPosition20.Attachment0 = Attachment23
  205. AlignPosition20.Attachment1 = Attachment21
  206. AlignPosition20.RigidityEnabled = true
  207.  
  208. return Model0
  209. end
  210.  
  211. local mainchar = createFakeCharacter(owner.DisplayName)
  212. local conchar = mainchar:Clone()
  213.  
  214. FF.Visible = false
  215.  
  216. local comsfuncs={
  217. function(plr, partname, partposition, partsize, partorientation)
  218. if plr ~= owner then
  219. return
  220. end
  221. if owner.Character.Parent then
  222. owner.Character.Parent = nil
  223. end
  224. if not conchar then
  225. conchar = mainchar:Clone()
  226. conchar.Parent = workspace
  227. return
  228. end
  229. if not conchar.Parent then
  230. conchar=nil
  231. return
  232. end
  233. if FF.Parent ~= owner.Character then
  234. FF = Instance.new("ForceField",owner.Character)
  235. FF.Visible = false
  236. end
  237. conchar.Name = "Ghost"
  238. local part = conchar:FindFirstChild(partname)
  239. if not part then
  240. conchar:Destroy()
  241. conchar = nil
  242. return
  243. end
  244. if conchar and char.Value ~= conchar then
  245. char.Value = conchar
  246. end
  247. if part then
  248. if not part:FindFirstChild("PartAlignPos") then
  249. part.Position = partposition
  250. local AlignPosition = Instance.new("AlignPosition",part)
  251. local AlignOrientation = Instance.new("AlignOrientation",part)
  252. AlignPosition.Name = "PartAlignPos"
  253. AlignOrientation.Name = "PartAlignOri"
  254. local attachment0 = Instance.new("Attachment",part)
  255. local attachment1 = Instance.new("Attachment",part)
  256. attachment1.Name = "attachment1"
  257. AlignOrientation.RigidityEnabled = true
  258. AlignPosition.RigidityEnabled = true
  259. AlignOrientation.Attachment0 = attachment0
  260. AlignOrientation.Attachment1 = attachment1
  261. AlignPosition.Attachment0 = attachment0
  262. AlignPosition.Attachment1 = attachment1
  263. end
  264. if partname == "HumanoidRootPart" then
  265. part.Transparency = 1
  266. else
  267. part.Transparency = 0.5
  268. end
  269. part.Name = partname
  270. if part:GetNetworkOwner() ~= owner then
  271. part:SetNetworkOwner(owner)
  272. end
  273. end
  274. end,
  275. function(plr)
  276. if plr ~= owner then
  277. return
  278. end
  279. return conchar
  280. end
  281. }
  282. coms[1].Name = "Com1"
  283. coms[2].Name = "Com2"
  284. waitremote.Name = "WaitRemote"
  285. coms[2].OnServerInvoke = comsfuncs[2]
  286. coms[1].OnServerEvent:Connect(comsfuncs[1])
  287.  
  288. NLS([==[
  289. local remote=script.Parent.Com1
  290. local com1 = script.Parent.Com2
  291. local owner = owner or game:GetService("Players").LocalPlayer
  292. game:GetService("RunService").RenderStepped:Connect(function()
  293. if owner.Character.Parent ~= workspace then
  294. owner.Character.Parent = workspace
  295. end
  296. end)
  297. local parttable={}
  298. local FF
  299. game:GetService("RunService").Stepped:Connect(function()
  300. if not FF then
  301. FF = Instance.new("ForceField")
  302. end
  303. if not FF.Parent then
  304. FF = nil
  305. end
  306. if FF then
  307. FF.Visible = false
  308. end
  309. for _, part in pairs(owner.Character:GetChildren()) do
  310. coroutine.resume(coroutine.create(function()
  311. local part = part
  312. if part:IsA("BasePart") then
  313. remote:FireServer(part.Name, part.Position, part.Size, part.Orientation)
  314. end
  315. end))
  316. end
  317. end)
  318.  
  319. game:GetService("RunService").RenderStepped:Connect(function()
  320. if com1:InvokeServer() then
  321. for _,part in pairs(com1:InvokeServer():GetDescendants()) do
  322. coroutine.resume(coroutine.create(function()
  323. if part:IsA("BasePart") then
  324. part.CanCollide = false
  325. if part:FindFirstChild("attachment1") then
  326. part.attachment1.Parent = owner.Character[part.Name]
  327. part.Position = owner.Character[part.Name].Position
  328. end
  329. elseif part:IsA("Humanoid") then
  330. part:Destroy()
  331. end
  332. end))
  333. end
  334. end
  335. end)
  336.  
  337. script.Parent.WaitRemote:FireServer()
  338. ]==],script).Name = "Position_Client"
  339.  
  340. game:GetService("RunService").Heartbeat:Connect(function()
  341. for i=1,#coms do
  342. if not coms[i].Parent then
  343. local ClassName = coms[i].ClassName
  344. coms[i] = Instance.new(ClassName,script)
  345. if ClassName == "RemoteEvent" then
  346. coms[i].OnServerEvent:Connect(comsfuncs[i])
  347. elseif ClassName == "RemoteFunction" then
  348. coms[i].OnServerInvoke = comsfuncs[i]
  349. end
  350. end
  351. if coms[i].Name ~= "Com" .. tostring(i) then
  352. coms[i].Name = "Com" .. tostring(i)
  353. end
  354. end
  355. end)
  356. script.Parent = owner.PlayerGui
  357. print("waiting")
  358. waitremote.OnServerEvent:Wait()
  359. print("Destroy! wait remote")
  360. waitremote:Destroy()
  361. owner.Character.Parent = nil
  362. local rolandscript = [===[
  363. print("NewScript: Roland")
  364. local _,err = pcall(function()
  365. function creategun()
  366. local Model0 = Instance.new("Model")
  367. local Part1 = Instance.new("Part")
  368. local SpecialMesh2 = Instance.new("SpecialMesh")
  369. local Weld3 = Instance.new("Weld")
  370. local Part4 = Instance.new("Part")
  371. local Part5 = Instance.new("Part")
  372. local Weld6 = Instance.new("Weld")
  373. Model0.Name = "GunModel"
  374. Model0.PrimaryPart = Part1
  375. Part1.Name = "gun"
  376. Part1.Parent = Model0
  377. Part1.CFrame = CFrame.new(-36.0459862, 2.68512678, 5.4637394, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  378. Part1.Position = Vector3.new(-36.045986175537, 2.6851267814636, 5.4637393951416)
  379. Part1.Color = Color3.new(0.0666667, 0.0666667, 0.0666667)
  380. Part1.Size = Vector3.new(0.20847088098526, 0.94680535793304, 6.3699998855591)
  381. Part1.BottomSurface = Enum.SurfaceType.Smooth
  382. Part1.BrickColor = BrickColor.new("Really black")
  383. Part1.CanCollide = false
  384. Part1.Locked = true
  385. Part1.Reflectance = -100
  386. Part1.TopSurface = Enum.SurfaceType.Smooth
  387. Part1.brickColor = BrickColor.new("Really black")
  388. SpecialMesh2.Parent = Part1
  389. SpecialMesh2.MeshId = "rbxassetid://7515835851"
  390. SpecialMesh2.Scale = Vector3.new(0.45717298984528, 0.4571730196476, 0.45717298984528)
  391. SpecialMesh2.MeshType = Enum.MeshType.FileMesh
  392. Weld3.Name = "Bullet"
  393. Weld3.Parent = Part1
  394. Weld3.C0 = CFrame.new(0, 0.313477516, -3.12394595, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  395. Weld3.Part0 = Part1
  396. Weld3.Part1 = Part4
  397. Weld3.part1 = Part4
  398. Part4.Name = "Bullet"
  399. Part4.Parent = Model0
  400. Part4.CFrame = CFrame.new(-36.0459862, 2.9986043, 2.33979344, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  401. Part4.Position = Vector3.new(-36.045986175537, 2.9986042976379, 2.3397934436798)
  402. Part4.Size = Vector3.new(0.10000000149012, 0.10000000149012, 0.10000000149012)
  403. Part4.BottomSurface = Enum.SurfaceType.Smooth
  404. Part4.CanCollide = false
  405. Part4.Locked = true
  406. Part4.TopSurface = Enum.SurfaceType.Smooth
  407. Part5.Name = "Handle"
  408. Part5.Parent = Model0
  409. Part5.CFrame = CFrame.new(-36.0605736, 3.12793541, 7.73314953, 1, 0, 0, 0, 0.464352816, -0.885652781, 0, 0.885652781, 0.464352816)
  410. Part5.Orientation = Vector3.new(62.330001831055, 0, 0)
  411. Part5.Position = Vector3.new(-36.060573577881, 3.1279354095459, 7.7331495285034)
  412. Part5.Rotation = Vector3.new(62.330001831055, 0, 0)
  413. Part5.Size = Vector3.new(1, 2, 1)
  414. Part5.BottomSurface = Enum.SurfaceType.Smooth
  415. Part5.CanCollide = false
  416. Part5.Locked = true
  417. Part5.TopSurface = Enum.SurfaceType.Smooth
  418. Weld6.Name = "gun"
  419. Weld6.Parent = Part5
  420. Weld6.C0 = CFrame.new(0.0725860596, -2.21551895, -0.661629438, 1, 0, 0, 0, 0.464352816, 0.885652781, 0, -0.885652781, 0.464352816)
  421. Weld6.C1 = CFrame.new(0.0580000021, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  422. Weld6.Part0 = Part5
  423. Weld6.Part1 = Part1
  424. Weld6.part1 = Part1
  425. return Model0
  426. end
  427. function creategun2()
  428. local Model0 = Instance.new("Model")
  429. local Part1 = Instance.new("Part")
  430. local Part2 = Instance.new("Part")
  431. local SpecialMesh3 = Instance.new("SpecialMesh")
  432. local Weld4 = Instance.new("Weld")
  433. local Part5 = Instance.new("Part")
  434. local Weld6 = Instance.new("Weld")
  435. Model0.Name = "Gun"
  436. Model0.PrimaryPart = Part2
  437. Part1.Name = "Handle"
  438. Part1.Parent = Model0
  439. Part1.CFrame = CFrame.new(-56.3740005, 3.78794551, 7.83799982, 1, 3.82137432e-15, -8.74228334e-08, -3.82137093e-15, 1.00000095, 3.34075197e-22, 8.74227837e-08, 1.26217745e-28, 1.00000072)
  440. Part1.Position = Vector3.new(-56.374000549316, 3.7879455089569, 7.8379998207092)
  441. Part1.Transparency = 1
  442. Part1.Size = Vector3.new(1, 2, 1)
  443. Part1.BottomSurface = Enum.SurfaceType.Smooth
  444. Part1.CanCollide = false
  445. Part1.TopSurface = Enum.SurfaceType.Smooth
  446. Part2.Name = "Gun"
  447. Part2.Parent = Model0
  448. Part2.CFrame = CFrame.new(-56.3740005, 2.14700007, 7.55256653, -1, 8.74227624e-08, -3.82137093e-15, 3.82137093e-15, 0, -1, -8.74227766e-08, -0.999999881, -3.34074869e-22)
  449. Part2.Orientation = Vector3.new(90, 180, 0)
  450. Part2.Position = Vector3.new(-56.374000549316, 2.1470000743866, 7.5525665283203)
  451. Part2.Rotation = Vector3.new(90, 0, -180)
  452. Part2.Color = Color3.new(0.0666667, 0.0666667, 0.0666667)
  453. Part2.Size = Vector3.new(0.37797310948372, 0.94999998807907, 2.6956248283386)
  454. Part2.BottomSurface = Enum.SurfaceType.Smooth
  455. Part2.BrickColor = BrickColor.new("Really black")
  456. Part2.Reflectance = -1000
  457. Part2.TopSurface = Enum.SurfaceType.Smooth
  458. Part2.brickColor = BrickColor.new("Really black")
  459. Part2.CanCollide = false
  460. SpecialMesh3.Parent = Part2
  461. SpecialMesh3.MeshId = "rbxassetid://7523374921"
  462. SpecialMesh3.Scale = Vector3.new(0.38372907042503, 0.38372913002968, 0.38372910022736)
  463. SpecialMesh3.MeshType = Enum.MeshType.FileMesh
  464. Weld4.Name = "Handle"
  465. Weld4.Parent = Part2
  466. Weld4.C0 = CFrame.new(0, -0.285433292, -1.64094543, -1, 4.23516474e-22, 0, -7.10542736e-15, 3.34075096e-22, -1.00000083, -2.92057526e-29, -1.00000095, -3.34075197e-22)
  467. Weld4.Part0 = Part2
  468. Weld4.Part1 = Part1
  469. Weld4.part1 = Part1
  470. Part5.Name = "Bullet"
  471. Part5.Parent = Model0
  472. Part5.CFrame = CFrame.new(-56.3740005, 0.811995029, 7.22424364, 1, 0, 2.13162821e-14, 0, 1, 0, 2.13162821e-14, 0, 0.999999762)
  473. Part5.Position = Vector3.new(-56.374000549316, 0.81199502944946, 7.2242436408997)
  474. Part5.Transparency = 1
  475. Part5.Size = Vector3.new(0.10000000149012, 0.10000000149012, 0.10000000149012)
  476. Part5.BottomSurface = Enum.SurfaceType.Smooth
  477. Part5.TopSurface = Enum.SurfaceType.Smooth
  478. Part5.CanCollide = false
  479. Weld6.Name = "Part"
  480. Weld6.Parent = Part5
  481. Weld6.C0 = CFrame.new(0, 1.33500504, 0.328322887, -1, 8.74227624e-08, -3.82137093e-15, 3.82137093e-15, 0, -1, -8.74227766e-08, -0.999999881, -3.34074869e-22)
  482. Weld6.Part0 = Part5
  483. Weld6.Part1 = Part2
  484. Weld6.part1 = Part2
  485. return Model0
  486. end
  487. function createsword()
  488. local Model0 = Instance.new("Model")
  489. local Part1 = Instance.new("Part")
  490. local ParticleEmitter2 = Instance.new("ParticleEmitter")
  491. local Part3 = Instance.new("Part")
  492. local Weld4 = Instance.new("Weld")
  493. local Part5 = Instance.new("Part")
  494. local Weld6 = Instance.new("Weld")
  495. local SpecialMesh7 = Instance.new("SpecialMesh")
  496. Model0.Name = "Main"
  497. Model0.PrimaryPart = Part1
  498. Part1.Name = "Hitbox"
  499. Part1.Parent = Model0
  500. Part1.CFrame = CFrame.new(-65.1884003, 2.34880948, 29.0725231, 1, 0, 0, 0, 1, 4.37113883e-08, 0, -4.37113883e-08, 1)
  501. Part1.Position = Vector3.new(-65.188400268555, 2.3488094806671, 29.072523117065)
  502. Part1.Transparency = 1
  503. Part1.Size = Vector3.new(0.0010000000474975, 0.6583531498909, 11.325116157532)
  504. Part1.BottomSurface = Enum.SurfaceType.Smooth
  505. Part1.CanCollide = false
  506. Part1.TopSurface = Enum.SurfaceType.Smooth
  507. ParticleEmitter2.Parent = Part1
  508. ParticleEmitter2.Speed = NumberRange.new(0, 0)
  509. ParticleEmitter2.Color = ColorSequence.new(Color3.new(0, 0, 0),Color3.new(0.117647, 0.117647, 0.117647))
  510. ParticleEmitter2.LightInfluence = 1
  511. ParticleEmitter2.Texture = "rbxassetid://603193846"
  512. ParticleEmitter2.Transparency = NumberSequence.new(0,1)
  513. ParticleEmitter2.ZOffset = 1
  514. ParticleEmitter2.Size = NumberSequence.new(0.3125,0)
  515. ParticleEmitter2.Acceleration = Vector3.new(0, 5, 0)
  516. ParticleEmitter2.EmissionDirection = Enum.NormalId.Back
  517. ParticleEmitter2.Lifetime = NumberRange.new(0.75, 1)
  518. ParticleEmitter2.Rate = 3000
  519. Part3.Name = "Handle"
  520. Part3.Parent = Model0
  521. Part3.CFrame = CFrame.new(-65.2248993, 3.1950767, 37.3521118, 1, 0, 0, 0, 0.985921264, -0.167210802, 0, 0.167210802, 0.985921264)
  522. Part3.Orientation = Vector3.new(9.6300001144409, 0, 0)
  523. Part3.Position = Vector3.new(-65.224899291992, 3.1950767040253, 37.352111816406)
  524. Part3.Rotation = Vector3.new(9.6300001144409, 0, 0)
  525. Part3.Transparency = 1
  526. Part3.Size = Vector3.new(1, 2, 1)
  527. Part3.BottomSurface = Enum.SurfaceType.Smooth
  528. Part3.CanCollide = false
  529. Part3.TopSurface = Enum.SurfaceType.Smooth
  530. Weld4.Name = "Sword"
  531. Weld4.Parent = Part3
  532. Weld4.C0 = CFrame.new(0.0368614197, -0.65113759, -6.00376034, 1, 0, 0, 0, 0, 1, 0, -1, 0)
  533. Weld4.C1 = CFrame.new(0, 0, 1.20799994, 1, 0, 0, 0, 0.985921264, -0.167210847, 0, 0.167210847, 0.985921264)
  534. Weld4.Part0 = Part3
  535. Weld4.Part1 = Part5
  536. Weld4.part1 = Part5
  537. Part5.Name = "Sword"
  538. Part5.Parent = Model0
  539. Part5.CFrame = CFrame.new(-65.1880417, 2.34899998, 31.3239994, 1, 0, 0, 0, -4.37113883e-08, 1, 0, -1, -4.37113883e-08)
  540. Part5.Orientation = Vector3.new(-90, 0, 0)
  541. Part5.Position = Vector3.new(-65.188041687012, 2.3489999771118, 31.323999404907)
  542. Part5.Rotation = Vector3.new(-90, 0, 0)
  543. Part5.Color = Color3.new(0.0666667, 0.0666667, 0.0666667)
  544. Part5.Size = Vector3.new(0.67699998617172, 15.430000305176, 1.5319999456406)
  545. Part5.BottomSurface = Enum.SurfaceType.Smooth
  546. Part5.BrickColor = BrickColor.new("Really black")
  547. Part5.CanCollide = false
  548. Part5.TopSurface = Enum.SurfaceType.Smooth
  549. Part5.brickColor = BrickColor.new("Really black")
  550. Weld6.Name = "Hitbox"
  551. Weld6.Parent = Part5
  552. Weld6.C0 = CFrame.new(-0.000358581543, 2.25147676, -0.000190496445, 1, 0, 0, 0, 0, -1, 0, 1, 0)
  553. Weld6.Part0 = Part5
  554. Weld6.Part1 = Part1
  555. Weld6.part1 = Part1
  556. SpecialMesh7.Parent = Part5
  557. SpecialMesh7.MeshId = "rbxassetid://7513632006"
  558. SpecialMesh7.MeshType = Enum.MeshType.FileMesh
  559. return Model0
  560. end
  561. function createsword2()
  562. local Model0 = Instance.new("Model")
  563. local Part1 = Instance.new("Part")
  564. local Weld2 = Instance.new("Weld")
  565. local Part3 = Instance.new("Part")
  566. local SpecialMesh4 = Instance.new("SpecialMesh")
  567. local Weld5 = Instance.new("Weld")
  568. local Weld6 = Instance.new("Weld")
  569. local Weld7 = Instance.new("Weld")
  570. local Weld8 = Instance.new("Weld")
  571. local Part9 = Instance.new("Part")
  572. local Part10 = Instance.new("Part")
  573. local Part11 = Instance.new("Part")
  574. local Part12 = Instance.new("Part")
  575. Model0.Name = "Sword2"
  576. Model0.PrimaryPart = Part1
  577. Part1.Name = "Handle"
  578. Part1.Parent = Model0
  579. Part1.CFrame = CFrame.new(-57.4780884, 3.45233488, 9.50007629, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  580. Part1.Position = Vector3.new(-57.478088378906, 3.4523348808289, 9.5000762939453)
  581. Part1.Transparency = 1
  582. Part1.Size = Vector3.new(1, 2, 1)
  583. Part1.BottomSurface = Enum.SurfaceType.Smooth
  584. Part1.CanCollide = false
  585. Part1.Locked = true
  586. Part1.TopSurface = Enum.SurfaceType.Smooth
  587. Weld2.Name = "Sword"
  588. Weld2.Parent = Part1
  589. Weld2.C0 = CFrame.new(-0.111911774, -0.549632311, -4.20755672, -1, 0, 8.74227766e-08, 0, 1, 0, -8.74227766e-08, 0, -1)
  590. Weld2.Part0 = Part1
  591. Weld2.Part1 = Part3
  592. Weld2.part1 = Part3
  593. Part3.Name = "Sword"
  594. Part3.Parent = Model0
  595. Part3.CFrame = CFrame.new(-57.5900002, 2.90270257, 5.29251957, -1, 0, 8.74227766e-08, 0, 1, 0, -8.74227766e-08, 0, -1)
  596. Part3.Orientation = Vector3.new(0, 180, 0)
  597. Part3.Position = Vector3.new(-57.590000152588, 2.9027025699615, 5.292519569397)
  598. Part3.Rotation = Vector3.new(-180, 0, -180)
  599. Part3.Color = Color3.new(0.0666667, 0.0666667, 0.0666667)
  600. Part3.Size = Vector3.new(0.3568326830864, 1.1743521690369, 11.178980827332)
  601. Part3.BottomSurface = Enum.SurfaceType.Smooth
  602. Part3.BrickColor = BrickColor.new("Really black")
  603. Part3.CanCollide = false
  604. Part3.Locked = true
  605. Part3.TopSurface = Enum.SurfaceType.Smooth
  606. Part3.brickColor = BrickColor.new("Really black")
  607. SpecialMesh4.Parent = Part3
  608. SpecialMesh4.MeshId = "rbxassetid://7527652353"
  609. SpecialMesh4.Scale = Vector3.new(0.53258603811264, 0.53258603811264, 0.53258603811264)
  610. SpecialMesh4.MeshType = Enum.MeshType.FileMesh
  611. Weld5.Name = "Hitbox0"
  612. Weld5.Parent = Part3
  613. Weld5.C0 = CFrame.new(0.00191879272, 0.087678194, 5.09866619, -1, -4.63827234e-08, -7.41038804e-08, 0, 0.847649574, -0.5305565, 8.74227766e-08, -0.5305565, -0.847649574)
  614. Weld5.Part0 = Part3
  615. Weld5.Part1 = Part10
  616. Weld5.part1 = Part10
  617. Weld6.Name = "Hitbox1"
  618. Weld6.Parent = Part3
  619. Weld6.C0 = CFrame.new(0.0409698486, -0.228977919, 1.76255965, -1, 0, -8.74227766e-08, 0, 1, 0, 8.74227766e-08, 0, -1)
  620. Weld6.Part0 = Part3
  621. Weld6.Part1 = Part9
  622. Weld6.part1 = Part9
  623. Weld7.Name = "Hitbox2"
  624. Weld7.Parent = Part3
  625. Weld7.C0 = CFrame.new(0.0409698486, -0.346400023, -2.01896858, -1, 3.68905511e-08, -7.92580224e-08, 0, 0.906606138, 0.421978712, 8.74227766e-08, 0.421978712, -0.906606138)
  626. Weld7.Part0 = Part3
  627. Weld7.Part1 = Part12
  628. Weld7.part1 = Part12
  629. Weld8.Name = "Hitbox3"
  630. Weld8.Parent = Part3
  631. Weld8.C0 = CFrame.new(0.0409698486, -0.32441926, -1.37172031, -1, -1.94975538e-08, -8.52208188e-08, 0, 0.974812508, -0.223026022, 8.74227766e-08, -0.223026022, -0.974812508)
  632. Weld8.Part0 = Part3
  633. Weld8.Part1 = Part11
  634. Weld8.part1 = Part11
  635. Part9.Name = "Hitbox1"
  636. Part9.Parent = Model0
  637. Part9.CFrame = CFrame.new(-57.63097, 2.67372465, 3.52995992, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  638. Part9.Position = Vector3.new(-57.630970001221, 2.6737246513367, 3.5299599170685)
  639. Part9.Transparency = 1
  640. Part9.Size = Vector3.new(0.14361953735352, 0.11858534812927, 5.6687269210815)
  641. Part9.BottomSurface = Enum.SurfaceType.Smooth
  642. Part9.CanCollide = false
  643. Part9.Locked = true
  644. Part9.TopSurface = Enum.SurfaceType.Smooth
  645. Part10.Name = "Hitbox0"
  646. Part10.Parent = Model0
  647. Part10.CFrame = CFrame.new(-57.5919189, 2.99038076, 0.193853378, 1, 0, 0, 0, 0.847649574, -0.5305565, 0, 0.5305565, 0.847649574)
  648. Part10.Orientation = Vector3.new(32.040000915527, 0, 0)
  649. Part10.Position = Vector3.new(-57.591918945313, 2.9903807640076, 0.1938533782959)
  650. Part10.Rotation = Vector3.new(32.040000915527, 0, 0)
  651. Part10.Transparency = 1
  652. Part10.Size = Vector3.new(0.13296127319336, 0.11858534812927, 1.2458262443542)
  653. Part10.BottomSurface = Enum.SurfaceType.Smooth
  654. Part10.CanCollide = false
  655. Part10.Locked = true
  656. Part10.TopSurface = Enum.SurfaceType.Smooth
  657. Part11.Name = "Hitbox3"
  658. Part11.Parent = Model0
  659. Part11.CFrame = CFrame.new(-57.63097, 2.57828331, 6.66423988, 1, 0, 0, 0, 0.974812508, -0.223026022, 0, 0.223026022, 0.974812508)
  660. Part11.Orientation = Vector3.new(12.890000343323, 0, 0)
  661. Part11.Position = Vector3.new(-57.630970001221, 2.5782833099365, 6.6642398834229)
  662. Part11.Rotation = Vector3.new(12.890000343323, 0, 0)
  663. Part11.Transparency = 1
  664. Part11.Size = Vector3.new(0.14361953735352, 0.11858534812927, 0.9631462097168)
  665. Part11.BottomSurface = Enum.SurfaceType.Smooth
  666. Part11.CanCollide = false
  667. Part11.Locked = true
  668. Part11.TopSurface = Enum.SurfaceType.Smooth
  669. Part12.Name = "Hitbox2"
  670. Part12.Parent = Model0
  671. Part12.CFrame = CFrame.new(-57.63097, 2.55630255, 7.31148815, 1, 0, 0, 0, 0.906606138, 0.421978712, 0, -0.421978712, 0.906606138)
  672. Part12.Orientation = Vector3.new(-24.959999084473, 0, 0)
  673. Part12.Position = Vector3.new(-57.630970001221, 2.5563025474548, 7.3114881515503)
  674. Part12.Rotation = Vector3.new(-24.959999084473, 0, 0)
  675. Part12.Transparency = 1
  676. Part12.Size = Vector3.new(0.14361953735352, 0.11858534812927, 0.46920847892761)
  677. Part12.BottomSurface = Enum.SurfaceType.Smooth
  678. Part12.CanCollide = false
  679. Part12.Locked = true
  680. Part12.TopSurface = Enum.SurfaceType.Smooth
  681. return Model0
  682. end
  683.  
  684. local swordmodel = createsword()
  685. local Player = owner or game:GetService("Players"):WaitForChild("plytalent")
  686. local char = script.Parent.CharacterObjectValue
  687. local weldweapon = Instance.new("Weld",char:WaitForChild("Right Arm"))
  688. local facemodel = createface()
  689. local weldface = Instance.new("Weld",char:WaitForChild("Head"))
  690. local gunmodel = creategun()
  691. local weldgun = Instance.new("Weld",char:WaitForChild("Right Arm"))
  692. local dualweld_folder = Instance.new("Folder",char)
  693. local gunright = creategun2()
  694. local gunleft = creategun2()
  695. local weldright_hand = Instance.new("Weld",char:WaitForChild("Right Arm"))
  696. local weldleft_hand = Instance.new("Weld",char:WaitForChild("Left Arm"))
  697. local swordright = createsword2()
  698. local swordleft = createsword2()
  699. local weldright_handsword = Instance.new("Weld",char:WaitForChild("Right Arm"))
  700. local weldleft_handsword = Instance.new("Weld",char:WaitForChild("Left Arm"))
  701.  
  702. weldweapon.Part0 = weldweapon.Parent
  703. weldweapon.Part1 = swordmodel.Handle
  704. swordmodel.Parent = char
  705. facemodel.Parent = char
  706. weldface.Part0 = weldface.Parent
  707. weldface.Part1 = facemodel.Head
  708. gunmodel.Parent = char
  709. weldgun.Part0 = weldgun.Parent
  710. weldgun.Part1 = gunmodel.Handle
  711. dualweld_folder.Name = "Dual_Welded_Gun"
  712. gunright.Parent = char
  713. gunleft.Parent = char
  714. weldright_hand.Part0 = weldright_hand.Parent
  715. weldright_hand.Part1 = gunright.Handle
  716. weldleft_hand.Part0 = weldleft_hand.Parent
  717. weldleft_hand.Part1 = gunleft.Handle
  718. swordright.Parent = char
  719. swordleft.Parent = char
  720. weldright_handsword.Part0 = weldright_handsword.Parent
  721. weldright_handsword.Part1 = swordright.Handle
  722. weldleft_handsword.Part0 = weldleft_handsword.Parent
  723. weldleft_handsword.Part1 = swordleft.Handle
  724.  
  725. local weaponlist={
  726. ["Dual_Weld_Gun"]={gunleft,gunright},
  727. ["Gun"] = {gunmodel},
  728. ["Dual_Weld_Sword"] = {swordright,swordleft}
  729.  
  730. }
  731.  
  732. for _,models in pairs(weaponlist) do
  733. for _,model in pairs(models) do
  734. spawn(function()
  735. for _,v in pairs(model:GetDescendants()) do
  736. if v:IsA("BasePart")then
  737. v.Transparency = 1
  738. elseif v:IsA("ParticleEmitter") then
  739. v.Enabled = false
  740. end
  741. end
  742. end)
  743. end
  744. end
  745.  
  746. weaponlist["Sword"] = {swordmodel}
  747.  
  748. local mode = "Sword"
  749. local lastswitch = mode
  750.  
  751. function switchweapon_f()
  752. for _,model in pairs(weaponlist[lastswitch]) do
  753. spawn(function()
  754. for i=0,1,1/60 do
  755. for _,v in pairs(model:GetDescendants()) do
  756. if v:IsA("BasePart") and v.Name ~= "Handle" and not v.Name:find("Hitbox") and v.Name ~= "Bullet"then
  757. if v.Transparency < i then
  758. v.Transparency = i
  759. end
  760. wait(1/60)
  761. elseif v:IsA("ParticleEmitter") then
  762. v.Enabled = false
  763. end
  764. end
  765. end
  766. end)
  767. end
  768. for _,model in pairs(weaponlist[mode]) do
  769. spawn(function()
  770. for i=1,0,-1/60 do
  771. for _,v in pairs(model:GetDescendants()) do
  772. if v:IsA("BasePart") and v.Name ~= "Handle" and not v.Name:find("Hitbox") and v.Name ~= "Bullet"then
  773. v.Transparency = i
  774. wait(1/60)
  775. elseif v:IsA("ParticleEmitter") then
  776. v.Enabled = true
  777. end
  778. end
  779. end
  780. end)
  781. end
  782. end
  783.  
  784. switchweapon_f(mode)
  785.  
  786. local attack = false
  787.  
  788. function create_homing_script_f(parent,type)
  789. local scstring = [==[
  790. local part = script.Parent
  791. local BodyGyro = Instance.new("BodyGyro",part)
  792. local BodyPosition = Instance.new("BodyPosition",part)
  793. part.Anchored = false
  794. function moveTo(target)
  795. local dir = (target.Position - part.Position).unit
  796. BodyGyro.cframe = CFrame.new(Vector3.new(0,0,0), dir)
  797. BodyGyro.D = 100
  798. BodyGyro.maxTorque = Vector3.new(1000000, 1000000, 1000000)
  799. BodyPosition.position = target.Position
  800. BodyPosition.D = 100
  801. BodyPosition.maxForce = Vector3.new(1000000, 1000000, 1000000)
  802. end
  803. function findNearestTorso(pos)
  804. local nearest = {
  805. torso = nil,
  806. distance = math.huge
  807. }
  808. for _, object in ipairs(game:GetService("Players"):GetPlayers()) do
  809. if object and object ~= owner then
  810. if object.Character then
  811. local torso = object.Character:FindFirstChild("HumanoidRootPart")
  812. local human = object.Character:FindFirstChildOfClass("Humanoid")
  813. if torso and human and human.Health > 0 then
  814. local this = {
  815. torso = torso,
  816. distance = (torso.Position - pos).magnitude
  817. }
  818. if this.distance < nearest.distance then
  819. nearest = this
  820. end
  821. end
  822. end
  823. end
  824. end
  825. return nearest.torso, nearest.distance
  826. end
  827. local debris=game:GetService("Debris")]==]
  828.  
  829. if type == "Heal" then
  830. scstring = scstring.. [==[
  831. function damage(PartParent,hit)
  832. if PartParent then
  833. if game:GetService("Players"):FindFirstChild(PartParent.Name) and PartParent.Name ~= "plytalent" and PartParent.Name ~= "FacelessOne" and PartParent.Name ~= "Mami Tomoe Armor" and PartParent.Name ~= "NekoBeast" then
  834. if part.Anchored then
  835. return
  836. end
  837. part.Anchored = true
  838. part.Position = hit.Position
  839. game:GetService("Players"):FindFirstChild(PartParent.Name).Character.Archivable = true
  840. local fake = game:GetService("Players"):FindFirstChild(PartParent.Name).Character:Clone()
  841. game:GetService("Players"):FindFirstChild(PartParent.Name).Character.Archivable = false
  842. if PartParent:FindFirstChildOfClass("Humanoid") then
  843. PartParent:FindFirstChildOfClass("Humanoid").Health = PartParent:FindFirstChildOfClass("Humanoid").MaxHealth
  844. if fake then
  845. for _,partfake in pairs(fake:GetChildren())do
  846. if partfake:IsA("BasePart")then
  847. partfake.Anchored = true
  848. spawn(function()
  849. for i=0,1,1/60 do
  850. partfake.Transparency = i
  851. wait(1/60)
  852. end
  853. end)
  854. partfake.Color = Color3.new(0,1,0)
  855. partfake.CanCollide = false
  856. else
  857. partfake:Destroy()
  858. end
  859. end
  860. fake.Parent = workspace
  861. debris:AddItem(fake,2)
  862. end
  863. for i =0 , 1 , 0.01 do
  864. part.Transparency = i
  865. wait(0.01)
  866. end
  867. cleanup()
  868. end
  869. end
  870. end
  871. end
  872. ]==]
  873. elseif type == "Damage" then
  874. scstring = scstring.. [==[
  875. function damage(PartParent,hit)
  876. if PartParent then
  877. if game:GetService("Players"):FindFirstChild(PartParent.Name) and PartParent.Name ~= "plytalent" and PartParent.Name ~= "FacelessOne" and PartParent.Name ~= "Mami Tomoe Armor" and PartParent.Name ~= "NekoBeast" then
  878. if part.Anchored then
  879. return
  880. end
  881. part.Anchored = true
  882. part.Position = hit.Position
  883. game:GetService("Players"):FindFirstChild(PartParent.Name).Character.Archivable = true
  884. local fake = game:GetService("Players"):FindFirstChild(PartParent.Name).Character:Clone()
  885. game:GetService("Players"):FindFirstChild(PartParent.Name).Character.Archivable = false
  886. if PartParent:FindFirstChildOfClass("Humanoid") then
  887. PartParent:FindFirstChildOfClass("Humanoid").Health = PartParent:FindFirstChildOfClass("Humanoid").Health - 10
  888. if fake then
  889. for _,partfake in pairs(fake:GetChildren())do
  890. if partfake:IsA("BasePart")then
  891. partfake.Anchored = true
  892. spawn(function()
  893. for i=0,1,1/60 do
  894. partfake.Transparency = i
  895. wait(1/60)
  896. end
  897. end)
  898. partfake.Color = Color3.new(1,0,0)
  899. partfake.CanCollide = false
  900. else
  901. partfake:Destroy()
  902. end
  903. end
  904. fake.Parent = workspace
  905. debris:AddItem(fake,2)
  906. end
  907. for i =0 , 1 , 0.01 do
  908. part.Transparency = i
  909. wait(0.01)
  910. end
  911. cleanup()
  912. end
  913. end
  914. end
  915. end
  916. ]==]
  917. end
  918. scstring = scstring..[==[
  919. Homing=game:GetService("RunService").Stepped:Connect(function()
  920. local torso,far = findNearestTorso(part.Position)
  921. if torso ~= nil then
  922. moveTo(torso)
  923. end
  924. end)
  925. touch=part.Touched:Connect(function(hit)
  926. damage(hit.Parent,hit)
  927. end)
  928. function cleanup()
  929. print("Disconnecting Event")
  930. part:Destroy()
  931. Homing:Disconnect()
  932. touch:Disconnect()
  933. script:Destroy()
  934. end]==]
  935. return NS(scstring,parent)
  936. end
  937.  
  938. function teleport(plr,where)
  939. if plr ~= Player then
  940. return
  941. end
  942. char:SetPrimaryPartCFrame(where*CFrame.new(0,3.5,0))
  943. end
  944.  
  945. local Dual_Weld_Gun_combo = 0
  946. local damagetype = "Heal"
  947.  
  948. local Remote_Animation = Instance.new("RemoteFunction",script)
  949. Remote_Animation.Name= "Animation"
  950.  
  951. function runAnimation(name)
  952. return Remote_Animation:InvokeClient(name)
  953. end
  954.  
  955. function attack_f(plr)
  956. if plr ~= Player or attack then
  957. return
  958. end
  959. print("CheckMode:",mode)
  960. attack = true
  961. if mode == "Gun" then
  962. runAnimation("Gun1_AttackPhase1")
  963. local clone = Instance.new("Part")
  964. clone.Size = Vector3.new(0.1,0.1,0.1)
  965. clone.Color = Color3.new(0,1,0)
  966. clone.Parent = workspace
  967. clone.CFrame = gunmodel.Bullet.CFrame
  968. create_homing_script_f(clone,damagetype)
  969. runAnimation("Gun1_AttackPhase2")
  970. elseif mode == "Dual_Weld_Gun" then
  971. runAnimation("Gun1_AttackPhase1")
  972. local clone = Instance.new("Part")
  973. clone.Size = Vector3.new(0.1,0.1,0.1)
  974. clone.Color = Color3.new(0,1,0)
  975. clone.Parent = workspace
  976. clone.CFrame = gunleft.Bullet.CFrame
  977. create_homing_script_f(clone,damagetype)
  978. runAnimation("Gun1_AttackPhase2")
  979. runAnimation("Gun1_AttackPhase3")
  980. local clone = Instance.new("Part")
  981. clone.Size = Vector3.new(0.1,0.1,0.1)
  982. clone.Color = Color3.new(0,1,0)
  983. clone.Parent = workspace
  984. clone.CFrame = gunright.Bullet.CFrame
  985. create_homing_script_f(clone,damagetype)
  986. runAnimation("Gun1_AttackPhase4")
  987. end
  988. attack = false
  989. end
  990.  
  991. function switch_f(plr,key)
  992. if plr ~= Player then
  993. return
  994. end
  995. local switched = false
  996.  
  997. if mode ~= lastswitch then
  998. lastswitch = mode
  999. end
  1000. if key == "q" and mode ~= "Sword" then
  1001. mode = "Sword"
  1002. switched = true
  1003. elseif key == "e" and mode ~= "Gun" then
  1004. mode = "Gun"
  1005. switched = true
  1006. elseif key == "r" and mode ~= "Dual_Weld_Gun" then
  1007. mode = "Dual_Weld_Gun"
  1008. switched = true
  1009. elseif key == "t" and mode ~= "Dual_Weld_Sword" then
  1010. mode = "Dual_Weld_Sword"
  1011. switched = true
  1012. elseif key == "f" and damagetype == "Damage" then
  1013. damagetype = "Heal"
  1014. print("Damage Mode:",damagetype)
  1015. elseif key == "f" and damagetype == "Heal" then
  1016. damagetype = "Damage"
  1017. print("Damage Mode:",damagetype)
  1018. end
  1019.  
  1020. if switched then
  1021. switchweapon_f(mode)
  1022. print("Current Mode:", mode)
  1023. end
  1024. end
  1025.  
  1026. local music = Instance.new("Sound",char.HumanoidRootPart)
  1027. music.SoundId = "rbxassetid://6659445380"
  1028. music.Volume = 0.1
  1029. music.Looped = true
  1030. music:Play()
  1031. local skill_folder = Instance.new("Folder",script)
  1032. local switch_remote = Instance.new("RemoteEvent",skill_folder)
  1033. local attack_remote = Instance.new("RemoteEvent",skill_folder)
  1034. local teleport_remote = Instance.new("RemoteEvent",skill_folder)
  1035.  
  1036. skill_folder.Name = "Skill_Folder"
  1037. switch_remote.Name = "Switch"
  1038. attack_remote.Name = "Attack"
  1039. teleport_remote.Name = "Teleport"
  1040.  
  1041. attack_remote.OnServerEvent:Connect(attack_f)
  1042. switch_remote.OnServerEvent:Connect(switch_f)
  1043. teleport_remote.OnServerEvent:Connect(teleport)
  1044.  
  1045. game:GetService("RunService").Heartbeat:Connect(function(delta)
  1046. music:Resume()
  1047. if Humanoid.MaxHealth < 999 then
  1048. Humanoid.MaxHealth = 999
  1049. end
  1050. if Humanoid.Health ~=Humanoid.MaxHealth then
  1051. Humanoid.Health =Humanoid.MaxHealth
  1052. end
  1053. end)
  1054. print("Start NewLocalScript: Animation")
  1055. NLS([=[
  1056. local _,err = pcall(function()
  1057. local Player = owner or game:GetService("Players").LocalPlayer
  1058.  
  1059. local Remote_Animation = script.Parent.Animation
  1060.  
  1061. local Character = Player.Character
  1062. local Torso = Character.Torso
  1063. local Humanoid = Character.Humanoid
  1064. local LeftArm = Character["Left Arm"]
  1065. local LeftLeg = Character["Left Leg"]
  1066. local RightArm = Character["Right Arm"]
  1067. local RightLeg = Character["Right Leg"]
  1068. local LS = Torso["Left Shoulder"]
  1069. local LH = Torso["Left Hip"]
  1070. local RS = Torso["Right Shoulder"]
  1071. local RH = Torso["Right Hip"]
  1072. local Neck = Torso.Neck
  1073. local RootPart = Character.HumanoidRootPart
  1074. local RootJoint = RootPart.RootJoint
  1075.  
  1076. local cf = CFrame.new
  1077. local angles = CFrame.Angles
  1078. local ROOTC0 = RootJoint.C0
  1079. local NECKC0 = Torso.Neck.C0
  1080. local COS = math.cos
  1081. local ACOS = math.acos
  1082. local SIN = math.sin
  1083. local ASIN = math.asin
  1084. local ABS = math.abs
  1085. local MRANDOM = math.random
  1086. local FLOOR = math.floor
  1087. local euler=CFrame.fromEulerAnglesXYZ
  1088. local angles=CFrame.Angles
  1089.  
  1090.  
  1091. RW, LW=Instance.new("Weld"), Instance.new("Weld")
  1092. RW.Name="Right Shoulder" LW.Name="Left Shoulder"
  1093. LH=Torso["Left Hip"]
  1094. RH=Torso["Right Hip"]
  1095.  
  1096. RootCF=euler(-1.57,0,3.14)
  1097. necko=cf(0, 1, 0, -1, -0, -0, 0, 0, 1, 0, 1, 0)
  1098.  
  1099. RSH=Character.Torso["Right Shoulder"]
  1100. LSH=Character.Torso["Left Shoulder"]
  1101.  
  1102. RSH.Parent=nil
  1103. LSH.Parent=nil
  1104.  
  1105. RW.Name="Right Shoulder"
  1106. RW.Part0=Character.Torso
  1107. RW.C0=cf(1.5, 0.5, 0)
  1108. RW.C1=cf(0, 0.5, 0)
  1109. RW.Part1=Character["Right Arm"]
  1110. RW.Parent=Character.Torso
  1111.  
  1112. LW.Name="Left Shoulder"
  1113. LW.Part0=Character.Torso
  1114. LW.C0=cf(-1.5, 0.5, 0)
  1115. LW.C1=cf(0, 0.5, 0)
  1116. LW.Part1=Character["Left Arm"]
  1117. LW.Parent=Character.Torso
  1118.  
  1119. function QuaternionSlerp(a, b, t)
  1120. local cosTheta = a[1]*b[1] + a[2]*b[2] + a[3]*b[3] + a[4]*b[4]
  1121. local startInterp, finishInterp;
  1122. if cosTheta >= 0.0001 then
  1123. if (1 - cosTheta) > 0.0001 then
  1124. local theta = math.acos(cosTheta)
  1125. local invSinTheta = 1/math.sin(theta)
  1126. startInterp = math.sin((1-t)*theta)*invSinTheta
  1127. finishInterp = math.sin(t*theta)*invSinTheta
  1128. else
  1129. startInterp = 1-t
  1130. finishInterp = t
  1131. end
  1132. else
  1133. if (1+cosTheta) > 0.0001 then
  1134. local theta = math.acos(-cosTheta)
  1135. local invSinTheta = 1/math.sin(theta)
  1136. startInterp = math.sin((t-1)*theta)*invSinTheta
  1137. finishInterp = math.sin(t*theta)*invSinTheta
  1138. else
  1139. startInterp = t-1
  1140. finishInterp = t
  1141. end
  1142. end
  1143. 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
  1144. end
  1145.  
  1146. function Clerp(a,b,t)
  1147. local qa = {QuaternionFromCFrame(a)}
  1148. local qb = {QuaternionFromCFrame(b)}
  1149. local ax, ay, az = a.x, a.y, a.z
  1150. local bx, by, bz = b.x, b.y, b.z
  1151. local _t = 1-t
  1152. return QuaternionToCFrame(_t*ax + t*bx, _t*ay + t*by, _t*az + t*bz,QuaternionSlerp(qa, qb, t))
  1153. end
  1154.  
  1155. function QuaternionFromCFrame(cf)
  1156. local mx, my, mz, m00, m01, m02, m10, m11, m12, m20, m21, m22 = cf:components()
  1157. local trace = m00 + m11 + m22
  1158. if trace > 0 then
  1159. local s = math.sqrt(1 + trace)
  1160. local recip = 0.5/s
  1161. return (m21-m12)*recip, (m02-m20)*recip, (m10-m01)*recip, s*0.5
  1162. else
  1163. local i = 0
  1164. if m11 > m00 then
  1165. i = 1
  1166. end
  1167. if m22 > (i == 0 and m00 or m11) then
  1168. i = 2
  1169. end
  1170. if i == 0 then
  1171. local s = math.sqrt(m00-m11-m22+1)
  1172. local recip = 0.5/s
  1173. return 0.5*s, (m10+m01)*recip, (m20+m02)*recip, (m21-m12)*recip
  1174. elseif i == 1 then
  1175. local s = math.sqrt(m11-m22-m00+1)
  1176. local recip = 0.5/s
  1177. return (m01+m10)*recip, 0.5*s, (m21+m12)*recip, (m02-m20)*recip
  1178. elseif i == 2 then
  1179. local s = math.sqrt(m22-m00-m11+1)
  1180. local recip = 0.5/s return (m02+m20)*recip, (m12+m21)*recip, 0.5*s, (m10-m01)*recip
  1181. end
  1182. end
  1183. end
  1184.  
  1185. function QuaternionToCFrame(px, py, pz, x, y, z, w)
  1186. local xs, ys, zs = x + x, y + y, z + z
  1187. local wx, wy, wz = w*xs, w*ys, w*zs
  1188. local xx = x*xs
  1189. local xy = x*ys
  1190. local xz = x*zs
  1191. local yy = y*ys
  1192. local yz = y*zs
  1193. local zz = z*zs
  1194. 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))
  1195. end
  1196.  
  1197.  
  1198. local function CFrameFromTopBack(at, top, back)
  1199. local right = top:Cross(back)
  1200. return CFrame.new(
  1201. at.x, at.y, at.z,
  1202. right.x, top.x, back.x,
  1203. right.y, top.y, back.y,
  1204. right.z, top.z, back.z
  1205. )
  1206. end
  1207.  
  1208. function rayCast(Pos, Dir, Max, Ignore)
  1209. return game:service("Workspace"):FindPartOnRay(Ray.new(Pos, Dir.unit * (Max or math.huge)), Ignore)
  1210. end
  1211.  
  1212. local destroy_animate = true
  1213. local currentsine = 0
  1214.  
  1215. function attackanimation(animation_name)
  1216. if animation_name == "Gun1_AttackPhase1" then
  1217. for i=0,1,1/60 do
  1218. RH.C0=Clerp(RH.C0,cf(1,-1 - 0.05 * math.cos(currentsine / 28),0)*angles(math.rad(0),math.rad(90),math.rad(0))*angles(math.rad(-2.5),math.rad(0),math.rad(0 + 1 * math.cos(currentsine / 34))),i)
  1219. LH.C0=Clerp(LH.C0,cf(-1,-1 - 0.05 * math.cos(currentsine / 28),0)*angles(math.rad(0),math.rad(-90),math.rad(0))*angles(math.rad(-2.5),math.rad(0),math.rad(0 + 1 * math.cos(currentsine / 34))),i)
  1220. RootJoint.C0=Clerp(RootJoint.C0,RootCF*cf(0,0,0 + 0.05 * math.cos(currentsine / 28))*angles(math.rad(0 - 1 * math.cos(currentsine / 34)),math.rad(0),math.rad(0)),i)
  1221. Torso.Neck.C0=Clerp(Torso.Neck.C0,necko*angles(math.rad(0),math.rad(0),math.rad(0)),i)
  1222. RW.C0=Clerp(RW.C0,cf(1.5,0.5 + 0.1 * math.cos(currentsine / 28),0)*angles(math.rad(60 - 1 * math.cos(currentsine / 8)),math.rad(0),math.rad(0)),i)
  1223. LW.C0=Clerp(LW.C0,cf(-1.5,0.5 + 0.1 * math.cos(currentsine / 28),0)*angles(math.rad(0),math.rad(0),math.rad(0)),i)
  1224. game:GetService("RunService").Heartbeat:Wait()
  1225. end
  1226. elseif animation_name == "Gun1_AttackPhase2" then
  1227. for i=0,1,1/60 do
  1228. RH.C0=Clerp(RH.C0,cf(1,-1 - 0.05 * math.cos(currentsine / 28),0)*angles(math.rad(0),math.rad(90),math.rad(0))*angles(math.rad(-2.5),math.rad(0),math.rad(0 + 1 * math.cos(currentsine / 34))),i)
  1229. LH.C0=Clerp(LH.C0,cf(-1,-1 - 0.05 * math.cos(currentsine / 28),0)*angles(math.rad(0),math.rad(-90),math.rad(0))*angles(math.rad(-2.5),math.rad(0),math.rad(0 + 1 * math.cos(currentsine / 34))),i)
  1230. RootJoint.C0=Clerp(RootJoint.C0,RootCF*cf(0,0,0 + 0.05 * math.cos(currentsine / 28))*angles(math.rad(0 - 1 * math.cos(currentsine / 34)),math.rad(0),math.rad(0)),i)
  1231. Torso.Neck.C0=Clerp(Torso.Neck.C0,necko*angles(math.rad(0),math.rad(0),math.rad(0)),i)
  1232. RW.C0=Clerp(RW.C0,cf(1.5,0.5 + 0.1 * math.cos(currentsine / 28),0)*angles(math.rad(80 - 1 * math.cos(currentsine / 8)),math.rad(0),math.rad(0)),i)
  1233. LW.C0=Clerp(LW.C0,cf(-1.25,0.5 + 0.1 * math.cos(currentsine / 28),0)*angles(math.rad(0),math.rad(0),math.rad(0)),i)
  1234. game:GetService("RunService").Heartbeat:Wait()
  1235. end
  1236. elseif animation_name == "Gun2_AttackPhase1" then
  1237. for i=0,1,1/60 do
  1238. RH.C0=Clerp(RH.C0,cf(1,-1 - 0.05 * math.cos(currentsine / 28),0)*angles(math.rad(0),math.rad(90),math.rad(0))*angles(math.rad(-2.5),math.rad(0),math.rad(0 + 1 * math.cos(currentsine / 34))),i)
  1239. LH.C0=Clerp(LH.C0,cf(-1,-1 - 0.05 * math.cos(currentsine / 28),0)*angles(math.rad(0),math.rad(-90),math.rad(0))*angles(math.rad(-2.5),math.rad(0),math.rad(0 + 1 * math.cos(currentsine / 34))),i)
  1240. RootJoint.C0=Clerp(RootJoint.C0,RootCF*cf(0,0,0 + 0.05 * math.cos(currentsine / 28))*angles(math.rad(0 - 1 * math.cos(currentsine / 34)),math.rad(0),math.rad(45)),i)
  1241. Torso.Neck.C0=Clerp(Torso.Neck.C0,necko*angles(math.rad(0),math.rad(0),math.rad(-45)),i)
  1242. RW.C0=Clerp(RW.C0,cf(1.5,0.5 + 0.1 * math.cos(currentsine / 28),0)*angles(math.rad(90 - 1 * math.cos(currentsine / 8)),math.rad(0),math.rad(45)),i)
  1243. LW.C0=Clerp(LW.C0,cf(-1.5,0.5 + 0.1 * math.cos(currentsine / 28),0)*angles(math.rad(0),math.rad(0),math.rad(0)),i)
  1244. game:GetService("RunService").Heartbeat:Wait()
  1245. end
  1246. elseif animation_name == "Gun2_AttackPhase2" then
  1247. for i=0,1,1/60 do
  1248. RH.C0=Clerp(RH.C0,cf(1,-1 - 0.05 * math.cos(currentsine / 28),0)*angles(math.rad(0),math.rad(90),math.rad(0))*angles(math.rad(-2.5),math.rad(0),math.rad(0 + 1 * math.cos(currentsine / 34))),i)
  1249. LH.C0=Clerp(LH.C0,cf(-1,-1 - 0.05 * math.cos(currentsine / 28),0)*angles(math.rad(0),math.rad(-90),math.rad(0))*angles(math.rad(-2.5),math.rad(0),math.rad(0 + 1 * math.cos(currentsine / 34))),i)
  1250. RootJoint.C0=Clerp(RootJoint.C0,RootCF*cf(0,0,0 + 0.05 * math.cos(currentsine / 28))*angles(math.rad(0 - 1 * math.cos(currentsine / 34)),math.rad(0),math.rad(45)),i)
  1251. Torso.Neck.C0=Clerp(Torso.Neck.C0,necko*angles(math.rad(0),math.rad(0),math.rad(-45)),i)
  1252. RW.C0=Clerp(RW.C0,cf(1.5,0.5 + 0.1 * math.cos(currentsine / 28),0)*angles(math.rad(110 - 1 * math.cos(currentsine / 8)),math.rad(0),math.rad(45)),i)
  1253. LW.C0=Clerp(LW.C0,cf(-1.25,0.5 + 0.1 * math.cos(currentsine / 28),0)*angles(math.rad(0),math.rad(0),math.rad(0)),i)
  1254. game:GetService("RunService").Heartbeat:Wait()
  1255. end
  1256. elseif animation_name == "Gun2_AttackPhase3" then
  1257. for i=0,1,1/60 do
  1258. RH.C0=Clerp(RH.C0,cf(1,-1 - 0.05 * math.cos(currentsine / 28),0)*angles(math.rad(0),math.rad(90),math.rad(0))*angles(math.rad(-2.5),math.rad(0),math.rad(0 + 1 * math.cos(currentsine / 34))),i)
  1259. LH.C0=Clerp(LH.C0,cf(-1,-1 - 0.05 * math.cos(currentsine / 28),0)*angles(math.rad(0),math.rad(-90),math.rad(0))*angles(math.rad(-2.5),math.rad(0),math.rad(0 + 1 * math.cos(currentsine / 34))),i)
  1260. RootJoint.C0=Clerp(RootJoint.C0,RootCF*cf(0,0,0 + 0.05 * math.cos(currentsine / 28))*angles(math.rad(0 - 1 * math.cos(currentsine / 34)),math.rad(0),math.rad(-45)),i)
  1261. Torso.Neck.C0=Clerp(Torso.Neck.C0,necko*angles(math.rad(0),math.rad(0),math.rad(45)),i)
  1262. RW.C0=Clerp(RW.C0,cf(1.5,0.5 + 0.1 * math.cos(currentsine / 28),0)*angles(math.rad(0),math.rad(0),math.rad(0)),i)
  1263. LW.C0=Clerp(LW.C0,cf(-1.25,0.5 + 0.1 * math.cos(currentsine / 28),0)*angles(math.rad(90 + 1 * math.cos(currentsine / 8)),math.rad(0),math.rad(-45)),i)
  1264. game:GetService("RunService").Heartbeat:Wait()
  1265. end
  1266. elseif animation_name == "Gun2_AttackPhase4" then
  1267. for i=0,1,1/60 do
  1268. RH.C0=Clerp(RH.C0,cf(1,-1 - 0.05 * math.cos(currentsine / 28),0)*angles(math.rad(0),math.rad(90),math.rad(0))*angles(math.rad(-2.5),math.rad(0),math.rad(0 + 1 * math.cos(currentsine / 34))),i)
  1269. LH.C0=Clerp(LH.C0,cf(-1,-1 - 0.05 * math.cos(currentsine / 28),0)*angles(math.rad(0),math.rad(-90),math.rad(0))*angles(math.rad(-2.5),math.rad(0),math.rad(0 + 1 * math.cos(currentsine / 34))),i)
  1270. RootJoint.C0=Clerp(RootJoint.C0,RootCF*cf(0,0,0 + 0.05 * math.cos(currentsine / 28))*angles(math.rad(0 - 1 * math.cos(currentsine / 34)),math.rad(0),math.rad(-45)),i)
  1271. Torso.Neck.C0=Clerp(Torso.Neck.C0,necko*angles(math.rad(0),math.rad(0),math.rad(45)),i)
  1272. RW.C0=Clerp(RW.C0,cf(1.5,0.5 + 0.1 * math.cos(currentsine / 28),0)*angles(math.rad(0),math.rad(0),math.rad(0)),i)
  1273. LW.C0=Clerp(LW.C0,cf(-1.25,0.5 + 0.1 * math.cos(currentsine / 28),0)*angles(math.rad(110 + 1 * math.cos(currentsine / 8)),math.rad(0),math.rad(-45)),i)
  1274. game:GetService("RunService").Heartbeat:Wait()
  1275. end
  1276. end
  1277. return "Complete"
  1278. end
  1279. Remote_Animation.OnClientInvoke = attackanimation
  1280. function animation(sine)
  1281. if not attack then
  1282. local torvel=(RootPart.Velocity*Vector3.new(1,0,1)).magnitude
  1283. local hitfloor,posfloor=rayCast(RootPart.Position,(CFrame.new(RootPart.Position,RootPart.Position - Vector3.new(0,1,0))).lookVector,4,Character)
  1284. if hitfloor then
  1285. if Character:FindFirstChild("Animate") and destroy_animate then
  1286. destroy_animate=false
  1287. wait(1)
  1288. Character:FindFirstChild("Animate"):Destroy()
  1289. end
  1290. end
  1291. if RootPart.Velocity.y > 1 and hitfloor==nil then
  1292. RH.C0=Clerp(RH.C0,cf(1,-1 - 0.05 * math.cos(sine/25),0)*angles(math.rad(0),math.rad(90),math.rad(0))*angles(math.rad(-5),math.rad(0),math.rad(-20)),.1)
  1293. LH.C0=Clerp(LH.C0,cf(-1,-1 - 0.05 * math.cos(sine/25),0)*angles(math.rad(0),math.rad(-90),math.rad(0))*angles(math.rad(-5),math.rad(0),math.rad(20)),.1)
  1294. RootJoint.C0=Clerp(RootJoint.C0,RootCF*cf(0,0,0 + 0.05 * math.cos(sine/25))*angles(math.rad(-10),math.rad(0),math.rad(0)),.1)
  1295. Torso.Neck.C0=Clerp(Torso.Neck.C0,necko*angles(math.rad(-2.5),math.rad(0),math.rad(0)),.1)
  1296. RW.C0=Clerp(RW.C0,cf(1.45,0.5 + 0.1 * math.cos(sine/25),0)*angles(math.rad(-5),math.rad(0),math.rad(25)),.1)
  1297. LW.C0=Clerp(LW.C0,cf(-1.45,0.5 + 0.1 * math.cos(sine/25),0)*angles(math.rad(-5),math.rad(0),math.rad(-25)),.1)
  1298. elseif RootPart.Velocity.y < -1 and hitfloor==nil then
  1299. RH.C0=Clerp(RH.C0,cf(1,-1 - 0.05 * math.cos(sine/25),0)*angles(math.rad(0),math.rad(90),math.rad(0))*angles(math.rad(-5),math.rad(0),math.rad(-20)),.1)
  1300. LH.C0=Clerp(LH.C0,cf(-1,-1 - 0.05 * math.cos(sine/25),0)*angles(math.rad(0),math.rad(-90),math.rad(0))*angles(math.rad(-5),math.rad(0),math.rad(20)),.1)
  1301. RootJoint.C0=Clerp(RootJoint.C0,RootCF*cf(0,0,0 + 0.05 * math.cos(sine/25))*angles(math.rad(0),math.rad(0),math.rad(0)),.1)
  1302. Torso.Neck.C0=Clerp(Torso.Neck.C0,necko*angles(math.rad(0),math.rad(0),math.rad(0)),.1)
  1303. RW.C0=Clerp(RW.C0,cf(1.45,0.5 + 0.1 * math.cos(sine/25),0)*angles(math.rad(-20),math.rad(0),math.rad(50)),.1)
  1304. LW.C0=Clerp(LW.C0,cf(-1.45,0.5 + 0.1 * math.cos(sine/25),0)*angles(math.rad(-20),math.rad(0),math.rad(-50)),.1)
  1305. elseif torvel<1 and hitfloor~=nil then
  1306. RH.C0=Clerp(RH.C0,cf(1,-1 - 0.05 * math.cos(sine / 28),0)*angles(math.rad(0),math.rad(90),math.rad(0))*angles(math.rad(-2.5),math.rad(0),math.rad(0 + 1 * math.cos(sine / 34))),.1)
  1307. LH.C0=Clerp(LH.C0,cf(-1,-1 - 0.05 * math.cos(sine / 28),0)*angles(math.rad(0),math.rad(-90),math.rad(0))*angles(math.rad(-2.5),math.rad(0),math.rad(0 + 1 * math.cos(sine / 34))),.1)
  1308. RootJoint.C0=Clerp(RootJoint.C0,RootCF*cf(0,0,0 + 0.05 * math.cos(sine / 28))*angles(math.rad(0 - 1 * math.cos(sine / 34)),math.rad(0),math.rad(0)),.1)
  1309. Torso.Neck.C0=Clerp(Torso.Neck.C0,necko*angles(math.rad(22.5 - 2.5 * math.cos(sine / 28)),math.rad(0),math.rad(0)),.1)
  1310. if mode == "Dual_Weld_Gun" or mode == "Sword" then
  1311. RW.C0=Clerp(RW.C0,cf(1.5,0.5 + 0.1 * math.cos(sine / 28),0)*angles(math.rad(0),math.rad(0),math.rad(0)),.1)
  1312. else
  1313. RW.C0=Clerp(RW.C0,cf(1.5,0.5 + 0.1 * math.cos(sine / 28),0)*angles(math.rad(0),math.rad(0),math.rad(0)),.1)
  1314. end
  1315. if mode == "Sword" then
  1316. LW.C0=Clerp(LW.C0,cf(-1.25,0.5 + 0.1 * math.cos(sine / 28),0)*angles(math.rad(75 - 1 * math.cos(sine / 8)),math.rad(0),math.rad(20)),.1)
  1317. else
  1318. LW.C0=Clerp(LW.C0,cf(-1.5,0.5 + 0.1 * math.cos(sine / 28),0)*angles(math.rad(0),math.rad(0),math.rad(0)),.1)
  1319. end
  1320. elseif torvel>2 and hitfloor~=nil then
  1321. RH.C0=Clerp(RH.C0,cf(1,-0.85,-0.15 - 0.15 * math.cos(sine / 4))*angles(math.rad(0),math.rad(90),math.rad(0))*angles(math.rad(0),math.rad(0 + 5 * math.cos(sine / 8)),math.rad(0 + 25 * math.cos(sine / 8))),.1)
  1322. LH.C0=Clerp(LH.C0,cf(-1,-0.85,-0.15 + 0.15 * math.cos(sine / 4))*angles(math.rad(0),math.rad(-90),math.rad(0))*angles(math.rad(0),math.rad(0 + 5 * math.cos(sine / 8)),math.rad(0 + 25 * math.cos(sine / 8))),.1)
  1323. RootJoint.C0=Clerp(RootJoint.C0,RootCF*cf(0,0,-0.15 - 0.1 * math.cos(sine / 4))*angles(math.rad(5),math.rad(0),math.rad(0 - 5 * math.cos(sine / 8))),.1)
  1324. Torso.Neck.C0=Clerp(Torso.Neck.C0,necko*angles(math.rad(10 + 2.5 * math.cos(sine / 100)),math.rad(0),math.rad(0 + 5 * math.cos(sine / 8))),.1)
  1325. if mode == "Dual_Weld_Gun" or mode == "Sword" then
  1326. RW.C0=Clerp(RW.C0,cf(1.5,0.5,0)*angles(math.rad(0 - 10 * math.cos(sine / 8)),math.rad(0),math.rad(10 - 10 * math.cos(sine / 4))),.1)
  1327. else
  1328. RW.C0=Clerp(RW.C0,cf(1.5,0.5,0)*angles(math.rad(0 - 45 * math.cos(sine / 8)),math.rad(0),math.rad(10 - 10 * math.cos(sine / 4))),.1)
  1329. end
  1330. if mode == "Dual_Weld_Gun" then
  1331. LW.C0=Clerp(LW.C0,cf(-1.5,0.5,0)*angles(math.rad(0 + 10 * math.cos(sine / 8)),math.rad(0),math.rad(-10 + 10 * math.cos(sine / 4))),.1)
  1332. else
  1333. LW.C0=Clerp(LW.C0,cf(-1.5,0.5,0)*angles(math.rad(0 + 45 * math.cos(sine / 8)),math.rad(0),math.rad(-10 + 10 * math.cos(sine / 4))),.1)
  1334. end
  1335. end
  1336. end
  1337. end
  1338. game:GetService("RunService").RenderStepped:Connect(function(delta)
  1339. currentsine = currentsine + (25*delta)
  1340. animation(currentsine)
  1341. end)
  1342. end)
  1343. print(err)
  1344. ]=],script).Name = "Animation"
  1345. print("Start NewLocalScript: Keybinds")
  1346. NLS([=[
  1347. local player = owner or game:GetService("Players").LocalPlayer
  1348. local keylist={
  1349. ["Teleport"] = {"n"},
  1350. ["Switch"] = {"q","e","r","t","f"}
  1351. }
  1352. local needargs = {
  1353. ["Teleport"] = "Hit",
  1354. ["Switch"] = "Key",
  1355. ["Attack"] = "Hit"
  1356. }
  1357. local mouse = player:GetMouse()
  1358. mouse.Button1Down:Connect(function()
  1359. if script.Parent:FindFirstChild("Skill_Folder") then
  1360. if script.Parent.Skill_Folder:FindFirstChild("Attack") then
  1361. print("Fired Remote Attack")
  1362. script.Parent.Skill_Folder:FindFirstChild("Attack"):FireServer()
  1363. end
  1364. end
  1365. end)
  1366. mouse.KeyDown:Connect(function(k)
  1367. for index, keybinds in pairs(keylist) do
  1368. for i=1,#keybinds do
  1369. if keybinds[i] == k then
  1370. if script.Parent:FindFirstChild("Skill_Folder") then
  1371. if script.Parent.Skill_Folder:FindFirstChild(index) then
  1372. local args = needargs[index]
  1373. if args == "Key" then
  1374. args = k
  1375. else
  1376. args = mouse[args]
  1377. end
  1378. script.Parent.Skill_Folder:FindFirstChild(index):FireServer(args)
  1379. end
  1380. end
  1381. end
  1382. end
  1383. end
  1384. end)
  1385. ]=]
  1386. ,script).Name = "Keybinds"
  1387. end)
  1388. print(err)
  1389. ]===]
  1390. NS(rolandscript,script).Name = "Roland"
Add Comment
Please, Sign In to add comment