Advertisement
JORGEEEEEE_EEE

big golem ovo

Jul 31st, 2019
123
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 51.66 KB | None | 0 0
  1. if game:GetService("RunService"):IsClient() then error("Please run as a server script. Use h/ instead of hl/.") end
  2. print("FE Compatibility: by WaverlyCole & Mokiros")
  3. InternalData = {}
  4. do
  5. script.Parent = owner.Character
  6. local Event = Instance.new("RemoteEvent")
  7. Event.Name = "UserInput"
  8. local function NewFakeEvent()
  9. local Fake = {fakeEvent=true,Connect=function(self,Func)self.Function=Func end}Fake.connect = Fake.Connect
  10. return Fake
  11. end
  12. local Mouse = {Target=nil,Hit=CFrame.new(),KeyUp=NewFakeEvent(),KeyDown=NewFakeEvent(),Button1Up=NewFakeEvent(),Button1Down=NewFakeEvent()}
  13. local UserInputService = {InputBegan=NewFakeEvent(),InputEnded=NewFakeEvent()}
  14. local ContextActionService = {Actions={},BindAction = function(self,actionName,Func,touch,...)
  15. self.Actions[actionName] = Func and {Name=actionName,Function=Func,Keys={...}} or nil
  16. end};ContextActionService.UnBindAction = ContextActionService.BindAction
  17. local function TriggerEvent(self,Event,...)
  18. local Trigger = Mouse[Event]
  19. if Trigger and Trigger.fakeEvent and Trigger.Function then
  20. Trigger.Function(...)
  21. end
  22. end
  23. Mouse.TrigEvent = TriggerEvent
  24. UserInputService.TrigEvent = TriggerEvent
  25. Event.OnServerEvent:Connect(function(FiredBy,Input)
  26. if FiredBy.Name ~= owner.Name then end
  27. if Input.MouseEvent then
  28. Mouse.Target = Input.Target
  29. Mouse.Hit = Input.Hit
  30. else
  31. local Begin = Input.UserInputState == Enum.UserInputState.Begin
  32. if Input.UserInputType == Enum.UserInputType.MouseButton1 then
  33. return Mouse:TrigEvent(Begin and "Button1Down" or "Button1Up")
  34. end
  35. for _,Action in pairs(ContextActionService.Actions) do
  36. for _,Key in pairs(Action.Keys) do
  37. if Key==Input.KeyCode then
  38. Action.Function(Action.Name,Input.UserInputState,Input)
  39. end
  40. end
  41. end
  42. Mouse:TrigEvent(Begin and "KeyDown" or "KeyUp",Input.KeyCode.Name:lower())
  43. UserInputService:TrigEvent(Begin and "InputBegan" or "InputEnded",Input,false)
  44. end
  45. end)
  46. InternalData["Mouse"] = Mouse
  47. InternalData["ContextActionService"] = ContextActionService
  48. InternalData["UserInputService"] = UserInputService
  49. Event.Parent = NLS([[
  50. local Player = owner
  51. local Event = script:WaitForChild("UserInput")
  52. local UserInputService = game:GetService("UserInputService")
  53. local Mouse = Player:GetMouse()
  54. local Input = function(Input,gameProcessedEvent)
  55. if gameProcessedEvent then return end
  56. Event:FireServer({KeyCode=Input.KeyCode,UserInputType=Input.UserInputType,UserInputState=Input.UserInputState})
  57. end
  58. UserInputService.InputBegan:Connect(Input)
  59. UserInputService.InputEnded:Connect(Input)
  60. local Hit,Target
  61. while wait(1/30) do
  62. if Hit ~= Mouse.Hit or Target ~= Mouse.Target then
  63. Hit,Target = Mouse.Hit,Mouse.Target
  64. Event:FireServer({["MouseEvent"]=true,["Target"]=Target,["Hit"]=Hit})
  65. end
  66. end
  67. ]],owner.Character)
  68. end
  69. RealGame = game;game = setmetatable({},{
  70. __index = function (self,Index)
  71. local Sandbox = function (Thing)
  72. if Thing:IsA("Player") then
  73. local RealPlayer = Thing
  74. return setmetatable({},{
  75. __index = function (self,Index)
  76. local Type = type(RealPlayer[Index])
  77. if Type == "function" then
  78. if Index:lower() == "getmouse" or Index:lower() == "mouse" then
  79. return function (self)
  80. return InternalData["Mouse"]
  81. end
  82. end
  83. return function (self,...)
  84. return RealPlayer[Index](RealPlayer,...)
  85. end
  86. else
  87. return RealPlayer[Index]
  88. end
  89. end;
  90. __tostring = function(self)
  91. return RealPlayer.Name
  92. end
  93. })
  94. end
  95. end
  96. if RealGame[Index] then
  97. local Type = type(RealGame[Index])
  98. if Type == "function" then
  99. if Index:lower() == "getservice" or Index:lower() == "service" then
  100. return function (self,Service)
  101. if Service:lower() == "players" then
  102. return setmetatable({},{
  103. __index = function (self2,Index2)
  104. local RealService = RealGame:GetService(Service)
  105. local Type2 = type(Index2)
  106. if Type2 == "function" then
  107. return function (self,...)
  108. return RealService[Index2](RealService,...)
  109. end
  110. else
  111. if Index2:lower() == "localplayer" then
  112. return Sandbox(owner)
  113. end
  114. return RealService[Index2]
  115. end
  116. end;
  117. __tostring = function(self)
  118. return RealGame:GetService(Service).Name
  119. end
  120. })
  121. elseif Service:lower() == "contextactionservice" then
  122. return InternalData["ContextActionService"]
  123. elseif Service:lower() == "contextactionservice" then
  124. return InternalData["UserInputService"]
  125. elseif Service:lower() == "runservice" then
  126. return setmetatable({},{
  127. __index = function(self2,Index2)
  128. local RealService = RealGame:GetService(Service)
  129. local Type2 = type(Index2)
  130. if Type2 == "function" then
  131. return function (self,...)
  132. return RealService[Index2](RealService,...)
  133. end
  134. else
  135. if Index2:lower() == "bindtorenderstep" then
  136. return function (self,Name,Priority,Function)
  137. return RealGame:GetService("RunService").Stepped:Connect(Function)
  138. end
  139. end
  140. if Index2:lower() == "renderstepped" then
  141. return RealService["Stepped"]
  142. end
  143. return RealService[Index2]
  144. end
  145. end
  146. })
  147. else
  148. return RealGame:GetService(Service)
  149. end
  150. end
  151. end
  152. return function (self,...)
  153. return RealGame[Index](RealGame,...)
  154. end
  155. else
  156. if game:GetService(Index) then
  157. return game:GetService(Index)
  158. end
  159. return RealGame[Index]
  160. end
  161. else
  162. return nil
  163. end
  164. end
  165. });Game = game;owner = game:GetService("Players").LocalPlayer
  166. print("Complete! Running...")
  167.  
  168. script.Parent=nil
  169. --- shortcuts
  170. v3 = Vector3.new
  171. cn = CFrame.new
  172. ca2 = CFrame.Angles
  173. mf = math.floor
  174. mran = math.random
  175. mrad = math.rad
  176. mdeg = math.deg
  177. ca = function(x,y,z) return ca2(mrad(x),mrad(y),mrad(z)) end
  178. mran2 = function(a,b) return mran(a*1000,b*1000)/1000 end
  179. ud=UDim2.new
  180. bn = BrickColor.new
  181. c3 = Color3.new
  182. -----
  183. --Player='Diitto'
  184. Players=game:service'Players'
  185. Player=Players.LocalPlayer --[Player]
  186. PChar=Player.Character
  187.  
  188. as,so={},{'metal','Block','Slash','Slash2','Hit','Kick'}
  189. as.corner='11294911'
  190. as.cone='1033714'
  191. as.ring="3270017"
  192. as.Chakram='47260990'
  193. as.ring2='18430887'
  194. as.blast='20329976'
  195. as.missile='10207677'
  196. as.fire='2693346'
  197. as.boom='3264793'
  198. as.slash='10209645'
  199. as.abscond='2767090'
  200. as.firelaser='13775494'
  201. as.diamond='9756362'
  202. as.metal='rbxasset://sounds\\unsheath.wav'
  203. as.Block = 'rbxasset://sounds\\metal.ogg'
  204. as.Slash = '10209645'
  205. as.Slash2 = '46760716'
  206. as.Hit='10209583'
  207. as.Kick='46153268'
  208. as.cast='2101137'
  209. as.rockhead= '21629626'
  210. as.rockheadt='21629620'
  211.  
  212.  
  213. for i,v in pairs(as) do
  214. if type(tonumber(v:sub(1,3)))=="number" then
  215. as[i]="http://www.roblox.com/asset/?id="..v
  216. end
  217. end
  218.  
  219. LastMade=nil
  220. iNew=function(tab)
  221. local v=Instance.new(tab[1])
  222. for Ind,Val in pairs(tab) do
  223. if Ind~=1 and Ind~=2 then
  224. v[Ind] = Val
  225. end
  226. end
  227. v.Parent=tab[2]==0 and LastMade or tab[2]
  228. LastMade=v
  229. return v
  230. end
  231. iPart=function(tab)
  232. local v=Instance.new(tab.type or 'Part')
  233. if tab.type~='CornerWedgePart' then v.formFactor='Custom' end
  234. v.TopSurface=0 v.BottomSurface=0
  235. if tab.sc then
  236. v.Size=v3(tab[2]*tab.sc,tab[3]*tab.sc,tab[4]*tab.sc)
  237. else
  238. v.Size=v3(tab[2],tab[3],tab[4])
  239. end
  240. if tab.co then v.BrickColor=bn(tab.co) end
  241. if tab.tr then v.Transparency=tab.tr end
  242. if tab.rf then v.Reflectance=tab.rf end
  243. if tab.can then v.CanCollide=tab.can end
  244. if tab.cf then v.CFrame=tab.cf end
  245. if tab.an then v.Anchored=tab.an end
  246. if tab.na then v.Name=tab.na end
  247. if tab.ma then v.Material=tab.ma end
  248. v.Parent=tab[1]
  249. v:BreakJoints()
  250. LastMade=v
  251. return v
  252. end
  253. function getoutline(x,z,i)
  254. return math.sqrt(x^2+z^2)+(i or 0.05),mdeg(math.atan2(x,z))
  255. end
  256. function v32(cf)
  257. local x,y,z=cf:toEulerAnglesXYZ()
  258. return v3(mdeg(x),mdeg(y),mdeg(z))
  259. end
  260. WeldLib={}
  261. function GetWeld(weld,CO)
  262. if not WeldLib[weld] then
  263. local x0,y0,z0=weld.C0:toEulerAnglesXYZ()
  264. local x1,y1,z1=weld.C1:toEulerAnglesXYZ()
  265. WeldLib[weld]={[0]=v3(mdeg(x0),mdeg(y0),mdeg(z0)),[1]=v3(mdeg(x1),mdeg(y1),mdeg(z1))}
  266. end
  267. return weld['C'..CO].p,WeldLib[weld][CO]
  268. end
  269. function ClearWeld(weld)
  270. if WeldLib[weld] then WeldLib[weld]=nil end
  271. end
  272. function TweenNum(i,loops,i1,i2,smooth)
  273. smooth = smooth or 1
  274. local perc
  275. if smooth == 1 then perc = math.sin((math.pi/2)/loops*i) else perc = i/loops end
  276. local ton
  277. if i1 > i2 then
  278. ton = -math.abs(i1 - i2) *perc
  279. else
  280. ton = math.abs(i1 - i2) *perc
  281. end
  282. return i1+ton
  283. end
  284. function TweenV3(i,loops,v1,v2,smooth)
  285. smooth = smooth or 1
  286. local perc
  287. if smooth == 1 then perc = math.sin((math.pi/2)/loops*i) else perc = i/loops end
  288. local tox2,toy2,toz2 = 0,0,0
  289. if v1.x > v2.x then
  290. tox2 = -math.abs(v1.x - v2.x) *perc
  291. else
  292. tox2 = math.abs(v1.x - v2.x) *perc
  293. end
  294. if v1.y > v2.y then
  295. toy2 = -math.abs(v1.y - v2.y) *perc
  296. else
  297. toy2 = math.abs(v1.y - v2.y) *perc
  298. end
  299. if v1.z > v2.z then
  300. toz2 = -math.abs(v1.z - v2.z) *perc
  301. else
  302. toz2 = math.abs(v1.z - v2.z) *perc
  303. end
  304. return v3(v1.x + tox2,v1.y + toy2,v1.z + toz2)
  305. end
  306. function TweenCF(i,loops,origpos,origangle,nextpos,nextangle,smooth)
  307. smooth = smooth or 1
  308. local perc
  309. if smooth == 1 then perc = math.sin((math.pi/2)/loops*i) else perc = i/loops end
  310. local tox,toy,toz = 0,0,0
  311. if origangle.x > nextangle.x then tox = -math.abs(origangle.x - nextangle.x) *perc
  312. else tox = math.abs(origangle.x - nextangle.x) *perc end
  313. if origangle.y > nextangle.y then toy = -math.abs(origangle.y - nextangle.y) *perc
  314. else toy = math.abs(origangle.y - nextangle.y) *perc end
  315. if origangle.z > nextangle.z then toz = -math.abs(origangle.z - nextangle.z) *perc
  316. else toz = math.abs(origangle.z - nextangle.z) *perc end
  317. local tox2,toy2,toz2 = 0,0,0
  318. if origpos.x > nextpos.x then
  319. tox2 = -math.abs(origpos.x - nextpos.x) *perc
  320. else tox2 = math.abs(origpos.x - nextpos.x) *perc end
  321. if origpos.y > nextpos.y then
  322. toy2 = -math.abs(origpos.y - nextpos.y) *perc
  323. else toy2 = math.abs(origpos.y - nextpos.y) *perc end
  324. if origpos.z > nextpos.z then
  325. toz2 = -math.abs(origpos.z - nextpos.z) *perc
  326. else toz2 = math.abs(origpos.z - nextpos.z) *perc end
  327. return cn(origpos.x + tox2,origpos.y + toy2,origpos.z + toz2)*ca(origangle.x + tox,origangle.y + toy,origangle.z + toz)
  328. end
  329. function SetWeld(weld,CO,i, loops, origpos,origangle, nextpos,nextangle,smooth)
  330. loops=math.floor(loops)
  331. smooth = smooth or 1
  332. if not WeldLib[weld] then
  333. local x0,y0,z0=weld.C0:toEulerAnglesXYZ()
  334. local x1,y1,z1=weld.C1:toEulerAnglesXYZ()
  335. WeldLib[weld]={[0]=v3(mdeg(x0),mdeg(y0),mdeg(z0)),[1]=v3(mdeg(x1),mdeg(y1),mdeg(z1))}
  336. end
  337. local perc =smooth==1 and math.sin((math.pi/2)/loops*i) or i/loops
  338. --print(weld.Part1)
  339. local tox,toy,toz = 0,0,0
  340. tox = origangle.x > nextangle.x and -math.abs(origangle.x - nextangle.x) *perc or math.abs(origangle.x - nextangle.x) *perc
  341. toy = origangle.y > nextangle.y and -math.abs(origangle.y - nextangle.y) *perc or math.abs(origangle.y - nextangle.y) *perc
  342. toz = origangle.z > nextangle.z and -math.abs(origangle.z - nextangle.z) *perc or math.abs(origangle.z - nextangle.z) *perc
  343. local tox2,toy2,toz2 = 0,0,0
  344. tox2= origpos.x > nextpos.x and -math.abs(origpos.x - nextpos.x) *perc or math.abs(origpos.x - nextpos.x) *perc
  345. toy2= origpos.y > nextpos.y and -math.abs(origpos.y - nextpos.y) *perc or math.abs(origpos.y - nextpos.y) *perc
  346. toz2= origpos.z > nextpos.z and -math.abs(origpos.z - nextpos.z) *perc or math.abs(origpos.z - nextpos.z) *perc
  347. WeldLib[weld][CO] = v3(origangle.x + tox,origangle.y + toy,origangle.z + toz)
  348. weld['C'..CO] = cn(origpos.x + tox2,origpos.y + toy2,origpos.z + toz2)*ca(origangle.x + tox,origangle.y + toy,origangle.z + toz)
  349. end
  350. function se(Key,Text)
  351. local Values = {}
  352. for value in (Text..Key):gmatch("(.-)"..Key) do
  353. table.insert(Values,value)
  354. end
  355. local Values2={}
  356. for i,v in pairs(Values) do Values2[i]=Values[i]:lower() end
  357. return Values,Values2
  358. end
  359. findplayer=function(nn)
  360. if not nn then return nil end
  361. local found
  362. for i,v in pairs(Players:GetPlayers()) do
  363. if string.find(v.Name:lower(),nn:lower()) and not found then found=v end
  364. end
  365. return found
  366. end
  367. LoopFunctions={}
  368. iLoopFunctions=-9000
  369. function DoLoop(times,func)
  370. iLoopFunctions=iLoopFunctions+1
  371. LoopFunctions[tonumber(iLoopFunctions)]={times,0,func}
  372. end
  373. function MeshEffect(times,cf1,cf2,scale1,scale2,tr1,tr2,col,type)
  374. local cf2=cf2 or cf1
  375. local v=iPart{Char,0.2,0.2,0.2,co=col,cf=cf1,na='Mesh',an=true,ca=false,tr=tr1}
  376. local mesh=iNew{'SpecialMesh',v,Scale=scale1}
  377. if type=='Brick' or type=='Sphere' then
  378. mesh.MeshType=type
  379. else
  380. mesh.MeshId=type
  381. end
  382. local x1,y1,z1 = cf1:toEulerAnglesXYZ()
  383. local x2,y2,z2 = cf2:toEulerAnglesXYZ()
  384. local count=0
  385. DoLoop(times,function(i) count=count+1
  386. mesh.Scale=TweenV3(count,times,scale1,scale2,1)*((type=='Brick' or type=='Sphere') and 5 or 1)
  387. v.Transparency=TweenNum(count,times,tr1,tr2,1)
  388. v.CFrame=TweenCF(count,times,cf1.p,v3(mdeg(x1),mdeg(y1),mdeg(z1)),cf2.p,v3(mdeg(x2),mdeg(y2),mdeg(z2)),1)
  389. if i==1 then v:Remove() end end)
  390. end
  391. Dmgv={8,16}
  392. HitDebounce={}
  393. Damage=function(Hum,Mult,Sound)
  394. if not Hum or Hum.Parent==Char then return end
  395. if not Hum.Parent:findFirstChild'Torso' then return end
  396. local HName=Hum.Parent.Name
  397. if HitDebounce[HName] and HitDebounce[HName]>tick() then return end
  398. HitDebounce[HName]=tick()+0.2
  399. local Mult=Mult or 1
  400. local Dealt=mran(Dmgv[1],Dmgv[2])*Mult
  401. local col=''
  402. if Hum.Parent:findFirstChild'Block' and Hum.Parent.Block.Value>0 then
  403. Hum.Parent.Block.Value=Hum.Parent.Block.Value-1
  404. col='Bright blue'
  405. else
  406. Hum.Health=Hum.Health-Dealt
  407. col='Bright red'
  408. end
  409. if Sound then so[col=='Bright blue' and 'Block' or 'Hit']:Play() end
  410. local DoH=iNew{'Model',Char,Name=col=='Bright blue' and 'Block' or Dealt}
  411. iNew{'Humanoid',DoH,MaxHealth=1/0,Health=1/0,Name=''}
  412. local Doh=iPart{DoH,0.6,0.2,0.6,co=col,an=true} Doh.Name='Head' iNew{'CylinderMesh',Doh}
  413. local dofs=Hum.Parent.Torso.CFrame*cn(mran2(-1.5,1.5),2.5,mran2(-1,1)) Doh.CFrame=dofs
  414. DoLoop(40,function(i) Doh.CFrame=dofs*cn(0,i*2,0) Doh.Transparency=i-0.5 if i==1 then DoH:Remove() end end)
  415. end
  416. AOEFind = function(pos,ra,f,f2) -- range get
  417. local p0,p1=pos-v3(ra/2,ra/2,ra/2),pos+v3(ra/2,ra/2,ra/2)
  418. pcall(function()
  419. for i,v in pairs(workspace:FindPartsInRegion3(Region3.new(p0,p1),nil,100)) do
  420. local Hum=v.Parent:findFirstChild'Humanoid'
  421. if v.Name=='Torso' and Hum and Hum.Health>0 and v.Parent~=Char then
  422. pcall(function() f(Hum,v) end)
  423. elseif f2 and not Hum then
  424. pcall(function() f2(v) end)
  425. end
  426. end
  427. end)
  428. end
  429. function FindSurface(part, position)
  430. local obj = part.CFrame:pointToObjectSpace(position)
  431. local siz = part.Size/2
  432. for i,v in pairs(Enum.NormalId:GetEnumItems()) do
  433. local vec = Vector3.FromNormalId(v)
  434. local wvec = part.CFrame:vectorToWorldSpace(vec)
  435. local vz = (obj)/(siz*vec)
  436. if (math.abs(vz.X-1) < 0.01 or math.abs(vz.Y-1) < 0.01 or math.abs(vz.Z-1) < 0.01) then
  437. return wvec,vec
  438. end
  439. end
  440. if part.className == "WedgePart" then
  441. return part.CFrame:vectorToWorldSpace(Vector3.new(0,0.707,-0.707)), Vector3.new(0,0.707,-0.707)
  442. end
  443. end
  444. function FaceBG(pos)
  445. BG.maxTorque=v3(1,1,1)/0
  446. BG.cframe=cn(Torso.Position,v3(pos.x,Torso.Position.y,pos.z))*cn(0,0,-1)
  447. end
  448. ray = function(Pos, Dir,tab,length) -- ray cast
  449. return workspace:FindPartOnRay(Ray.new(Pos, Dir.unit *(length or 999)),tab)
  450. end
  451. function Projectile(ofs,speed,part,adj,fhit,fnohit)
  452. part.CFrame=ofs*adj
  453. local stop=false
  454. DoLoop(50,function(x)
  455. local i=x
  456. if not stop then
  457. local hit,pos=ray(ofs.p,ofs.p-ofs*cn(0,0,-1).p,Char,speed+1)
  458. if hit then
  459. --Hit
  460. if fhit then i=1 stop=true
  461. ----
  462. local cof=FindSurface(hit,pos)
  463. --iPart{workspace,2,2,0.2,cf=cn(pos,pos+cof),an=true,co='Black'}
  464. ----
  465. local x,y,z=ofs:toEulerAnglesXYZ()
  466. ofs=cn(pos)*ca(mdeg(x),mdeg(y),mdeg(z))*cn(0,0,-part.Size.y/2)
  467. part.CFrame=ofs*adj
  468. fhit(hit,pos) end
  469. else
  470. ofs=ofs*cn(0,0,speed)
  471. part.CFrame=ofs*adj
  472. end
  473. if i==1 then
  474. if fnohit then fnohit(ofs.p) else part:Remove() end
  475. end
  476. end
  477. end)
  478. end
  479.  
  480. CC={'','Bright yellow','Flame reddish orange'}
  481. Scale=5
  482. Mat='Marble'
  483.  
  484. SpawnPoint=PChar.Torso.CFrame*cn(0,1+Scale*3,-20-Scale*1.5)
  485. name='Brock'
  486. pcall(function() _G.OldMod00:Remove() end)
  487.  
  488. ---------------
  489. UNDYING=function()
  490. pcall(function() fUNDYING:disconnect() end)
  491. pcall(function() local hum=Grabbing.Part1.Parent.Humanoid Grabbing:Remove() Grabbing=nil hum.PlatformStand=false end)
  492. Torso.Anchored=true Torso.Transparency=1 Torso.CanCollide=false
  493. Stand:Remove() Head:Remove()
  494. local RespawnPos=cn(Torso.CFrame.p+v3(0,Scale*5,0))*ca(0,mran(-360,360),0)
  495. wait(4)
  496. Anim='Reviving'
  497. local oldChar=Char
  498. local oldRootLimbs=RootLimbs
  499. for i,v in pairs(oldRootLimbs) do v.Anchored=true end
  500. fMarble(Char,function(v) v.Anchored=true end)
  501. MakeAI(RespawnPos) Anim='Reviving'
  502. fMarble(Char,function(v) v.Transparency=1 end)
  503. for i,v in pairs(RootLimbs) do v.Transparency=1 end
  504. wait(0.1) Torso.Anchored=true
  505. local Reconstruct={}
  506. fMarble(oldChar,function(v)
  507. local x1,y1,z1=v.CFrame:toEulerAnglesXYZ()
  508. local x2,y2,z2=Char[v.Parent.Name][v.Name].CFrame:toEulerAnglesXYZ()
  509. Reconstruct[#Reconstruct+1]={v,Char[v.Parent.Name][v.Name],v.Position,v3(mdeg(x1),mdeg(y1),mdeg(z1)),v3(mdeg(x2),mdeg(y2),mdeg(z2))} end)
  510. for i,v in pairs(oldRootLimbs) do
  511. local x1,y1,z1=v.CFrame:toEulerAnglesXYZ()
  512. local x2,y2,z2=Char[v.Name].CFrame:toEulerAnglesXYZ()
  513. Reconstruct[#Reconstruct+1]={v,Char[v.Name],v.Position,v3(mdeg(x1),mdeg(y1),mdeg(z1)),v3(mdeg(x2),mdeg(y2),mdeg(z2))} end
  514. local tweens=100
  515. for tween=1,tweens do
  516. for i,v in pairs(Reconstruct) do v[1].CFrame=TweenCF(tween,tweens,v[3],v[4],v[2].Position,v[5],1)*ca(360*(tween/tweens),720*(tween/tweens),0) end
  517. wait()
  518. end
  519. oldChar:Remove()
  520. fMarble(Char,function(v) v.Transparency=0 end)
  521. for i,v in pairs(RootLimbs) do v.Transparency=0 end
  522. Torso.Anchored=false wait()
  523. BG.maxTorque=v3(1,1,1)/0 BG.cframe=Torso.CFrame
  524. ReturnAnim()
  525. wait(2)
  526. BG.maxTorque=nov3
  527. Anim,ArmAnim,LegAnim='None','None','None'
  528. end
  529. ------
  530.  
  531. function MakeAI(SpawnPoint2)
  532. Char=iNew{'Model',workspace,Name=name,archivable=false} _G.OldMod00=Char
  533. Torso=iPart{Char,2,2,1,sc=Scale,co=CC[1],cf=SpawnPoint2,na='Torso'}
  534. pTorso=iPart{Char,2,2,1,sc=Scale,co=CC[1],cf=SpawnPoint2,na='pTorso'}
  535. Head=iPart{Char,1,1,1,sc=Scale,co=CC[1],na='Head'}
  536. pHead=iPart{Char,1,1,1,sc=Scale,co=CC[1],na='pHead'} iNew{'SpecialMesh',pHead,Scale=v3(1,1,1)*Scale/1.4,VertexColor=v3(1,1,1)/1.65,MeshId=as.rockhead,TextureId=as.rockheadt}
  537. Stand=iPart{Char,1.5,2.9,1.1,sc=Scale,co=CC[1],na='Stand'}
  538.  
  539. for i,n in pairs(so) do
  540. local v=iNew{'Sound',Torso,Volume=1,Pitch=1,Looped=false,Name=v,SoundId=as[n]}
  541. so[n]=v
  542. end
  543.  
  544.  
  545. LSho=iPart{Char,1,1.5,1,sc=Scale,co=CC[1],na='LSho'}
  546. LArm=iPart{Char,1,1.5,1,sc=Scale,co=CC[1],na='LArm'}
  547.  
  548. RSho=iPart{Char,1,1.5,1,sc=Scale,co=CC[1],na='RSho'}
  549. RArm=iPart{Char,1,1.5,1,sc=Scale,co=CC[1],na='RArm'}
  550.  
  551. LThi=iPart{Char,1,1.5,1,sc=Scale,co=CC[1],na='LThi'}
  552. LLeg=iPart{Char,1,1.5,1,sc=Scale,co=CC[1],na='LLeg'}
  553.  
  554. RThi=iPart{Char,1,1.5,1,sc=Scale,co=CC[1],na='RThi'}
  555. RLeg=iPart{Char,1,1.5,1,sc=Scale,co=CC[1],na='RLeg'}
  556.  
  557.  
  558.  
  559. nov3=v3(0,0,0)
  560. Marble={}
  561. MarbleSpeed=0.2
  562. MarbleMax=12
  563. for i,v in pairs({pTorso,LSho,RSho,LArm,RArm,LThi,RThi,LLeg,RLeg}) do
  564. v.Material=Mat
  565. local VS=v.Size
  566. local va=1.2
  567. --v.Size=v.Size/1.5
  568. local vv=v:Clone()
  569. for x=-1,1,2 do
  570. for y=-1,1,2 do
  571. for z=-1,1,2 do
  572. local marb=vv:Clone() marb.Size=VS/mran2(1.8,2.2) marb.Parent=v marb.Name=x..y..z
  573. local wmarb=iNew{'Weld',marb,Part0=v,Part1=marb,C0=cn(VS.x/4*x/va,VS.y/4*y,VS.z/4*z/va)*ca(mran(-MarbleMax,MarbleMax),mran(-MarbleMax,MarbleMax),mran(-MarbleMax,MarbleMax))}
  574. Marble[#Marble+1]={wmarb,mran(-1,1),mran(-1,1),mran(-1,1)}
  575. end end end
  576. iNew{'BlockMesh',v,Scale=v3(1,1,1)/1.5}
  577. v.Transparency=0 --.995
  578. end
  579.  
  580. for i,v in pairs(Char:children()) do if v:IsA'BasePart' and v.Name~='Torso' then v.CFrame=Torso.CFrame end end
  581.  
  582. Head.Transparency=0.99
  583. Head.CanCollide=false
  584. Neck=iNew{'Weld',Torso,Part0=Torso,Part1=Head,C0=cn(0,0,0)}
  585. pNeck=iNew{'Weld',Torso,Part0=pTorso,Part1=pHead,C0=cn(0,1.5*Scale,0)}
  586. Hum=iNew{'Humanoid',Char}
  587.  
  588.  
  589. Torso.Transparency=1
  590. wTorso=iNew{'Weld',Torso,Part0=Torso,Part1=pTorso,C0=cn(0,-2.5*Scale,0)*ca(0,0,0)}
  591. oTorso=cn(0,0,0)
  592.  
  593. Stand.Transparency=1
  594. wStand=iNew{'Weld',Torso,Part0=Torso,Part1=Stand,C0=cn(0,-2.5*Scale,0)}
  595.  
  596. wLSho=iNew{'Weld',LSho,Part0=pTorso,Part1=LSho,C0=cn(-1.5*Scale,0.75*Scale,0),C1=cn(0,0.25*Scale,0)}
  597. wLArm=iNew{'Weld',LArm,Part0=LSho,Part1=LArm,C0=cn(0,-0.75*Scale,0),C1=cn(0,0.75*Scale,0)}
  598.  
  599. wRSho=iNew{'Weld',RSho,Part0=pTorso,Part1=RSho,C0=cn(1.5*Scale,0.75*Scale,0),C1=cn(0,0.25*Scale,0)}
  600. wRArm=iNew{'Weld',RArm,Part0=RSho,Part1=RArm,C0=cn(0,-0.75*Scale,0),C1=cn(0,0.75*Scale,0)}
  601.  
  602. wLThi=iNew{'Weld',LThi,Part0=pTorso,Part1=LThi,C0=cn(-0.5*Scale,-1*Scale,0),C1=cn(0,0.75*Scale,0)}
  603. wLLeg=iNew{'Weld',LLeg,Part0=LThi,Part1=LLeg,C0=cn(1,-0.75*Scale,0),C1=cn(0,0.75*Scale,0)}
  604.  
  605. wRThi=iNew{'Weld',RThi,Part0=pTorso,Part1=RThi,C0=cn(0.5*Scale,-1*Scale,0),C1=cn(0,0.75*Scale,0)}
  606. wRLeg=iNew{'Weld',RLeg,Part0=RThi,Part1=RLeg,C0=cn(0,-0.75*Scale,0),C1=cn(0,0.75*Scale,0)}
  607.  
  608. wLSho.C0=cn(-1.5*Scale,0.75*Scale,0)*ca(0,0,-135) --a,b
  609. wLArm.C0=cn(0,-0.75*Scale,0)*ca(0,0,0) --c,d
  610. wRSho.C0=cn(1.5*Scale,0.75*Scale,0)*ca(0,0,135) --e,f
  611. wRArm.C0=cn(0,-0.75*Scale,0)*ca(0,0,0) --g,h
  612. ----
  613. wLThi.C0=cn(-0.5*Scale,-1*Scale,0)*ca(0,0,-45) --i,j
  614. wLLeg.C0=cn(0,-0.75*Scale,0)*ca(0,0,0) --k,l
  615. wRThi.C0=cn(0.5*Scale,-1*Scale,0)*ca(0,0,45) --m,n
  616. wRLeg.C0=cn(0,-0.75*Scale,0)*ca(0,0,0) --o,p
  617.  
  618. BG=iNew{'BodyGyro',Torso,maxTorque=nov3}
  619. BP=iNew{'BodyPosition',Torso,maxForce=nov3}
  620. fUNDYING=Hum.Died:connect(UNDYING)
  621. LimbNames={'LSho','RSho','LArm','RArm','RThi','LThi','RLeg','LLeg'}
  622. for i=1,8 do local v=LimbNames[i] LimbNames[v]=getfenv()["w"..v] end
  623. RootLimbs={pHead,pTorso,LSho,RSho,LArm,RArm,RThi,LThi,RLeg,LLeg}
  624. Anim,LegAnim,ArmAnim='Sit','Sit','Sit'
  625. local a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p=GetPose()
  626. SetWeld(wLSho,0,1,1,a,b,v3(-1.5*Scale,0.5*Scale,0),v3(0,0,-10),1)
  627. SetWeld(wLArm,0,1,1,c,d,v3(0,-0.75*Scale,0),v3(10,0,10),1)
  628. SetWeld(wRSho,0,1,1,e,f,v3(1.5*Scale,0.5*Scale,0),v3(0,0,10),1)
  629. SetWeld(wRArm,0,1,1,g,h,v3(0,-0.75*Scale,0),v3(10,0,-10),1)
  630. SetWeld(wLThi,0,1,1,i,j,v3(-0.5*Scale,-1*Scale,0),v3(15,0,-5),1)
  631. SetWeld(wLLeg,0,1,1,k,l,v3(0,-0.75*Scale,0),v3(-15,0,5),1)
  632. SetWeld(wRThi,0,1,1,m,n,v3(0.5*Scale,-1*Scale,0),v3(15,0,5),1)
  633. SetWeld(wRLeg,0,1,1,o,p,v3(0,-0.75*Scale,0),v3(-15,0,-5),1)
  634. Oa,Ob,Oc,Od,Oe,Of,Og,Oh,Oi,Oj,Ok,Ol,Om,On,Oo,Op=GetPose()
  635. SetWeld(wLSho,0,1,1,nov3,nov3,a,b,1)
  636. SetWeld(wLArm,0,1,1,nov3,nov3,c,d,1)
  637. SetWeld(wRSho,0,1,1,nov3,nov3,e,f,1)
  638. SetWeld(wRArm,0,1,1,nov3,nov3,g,h,1)
  639. SetWeld(wLThi,0,1,1,nov3,nov3,i,j,1)
  640. SetWeld(wLLeg,0,1,1,nov3,nov3,k,l,1)
  641. SetWeld(wRThi,0,1,1,nov3,nov3,m,n,1)
  642. SetWeld(wRLeg,0,1,1,nov3,nov3,o,p,1)
  643. end
  644.  
  645. function GetPose()
  646. local a,b=GetWeld(wLSho,0)
  647. local c,d=GetWeld(wLArm,0)
  648. local e,f=GetWeld(wRSho,0)
  649. local g,h=GetWeld(wRArm,0)
  650. local i,j=GetWeld(wLThi,0)
  651. local k,l=GetWeld(wLLeg,0)
  652. local m,n=GetWeld(wRThi,0)
  653. local o,p=GetWeld(wRLeg,0)
  654. local q,r=GetWeld(wTorso,0)
  655. return a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r
  656. end
  657.  
  658. MakeAI(SpawnPoint)
  659.  
  660. ASpeed=28
  661. coroutine.resume(coroutine.create(function()
  662. SetWeld(wLSho,0,1,1,nov3,nov3,wLSho.C0.p,v3(45,0,-10),1)
  663. SetWeld(wLArm,0,1,1,nov3,nov3,wLArm.C0.p,v3(45,0,10),1)
  664. SetWeld(wRSho,0,1,1,nov3,nov3,wRSho.C0.p,v3(45,0,10),1)
  665. SetWeld(wRArm,0,1,1,nov3,nov3,wRArm.C0.p,v3(45,0,-10),1)
  666. SetWeld(wLThi,0,1,1,nov3,nov3,v3(-0.5*Scale,-0.6*Scale,-0.5*Scale),v3(125,0,-12),1)
  667. SetWeld(wLLeg,0,1,1,nov3,nov3,wLLeg.C0.p,v3(-70,0,12),1)
  668. SetWeld(wRThi,0,1,1,nov3,nov3,v3( 0.5*Scale,-0.6*Scale,-0.5*Scale),v3(125,0,12),1)
  669. SetWeld(wRLeg,0,1,1,nov3,nov3,wRLeg.C0.p,v3(-70,0,-12),1)
  670. SetWeld(wTorso,0,1,1,oTorso,nov3,v3(0,-3*Scale,0),nov3,1)
  671. wait(1)
  672. Anim='Standing'
  673. local a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p=GetPose()
  674. for x=1,ASpeed do
  675. SetWeld(wTorso,0,x,ASpeed,wTorso.C0.p,nov3,oTorso,nov3,1)
  676. SetWeld(wLSho,0,x,ASpeed,a,b,v3(-1.5*Scale,0.5*Scale,0),v3(0,0,-10),1)
  677. SetWeld(wLArm,0,x,ASpeed,c,d,v3(0,-0.75*Scale,0),v3(10,0,10),1)
  678. SetWeld(wRSho,0,x,ASpeed,e,f,v3(1.5*Scale,0.5*Scale,0),v3(0,0,10),1)
  679. SetWeld(wRArm,0,x,ASpeed,g,h,v3(0,-0.75*Scale,0),v3(10,0,-10),1)
  680. SetWeld(wLThi,0,x,ASpeed,i,j,v3(-0.5*Scale,-1*Scale,0),v3(15,0,-5),1)
  681. SetWeld(wLLeg,0,x,ASpeed,k,l,v3(0,-0.75*Scale,0),v3(-15,0,5),1)
  682. SetWeld(wRThi,0,x,ASpeed,m,n,v3(0.5*Scale,-1*Scale,0),v3(15,0,5),1)
  683. SetWeld(wRLeg,0,x,ASpeed,o,p,v3(0,-0.75*Scale,0),v3(-15,0,-5),1)
  684. wait()
  685. end
  686. ArmAnim='None'
  687. LegAnim='None'
  688. Anim='None'
  689. end))
  690. --Target=PChar
  691. function Stay(bool,cff)
  692. BG.maxTorque=bool and v3(1,1,1)/0 or nov3 BG.cframe=cff or Torso.CFrame
  693. BP.maxForce=BG.maxTorque BP.position=Torso.Position
  694. end
  695. function fMarble(Ch,func)
  696. for i,v in pairs(Ch:children()) do
  697. for x=-1,1,2 do
  698. for y=-1,1,2 do
  699. for z=-1,1,2 do
  700. if v:findFirstChild(x..y..z) then func(v[x..y..z]) end
  701. end end end
  702. end
  703. end
  704. function ReturnAnim()
  705. local ne1,ne2=GetWeld(pNeck,0)
  706. local wt1,wt2=GetWeld(wTorso,0)
  707. local a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p=GetPose()
  708. for x=1,ASpeed do
  709. SetWeld(wLSho,0,x,ASpeed,a,b,Oa,Ob,1)
  710. SetWeld(wLArm,0,x,ASpeed,c,d,Oc,Od,1)
  711. SetWeld(wRSho,0,x,ASpeed,e,f,Oe,Of,1)
  712. SetWeld(wRArm,0,x,ASpeed,g,h,Og,Oh,1)
  713. SetWeld(wLThi,0,x,ASpeed,i,j,Oi,Oj,1)
  714. SetWeld(wLLeg,0,x,ASpeed,k,l,Ok,Ol,1)
  715. SetWeld(wRThi,0,x,ASpeed,m,n,Om,On,1)
  716. SetWeld(wRLeg,0,x,ASpeed,o,p,Oo,Op,1)
  717. SetWeld(wTorso,0,x,ASpeed,wt1,wt2,oTorso,nov3,1)
  718. SetWeld(pNeck,0,x,ASpeed,ne1,ne2,v3(0,1.5,0)*Scale,nov3,1)
  719. wait()
  720. end
  721. end
  722.  
  723. ChatConnection=Player.Chatted:connect(function(msg)
  724. coroutine.resume(coroutine.create(function()
  725. if not Char.Parent then return end
  726. local Sep,sep=se(';',msg)
  727. local p1,p2=findplayer(Sep[2]),findplayer(Sep[3])
  728. local cmd=sep[1]
  729. --print(Sep[1])
  730. --print(LimbNames[Sep[1]])
  731. Tt=(p1 and p1.Character and p1.Character:findFirstChild'Torso') and p1.Character.Torso or nil
  732. if cmd=='sit' and (Anim=='None' or Anim=='Follow') then
  733. Anim='Sitting'
  734. Hum:MoveTo(Torso.Position,Torso)
  735. LegAnim,ArmAnim='Sit','Sit'
  736. for x=1,ASpeed do
  737. SetWeld(wLSho,0,x,ASpeed,Oa,Ob,Oa,v3(45,0,-10),1)
  738. SetWeld(wLArm,0,x,ASpeed,Oc,Od,Oc,v3(45,0,10),1)
  739. SetWeld(wRSho,0,x,ASpeed,Oe,Of,Oe,v3(45,0,10),1)
  740. SetWeld(wRArm,0,x,ASpeed,Og,Oh,Og,v3(45,0,-10),1)
  741. SetWeld(wLThi,0,x,ASpeed,Oi,Oj,v3(-0.5*Scale,-0.6*Scale,-0.5*Scale),v3(125,0,-12),1)
  742. SetWeld(wLLeg,0,x,ASpeed,Ok,Ol,Ok,v3(-70,0,12),1)
  743. SetWeld(wRThi,0,x,ASpeed,Om,On,v3( 0.5*Scale,-0.6*Scale,-0.5*Scale),v3(125,0,12),1)
  744. SetWeld(wRLeg,0,x,ASpeed,Oo,Op,Oo,v3(-70,0,-12),1)
  745. SetWeld(wTorso,0,x,ASpeed,oTorso,nov3,v3(0,-3*Scale,0),nov3,1)
  746. wait()
  747. end
  748. Anim='Sit'
  749. elseif (cmd=='stand' or cmd=='stop') and (Anim=='Roll' or Anim=='Sit' or Anim=='Follow' or Anim=='Form' or Anim=='Dance' or Anim=='Grab') then
  750. if Anim=='Sit' or Anim=='Form' or Anim=='Dance' or Anim=='Roll' then
  751. Anim='Returning'
  752. ReturnAnim()
  753. else
  754. Target=nil
  755. wait(0.2)
  756. Hum:MoveTo(Torso.Position,Torso)
  757. end
  758. LegAnim,ArmAnim,Anim='None','None','None'
  759. elseif cmd=='follow' and Tt and Anim=='None' then
  760. Anim='Follow'
  761. Target=p1.Character
  762. elseif cmd=='shoot' and Tt and RArm['1-11'].Transparency~=1 and ArmAnim=='None' then
  763. Target=p1.Character
  764. ArmAnim='Shoot'
  765. FaceBG(Tt.Position)
  766. wait(0.1)
  767. local cff=cn(pTorso.CFrame.p,v3(Tt.Position.x,pTorso.Position.y,Tt.Position.z))
  768. local ofs=cff:toObjectSpace(cn(cff*cn(1.5*Scale,0.5*Scale,0).p,Tt.CFrame*cn(0,2,0).p)*ca(90,0,0)*cn(0,-0.25*Scale,0))
  769. local x,y,z=ofs:toEulerAnglesXYZ()
  770. local rot=v3(mdeg(x),mdeg(y),mdeg(z))
  771. for q=1,ASpeed do
  772. SetWeld(wRArm,0,q,ASpeed,Og,Oh,Og,nov3,1)
  773. SetWeld(wRSho,0,q,ASpeed,Oe,Of,ofs.p,rot,1)
  774. SetWeld(wRSho,1,q,ASpeed,v3(0,0.25*Scale,0),nov3,nov3,nov3,1)
  775. wait()
  776. end
  777. for y=-1,1,2 do for x=-1,1,2 do for z=-1,1,2 do
  778. local new=RArm[x..y..z]:Clone() new.Parent=RArm game.Debris:AddItem(new,8) new.Touched:connect(function(hit) Damage(hit.Parent:findFirstChild'Humanoid') end)
  779. new.CFrame=RArm[x..y..z].CFrame*cn(0,-Scale*1.5,0) new.CanCollide=true new.Velocity=cn(new.Position,Target.Torso.Position).lookVector*((new.Position-Target.Torso.Position).magnitude*20+900)
  780. RArm[x..y..z].Transparency=1 so.Block:Play() wait(0.06)
  781. end end end
  782. RArm.Transparency=1
  783. delay(1,function()
  784. for x=-1,1,2 do for y=-1,1,2 do for z=-1,1,2 do local new=RArm[x..y..z]:Clone() new.Transparency=0 new.CanCollide=false new.Name='f'..new.Name new.Parent=RArm new.CFrame=RArm.CFrame*cn(Scale*x*2,Scale*-3,Scale*z*2)
  785. iNew{'BodyPosition',new,maxForce=v3(1,1,1)/0,position=RArm[x..y..z].Position} wait(0.14) end end end
  786. DoLoop(35,function(i) for x=-1,1,2 do for y=-1,1,2 do for z=-1,1,2 do RArm['f'..x..y..z].BodyPosition.position=RArm[x..y..z].Position if i==1 then RArm['f'..x..y..z]:Remove() RArm[x..y..z].Transparency=0 RArm.Transparency=0 end end end end end)
  787. end)
  788. for q=1,ASpeed do
  789. SetWeld(wRArm,0,q,ASpeed,Og,nov3,Og,Oh,1)
  790. SetWeld(wRSho,0,q,ASpeed,ofs.p,rot,Oe,Of,1)
  791. SetWeld(wRSho,1,q,ASpeed,nov3,nov3,v3(0,0.25*Scale,0),nov3,1)
  792. wait()
  793. end
  794. BG.maxTorque=nov3
  795. ArmAnim='None'
  796. elseif cmd=='slam' and (Anim=='None' or Anim=='Follow') and Tt then
  797. Target=p1
  798. local lTt=Tt
  799. Anim='Follow'
  800. repeat Hum:MoveTo(Tt.Position+v3(0.5,0.5,0.5),Tt) wait(0.2) until lTt~=Tt or (Tt.Position-pTorso.Position).magnitude<10+Scale*5.5 or Anim~='Follow'
  801. if Anim~='Follow' then BG.maxTorque=nov3 return end
  802. if lTt~=Tt then return end
  803. Anim,LegAnim,ArmAnim='Slam','',''
  804. Hum:MoveTo(Torso.Position,Torso)
  805. FaceBG(Tt.Position)
  806. Stay(true,BG.cframe)
  807. local a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p=GetPose()
  808. ASpeed2=15
  809. for x=1,ASpeed2 do
  810. SetWeld(wLSho,0,x,ASpeed2,a,b,Oa,v3(180,0,0),1)
  811. SetWeld(wRSho,0,x,ASpeed2,e,f,Oe,v3(180,0,0),1)
  812. SetWeld(wTorso,0,x,ASpeed2,nov3,nov3,v3(0,3,0)*Scale,nov3,1)
  813. wait()
  814. end
  815. for x=1,ASpeed2 do
  816. SetWeld(wTorso,0,x,ASpeed2,v3(0,3,0)*Scale,nov3,v3(0,-3*Scale+2.5,-6*Scale),v3(-89,0,0),1)
  817. wait()
  818. end
  819. AOEFind(pTorso.Position,6.5*Scale,function(Hum) Damage(Hum,3,true) Hum.Sit=true end)
  820. MeshEffect(35,Torso.CFrame*cn(0,-3.5*Scale,-6*Scale)*ca(90,0,0),nil,v3(2,2,1)*Scale,v3(12,12,5)*Scale,0.2,1,'Light stone grey',as.ring)
  821. wait(0.5)
  822. for x=1,ASpeed do
  823. SetWeld(wTorso,0,x,ASpeed,v3(0,-3*Scale+2.5,-6*Scale),v3(-90,0,0),nov3,nov3,1)
  824. SetWeld(wLSho,0,x,ASpeed,Oa,v3(180,0,0),Oa,Ob,1)
  825. SetWeld(wRSho,0,x,ASpeed,Oe,v3(180,0,0),Oe,Of,1)
  826. wait()
  827. end
  828. Stay(false)
  829. Anim,LegAnim,ArmAnim='None','None','None'
  830. elseif cmd=='boulder' and Anim=='None' then
  831. Target=p1.Character
  832. Anim,LegAnim,ArmAnim='','',''
  833. Stay(true)
  834. FaceBG(Tt.Position)
  835. for x=1,ASpeed do
  836. SetWeld(wLSho,0,x,ASpeed,Oa,Ob,Oa,v3(135,0,0),1)
  837. SetWeld(wLArm,0,x,ASpeed,Oc,Od,Oc,v3(0,0,0),1)
  838. SetWeld(wRSho,0,x,ASpeed,Oe,Of,Oe,v3(135,0,0),1)
  839. SetWeld(wRArm,0,x,ASpeed,Og,Oh,Og,v3(0,0,-10),1)
  840. SetWeld(wLThi,0,x,ASpeed,Oi,Oj,v3(-0.5,-0.5,0.25)*Scale,v3(45,0,-15),1)
  841. SetWeld(wLLeg,0,x,ASpeed,Ok,Ol,Ok,v3(0,0,0),1)
  842. SetWeld(wRThi,0,x,ASpeed,Om,On,v3( 0.5,-0.5,0.25)*Scale,v3(45,0,15),1)
  843. SetWeld(wRLeg,0,x,ASpeed,Oo,Op,Oo,v3(0,0,0),1)
  844. SetWeld(wTorso,0,x,ASpeed,oTorso,nov3,v3(0,-1.5,-1.5)*Scale,v3(-90,0,0),1)
  845. wait()
  846. end
  847. wait(0.2)
  848. local boulder=iPart{Char,1,1,1,type='WedgePart'} boulder.Material=Mat
  849. local wm=iNew{'SpecialMesh',boulder,Scale=v3(4,3,4)*Scale,MeshType='Wedge'}
  850. local wb=iNew{'Weld',boulder,Part0=RArm,Part1=boulder,C0=cn(-1.5*Scale,-2.3*Scale,0)*ca(180,180,0)}
  851. local a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r=GetPose()
  852. for x=1,ASpeed*2 do
  853. SetWeld(wLSho,0,x,ASpeed*2,a,b,a,v3(225,0,0),1)
  854. SetWeld(wLArm,0,x,ASpeed*2,c,d,c,v3(45,0,0),1)
  855. SetWeld(wRSho,0,x,ASpeed*2,e,f,e,v3(225,0,0),1)
  856. SetWeld(wRArm,0,x,ASpeed*2,g,h,g,v3(45,0,0),1)
  857. SetWeld(wLThi,0,x,ASpeed*2,i,j,Oi,v3(0,0,-15),1)
  858. SetWeld(wLLeg,0,x,ASpeed*2,k,l,k,v3(0,0,0),1)
  859. SetWeld(wRThi,0,x,ASpeed*2,m,n,Om,v3(0,0,15),1)
  860. SetWeld(wRLeg,0,x,ASpeed*2,o,p,o,v3(0,0,0),1)
  861. SetWeld(wTorso,0,x,ASpeed*2,q,r,nov3,nov3,1)
  862. wait()
  863. end
  864. FaceBG(Tt.Position)
  865. for x=1,ASpeed/2 do
  866. SetWeld(wLSho,0,x,math.floor(ASpeed/2),a,v3(225,0,0),a,v3(90,0,0),1)
  867. SetWeld(wLArm,0,x,math.floor(ASpeed/2),c,v3(45,0,0),c,v3(45,0,0),1)
  868. SetWeld(wRSho,0,x,math.floor(ASpeed/2),e,v3(225,0,0),e,v3(90,0,0),1)
  869. SetWeld(wRArm,0,x,math.floor(ASpeed/2),g,v3(45,0,0),g,v3(45,0,0),1)
  870. wait()
  871. end
  872. local bcf=boulder.CFrame
  873. wb:Remove()
  874. wm:Remove()
  875. boulder.Size=wm.Scale
  876. boulder.CFrame=cn(boulder.Position,Target.Torso.Position)*cn(0,3,-1)*ca(0,180,0)
  877. --boulder.Friction=0.1
  878. boulder.Elasticity=0
  879. boulder.Velocity=(boulder.CFrame*ca(0,180,0)).lookVector*((boulder.Position-Target.Torso.Position).magnitude*1+90)
  880. boulder.RotVelocity=nov3
  881. game.Debris:AddItem(boulder,8)
  882. Stay(false)
  883. ReturnAnim()
  884. Anim,LegAnim,ArmAnim='None','None','None'
  885. elseif cmd=='grab' and Tt and not Grabbing then
  886. Target=p1
  887. local lTt=Tt
  888. Anim='Follow'
  889. repeat Hum:MoveTo(Tt.Position+v3(0.5,0.5,0.5),Tt) wait(0.2) until lTt~=Tt or (Tt.Position-Stand.CFrame*cn(0,-Stand.Size.y/2+1,-2.8*Scale).p).magnitude<10 or Anim~='Follow'
  890. if Anim~='Follow' then BG.maxTorque=nov3 return end
  891. if lTt~=Tt then return end
  892. pcall(function() Tt.Parent.Humanoid.PlatformStand=true end)
  893. Hum:MoveTo(Torso.Position,Torso)
  894. Anim,LegAnim,ArmAnim='Grab','',''
  895. FaceBG(Tt.Position)
  896. for x=1,ASpeed do
  897. SetWeld(wLSho,0,x,ASpeed,Oa,Ob,Oa,v3(-30,0,-30),1)
  898. SetWeld(wLArm,0,x,ASpeed,Oc,Od,Oc,v3(0,0,0),1)
  899. SetWeld(wRSho,0,x,ASpeed,Oe,Of,Oe,v3(145,0,-30),1)
  900. SetWeld(wRArm,0,x,ASpeed,Og,Oh,Og,v3(0,0,0),1)
  901. SetWeld(wLThi,0,x,ASpeed,Oi,Oj,v3(-0.5,-0.4,0.3)*Scale,v3(70,0,0),1)
  902. SetWeld(wLLeg,0,x,ASpeed,Ok,Ol,Ok,v3(-20,0,0),1)
  903. SetWeld(wRThi,0,x,ASpeed,Om,On,v3(0.5,-0.5,-0.3)*Scale,v3(135,0,0),1)
  904. SetWeld(wRLeg,0,x,ASpeed,Oo,Op,Oo,v3(-90,0,0),1)
  905. SetWeld(wTorso,0,x,ASpeed,oTorso,nov3,v3(0,-2,-1.5)*Scale,v3(-90,0,0),1)
  906. wait()
  907. end
  908. local ofs=RArm.CFrame:toObjectSpace(Tt.CFrame)
  909. Tt.Parent.Humanoid.PlatformStand=true
  910. Grabbing=iNew{'Weld',RArm,Part0=RArm,Part1=Tt,C0=ofs}
  911. local a,b=GetWeld(Grabbing,0)
  912. for x=1,ASpeed do
  913. SetWeld(Grabbing,0,x,ASpeed,a,b,v3(0,-0.75*Scale-1,0),v3(-90,0,0),1)
  914. wait()
  915. end
  916. Stay(false)
  917. ReturnAnim()
  918. Anim,LegAnim,ArmAnim='None','None','None'
  919. elseif cmd=='dance' and (Anim=='None' or Anim=='Follow') then
  920. Hum:MoveTo(pTorso.Position,pTorso)
  921. Anim,ArmAnim,LegAnim='Dance','Dance','Dance'
  922. local ASpeed=math.floor(ASpeed/2)
  923. repeat
  924. local a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r=GetPose()
  925. for x=1,ASpeed do
  926. if Anim~='Dance' then break end
  927. SetWeld(wLSho,0,x,ASpeed,a,b,v3(-1.2,0.5,-0.25)*Scale,v3(35,0,30),1)
  928. SetWeld(wLArm,0,x,ASpeed,c,d,c,v3(25,0,0),1)
  929. SetWeld(wRSho,0,x,ASpeed,e,f,v3( 1.2,0.5,-0.25)*Scale,v3(45,0,-30),1)
  930. SetWeld(wRArm,0,x,ASpeed,g,h,g,v3(25,0,0),1)
  931. SetWeld(wLThi,0,x,ASpeed,i,j,i,v3(0,0,0),1)
  932. SetWeld(wLLeg,0,x,ASpeed,k,l,k,v3(0,0,0),1)
  933. SetWeld(wRThi,0,x,ASpeed,m,n,m,v3(45,0,20),1)
  934. SetWeld(wRLeg,0,x,ASpeed,o,p,o,v3(-45,0,-20),1)
  935. wait()
  936. end
  937. local a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r=GetPose()
  938. for x=1,ASpeed do
  939. if Anim~='Dance' then break end
  940. SetWeld(wLSho,0,x,ASpeed,a,b,v3(-1.2,0.5,-0.25)*Scale,v3(95,0,30),1)
  941. SetWeld(wLArm,0,x,ASpeed,c,d,c,v3(-10,0,0),1)
  942. SetWeld(wRSho,0,x,ASpeed,e,f,v3( 1.2,0.5,-0.25)*Scale,v3(105,0,-30),1)
  943. SetWeld(wRArm,0,x,ASpeed,g,h,g,v3(-10,0,0),1)
  944. SetWeld(wLThi,0,x,ASpeed,i,j,i,v3(45,0,-20),1)
  945. SetWeld(wLLeg,0,x,ASpeed,k,l,k,v3(-45,0,20),1)
  946. SetWeld(wRThi,0,x,ASpeed,m,n,m,v3(0,0,0),1)
  947. SetWeld(wRLeg,0,x,ASpeed,o,p,o,v3(0,0,0),1)
  948. wait()
  949. end
  950. until Anim~='Dance'
  951. elseif cmd=='roll' and (Anim=='None' or Anim=='Follow') then
  952. Target=p1
  953. local lTt=Tt
  954. Anim,ArmAnim,LegAnim='Roll','',''
  955. local a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r=GetPose()
  956. local n1,n2=GetWeld(pNeck,0)
  957. for x=1,ASpeed do
  958. SetWeld(wLSho,0,x,ASpeed,a,b,v3(-1.5,0.5,0)*Scale,v3(0,0,-45),1)
  959. SetWeld(wLArm,0,x,ASpeed,c,d,c,v3(0,0,90),1)
  960. SetWeld(wRSho,0,x,ASpeed,e,f,v3( 1.5,0.5,0)*Scale,v3(0,0,45),1)
  961. SetWeld(wRArm,0,x,ASpeed,g,h,g,v3(0,0,-90),1)
  962. SetWeld(wLThi,0,x,ASpeed,i,j,v3(0,1, 0.5)*Scale,v3(-30,0,0),1)
  963. SetWeld(wLLeg,0,x,ASpeed,k,l,k,v3(60,0,0),1)
  964. SetWeld(wRThi,0,x,ASpeed,m,n,v3(0,1,-0.5)*Scale,v3(30,0,0),1)
  965. SetWeld(wRLeg,0,x,ASpeed,o,p,o,v3(-60,0,0),1)
  966. SetWeld(pNeck,0,x,ASpeed,n1,n2,v3(0,0,0),n2,1)
  967. SetWeld(wTorso,0,x,ASpeed,oTorso,nov3,v3(0,-2,0)*Scale,nov3,1)
  968. wait()
  969. end
  970. tWS[2]=3
  971. repeat
  972. local cf=Torso.CFrame*cn(mran2(-1,1)*Scale,-4*Scale,0.5*Scale)*ca(90+mran(-20,20),mran(-30,30),0)
  973. MeshEffect(24,cf,cf*cn(0,4*Scale,0),v3(0.5,0.5,0.5)*Scale,v3(mran2(1,4),mran2(3,5),mran2(1,3))*Scale,0.1,1,'Dark stone grey','Brick')
  974. Hum:MoveTo(Tt.CFrame*cn(0,0,Scale).p,Tt) wTorso.C0=wTorso.C0*ca(-20,0,0) wait(0.035) until lTt~=Tt or (Tt.Position-Stand.CFrame*cn(0,-Stand.Size.y/2+1,-2.8*Scale).p).magnitude<6 or Anim~='Roll'
  975. tWS[2]=1
  976. ClearWeld(wTorso)
  977. if Anim~='Roll' then return end
  978. Hum:MoveTo(Torso.Position+v3(0,1,0),Torso)
  979. Torso.Anchored=true Torso.Velocity=nov3
  980. local cf=Stand.CFrame*cn(0,0,-1.5*Scale)*ca(-45,0,0) --iPart{Char,1,1,1,co='Black',cf=cf,an=true}
  981. MeshEffect(50,cf,nil,v3(3.5,3.5,2)*Scale,v3(11,11,6)*Scale,0.1,1,'White',as.ring)
  982. for i=1,16 do
  983. local cf=cf*ca(90,360*(i/16),0)*ca(45,0,0)
  984. MeshEffect(40,cf,cf*cn(0,10*Scale,0),v3(0.2,2,0.2)*Scale,v3(1,5,1)*Scale,0.1,1,'','Sphere')
  985. end
  986. AOEFind(cf.p,6.5*Scale,function(Hum,v) Damage(Hum,2,true) Hum.Sit=true v.Velocity=cn(pTorso.Position,v.Position).lookVector*50 end)
  987. wait(0.2)
  988. Torso.Anchored=false
  989. ReturnAnim()
  990. Hum:MoveTo(Torso.Position,Torso)
  991. Anim,LegAnim,ArmAnim='None','None','None'
  992. elseif cmd=='beam' and (Anim=='None' or Anim=='Follow') then
  993. Anim='beam'
  994. local che =iPart{Char,1,1,1,sc=Scale,co=CC[1],ma=Mat} local chew=iNew{'Weld',che ,Part0=pTorso,Part1=che}
  995. local che2=iPart{che ,0.8*Scale,0.2,0.8*Scale,co='Really black'} local che2w=iNew{'Weld',che2,Part0=che,Part1=che2}
  996. local chem=iNew{'CylinderMesh',che} iNew{'CylinderMesh',che2}
  997. local chest,chex,i={},0,0
  998. for x=-1,1,2 do for y=-1,1,2 do i=i+1 chest[i]={pTorso[x..y..'-1']} chest[i][2]=chest[i][1].Weld chest[i][3]=chest[i][2].C0
  999. local xx,yy,zz=chest[i][2].C0:toEulerAnglesXYZ() chest[i][4]=v3(mdeg(xx),mdeg(yy),mdeg(zz))
  1000. chest[i][5]=cn(0.45*x*Scale,0,-0.5*Scale)*chest[i][3] chest[i][6]=chest[i][4]+v3(0,-105*x,0) end end
  1001. local len=1.75
  1002. local dochest=function(v,chexx,adj)
  1003. local p=v/ASpeed
  1004. chex=adj*p
  1005. chem.Scale=v3(1,len*p,1)
  1006. chew.C0=ca(chexx+chex,0,0)*cn(0,len/2*p*Scale,0)
  1007. che2w.C0=cn(0,len/2*p*Scale,0)
  1008. for i=1,4 do SetWeld(chest[i][2],0,v,ASpeed,chest[i][3],chest[i][4],chest[i][5],chest[i][6],1) end
  1009. end
  1010. for v=1,ASpeed do if Tt then FaceBG(Tt.Position) end dochest(v,-90,-45) wait() end
  1011. local beam=iPart{Char,0.7*Scale,1,0.7*Scale,co='New Yeller',an=true,tr=0.3} beamm=iNew{'CylinderMesh',beam}
  1012. for i=1,ASpeed*3 do
  1013. local p=i/ASpeed*3
  1014. chex=90*math.sin((math.pi/2)/(ASpeed*3)*i)
  1015. chew.C0=ca(-135+chex,0,0)*cn(0,len/2*Scale,0)
  1016. local hit,pos=ray(che2.Position,che2.Position-che2.CFrame*cn(0,-1,0).p,Char)
  1017. local mag=(che2.Position-pos).magnitude local p1,p2=che2.Position+v3(mran2(-1,1),mran2(-1,1),mran2(-1,1))/3,pos+v3(mran2(-1,1),mran2(-1,1),mran2(-1,1))/3
  1018. beam.CFrame=cn(p1,p2)*cn(0,0,-mag/2)*ca(90,0,0) beamm.Scale=v3(1,mag+(Scale/3),1)
  1019. AOEFind(pos,Scale*2,function(Hum) Damage(Hum,2.5) end)
  1020. if i%2==0 then for i=1,5 do local cf=cn(pos)*ca(0,mran(-180,180),mran(-95,95)) MeshEffect(8,cf,cf*cn(0,Scale*2.2,0),v3(0.1,0.4,0.1)*Scale,v3(0.4,3,0.4)*Scale,0.2,1,CC[mran(2,3)],as.cone) end
  1021. MeshEffect(8,cn(pos),nil,v3(0.8,0.8,0.8)*Scale,v3(4,4,4)*Scale,0.2,1,CC[mran(2,3)],'Sphere') end
  1022. if Tt then FaceBG(Tt.Position) end
  1023. wait()
  1024. end
  1025. DoLoop(12,function(i) beam.Transparency=0.3+i*0.7 if i==1 then beam:Remove() end end)
  1026. for v=ASpeed,0,-1 do dochest(v,-90,45) wait() end
  1027. Stay(false)
  1028. che:Remove()
  1029. Anim='None'
  1030. ---------------------------------------------------------------------------=---WWWWWWWWWWWWWWWWWW
  1031. elseif cmd=='box' and (Anim=='None' or Anim=='Follow') then
  1032. Anim,ArmAnim='cart','cart'
  1033. for x=1,ASpeed do
  1034. SetWeld(wLSho,0,x,ASpeed,Oa,Ob,Oa,v3(90,0,10),1)
  1035. SetWeld(wLArm,0,x,ASpeed,Oc,Od,Oc,v3(0,0,25),1)
  1036. SetWeld(wRSho,0,x,ASpeed,Oe,Of,Oe,v3(90,0,-10),1)
  1037. SetWeld(wRArm,0,x,ASpeed,Og,Oh,Og,v3(0,0,-25),1)
  1038. wait()
  1039. end
  1040. Stay(true)
  1041. local spawn=RArm.CFrame*cn(0,-0.75*Scale-2,0)*ca(-90,0,0)
  1042. local des=iPart{Char,1,1,1,an=true,ma=Mat,cf=spawn,ca=false}
  1043. for i=1,6,0.2 do des.Size=v3(i,i,i) des.CFrame=spawn*cn(0,0,-i/2) wait() end
  1044. local cart=iNew{'Model',workspace,Name='Cart'}
  1045. local base=iPart{cart,4,1,5,ma=Mat,cf=des.CFrame} iNew{'BodyGyro',base}
  1046. for x=-1,1,2 do
  1047. local new=iPart{cart,0.5,4,5,ma=Mat,cf=base.CFrame} iNew{'Weld',new,Part0=base,Part1=new,C0=cn(1.75*x,2.5,0)}
  1048. local new=iPart{cart,3.5,4,0.5,ma=Mat,cf=base.CFrame} iNew{'Weld',new,Part0=base,Part1=new,C0=cn(0,2.5,2.25*x)}
  1049. end
  1050. for i=6,0.8,-0.2 do des.Size=v3(i,i,i) des.CFrame=spawn*cn(0,0,-i/2) wait() end des:Remove()
  1051. Stay(false)
  1052. ReturnAnim()
  1053. Anim,ArmAnim='None','None'
  1054. elseif cmd=='crush' and Grabbing and (Anim=='None' or Anim=='Follow') then
  1055. Anim,ArmAnim='crush','crush'
  1056. for x=1,ASpeed do
  1057. SetWeld(wLSho,0,x,ASpeed,Oa,Ob,Oa,v3(80,0,-160),1)
  1058. SetWeld(wLArm,0,x,ASpeed,Oc,Od,Oc,v3(0,0,80),1)
  1059. SetWeld(wRSho,0,x,ASpeed,Oe,Of,Oe,v3(80,0,160),1)
  1060. SetWeld(wRArm,0,x,ASpeed,Og,Oh,Og,v3(0,0,-80),1)
  1061. wait()
  1062. end
  1063. local a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r=GetPose()
  1064. wait(0.2)
  1065. for x=1,ASpeed/2 do
  1066. SetWeld(wLSho,0,x,ASpeed/2,a,b,Oa,v3(80,0,-14),1)
  1067. SetWeld(wLArm,0,x,ASpeed/2,c,d,Oc,v3(0,0,80),1)
  1068. SetWeld(wRSho,0,x,ASpeed/2,e,f,Oe,v3(80,0,14),1)
  1069. SetWeld(wRArm,0,x,ASpeed/2,g,h,Og,v3(0,0,-80),1)
  1070. wait()
  1071. end
  1072. MeshEffect(35,Grabbing.Part1.CFrame,nil,v3(2,2,1)*Scale,v3(7,7,3)*Scale,0.3,1,'Light stone grey',as.ring)
  1073. local crushjo=60
  1074. pcall(function() for i,v in pairs({'Neck','Left Shoulder','Right Shoulder','Left Hip','Right Hip'}) do local w=Grabbing.Part1.Parent.Torso[v] w.C1=w.C1*ca(mran(-crushjo,crushjo),mran(-crushjo,crushjo),mran(-crushjo,crushjo)) end end)
  1075. local hit=Grabbing.Part1
  1076. Grabbing:Remove() Grabbing=nil
  1077. wait(2)
  1078. pcall(function() hit.Parent.Humanoid.PlatformStand=false end)
  1079. ReturnAnim()
  1080. Anim,ArmAnim='None','None'
  1081. elseif cmd=='eat' and Grabbing and (Anim=='None' or Anim=='Follow') then
  1082. Anim,ArmAnim='Eat','Eat'
  1083. for x=1,ASpeed*2 do
  1084. SetWeld(wRSho,0,x,ASpeed*2,Oe,Of,Oe,v3(135,0,15),1)
  1085. SetWeld(wRArm,0,x,ASpeed*2,Og,Oh,Og,v3(45,-10,-100),1)
  1086. wait()
  1087. end
  1088. wait(1)
  1089. for x=1,40 do
  1090. SetWeld(wRSho,0,1,1,Oe,Of,Oe,v3(135+mran(-3,3),0,15+mran(-3,3)),1)
  1091. SetWeld(wRArm,0,1,1,Og,Oh,Og,v3(45,-10+mran(-12,12),-100+mran(-3,3)),1)
  1092. wait(0.05)
  1093. if x%2==0 then
  1094. local cf=Grabbing.Part1.CFrame*ca(180,mran(-180,180),mran(-40,40))*cn(0,1.5,0)
  1095. MeshEffect(24,cf,cf*cn(0,10,0),v3(0.2,2,0.2),v3(0.4,5,0.4),0.1,1,'Really red','Sphere')
  1096. end
  1097. end
  1098. Grabbing.Part1:BreakJoints()
  1099. pcall(function() Grabbing.Part1.Parent.Head:Remove() end)
  1100. Grabbing:Remove() Grabbing=nil
  1101. wait(2)
  1102. ReturnAnim()
  1103. Anim,ArmAnim='None','None'
  1104. elseif cmd=='drop' and Grabbing then
  1105. local hum=Grabbing.Part1.Parent.Humanoid Grabbing:Remove() Grabbing=nil hum.PlatformStand=false
  1106. elseif LimbNames[Sep[1]] and (Anim=='None' or Anim=='Form') then
  1107. Anim,ArmAnim,LegAnim='Form','Form','Form'
  1108. local v1,v2=GetWeld(LimbNames[Sep[1]],0)
  1109. local sepx=se(',',Sep[2])
  1110. for x=1,ASpeed*2 do
  1111. SetWeld(LimbNames[Sep[1]],0,x,ASpeed*2,v1,v2,v1,v3(tonumber(sepx[1]),tonumber(sepx[2]),tonumber(sepx[3])),1)
  1112. wait()
  1113. end
  1114. elseif cmd=='plode' then
  1115. Char:BreakJoints() wait()
  1116. local Pressure=tonumber(sep[2]) or 50
  1117. fMarble(Char,function(v) v.Velocity=cn(Torso.Position,v.Position).lookVector*Pressure end)
  1118. for i,v in pairs(RootLimbs) do v.Velocity=cn(Torso.Position,v.Position).lookVector*Pressure end
  1119. elseif cmd=='explode' then
  1120. iNew{'Explosion',pTorso,Position=pTorso.Position,BlastRadius=Scale*20}
  1121. elseif cmd=='goto' then
  1122. pcall(function()
  1123. Hum:MoveTo(Player:GetMouse().Hit.p,Player:GetMouse().Target) end)
  1124. elseif cmd=='newscale' and tonumber(sep[2]) then
  1125. Char:BreakJoints()
  1126. Scale=tonumber(sep[2])
  1127. if Scale<0.5 then Scale=0.5 end
  1128. if Scale>=100 then Scale=100 end
  1129. elseif cmd=='nobox' then
  1130. for i,v in pairs(workspace:children()) do if v.Name=='Cart' then v:Remove() end end
  1131. elseif cmd=='die' then
  1132. Char:BreakJoints()
  1133. elseif cmd=='brick' then
  1134. iPart{workspace,12,30,30,cf=Player.Character.Torso.CFrame*cn(0,10,-20),tr=0.5,an=true}
  1135. elseif cmd=='test' then
  1136. local pt=Player.Character.Torso.CFrame
  1137. MeshEffect(35,pt*cn(0,5,0)*ca(90,0,0),nil,v3(2,2,1)*Scale,v3(7,7,3)*Scale,0.2,1,'Light stone grey',as.ring)
  1138. else
  1139. end
  1140. end))
  1141. end)
  1142. keys={}
  1143. NewAnim={}
  1144. Player:GetMouse().KeyDown:connect(function(k)
  1145. coroutine.resume(coroutine.create(function() keys[k]=true
  1146. if (k=='q' or k=='e') and (Anim=='None' or Anim=='Laser') and (ArmAnim=='None' or ArmAnim=='Laser') and not NewAnim[k] then
  1147. NewAnim[k]=true
  1148. local w1,w2=k=='q' and wLSho or wRSho,k=='q' and wLArm or wRArm
  1149. local x=k=='q' and -1 or 1
  1150. local aa,bb=GetWeld(w1,0)
  1151. local cc,dd=GetWeld(w2,0)
  1152. local targ=w1.Part1.CFrame*cn(0,-333,0)
  1153. local tips={}
  1154. local co=0
  1155. local sho1=iPart{Char,0.35,RArm.Size.y/Scale+0.15 ,0.35,sc=Scale,co=CC[1]} iNew{'Weld',sho1,Part0=k=='q' and LArm or RArm,Part1=sho1} iNew{'CylinderMesh',sho1}
  1156. local sho2=iPart{Char,0.3,RArm.Size.y/Scale+0.16,0.3,sc=Scale,co='Really black'} iNew{'Weld',sho2,Part0=sho1,Part1=sho2} iNew{'CylinderMesh',sho2}
  1157. for x=-1,1,2 do for z=-1,1,2 do tips[#tips+1]={(k=='q' and LArm or RArm)[x..'-1'..z].Weld}
  1158. co=co+0.25
  1159. local asd=tips[#tips]
  1160. asd[2],asd[3]=GetWeld(asd[1],0)
  1161. local cf=ca(0,360*co,0)*cn(0,asd[2].y*1.8,-0.75*Scale)*ca(-20,0,0)
  1162. asd[4]=cf.p
  1163. local a,b,c=cf:toEulerAnglesXYZ()
  1164. asd[5]=v3(mdeg(a),mdeg(b),mdeg(c))
  1165. end end
  1166. for u=1,ASpeed/2 do
  1167. for i=1,4 do local asd=tips[i]
  1168. SetWeld(asd[1],0,u,ASpeed/2,asd[2],asd[3],asd[4],asd[5],1)
  1169. end wait()
  1170. end
  1171. repeat Anim,ArmAnim,LaserOn='Laser','Laser',true wait()
  1172. for i=1,4 do tips[i][1].C0=ca(0,15*x,0)*tips[i][1].C0 end
  1173. targ=TweenV3(1,12,targ,Player:GetMouse().Hit.p)
  1174. w1.C0=pTorso.CFrame:toObjectSpace(cn(pTorso.CFrame*cn(1.5*Scale*x,0.5*Scale,0).p,targ))*ca(90,0,0)
  1175. w2.C0=cn(0,-0.75*Scale,0)
  1176. until not keys[k]
  1177. ClearWeld(w1) ClearWeld(w2) for i=1,4 do ClearWeld(tips[i][1]) tips[i][6],tips[i][7]=GetWeld(tips[i][1],0) end
  1178. local a,b=GetWeld(w1,0)
  1179. local c,d=GetWeld(w2,0)
  1180. for z=1,ASpeed/2 do
  1181. for i=1,4 do SetWeld(tips[i][1],0,z,ASpeed/2,tips[i][6],tips[i][7],tips[i][2],tips[i][3],1) end
  1182. SetWeld(w1,0,z,ASpeed/2,a,b,aa,bb,1)
  1183. SetWeld(w2,0,z,ASpeed/2,c,d,cc,dd,1)
  1184. wait()
  1185. end
  1186. sho1:Remove() sho2:Remove()
  1187. NewAnim[k]=false
  1188. Anim,ArmAnim,LaserOn='None','None',false
  1189. end
  1190. end)) end)
  1191. Player:GetMouse().KeyUp:connect(function(k) keys[k]=false end)
  1192. Player:GetMouse().Button1Down:connect(function()
  1193. Button=true
  1194. if keys.f and Player:GetMouse().Target and Anim=='None' then
  1195. Hum:MoveTo(Player:GetMouse().Hit.p,Player:GetMouse().Target)
  1196. elseif (keys.q or keys.e) and LaserOn then
  1197. local pick=keys.q and 'q' or 'e'
  1198. repeat
  1199. local ofs=(pick=='q' and LArm or RArm).CFrame*ca(90,0,0)
  1200. if pick=='q' and keys.e then pick='e'
  1201. elseif pick=='e' and keys.q then pick='q' end
  1202. local part=iPart{Char,0.2,0.5,0.2,sc=Scale,co=CC[mran(2,3)],an=true,ma=Mat} iNew{'CylinderMesh',part}
  1203. Projectile(ofs,2*Scale,part,ca(-90,0,0),function(hit,pos)
  1204. AOEFind(pos,Scale*2,function(Hum,v) Damage(Hum) end)
  1205. end,
  1206. function(pos)
  1207. for i=1,5 do local cf=cn(pos)*ca(0,mran(-180,180),mran(-95,95)) MeshEffect(8,cf,cf*cn(0,Scale*2.2,0),v3(0.07,0.3,0.07)*Scale,v3(0.4,3,0.4)*Scale,0.2,1,CC[mran(2,3)],as.cone) end
  1208. MeshEffect(8,cn(pos),nil,v3(0.1,0.1,0.1)*Scale,v3(3,3,3)*Scale,0.2,1,CC[mran(2,3)],'Sphere') part:Remove() end)
  1209. wait((keys.q and keys.e) and 0.2 or 0.4)
  1210. until not Button or (not keys.q and not keys.e)
  1211. elseif 'swag'=='sweg' then
  1212. end
  1213. end)
  1214. Player:GetMouse().Button1Up:connect(function()
  1215. Button=false
  1216. end)
  1217.  
  1218. WalkAnim=0
  1219. Walking=false
  1220. WalkMulp=1
  1221. WalkMax=16
  1222. Hum.WalkSpeed=18
  1223. tWS={1,1,1,1,1,1,1}
  1224.  
  1225. Marbler=0
  1226. local cou=0
  1227. while Char.Parent do
  1228. cou=cou+1
  1229. --if cou%2==0 then print(cou) end
  1230. if Hum.Health>0 then
  1231. if Torso.Velocity.y>5 then Torso.Velocity=v3(Torso.Velocity.x,5,Torso.Velocity.z) end
  1232. Walking=v3(Torso.Velocity.x,0,Torso.Velocity.z).magnitude>Hum.WalkSpeed-2 and true or false
  1233. if Walking and LegAnim=='None' then
  1234. WalkAnim=WalkAnim+WalkMulp
  1235. end
  1236. if WalkAnim>0 and not Walking then
  1237. WalkAnim=WalkAnim-1
  1238. elseif WalkAnim<0 and not Walking then
  1239. WalkAnim=WalkAnim+1
  1240. end
  1241. if math.abs(WalkAnim)>=WalkMax then WalkMulp=WalkMulp*-1 end
  1242. local WalkAdj=26
  1243. Neck.C0=Torso.CFrame:toObjectSpace(pHead.CFrame)
  1244. if ArmAnim=='None' then
  1245. SetWeld(wLSho,0,WalkAnim,WalkMax,Oa,Ob,Oa,v3(-WalkAdj*1.5,0,-10),1)
  1246. SetWeld(wLArm,0,WalkAnim,WalkMax,Oc,Od,Oc,v3(10+(WalkAnim>0 and WalkAdj or 0),0,10),1)
  1247. SetWeld(wRSho,0,WalkAnim,WalkMax,Oe,Of,Oe,v3(WalkAdj*1.5,0,10),1)
  1248. SetWeld(wRArm,0,WalkAnim,WalkMax,Og,Oh,Og,v3(10+(WalkAnim>0 and WalkAdj or 0),0,-10),1)
  1249. end
  1250. if LegAnim=='None' then
  1251. SetWeld(wLThi,0,WalkAnim,WalkMax,Oi,Oj,Oi,v3(15+WalkAdj,0,-5),1)
  1252. SetWeld(wLLeg,0,WalkAnim,WalkMax,Ok,Ol,Ok,v3(-15+(WalkAnim>0 and -WalkAdj or 0),0,5),1)
  1253. SetWeld(wRThi,0,WalkAnim,WalkMax,Om,On,Om,v3(15-WalkAdj,0,5),1)
  1254. SetWeld(wRLeg,0,WalkAnim,WalkMax,Oo,Op,Oo,v3(-15+(WalkAnim<0 and WalkAdj or 0),0,-5),1)
  1255. end
  1256. --[[
  1257. for i,v in pairs(Marble) do
  1258. v[1].C0=v[1].C0*ca(MarbleSpeed*v[2],MarbleSpeed*v[3],MarbleSpeed*v[4])
  1259. Marbler=Marbler+(MarbleSpeed*v[2])
  1260. if Marbler>MarbleMax then
  1261. v[2]=v[2]*-1
  1262. v[3]=v[3]*-1
  1263. v[4]=v[4]*-1
  1264. end
  1265. end --]]
  1266. if Anim=='Follow' and Target and Target:findFirstChild'Torso' and not BG.maxTorque~=v3(1,1,1)/0 then
  1267. Hum:MoveTo(Target.Torso.CFrame*cn(2.5*Scale,0,5*Scale).p,Target.Torso)
  1268. end
  1269. if Grabbing and (not Grabbing.Part1 or not Grabbing.Part1.Parent or Grabbing.Part1.Parent:findFirstChild'Humanoid'==nil or Grabbing.Part1.Parent.Humanoid.Health<1) then
  1270. Grabbing:Remove() Grabbing=nil
  1271. end
  1272. end--hleat
  1273. --DoLoop Package
  1274. for i,v in pairs(LoopFunctions) do
  1275. v[2]=v[2]+1
  1276. v[3](v[2]/v[1])
  1277. if v[1]<=v[2] then LoopFunctions[i]=nil end
  1278. end
  1279. local ws=18
  1280. for i=1,#tWS do ws=ws*tWS[i] end
  1281. Hum.WalkSpeed=ws
  1282. if Hum.MaxHealth~=8000 then Hum.MaxHealth=8000 Hum.Health=8000 end
  1283. Hum.Health=Hum.Health+0.1
  1284. wait(0.03)
  1285. end
  1286. ChatConnection:disconnect()
  1287. game:service'Debris':AddItem(script,0.5)
  1288. script.Disabled=true
  1289.  
  1290. --[[
  1291. sit;
  1292. dance;
  1293. stop;
  1294. follow;
  1295. die;
  1296. grab;PLAYERNAME
  1297. roll;PLAYERNAME
  1298. crush;PLAYERNAME
  1299. beam;PLAYERNAME
  1300. box;
  1301. boulder;
  1302. newscale;NUMBER
  1303. press q and e for machine gun!
  1304. --[[
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement