Advertisement
PyroSilver

Untitled

Dec 21st, 2015
140
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 28.97 KB | None | 0 0
  1.  
  2. --MADE BY CoolLegend (NOT THE SCRIPT) All you got to do is create local and run it.
  3. function Part(Par, Anc, Colli, Tran, Ref, Col, Siz)
  4. local p = Instance.new("Part")
  5. p.formFactor = "Custom"
  6. p.TopSurface = 0
  7. p.BottomSurface = 0
  8. p.Transparency = Tran
  9. p.Reflectance = Ref
  10. p.Anchored = Anc
  11. p.CanCollide = Colli
  12. p.BrickColor = Col
  13. p.Size = Siz
  14. p.Locked = true
  15. p.Parent = Par
  16. p:BreakJoints()
  17. return p
  18. end
  19. function Weld(P0, P1, C0, C1)
  20. local w = Instance.new("Weld")
  21. w.Part0 = P0
  22. w.Part1 = P1
  23. if C0 then
  24. w.C0 = C0
  25. end
  26. if C1 then
  27. w.C1 = C1
  28. end
  29. w.Parent = P0
  30. return w
  31. end
  32. V3 = Vector3.new
  33. C3 = Color3.new
  34. BN = BrickColor.new
  35. CN = CFrame.new
  36. CA = CFrame.Angles
  37. MR = math.rad
  38. MRA = math.random
  39. MP = math.pi
  40. MH = math.huge
  41. UD = UDim2.new
  42. Asset = "http://www.roblox.com/asset/?id="
  43. Noob = nil
  44. function MakeMotor(torso, p1, c0, c1)
  45. local mot = Instance.new("Motor6D")
  46. mot.C0 = c0
  47. mot.C1 = c1
  48. mot.Part0 = torso
  49. mot.Part1 = p1
  50. mot.Parent = torso
  51. return mot
  52. end
  53. function Set(tab)
  54. for _,v in pairs(tab) do
  55. local motor = v[1]
  56. local vel = v[2]
  57. local des = v[3]
  58. motor.MaxVelocity = vel
  59. motor.DesiredAngle = des
  60. end
  61. end
  62. function Animate(Hum, RSH, LSH, RH, LH)
  63. local pose = "Standing"
  64. local function sit()
  65. pose = "Seated"
  66. end
  67. local function jump()
  68. pose = "Jumping"
  69. end
  70. local function died()
  71. pose = "Dead"
  72. end
  73. local function falling()
  74. pose = "Falling"
  75. end
  76. local function climbing()
  77. pose = "Climbing"
  78. end
  79. local function run(speed)
  80. if speed > 0.5 then
  81. pose = "Running"
  82. else
  83. pose = "Standing"
  84. end
  85. end
  86. local function move()
  87. if pose == "Seated" then
  88. Set({{RSH, 0.15, math.pi/2}, {LSH, 0.15, -math.pi/2}, {LH, 0.15, math.pi/2}, {RH, 0.15, -math.pi/2}})
  89. return
  90. end
  91. if pose == "Jumping" then
  92. Set({{RSH, 0.3, math.pi}, {LSH, 0.3, -math.pi}, {LH, 0.3, 0}, {RH, 0.3, 0}})
  93. return
  94. end
  95. if pose == "Standing" then
  96. Set({{RSH, 0.25, 0}, {LSH, 0.25, 0}, {LH, 0.25, 0}, {RH, 0.25, 0}})
  97. return
  98. end
  99. if pose == "Falling" then
  100. Set({{RSH, 0.35, math.pi}, {LSH, 0.35, -math.pi}, {LH, 0.35, 0}, {RH, 0.35, 0}})
  101. return
  102. end
  103. if pose == "Running" then
  104. Set({{RSH, 0.2, -0.8}, {LSH, 0.2, 0.8}, {LH, 0.2, 0}, {RH, 0.2, 0}})
  105. elseif pose == "Climbing" then
  106. Set({{RSH, 0.35, 2.8}, {LSH, 0.35, -2.8}, {LH, 0.35, 0.1}, {RH, 0.35, 0.1}})
  107. end
  108. end
  109. Hum.Jumping:connect(jump)
  110. Hum.Running:connect(run)
  111. Hum.Seated:connect(sit)
  112. Hum.Died:connect(died)
  113. Hum.FreeFalling:connect(falling)
  114. Hum.Climbing:connect(climbing)
  115. coroutine.resume(coroutine.create(function()
  116. while pose ~= "Dead" do
  117. wait(0.04)
  118. move()
  119. end
  120. end))
  121. end
  122. function MakeNoob(pos, scale)
  123. local Nub = Instance.new("Model")
  124. Nub.Name = "Cannoneer nub"
  125. local Torso = Part(Nub, false, false, 0, 0, BN("Bright blue"), V3(2*scale, 2*scale, 1*scale))
  126. Torso.Name = "Torso"
  127. local Head = Part(Nub, false, false, 0, 0, BN("Bright yellow"), V3(2*scale, 1*scale, 1*scale))
  128. Head.Name = "Head"
  129. local Neck = MakeMotor(Torso, Head, CN(0, 1*scale, 0, -1, -0, -0, 0, 0, 1, 0, 1, 0), CN(0, -0.5*scale, 0, -1, -0, -0, 0, 0, 1, 0, 1, 0))
  130. local HeadMesh = Instance.new("SpecialMesh",Head)
  131. HeadMesh.Scale = V3(1.25, 1.25, 1.25)
  132. local Face = Instance.new("Decal",Head)
  133. Face.Face = "Front"
  134. Face.Texture = Asset..(13038247)
  135. local Rarm = Part(Nub, false, false, 0, 0, BN("Bright yellow"), V3(1*scale, 2*scale, 1*scale))
  136. Rarm.Name = "Right Arm"
  137. local Larm = Part(Nub, false, false, 0, 0, BN("Bright yellow"), V3(1*scale, 2*scale, 1*scale))
  138. Larm.Name = "Left Arm"
  139. local Rleg = Part(Nub, false, false, 0, 0, BN("Br. yellowish green"), V3(1*scale, 2*scale, 1*scale))
  140. Rleg.Name = "Right Leg"
  141. local Lleg = Part(Nub, false, false, 0, 0, BN("Br. yellowish green"), V3(1*scale, 2*scale, 1*scale))
  142. Lleg.Name = "Left Leg"
  143. local RSH = MakeMotor(Torso, Rarm, CN(1*scale, 0.5*scale, 0) * CA(0, MR(90), 0), CN(-0.5*scale, 0.5*scale, 0) * CA(0, MR(90), 0))
  144. local LSH = MakeMotor(Torso, Larm, CN(-1*scale, 0.5*scale, 0) * CA(0, MR(-90), 0), CN(0.5*scale, 0.5*scale, 0) * CA(0, MR(-90), 0))
  145. local RH = MakeMotor(Torso, Rleg, CN(0.5*scale, -1*scale, 0) * CA(0, MR(-90), 0), CN(0, 1*scale, 0) * CA(0, MR(-90), 0))
  146. local LH = MakeMotor(Torso, Lleg, CN(-0.5*scale, -1*scale, 0) * CA(0, MR(90), 0), CN(0, 1*scale, 0) * CA(0, MR(90), 0))
  147. local Hum = Instance.new("Humanoid")
  148. local Speed = 14+(2*scale)
  149. Hum.Parent = Nub
  150. Hum.Died:connect(function()
  151. wait(6)
  152. Nub:remove()
  153. wait(5)
  154. MakeNoob(pos, scale)
  155. end)
  156. Nub.Parent = workspace
  157. Nub:MakeJoints()
  158. Hum.MaxHealth = 50+(scale*70)
  159. Hum.Health = 50+(scale*70)
  160. Nub:MoveTo(pos)
  161. coroutine.resume(coroutine.create(function()
  162. repeat wait()
  163. Hum.Health = Hum.MaxHealth
  164. until Hum.Health >= Hum.MaxHealth-1
  165. end))
  166. Animate(Hum,RSH,LSH,RH,LH)
  167. local Char = Nub
  168. local necko = CN(0, 1*scale, 0, -1, -0, -0, 0, 0, 1, 0, 1, 0)
  169. local ShootColors = {"Bright yellow", "New Yeller", "Bright orange", "Neon orange", "Really red", "Bright red"}
  170. local Attacking = false
  171. local Accuracy = 5
  172. local Debounce = true
  173. local Hurt = false
  174. local Damage = {15,42}
  175. local Selected = false
  176. local ContentProvider = game:GetService("ContentProvider")
  177. local function RC(Pos, Dir, Max, Ignore)
  178. return workspace:FindPartOnRay(Ray.new(Pos, Dir.unit * (Max or 999)), Ignore)
  179. end
  180. local function RayC(Start, En, MaxDist, Ignore)
  181. return RC(Start, (En - Start), MaxDist, Ignore)
  182. end
  183. local function ComputePos(pos1, pos2)
  184. return CN(pos1, V3(pos2.x, pos1.y, pos2.z))
  185. end
  186. local function DetectSurface(pos, part)
  187. local surface = nil
  188. local pospos = part.CFrame
  189. local pos2 = pospos:pointToObjectSpace(pos)
  190. local siz = part.Size
  191. local shaep = part.Shape
  192. if shaep == Enum.PartType.Ball or shaep == Enum.PartType.Cylinder then
  193. surface = {"Anything", CN(pospos.p, pos)*CN(0, 0, -(pospos.p - pos).magnitude)*CA(MR(-90), 0, 0)}
  194. else
  195. if pos2.Y > ((siz.Y/2)-0.04) then
  196. surface = {"Top", CA(0, 0, 0)}
  197. elseif pos2.Y < -((siz.Y/2)-0.04) then
  198. surface = {"Bottom", CA(-MP, 0, 0)}
  199. elseif pos2.X > ((siz.X/2)-0.04) then
  200. surface = {"Right", CA(0, 0, MR(-90))}
  201. elseif pos2.X < -((siz.X/2)-0.04) then
  202. surface = {"Left", CA(0, 0, MR(90))}
  203. elseif pos2.Z > ((siz.Z/2)-0.04) then
  204. surface = {"Back", CA(MR(90), 0, 0)}
  205. elseif pos2.Z < -((siz.Z/2)-0.04) then
  206. surface = {"Front", CA(MR(-90), 0, 0)}
  207. end
  208. end
  209. return surface
  210. end
  211. local function waitChild(n, p)
  212. local c = p:findFirstChild(n)
  213. if c then return c end
  214. while true do
  215. c = p.ChildAdded:wait()
  216. if c.Name == n then return c end
  217. end
  218. end
  219. local function Notime(func)
  220. coroutine.resume(coroutine.create(function()
  221. func()
  222. end))
  223. end
  224. RSH.Part0 = Torso
  225. LSH.Part0 = Torso
  226. RH.Part0 = Torso
  227. LH.Part0 = Torso
  228. local Add = {
  229. Mesh = function(P, ID, Scale, Tex)
  230. local m = Instance.new("SpecialMesh")
  231. m.MeshType = "FileMesh"
  232. m.MeshId = ID or ""
  233. m.Scale = Scale or V3(1, 1, 1)
  234. m.TextureId = Tex or ""
  235. m.Parent = P
  236. return m
  237. end,
  238. Sphere = function(P, Scale)
  239. local m = Instance.new("SpecialMesh")
  240. m.MeshType = "Sphere"
  241. m.Scale = Scale or V3(1, 1, 1)
  242. m.Parent = P
  243. return m
  244. end
  245. }
  246. local Sounds = {
  247. Shoot = {Id = "http://www.roblox.com/asset/?id=2697431", Pitch = 0.3, Volume = 0.5},
  248. Boom = {Id = "http://www.roblox.com/asset/?id=2692806", Pitch = 0.55, Volume = 0.4},
  249. Slash = {Id = "rbxasset://sounds//swordslash.wav", Pitch = 0.5, Volume = 0.5},
  250. Hit = {Id = "http://www.roblox.com/asset/?id=2801263", Pitch = 0.85, Volume = 0.35},
  251. Reload = {Id = "rbxasset://soundsmetal.ogg", Pitch = 1, Volume = 0.45},
  252. }
  253. for _,v in pairs(Sounds) do
  254. ContentProvider:Preload(v.Id)
  255. end
  256. local function PlaySound(Sound, bool)
  257. local s = Instance.new("Sound")
  258. s.Looped = false
  259. s.Volume = Sound.Volume
  260. s.SoundId = Sound.Id
  261. if bool then
  262. s.Pitch = MRA((Sound.Pitch*0.75)*1000, (Sound.Pitch*1.15)*1000)/1000
  263. else
  264. s.Pitch = Sound.Pitch
  265. end
  266. s.Parent = Torso
  267. s:play()
  268. Notime(function()
  269. wait(0.5)
  270. s:remove()
  271. end)
  272. end
  273. local function GetParts(pos, dist)
  274. local parts = {}
  275. local function o(p)
  276. for _,v in pairs(p:children()) do
  277. if v:IsA("BasePart") then
  278. if (pos - v.Position).magnitude <= dist then
  279. table.insert(parts, {v, (pos - v.Position).magnitude, v.Anchored})
  280. end
  281. end
  282. o(v)
  283. end
  284. end
  285. o(workspace)
  286. return parts
  287. end
  288. local function GetHum(P)
  289. for _,v in pairs(P:children()) do
  290. if v:IsA("Humanoid") then
  291. if v.Health > 0 then
  292. return v
  293. end
  294. end
  295. end
  296. end
  297. local function GetGroup(Pos, Distance, Hit)
  298. local tab = {}
  299. for _,v in pairs(workspace:children()) do
  300. local h = GetHum(v)
  301. local t = v:findFirstChild("Torso")
  302. if h and t and v ~= Hit.Parent then
  303. if (t.Position - Pos).magnitude <= Distance then
  304. table.insert(tab, {h, v, (t.Position - Pos).magnitude})
  305. end
  306. end
  307. end
  308. if Hit then
  309. local h = GetHum(Hit.Parent)
  310. if h then
  311. table.insert(tab, {h, Hit.Parent, 0})
  312. end
  313. end
  314. return tab
  315. end
  316. local Model = Instance.new("Model")
  317. Model.Name = "Hand Cannon"
  318. local FTorso = Part(Model, false, false, 1, 0, Torso.BrickColor, V3(2*scale, 2*scale, 1*scale))
  319. local FW = Weld(Torso, FTorso)
  320. local RAB = Part(Model, false, false, 1, 0, BN("White"), V3(0.2, 0.2, 0.2))
  321. local LAB = Part(Model, false, false, 1, 0, BN("White"), V3(0.2, 0.2, 0.2))
  322. local RLB = Part(Model, false, false, 1, 0, BN("White"), V3(0.2, 0.2, 0.2))
  323. local LLB = Part(Model, false, false, 1, 0, BN("White"), V3(0.2, 0.2, 0.2))
  324. local RABW = Weld(Torso, RAB, CN(), CN(-1.5*scale, -0.5*scale, 0))
  325. local LABW = Weld(Torso, LAB, CN(), CN(1.5*scale, -0.5*scale, 0))
  326. local RLBW = Weld(Torso, RLB, CN(), CN(-0.5*scale, 1*scale, 0))
  327. local LLBW = Weld(Torso, LLB, CN(), CN(0.5*scale, 1*scale, 0))
  328. local RAW = Weld(RAB, nil, CN(), CN(0, 0.5*scale, 0))
  329. local LAW = Weld(LAB, nil, CN(), CN(0, 0.5*scale, 0))
  330. local RLW = Weld(RLB, nil, CN(), CN(0, 1*scale, 0))
  331. local LLW = Weld(LLB, nil, CN(), CN(0, 1*scale, 0))
  332. local TW = Weld(Torso, nil, CN(0.7*scale, 0.8*scale, 1.2*scale), CA(0, MR(180), MR(55)))
  333. local Weapon = Instance.new("Model")
  334. Weapon.Name = "Cannon"
  335. local HB = Part(Weapon, false, false, 1, 0, BN("White"), V3(0.2, 0.2, 0.2))
  336. local HBW = Weld(Rarm, HB, CN(0, -0.7*scale, 0), CA(0, MR(90), MR(90)))
  337. local HW = Weld(HB, nil)
  338. local Handle = Part(Weapon, false, false, 0, 0, BN("Dark grey"), V3(0.5*scale, 0.5*scale, 0.3*scale))
  339. Add.Mesh(Handle, "http://www.roblox.com/asset/?id=3270017", V3(1*scale, 0.7*scale, 2.2*scale), "")
  340. TW.Part1 = Handle
  341. local Main = Part(Weapon, false, false, 0, 0, BN("Dark grey"), V3(1.5*scale, 1.5*scale, 3*scale))
  342. Add.Mesh(Main, "http://www.roblox.com/asset/?id=3270017", V3(1.6*scale, 1.6*scale, 15*scale), "")
  343. Weld(Handle, Main, CA(0, MR(90), MR(90)), CN(1*scale, 0, 0.2*scale))
  344. local Main2 = Part(Weapon, false, false, 0, 0, BN("Gun metallic"), V3(1*scale, 1*scale, 1.5*scale))
  345. Add.Mesh(Main2, "http://www.roblox.com/asset/?id=3270017", V3(1.2*scale, 1.2*scale, 8*scale), "")
  346. Weld(Main, Main2, CN(), CN(0, 0, 1.7*scale))
  347. local Handle2 = Part(Weapon, false, false, 0, 0, BN("Dark grey"), V3(0.5*scale, 0.5*scale, 0.3*scale))
  348. Add.Mesh(Handle2, "http://www.roblox.com/asset/?id=3270017", V3(0.7*scale, 0.8*scale, 2.2*scale), "")
  349. Weld(Main2, Handle2, CA(0, MR(90), MR(90)), CN(-0.65*scale, 0, 0))
  350. local Tip = Part(Weapon, false, false, 0, 0, BN("Earth yellow"), V3(1.6*scale, 1.6*scale, 0.6*scale))
  351. Add.Sphere(Tip, V3(1.05, 1.05, 1))
  352. Weld(Main, Tip, CN(), CN(0, 0, -1.15*scale))
  353. local Tip4 = Part(Weapon, false, false, 0, 0, BN("Black"), V3(1.2*scale, 1.2*scale, 0.3*scale))
  354. Add.Mesh(Tip4, "http://www.roblox.com/asset/?id=3270017", V3(1.7*scale, 1.7*scale, 10*scale), "")
  355. Weld(Main, Tip4, CN(), CN(0, 0, -0.15*scale))
  356. for i = 1.3, 1.45, 0.1 do
  357. local Tip3 = Part(Weapon, false, false, 0, 0, BN("Dark grey"), V3(1.2*scale, 1.2*scale, 0.3*scale))
  358. Add.Mesh(Tip3, "http://www.roblox.com/asset/?id=3270017", V3(i*scale, i*scale, 2*scale), "")
  359. Weld(Main2, Tip3, CN(), CN(0, 0, 0.6*scale))
  360. end
  361. for i = -0.95, 0.66, 1.55 do
  362. local Tip3 = Part(Weapon, false, false, 0, 0, BN("Dark Curry"), V3(1.2*scale, 1.2*scale, 0.3*scale))
  363. Add.Mesh(Tip3, "http://www.roblox.com/asset/?id=3270017", V3(1.65*scale, 1.65*scale, 3*scale), "")
  364. Weld(Main, Tip3, CN(), CN(0, 0, i*scale))
  365. end
  366. for i = 1.3, 1.5, 0.1 do
  367. local Tip2 = Part(Weapon, false, false, 0, 0, BN("Earth yellow"), V3(1.6*scale, 1.6*scale, 0.6*scale))
  368. Add.Mesh(Tip2, "http://www.roblox.com/asset/?id=3270017", V3(i*scale, i*scale, 2*scale), "")
  369. Weld(Main, Tip2, CN(), CN(0, 0, 1.1*scale))
  370. end
  371. for i = -0.3, 1, 0.15 do
  372. local p = Part(Weapon, false, false, 0.7, 0, BN("Black"), V3(0.2, 0.2, 0.2))
  373. Add.Sphere(p, V3(6*scale, 6*scale, 2*scale))
  374. Weld(Main2, p, CN(0, 0, i*scale))
  375. end
  376. Weapon.Parent = Model
  377. Model.Parent = Char
  378.  
  379. local function Show_Damage(P, D)
  380. local mo = Instance.new("Model")
  381. mo.Name = "- "..D
  382. local p = Part(mo, false, false, 0, 0, BN("Bright red"), V3(0.2, 0.2, 0.2))
  383. p.Name = "Head"
  384. local m = Instance.new("SpecialMesh")
  385. m.MeshType = "Brick"
  386. m.Scale = Vector3.new(4.5, 2.3, 4.5)
  387. m.Parent = p
  388. local bp = Instance.new("BodyPosition", p)
  389. bp.maxForce = V3(MH, MH, MH)
  390. bp.P = 9001
  391. bp.position = CN(P) * CN(0, 1.5, 0).p
  392. local h = Instance.new("Humanoid")
  393. h.Health = 0
  394. h.MaxHealth = 0
  395. h.Name = "asd"
  396. h.Parent = mo
  397. local nah = true
  398. mo.Parent = workspace
  399. p.CFrame = CN(P)
  400. Notime(function()
  401. wait(1.5)
  402. for i = 0, 1, 0.05 do
  403. p.Transparency = i
  404. if nah then mo.Name = "" nah = false else mo.Name = "- "..D nah = true end
  405. wait()
  406. end
  407. mo:remove()
  408. end)
  409. end
  410. local function Kill(hit)
  411. if Debounce and Hurt then
  412. local Hu = GetHum(hit.Parent)
  413. if Hu then
  414. Debounce = false
  415. local Dmg = MRA(Damage[1], Damage[2])
  416. Hu.Health = Hu.Health - Dmg
  417. pcall(function() Show_Damage(Tip.Position, Dmg) end)
  418. PlaySound(Sounds.Hit, true)
  419. local chance = MRA(1, 10)
  420. if chance >=5 then
  421. Hu.PlatformStand = true
  422. wait(0.1)
  423. hit.Velocity = (CN(Torso.CFrame * CN(0, 0.5, 0).p, hit.Position).lookVector * 45)
  424. hit.RotVelocity = V3(MRA(-10, 10), MRA(-10, 10), MRA(-10, 10))
  425. wait(0.3)
  426. Hu.PlatformStand = false
  427. end
  428. end
  429. end
  430. end
  431. Main.Touched:connect(Kill)
  432. local function Attach(t)
  433. RSH.Part0 = t
  434. LSH.Part0 = t
  435. RH.Part0 = t
  436. LH.Part0 = t
  437. RABW.Part0 = t
  438. LABW.Part0 = t
  439. LLBW.Part0 = t
  440. RLBW.Part0 = t
  441. if t == Torso then
  442. FTorso.Transparency = 1
  443. else
  444. Torso.Transparency = 1
  445. end
  446. t.Transparency = 0
  447. end
  448. local function SelectAnim()
  449. RAW.Part1 = Rarm
  450. for i = 0.25, 1, 0.25 do
  451. RAW.C0 = CA(MR(-10*i), 0, MR(-5*i))
  452. wait()
  453. end
  454. for i = 0.1, 1, 0.1 do
  455. RAW.C0 = CA(MR(-10-90*i), 0, MR(-5-30*i))
  456. wait()
  457. end
  458. for i = 0.5, 1, 0.5 do
  459. RAW.C0 = CA(MR(-100-5*i), 0, MR(-35))
  460. wait()
  461. end
  462. HW.Part1 = Handle
  463. HW.C0 = CA(MR(50), 0, MR(-37))
  464. TW.Part1 = nil
  465. Attach(FTorso)
  466. LAW.Part1 = Larm
  467. for i = 0.25, 1, 0.25 do
  468. RAW.C0 = CA(MR(-105+10*i), 0, MR(-35+5*i))
  469. LAW.C0 = CA(MR(15*i), 0, MR(5*i))
  470. FW.C0 = CA(0, MR(-5*i), 0)
  471. HW.C0 = CA(MR(50-5*i), 0, MR(-37))
  472. wait()
  473. end
  474. for i = 0.06, 1, 0.06 do
  475. RAW.C0 = CA(MR(-95+95*i), MR(35*i), MR(-30+50*i))
  476. LAW.C0 = CA(MR(15+25*i), 0, MR(5+15*i)) * CN(0, (-0.4*scale)*i, 0)
  477. FW.C0 = CA(0, MR(-5-30*i), 0)
  478. HW.C0 = CA(MR(45), 0, MR(-37+15*i))
  479. wait()
  480. end
  481. Hum.WalkSpeed = Speed-3
  482. for i = 0.1, 1, 0.1 do
  483. RAW.C0 = CA(MR(15*i), MR(35+10*i), MR(20+8*i))
  484. LAW.C0 = CA(MR(40+7*i), 0, MR(20+6*i)) * CN(0, (-0.4*scale)-(0.2*scale)*i, 0)
  485. FW.C0 = CA(0, MR(-35-10*i), 0)
  486. HW.C0 = CA(MR(45-11*i), 0, MR(-22+15*i))
  487. wait()
  488. end
  489. for i = 0.25, 1, 0.25 do
  490. RAW.C0 = CA(MR(15+5*i), MR(45+5*i), MR(28+2*i))
  491. LAW.C0 = CA(MR(47+3*i), 0, MR(26+4*i)) * CN(0, -0.6*scale, 0)
  492. FW.C0 = CA(0, MR(-45-5*i), 0)
  493. HW.C0 = CA(MR(34-4*i), 0, MR(-7+7*i))
  494. wait()
  495. end
  496. end
  497. local function DeselAnim()
  498. for i = 0.25, 1, 0.25 do
  499. RAW.C0 = CA(MR(20-5*i), MR(50-5*i), MR(30-5*i))
  500. LAW.C0 = CA(MR(50-5*i), 0, MR(30-5*i)) * CN(0, -((0.6+0.1)*scale)*i, 0)
  501. FW.C0 = CA(0, MR(-50+5*i), 0)
  502. HW.C0 = CA(MR(30+5*i), 0, MR(-10*i))
  503. wait()
  504. end
  505. for i = 0.15, 1, 0.15 do
  506. RAW.C0 = CA(MR(15-30*i), MR(45-10*i), MR(25-5*i))
  507. LAW.C0 = CA(MR(45-20*i), 0, MR(25-15*i)) * CN(0, -0.5+0.2*i, 0)
  508. FW.C0 = CA(0, MR(-45+10*i), 0)
  509. HW.C0 = CA(MR(35+10*i), 0, MR(-10-15*i))
  510. wait()
  511. end
  512. for i = 0.12, 1, 0.12 do
  513. RAW.C0 = CA(MR(-15-70*i), MR(35-30*i), MR(20-30*i))
  514. LAW.C0 = CA(MR(25-25*i), 0, MR(10-10*i)) * CN(0, -0.3+0.3*i, 0)
  515. FW.C0 = CA(0, MR(-35+20*i), 0)
  516. HW.C0 = CA(MR(45+5*i), 0, MR(-25-12*i))
  517. wait()
  518. end
  519. LAW.Part1 = nil
  520. HW.C0 = CA(MR(50), 0, MR(-37))
  521. for i = 0.25, 1, 0.25 do
  522. RAW.C0 = CA(MR(-85-20*i), MR(5-5*i), MR(-10-25*i))
  523. FW.C0 = CA(0, MR(-15+15*i), 0)
  524. wait()
  525. end
  526. Attach(Torso)
  527. HW.Part1 = nil
  528. TW.Part1 = Handle
  529. Hum.WalkSpeed = 16
  530. for i = 0.15, 1, 0.15 do
  531. RAW.C0 = CA(MR(-105+95*i), 0, MR(-35+30*i))
  532. wait()
  533. end
  534. for i = 0.33, 1, 0.33 do
  535. RAW.C0 = CA(MR(-10+10*i), 0, MR(-5+5*i))
  536. wait()
  537. end
  538. RAW.Part1 = nil
  539. end
  540. local function Explode(Par, Pos, surface)
  541. Notime(function()
  542. local cf = CN(Pos) * CA(Par.CFrame:toEulerAnglesXYZ()) * surface[2] * CN(0, 1, 0)
  543. local col = Par.BrickColor.Color
  544. local r, g, b = col.r, col.g, col.b
  545. local col1, col2, col3 = C3(MRA(r*60, r*100)/100, MRA(g*60, g*100)/100, MRA(b*60, b*100)/100), C3(MRA(r*60, r*100)/100, MRA(g*60, g*100)/100, MRA(b*60, b*100)/100), C3(MRA(r*60, r*100)/100, MRA(g*60, g*100)/100, MRA(b*60, b*100)/100)
  546. local p = Part(workspace, true, false, 0, 0, BN(col1.r, col1.g, col1.b), V3(0.2, 0.2, 0.2))
  547. local p2 = Part(workspace, true, false, 0, 0, BN(col2.r, col2.g, col2.b), V3(0.2, 0.2, 0.2))
  548. local p3 = Part(workspace, true, false, 0, 0, BN(col3.r, col3.g, col3.b), V3(0.2, 0.2, 0.2))
  549. p.CFrame = cf
  550. p2.CFrame = cf
  551. p3.CFrame = cf
  552. local m = Add.Mesh(p, "http://www.roblox.com/asset/?id=20329976", V3(1, 1, 1))
  553. local m2 = Add.Mesh(p2, "http://www.roblox.com/asset/?id=20329976", V3(1, 1, 1))
  554. local m3 = Add.Mesh(p3, "http://www.roblox.com/asset/?id=20329976", V3(1, 1, 1))
  555. for i = -0.2, 1, 0.12 do
  556. p2.Transparency = i+0.1
  557. p.Transparency = i
  558. p3.Transparency = i+0.2
  559. m.Scale = V3(scale+(2.5*scale)*i, (1.4*scale)+scale*i, scale+(2.5*scale)*i)
  560. m2.Scale = V3((0.8*scale)+(2*scale)*i, (1.2*scale)+scale*i, (0.8*scale)+(2*scale)*i)
  561. m3.Scale = V3((0.5*scale)+scale*i, scale+scale*i, (0.5*scale)+scale*i)
  562. wait()
  563. end
  564. p2:remove()
  565. p3:remove()
  566. p:remove()
  567. end)
  568. end
  569. local function Shoot(Pos)
  570. coroutine.resume(coroutine.create(function()
  571. local acc = Accuracy*100
  572. local Start = Main2.CFrame * CN(0, 0, -0.5).p
  573. local Face = CN(Start, Pos) * CA(MR(MRA(-acc, acc))/100, MR(MRA(-acc, acc))/100, MR(MRA(-acc, acc))/100)
  574. local Cannonball = Part(Model, true, false, 0, 0, BN("Black"), V3(1.3*scale, 1.3*scale, 1.3*scale))
  575. Add.Sphere(Cannonball)
  576. Cannonball.CFrame = Face
  577. local Go = 3*scale
  578. local Drop = 0.55/(Go*3)
  579. local Dist = 500*scale
  580. local lastP = Start
  581. local omg = 0
  582. for i = Go, Dist, Go do
  583. Drop = Drop + 1/(Go*3)
  584. omg = omg + Drop
  585. local dropping = CA(MR(-Drop), 0, 0)
  586. if omg > 130 then
  587. dropping = CN()
  588. end
  589. Face = Face * dropping * CN(0, 0, -Go)
  590. Cannonball.CFrame = Face
  591. local Magn = (Face.p - lastP).magnitude
  592. local T = Part(Model, true, false, 0.1, 0, BN("Mid gray"), V3(0.2, 1, 0.2))
  593. local M = Instance.new("SpecialMesh",T)
  594. M.MeshType = "Head"
  595. M.Scale = V3(4.5*scale, Magn, 4.5*scale)
  596. T.CFrame = CN(lastP, Face.p) * CA(MR(-90), 0, 0) * CN(0, Magn/2, 0)
  597. Notime(function()
  598. wait(0.1)
  599. for i = 0.1, 1, 0.1 do
  600. T.Transparency = i+0.1
  601. M.Scale = V3(5-5*i, Magn+0.5, 5-5*i)
  602. wait()
  603. end
  604. T:remove()
  605. end)
  606. local Hit, Hitpos = RayC(lastP, Face.p, Go*2, Char)
  607. lastP = Face.p
  608. if Hit then
  609. PlaySound(Sounds.Boom, true)
  610. local s = DetectSurface(Hitpos, Hit)
  611. Explode(Hit, Hitpos, s)
  612. Cannonball.CFrame = CN(Hitpos)
  613. local hu = GetHum(Hit.Parent)
  614. if hu == nil and Hit.Parent.className ~= "Hat" and Hit.Anchored then
  615. coroutine.resume(coroutine.create(function()
  616. wait(10)
  617. for i = 0, 1, 0.04 do
  618. Cannonball.Transparency = i
  619. wait()
  620. end
  621. Cannonball:remove()
  622. end))
  623. else
  624. Cannonball:remove()
  625. end
  626. local Noobs = GetGroup(Hitpos, 5*scale, Hit)
  627. for _,v in pairs(Noobs) do
  628. local dm = 60/((v[3]+3)/3)
  629. local multi = (scale+10)/10
  630. dm = MRA(dm*0.9, dm*1.04)*multi
  631. v[1].Health = v[1].Health - dm
  632. local t = v[2]:findFirstChild("Head")
  633. if t then
  634. Show_Damage(t.Position, dm)
  635. end
  636. end
  637. local Parts = GetParts(Hitpos, 6*scale)
  638. for _,v in pairs(Parts) do
  639. if v[3] == false then
  640. Notime(function()
  641. if v[1].Name == "Brick wall" then
  642. v[1]:BreakJoints()
  643. v[1].Velocity = (CN(Hitpos, v[1].Position).lookVector * (110/((v[2]+2)/3)))
  644. wait(0.1)
  645. v[1].Velocity = (CN(Hitpos, v[1].Position).lookVector * (110/((v[2]+2)/3)))
  646. else
  647. v[1].Velocity = (CN(Hitpos, v[1].Position).lookVector * (80/((v[2]+2)/3)))
  648. end
  649. end)
  650. end
  651. end
  652. break
  653. end
  654. wait()
  655. end
  656. end))
  657. end
  658. local function ShootAnim(pos)
  659. RLW.Part1 = Rleg
  660. LLW.Part1 = Lleg
  661. local cf = ComputePos(Torso.Position, pos)
  662. local bp = Instance.new("BodyPosition",Torso)
  663. bp.maxForce = V3(MH, 0, MH)
  664. bp.P = 11000
  665. PlaySound(Sounds.Shoot, true)
  666. local effect = Part(Model, false, false, 0, 0, BN(ShootColors[MRA(1,#ShootColors)]), V3(0.2, 0.2, 0.2))
  667. local effect2 = Part(Model, false, false, 0, 0, BN(ShootColors[MRA(1,#ShootColors)]), V3(0.2, 0.2, 0.2))
  668. local m1 = Add.Mesh(effect, "http://www.roblox.com/asset/?id=20329976", V3(1,1,1))
  669. local m2 = Add.Mesh(effect2, "http://www.roblox.com/asset/?id=20329976", V3(1,1,1))
  670. local w1 = Weld(Main2, effect, CA(MR(-90), 0, 0), CN(0, -1, 0))
  671. local w2 = Weld(Main2, effect2, CA(MR(-90), 0, 0), CN(0, -1, 0))
  672. for i = 0, 1, 0.5 do
  673. RAW.C0 = CA(MR(20-50*i), MR(50-25*i), MR(30+45*i))
  674. LAW.C0 = CA(MR(50-10*i), 0, MR(30+20*i)) * CN(0, (-0.6*scale)-(0.3*scale)*i, 0)
  675. RLW.C0 = CA(MR(30*i), 0, MR(-15*i))
  676. LLW.C0 = CA(MR(10*i), 0, MR(-35*i))
  677. FW.C0 = CA(MR(5*i), MR(-50-15*i), 0)
  678. HW.C0 = CA(MR(30), MR(35*i), MR(-25*i))
  679. Neck.C0 = necko * CA(MR(10*i), 0, 0)
  680. bp.position = cf * CN(0, 0, (3*scale)*i).p
  681. m1.Scale = V3((0.5*scale)+(0.6*scale)*i, (0.4*scale)+(0.2*scale)*i, (0.5*scale)+(0.6*scale)*i)
  682. m2.Scale = V3((0.3*scale)+(0.5*scale)*i, (0.5*scale)+scale*i, (0.3*scale)+(0.5*scale)*i)
  683. w1.C1 = CN(0, -scale-(0.2*scale)*i, 0)
  684. w2.C1 = CN(0, -scale-(0.5*scale)*i, 0)
  685. effect.Transparency = 0.2*i
  686. effect2.Transparency = 0.2*i
  687. wait()
  688. end
  689. for i = 0.2, 1, 0.2 do
  690. RAW.C0 = CA(MR(-30-10*i), MR(25-5*i), MR(75+5*i))
  691. LAW.C0 = CA(MR(40-5*i), 0, MR(50+5*i)) * CN(0, (-0.9*scale)-(0.05*scale)*i, 0)
  692. RLW.C0 = CA(MR(30+5*i), 0, MR(-15))
  693. LLW.C0 = CA(MR(10+5*i), 0, MR(-35-5*i))
  694. FW.C0 = CA(MR(5+5*i), MR(-65-5*i), 0)
  695. HW.C0 = CA(MR(30), MR(35+5*i), MR(-25-5*i))
  696. Neck.C0 = necko * CA(MR(10+5*i), 0, 0)
  697. bp.position = cf * CN(0, 0, (3*scale)+scale*i).p
  698. m1.Scale = V3(scale+scale*i, (0.7*scale)+(0.9*scale)*i, scale+scale*i)
  699. m2.Scale = V3((0.8*scale)+(0.6*scale)*i, (1.5*scale)+(1.6*scale)*i, (0.8*scale)+(0.6*scale)*i)
  700. w1.C1 = CN(0, (-1.2*scale)-(0.6*scale)*i, 0)
  701. w2.C1 = CN(0, (-1.5*scale)-(1.8*scale)*i, 0)
  702. effect.Transparency = 0.2+0.9*i
  703. effect2.Transparency = 0.2+0.9*i
  704. wait()
  705. end
  706. effect:remove()
  707. effect2:remove()
  708. for i = 0.2, 1, 0.2 do
  709. bp.position = cf * CN(0, 0, (4*scale)+(0.8*scale)*i).p
  710. wait()
  711. end
  712. for i = 0.08, 1, 0.06 do
  713. RAW.C0 = CA(MR(-40+50*i), MR(20+15*i), MR(80-35*i))
  714. LAW.C0 = CA(MR(35-30*i), 0, MR(55-45*i)) * CN(0, (-0.95*scale)+(0.5*scale)*i, 0)
  715. RLW.C0 = CA(MR(35-35*i), 0, MR(-15+25*i))
  716. LLW.C0 = CA(MR(15-15*i), 0, MR(-40+30*i))
  717. FW.C0 = CA(MR(10-7*i), MR(-70+40*i), 0)
  718. HW.C0 = CA(MR(30), MR(40-40*i), MR(-30-10*i))
  719. Neck.C0 = necko * CA(MR(15+5*i), 0, MR(20*i))
  720. bp.position = cf * CN(0, 0, (4.8*scale)+(0.8*scale)*i).p
  721. wait()
  722. end
  723. bp:remove()
  724. for i = 0.33, 1, 0.33 do
  725. RAW.C0 = CA(MR(10+10*i), MR(35+5*i), MR(45-5*i))
  726. LAW.C0 = CA(MR(5), 0, MR(10)) * CN(0, (-0.45*scale)+(0.1*scale)*i, 0)
  727. FW.C0 = CA(MR(3-3*i), MR(-30+5*i), 0)
  728. HW.C0 = CA(MR(30), 0, MR(-40-10*i))
  729. wait()
  730. end
  731. for i = 0.12, 1, 0.12 do
  732. RAW.C0 = CA(MR(20+5*i), MR(40+5*i), MR(40+5*i))
  733. LAW.C0 = CA(MR(5), 0, MR(10)) * CN(0, (-0.35*scale)-(0.3*scale)*i, 0)
  734. FW.C0 = CA(0, MR(-25+5*i), 0)
  735. HW.C0 = CA(MR(30), 0, MR(-50-5*i))
  736. wait()
  737. end
  738. local b = Part(Model, false, false, 0, 0, BN("Black"), V3(1.1*scale, 1.1*scale, 1.1*scale))
  739. local m = Add.Sphere(b)
  740. local w = Weld(Larm, b, CN(), CN(0, 1.4*scale, 0))
  741. for i = 0.16, 1, 0.16 do
  742. LAW.C0 = CA(MR(5+30*i), 0, MR(10+10*i)) * CN(0, (-0.65*scale)+(0.65*scale)*i, 0)
  743. RAW.C0 = CA(MR(25), MR(45+3*i), MR(40))
  744. m.Scale = V3(0.5+0.5*i, 0.5+0.5*i, 0.5+0.5*i)
  745. Neck.C0 = necko * CA(MR(20-10*i), 0, MR(20-15*i))
  746. wait()
  747. end
  748. for i = 0.1, 1, 0.1 do
  749. LAW.C0 = CA(MR(35+105*i), 0, MR(20+20*i)) * CN(0, (-0.9*scale)*i, 0)
  750. RAW.C0 = CA(MR(25), MR(48+6*i), MR(40))
  751. Neck.C0 = necko * CA(MR(10-10*i), 0, MR(5-35*i))
  752. wait()
  753. end
  754. for i = 0.16, 1, 0.16 do
  755. LAW.C0 = CA(MR(140-10*i), 0, MR(40-15*i)) * CN(0, (-0.9*scale)-(0.2*scale)*i, 0)
  756. RAW.C0 = CA(MR(25), MR(54), MR(40))
  757. Neck.C0 = necko * CA(MR(5*i), 0, MR(-30))
  758. w.C0 = CN((1.5*scale)*i, (0.55*scale)*i, (1.1*scale)*i)
  759. wait()
  760. end
  761. PlaySound(Sounds.Reload, true)
  762. b:remove()
  763. w:remove()
  764. for i = 0.2, 1, 0.2 do
  765. LAW.C0 = CA(MR(130-10*i), 0, MR(25-15*i)) * CN(0, (-1.1*scale)+(0.2*scale)*i, 0)
  766. RAW.C0 = CA(MR(25-10*i), MR(54), MR(40))
  767. Neck.C0 = necko * CA(MR(5-3*i), 0, MR(-30+5*i))
  768. HW.C0 = CA(MR(30), 0, MR(-55+10*i))
  769. FW.C0 = CA(0, MR(-20-5*i), 0)
  770. wait()
  771. end
  772. for i = 0.11, 1, 0.11 do
  773. LAW.C0 = CA(MR(120-60*i), 0, MR(10+15*i)) * CN(0, (-0.9*scale)+(0.3*scale)*i, 0)
  774. RAW.C0 = CA(MR(15+5*i), MR(54-4*i), MR(40-10*i))
  775. Neck.C0 = necko * CA(MR(2-2*i), 0, MR(-25+25*i))
  776. HW.C0 = CA(MR(30), 0, MR(-45+45*i))
  777. FW.C0 = CA(0, MR(-25-20*i), 0)
  778. RLW.C0 = CA(0, 0, MR(10-8*i))
  779. LLW.C0 = CA(0, 0, MR(-10+8*i))
  780. wait()
  781. end
  782. Neck.C0 = necko
  783. for i = 0.25, 1, 0.25 do
  784. LAW.C0 = CA(MR(60-10*i), 0, MR(25+5*i)) * CN(0, -0.6*scale, 0)
  785. RAW.C0 = CA(MR(20), MR(50), MR(30))
  786. HW.C0 = CA(MR(30), 0, 0)
  787. FW.C0 = CA(0, MR(-45-5*i), 0)
  788. RLW.C0 = CA(0, 0, MR(2-2*i))
  789. LLW.C0 = CA(0, 0, MR(-2+2*i))
  790. wait()
  791. end
  792. RLW.Part1 = nil
  793. LLW.Part1 = nil
  794. RAW.C0 = CA(MR(20), MR(50), MR(30))
  795. LAW.C0 = CA(MR(50), 0, MR(30)) * CN(0, -0.6*scale, 0)
  796. FW.C0 = CA(0, MR(-50), 0)
  797. HW.C0 = CA(MR(30), 0, 0)
  798. Neck.C0 = necko
  799. end
  800. local function Melee()
  801. PlaySound(Sounds.Slash, true)
  802. for i = 0.25, 1, 0.25 do
  803. RAW.C0 = CA(MR(20+5*i), MR(50-5*i), MR(30+3*i))
  804. LAW.C0 = CA(MR(50), 0, MR(30+4*i)) * CN(0, (-0.6*scale)-(0.05*scale)*i, 0)
  805. HW.C0 = CA(MR(30), MR(5*i), 0)
  806. FW.C0 = CA(0, MR(-50-5*i), 0)
  807. wait()
  808. end
  809. for i = 0.12, 1, 0.12 do
  810. RAW.C0 = CA(MR(25+25*i), MR(45-30*i), MR(33+7*i))
  811. LAW.C0 = CA(MR(50), 0, MR(34+11*i)) * CN(0, (-0.65*scale)-(0.25*scale)*i, 0)
  812. HW.C0 = CA(MR(30), MR(5+25*i), 0)
  813. FW.C0 = CA(0, MR(-55-25*i), 0)
  814. wait()
  815. end
  816. for i = 0.33, 1, 0.33 do
  817. RAW.C0 = CA(MR(50+15*i), MR(15-5*i), MR(40-10*i)) * CN(0, (-0.2*scale)*i, 0)
  818. LAW.C0 = CA(MR(50+10*i), 0, MR(45-5*i)) * CN(0, (-0.9*scale)+(0.15*scale)*i, 0)
  819. HW.C0 = CA(MR(30+2*i), MR(30+5*i), 0)
  820. FW.C0 = CA(0, MR(-80+10*i), MR(-5*i))
  821. wait()
  822. end
  823. Hurt = true
  824. Debounce = true
  825. for i = 0.07, 1, 0.07 do
  826. RAW.C0 = CA(MR(65+55*i), MR(10), MR(30-70*i)) * CN(0, (-0.2*scale)-(1.1*scale)*i, 0)
  827. LAW.C0 = CA(MR(60+120*i), 0, MR(40-70*i)) * CN(0, (-0.75*scale)+(0.7*scale)*i, 0)
  828. HW.C0 = CA(MR(32+6*i), MR(35+20*i), MR(-4*i))
  829. FW.C0 = CA(0, MR(-70+110*i), 0)
  830. wait()
  831. end
  832. for i = 0.16, 1, 0.16 do
  833. RAW.C0 = CA(MR(120+10*i), MR(10), MR(-40-5*i)) * CN(0, (-1.3*scale)-(0.1*scale)*i, 0)
  834. LAW.C0 = CA(MR(180+15*i), 0, MR(-30-20*i)) * CN(0, (-0.05*scale)+(0.1*scale)*i, 0)
  835. HW.C0 = CA(MR(38+2*i), MR(55-6*i), MR(-4-1*i))
  836. FW.C0 = CA(0, MR(40+10*i), 0)
  837. wait()
  838. end
  839. Hurt = false
  840. for i = 0.2, 1, 0.2 do
  841. RAW.C0 = CA(MR(130+5*i), MR(10), MR(-45-2*i)) * CN(0, (-1.4*scale)-(0.05*scale)*i, 0)
  842. LAW.C0 = CA(MR(195+5*i), 0, MR(-50-8*i)) * CN(0, (0.05*scale)+(0.05*scale)*i, 0)
  843. HW.C0 = CA(MR(40), MR(49-2*i), MR(-5))
  844. FW.C0 = CA(0, MR(50+3*i), 0)
  845. wait()
  846. end
  847. wait(0.2)
  848. for i = 0.2, 1, 0.2 do
  849. RAW.C0 = CA(MR(135-10*i), MR(10+5*i), MR(-47+10*i)) * CN(0, (-1.45*scale)+(0.25*scale)*i, 0)
  850. LAW.C0 = CA(MR(200-10*i), 0, MR(-58+10*i)) * CN(0, (0.1*scale)-(0.1*scale)*i, 0)
  851. HW.C0 = CA(MR(40), MR(47-5*i), MR(-5+5*i))
  852. FW.C0 = CA(0, MR(53-10*i), 0)
  853. wait()
  854. end
  855. for i = 0.08, 1, 0.08 do
  856. RAW.C0 = CA(MR(125-90*i), MR(15+30*i), MR(-37+57*i)) * CN(0, (-1.2*scale)+(1.1*scale)*i, 0)
  857. LAW.C0 = CA(MR(190-125*i), 0, MR(-48+68*i)) * CN(0, (-0.5*scale)*i, 0)
  858. HW.C0 = CA(MR(40-7*i), MR(42-37*i), 0)
  859. FW.C0 = CA(0, MR(43-82*i), 0)
  860. wait()
  861. end
  862. for i = 0.2, 1, 0.2 do
  863. RAW.C0 = CA(MR(35-15*i), MR(45+5*i), MR(20+10*i)) * CN(0, (-0.1*scale)+(0.1*scale)*i, 0)
  864. LAW.C0 = CA(MR(65-15*i), 0, MR(20+10*i)) * CN(0, (-0.5*scale)-(0.1*scale)*i, 0)
  865. HW.C0 = CA(MR(33-3*i), MR(5-5*i), 0)
  866. FW.C0 = CA(0, MR(-41-9*i), 0)
  867. wait()
  868. end
  869. RLW.Part1 = nil
  870. LLW.Part1 = nil
  871. RAW.C0 = CA(MR(20), MR(50), MR(30))
  872. LAW.C0 = CA(MR(50), 0, MR(30)) * CN(0, -0.6*scale, 0)
  873. FW.C0 = CA(0, MR(-50), 0)
  874. HW.C0 = CA(MR(30), 0, 0)
  875. Neck.C0 = necko
  876. end
  877. wait(1)
  878. Selected = true
  879. SelectAnim()
  880. wait(1.5)
  881. while Hum.Health > 0 do
  882. local list = game.Players:GetPlayers()
  883. local targ = list[MRA(1,#list)].Character:findFirstChild("Torso")
  884. if targ then
  885. local choice = MRA(1,6)
  886. if choice == 1 then
  887. repeat
  888. wait(0.2)
  889. if targ.Parent == nil then break end
  890. Hum:MoveTo(CN(targ.Position, Torso.Position) * CN(0, 0, -(scale)).p, targ)
  891. until (Torso.Position - targ.Position).magnitude < (scale*2)+1
  892. Melee()
  893. else
  894. local bg = Instance.new("BodyGyro")
  895. bg.P = 3000
  896. bg.maxTorque = V3(MH, MH, MH)
  897. bg.cframe = ComputePos(Torso.Position, targ.Position)
  898. bg.Parent = Torso
  899. local pos = Torso.Position
  900. local pos2 = targ.Position
  901. for i = 1, 10, 1 do
  902. wait(0.1)
  903. bg.cframe = ComputePos(Torso.Position, targ.Position)
  904. pos2 = targ.Position
  905. end
  906. bg:remove()
  907. wait(0.2)
  908. if Hum.Health >0 then
  909. local magn = ((Torso.Position - pos2).magnitude+5)/((scale+10)/10)
  910. local pos = pos2 + V3(0, magn/11, 0)
  911. Shoot(pos)
  912. ShootAnim(pos)
  913. local p = RayC(pos, pos-V3(0, 10, 0), scale*4, Char)
  914. if p then
  915. Hum:MoveTo(CN(pos, Torso.Position) * CN(0, 0, -2).p, p)
  916. end
  917. end
  918. end
  919. end
  920. wait(0.2)
  921. end
  922. return Nub
  923. end
  924. for i = 1, 1 do
  925. coroutine.resume(coroutine.create(function()
  926. local nub = MakeNoob(V3(MRA(-50, 50),20,MRA(-50, 50)), 30)
  927. end))
  928. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement