Advertisement
lafur

Untitled

Sep 16th, 2018
118
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 38.49 KB | None | 0 0
  1. --https://github.com/Mokiros/roblox-FE-compatibility
  2. if game:GetService("RunService"):IsClient() then error("Script must be server-side in order to work; use h/ and not hl/") end
  3. local Player,Mouse,mouse,UserInputService,ContextActionService = owner
  4. local RealPlayer = Player
  5. do print("FE Compatibility code by Mokiros")local a=RealPlayer;script.Parent=a.Character;local b=Instance.new("RemoteEvent")b.Name="UserInput_Event"local function c()local d={_fakeEvent=true,Functions={},Connect=function(self,e)table.insert(self.Functions,e)end}d.connect=d.Connect;return d end;local f={Target=nil,Hit=CFrame.new(),KeyUp=c(),KeyDown=c(),Button1Up=c(),Button1Down=c(),Button2Up=c(),Button2Down=c()}local g={InputBegan=c(),InputEnded=c()}local CAS={Actions={},BindAction=function(self,h,i,j,...)CAS.Actions[h]=i and{Name=h,Function=i,Keys={...}}or nil end}CAS.UnbindAction=CAS.BindAction;local function k(self,l,...)local d=f[l]if d and d._fakeEvent then for m,e in pairs(d.Functions)do e(...)end end end;f.TrigEvent=k;g.TrigEvent=k;b.OnServerEvent:Connect(function(n,o)if n~=a then return end;f.Target=o.Target;f.Hit=o.Hit;if not o.isMouse then local p=o.UserInputState==Enum.UserInputState.Begin;if o.UserInputType==Enum.UserInputType.MouseButton1 then return f:TrigEvent(p and"Button1Down"or"Button1Up")end;if o.UserInputType==Enum.UserInputType.MouseButton2 then return f:TrigEvent(p and"Button2Down"or"Button2Up")end;for m,d in pairs(CAS.Actions)do for m,q in pairs(d.Keys)do if q==o.KeyCode then d.Function(d.Name,o.UserInputState,o)end end end;f:TrigEvent(p and"KeyDown"or"KeyUp",o.KeyCode.Name:lower())g:TrigEvent(p and"InputBegan"or"InputEnded",o,false)end end)b.Parent=NLS([==[local a=game:GetService("Players").LocalPlayer;local b=script:WaitForChild("UserInput_Event")local c=a:GetMouse()local d=game:GetService("UserInputService")local e=function(f,g)if g then return end;b:FireServer({KeyCode=f.KeyCode,UserInputType=f.UserInputType,UserInputState=f.UserInputState,Hit=c.Hit,Target=c.Target})end;d.InputBegan:Connect(e)d.InputEnded:Connect(e)local h,i;while wait(1/30)do if h~=c.Hit or i~=c.Target then h,i=c.Hit,c.Target;b:FireServer({isMouse=true,Target=i,Hit=h})end end]==],Player.Character)local r=game;local s={__index=function(self,q)local t=rawget(self,"_RealService")if t then return typeof(t[q])=="function"and function(m,...)return t[q](t,...)end or t[q]end end,__newindex=function(self,q,u)local t=rawget(self,"_RealService")if t then t[q]=u end end}local function v(d,w)d._RealService=typeof(w)=="string"and r:GetService(w)or w;return setmetatable(d,s)end;local x={GetService=function(self,t)return rawget(self,t)or r:GetService(t)end,Players=v({LocalPlayer=v({GetMouse=function(self)return f end},Player)},"Players"),UserInputService=v(g,"UserInputService"),ContextActionService=v(CAS,"ContextActionService"),RunService=v({_btrs={},RenderStepped=r:GetService("RunService").Heartbeat,BindToRenderStep=function(self,h,m,i)self._btrs[h]=self.Heartbeat:Connect(i)end,UnbindFromRenderStep=function(self,h)self._btrs[h]:Disconnect()end},"RunService")}rawset(x.Players,"localPlayer",x.Players.LocalPlayer)x.service=x.GetService;v(x,game)game,owner=x,x.Players.LocalPlayer end --Epic Staff Gifted by TheRedAngel, Regular Script!
  6.  
  7. name = 'Epic Staff'
  8. PLAYERS = game:GetService('Players')
  9. ply = PLAYERS.LocalPlayer
  10. char = ply.Character
  11. pcall(function() char:FindFirstChild("legetdgq"):Remove() end)
  12. m = Instance.new("Model",char) m.Name = "YOURNAMEHERE"
  13. hop = Instance.new("HopperBin",ply.Backpack)
  14. hop.Name = name
  15. debris = game:GetService("Debris")
  16.  
  17. cfn,ang,v3n,ud2n,V2 = CFrame.new,CFrame.Angles,Vector3.new,UDim2.new,Vector2.new
  18. floatforce = 196.25
  19.  
  20. torso,head = char.Torso,char.Head
  21. attacking = false
  22.  
  23. rs = torso["Right Shoulder"]
  24. ls = torso["Left Shoulder"]
  25. rh = torso["Right Hip"]
  26. lh = torso["Left Hip"]
  27. neck = torso["Neck"]
  28. rw,lw = nil,nil
  29. rhw,lhw = nil,nil
  30. local orgc1 = rs.C1
  31.  
  32. rarm = char["Right Arm"]
  33. larm = char["Left Arm"]
  34. rleg = char["Right Leg"]
  35. lleg = char["Left Leg"]
  36.  
  37. normposr = cfn(1.5,.5,0)
  38. normposl = cfn(-1.5,.5,0)
  39. normposl2 = cfn(.5,-1.5,0)
  40. normposr2 = cfn(-.5,-1.5,0)
  41. normposn = CFrame.new(0,1,0,-1,-0,-0,0,0,1,0,1,0)
  42.  
  43. holdpos = normposr*ang(math.pi/2,0,0)
  44. holdpos2 = normposl*ang(math.pi/2,0,0)
  45.  
  46. --------UTILITIES START-------
  47. function genNew(ClassName, Parent, Properties)
  48. local nObj = Instance.new(ClassName, Parent)
  49. if Properties["FormFactor"] then
  50. nObj["FormFactor"] = Properties["FormFactor"]
  51. end
  52. for Prop, Value in pairs(Properties) do
  53. nObj[Prop] = Value
  54. end
  55. return nObj
  56. end
  57.  
  58. T = {["P"] = function(x,y,z,color,transparency,cancollide,anchored,parent,typee)
  59. if typee == 'wedge' then
  60. c = Instance.new("WedgePart",m)
  61. elseif typee == 'seat' then
  62. c = Instance.new("Seat",m)
  63. elseif typee == 'vseat' then
  64. c = Instance.new("VehicleSeat",m)
  65. else
  66. c = Instance.new("Part",m)
  67. end
  68. c.TopSurface,c.BottomSurface = 0,0
  69. c.Locked = true
  70. c.formFactor = "Custom"
  71. c.Size = Vector3.new(x,y,z)
  72. if color ~= "random" then
  73. c.BrickColor = BrickColor.new(color)
  74. else c.BrickColor = BrickColor:random()
  75. end
  76. c.Transparency = transparency
  77. c.CanCollide = cancollide
  78. if anchored ~= nil then c.Anchored = anchored end
  79. if parent ~= nil then c.Parent = parent end
  80. return c
  81. end
  82. ,
  83. ["C"] = function(func) coroutine.resume(coroutine.create(func)) end
  84. ,
  85. ["W"] = function(part0,part1,x,y,z,rx,ry,rz,parent)
  86. w = Instance.new("Motor",m)
  87. if parent ~= nil then w.Parent = parent end
  88. w.Part0,w.Part1 = part0,part1
  89. w.C1 = CFrame.new(x,y,z) * CFrame.Angles(rx,ry,rz)
  90. return w
  91. end
  92. ,
  93. ["BG"] = function(parent)
  94. local c = Instance.new("BodyGyro",parent)
  95. c.P = 20e+003
  96. c.cframe = parent.CFrame
  97. c.maxTorque = Vector3.new(c.P,c.P,c.P)
  98. return c
  99. end
  100. ,
  101. ["BP"] = function(parent,position)
  102. local bp = Instance.new("BodyPosition",parent)
  103. bp.maxForce = Vector3.new()*math.huge
  104. bp.position = position
  105. return bp
  106. end
  107. ,
  108. ["F"] = function(parent,size,heat,color,secondcolor,enabled)
  109. f = Instance.new("Fire",parent)
  110. f.Size = size
  111. f.Heat = heat
  112. if enabled ~= nil then f.Enabled = enabled end
  113. if color ~= nil then f.Color = BrickColor.new(color).Color end
  114. if secondcolor ~= nil then f.SecondaryColor = BrickColor.new(secondcolor).Color end
  115. return f
  116. end
  117. ,
  118.  
  119. ["FM"] = function(parent,meshid,x,y,z,meshtexture)
  120. if meshid == "cylinder" then
  121. mesh = Instance.new("CylinderMesh",parent)
  122. mesh.Scale = Vector3.new(x,y,z)
  123. return mesh
  124. elseif meshid == 'block' then
  125. mesh = Instance.new("BlockMesh",parent)
  126. mesh.Scale = Vector3.new(x,y,z)
  127. return mesh
  128. end
  129. mesh = Instance.new("SpecialMesh",parent)
  130.  
  131. if meshid == 'wedge' then
  132. mesh.MeshType = 'Wedge'
  133. elseif meshid == 'sphere' then
  134. mesh.MeshType = 3
  135. elseif type(meshid) == "number" then
  136. mesh.MeshId = "rbxassetid://"..meshid
  137. else
  138. mesh.MeshId = "rbxassetid://"..meshids[meshid]
  139. end
  140. mesh.Scale = Vector3.new(x,y,z)
  141. if meshtexture then
  142. if type(meshtexture) == "number" then mesh.TextureId = "rbxassetid://"..meshtexture else
  143. mesh.TextureId = "rbxassetid://"..textureids[meshtexture] end
  144. end
  145. return mesh
  146. end,
  147.  
  148. ["Dec"] = function(parent,face,id,transparency)
  149. c = Instance.new("Decal",parent)
  150. c.Face = face
  151. c.Texture = id
  152. if transparency then c.Transparency = transparency end
  153. return c
  154. end,
  155. ["S"] = function(id,pitch,volume,parent)
  156. cur = nil
  157. found = false
  158. if type(id) == 'string' then
  159. for i,v in pairs(char.Head:children()) do
  160. if v:IsA("Sound") and v.Name == id and not found then
  161. cur = v
  162. if parent then cur = v:Clone() cur.Parent = parent end
  163. cur.Pitch = pitch
  164. if volume then cur.Volume = volume end
  165. cur:Play()
  166. found = true
  167. return cur
  168. end
  169. end
  170. elseif type(id) == 'number' then
  171. local a = char.Head:FindFirstChild('exteo')
  172. a.SoundId = 'rbxassetid://'..id
  173. a.Pitch = pitch
  174. if volume then a.Volume = volume end
  175. a:Play()
  176. return a
  177. end
  178. end
  179. }
  180. function FindHumanoid(a,b)
  181. for i,v in pairs(a:children()) do
  182. if v:IsA('Humanoid') then
  183. if not b then
  184. if v.Parent ~= char then return v end
  185. else return v end
  186. end
  187. end
  188. end
  189. function damage(hit,amount,delay) ---- VAHINKO DAMAGE
  190. hum = FindHumanoid(hit)
  191. if hum then
  192. if delay then
  193. local found = CheckTag(hum,'tag')
  194. if not found then
  195. local a = AddTag(hum,'tag')
  196. debris:AddItem(a,delay)
  197. hum.Health = hum.Health - amount
  198. end
  199. else hum.Health = hum.Health - amount
  200. end
  201. return hum
  202. end
  203. end
  204.  
  205. rtorso = torso
  206.  
  207. lock = {["R"] =
  208. function(a)
  209. if a == 1 then
  210. rabrick = T.P(1,1,1,"White",1,false,false)
  211. rw = T.W(rabrick,rtorso,1.5,.5,0,0,0,0)
  212. T.W(rarm,rabrick,0,-.5,0,0,0,0)
  213. elseif a == 2 then
  214. rlbrick = T.P(1,1,1,"White",1,false,false)
  215. rhw = T.W(rlbrick,rtorso,-.5,-1.5,0,0,0,0)
  216. T.W(rleg,rlbrick,0,-.5,0,0,0,0)
  217. elseif a == 0 then
  218. rs.Parent = rtorso
  219. rw.Parent = nil
  220. rabrick:Destroy() rabrick = nil
  221. elseif a == -1 then
  222. rhw.Parent = nil
  223. rh.Parent = rtorso
  224. rlbrick:Destroy() rlbrick = nil
  225. end
  226. end
  227. , ["L"] = function(a)
  228. if a == 1 then
  229. labrick = T.P(1,1,1,"White",1,false,false)
  230. lw = T.W(labrick,rtorso,-1.5,.5,0,0,0,0)
  231. T.W(larm,labrick,0,-.5,0,0,0,0)
  232. elseif a == 2 then
  233. llbrick = T.P(1,1,1,"White",1,false,false)
  234. lhw = T.W(llbrick,rtorso,.5,-1.5,0,0,0,0)
  235. T.W(lleg,llbrick,0,-.5,0,0,0,0)
  236. elseif a == 0 then
  237. ls.Parent = rtorso
  238. lw.Parent = nil
  239. labrick:Destroy() labrick = nil
  240. elseif a == -1 then
  241. lhw.Parent = nil
  242. lh.Parent = rtorso
  243. llbrick:Destroy() llbrick = nil
  244. end
  245. end
  246. }
  247.  
  248. function spaas(position,radius,number,number2,color)
  249. mode = Instance.new("Model",m)
  250.  
  251. for i = 1,number2 do
  252. pos = position+v3n(M.R(-radius,radius),M.R(-radius,radius),M.R(-radius,radius))
  253. mag = (position-pos).magnitude
  254.  
  255. col = color or 'Toothpaste'
  256. local laz = T.P(.1,mag,.1,col,0,false,true,mode)
  257.  
  258. T.FM(laz,'cylinder',.3,1,.3)
  259. laz.CFrame = (cfn(position,pos)*cfn(0,0,-mag/2))*ang(math.pi/2,0,0)
  260.  
  261. cframe = (laz.CFrame*cfn(0,-mag/2,0)).p
  262. pos2 = cframe+v3n(M.R(-radius,radius),M.R(-radius,radius),M.R(-radius,radius))
  263. mag2 = (cframe-pos2).magnitude
  264. local laz2 = T.P(.1,mag2,.1,col,0,false,true,mode)
  265. T.FM(laz2,'cylinder',.3,1,.3)
  266. laz2.CFrame = (cfn(cframe,pos2)*cfn(0,0,-mag2/2))*ang(math.pi/2,0,0)
  267.  
  268. previo = laz2
  269. for i = 1,number do
  270. cframe = (previo.CFrame*cfn(0,-mag/2,0)).p
  271. pos2 = cframe+v3n(M.R(-radius,radius),M.R(-radius,radius),M.R(-radius,radius))
  272. mag2 = (cframe-pos2).magnitude
  273.  
  274. local laz2 = T.P(.1,mag2,.1,col,0,false,true,mode)
  275. T.FM(laz2,'cylinder',.3,1,.3)
  276. laz2.CFrame = (cfn(cframe,pos2)*cfn(0,0,-mag2/2))*ang(math.pi/2,0,0)
  277.  
  278. previo = laz2
  279. end
  280.  
  281. end
  282. debris:AddItem(mode,.1)
  283. return mode
  284. end
  285. function lightning(startpos,endpos,times,offse,livetime,col,dmg)
  286. local curpos = startpos
  287. for i = 1,times do
  288. mag = (startpos-endpos).magnitude offs = {-offse,offse}
  289. offset = v3n(offs[M.R(1,2)],offs[M.R(1,2)],offs[M.R(1,2)])
  290. laz = T.P(.1,.1,mag/times,col,0,false,true,m)
  291. if dmg then laz.Touched:connect(function(hit) damage(hit.Parent,dmg[1],dmg[2]) end) end
  292. apos = (cfn(curpos,endpos)*cfn(0,0,-mag/times)).p+offset
  293. if times == i then
  294. mag2 = (curpos-endpos).magnitude
  295. laz.Size = v3n(.1,.1,mag2)
  296. laz.CFrame = cfn(curpos,endpos)*cfn(0,0,-mag2/2)
  297. else
  298. laz.CFrame = cfn(curpos,apos)*cfn(0,0,-mag/times/2)
  299. end
  300. curpos = laz.CFrame*cfn(0,0,-mag/times/2).p debris:AddItem(laz,livetime)
  301. end
  302. end
  303. ------MESHIDS---
  304. meshids = {["penguin"] = 15853464, ["ring"] = 3270017,
  305. ["spike"] = 1033714,["cone"] = 1082802,["crown"] = 20329976,["crossbow"] = 15886761,
  306. ["cloud"] = 1095708,["mjolnir"] = 1279013,["diamond"] = 9756362, ["hand"] = 37241605,
  307. ["fist"] = 65322375,["skull"] = 36869983,["totem"] = 35624068,["spikeb"] = 9982590,["dragon"] = 58430372,["fish"] = 31221717, ["coffee"] = 15929962,["spiral"] = 1051557,
  308. ["ramen"] = 19380188,["lightning"] = 72583597,["bullet"]=2697549,['cheese'] = 1090700,["pan"] = 24342877,["ketchup"] = 29690481,
  309. ["duck"] = 9419831,["unicorn"]=84003494}---some meshids
  310. textureids = {["cone"] = 1082804,["rainbow"] = 28488599,["fish"] = 31221733, ["coffee"] = 24181455,["monster"] = 33366441,["ramen"] = 19380153,
  311. ["cheese"] = 1090703}
  312. soundids = {["bell"] = 20005706,["flintlock"] = 13510352,["falcon"] = 1387390,['sensa'] = 4700455,
  313. ['midas'] = 17385513;
  314. ['spark'] = 10756118;
  315. ['boom'] = 10730819;
  316. ['plank'] = 10548112;
  317. ['harmonica1'] = 33069371;
  318. ['harmonica2'] = 33069412;
  319. ['thump'] = 10730819;
  320. ['hit'] = 2801263;
  321. ['crunch'] = 15047813;
  322. }
  323. function AddTag(object,tagname) local tag = Instance.new("BoolValue",object) tag.Name = tagname return tag end
  324. function CheckTag(object,tagname) local found = object:FindFirstChild(tagname) if found then return found else return _ end end
  325. function RemoveTag(object,tagname) local found = CheckTag(object,tagname) if found then found:Remove() end end
  326. for i,v in pairs(soundids) do ---Remove sounds
  327. for _,q in pairs(char.Head:children()) do
  328. if q.Name == i then q:Remove() end
  329. end
  330. end
  331. for i,v in pairs(soundids) do ----Add sounds
  332. sound = Instance.new("Sound")
  333. sound.SoundId = "http://www.roblox.com/asset/?id="..v
  334. sound.Name = i
  335. sound.Parent = char.Head
  336. end
  337. genNew('Sound',char.Head,{
  338. Name = 'slash';
  339. SoundId = 'rbxasset://sounds//swordslash.wav'
  340. })
  341.  
  342. waitbp = function(a,r) while (a.Parent.Position-a.position).magnitude > r do wait() end end
  343.  
  344. M = {["R"] = function(a,b) return math.random(a,b) end,
  345. ["Cos"] = function(a) return math.cos(a) end,
  346. ["Sin"] = function(a) return math.sin(a) end,
  347. ["D"] = function(a) return math.rad(a) end
  348. }
  349.  
  350. function findground(position,radius,ignore)
  351. if ignore then
  352. ig = ignore table.insert(ig,m)
  353. else ig = {m}
  354. end
  355. local ray = Ray.new(position.p,position.p+(position.p-v3n(0,200,0)).unit*radius)
  356. local obj,pos2 = Workspace:FindPartOnRayWithIgnoreList(ray,ig)
  357. if obj and pos2 then return obj,pos2 else return nil end
  358. end
  359. rweld = _
  360. faketorso = _
  361. function faketor()
  362. if rtorso == torso then
  363. torso.Transparency = 1
  364. faketorso = T.P(2,2,1,'White',0,false,false,char)
  365. rweld = T.W(faketorso,torso,0,0,0,0,0,0)
  366. rtorso = faketorso hw.Part1 = rtorso
  367. for i,v in pairs({lh,ls,rh,rs}) do v.Part0 = rtorso end
  368. elseif rtorso ~= torso then
  369. rtorso = torso
  370. for i,v in pairs({lh,ls,rh,rs}) do v.Part0 = rtorso end
  371. hw.Part1 = torso
  372. faketorso:Remove()
  373. rweld:Remove()
  374. torso.Transparency = 0
  375. end
  376.  
  377. end
  378.  
  379. function calcp(a,b) --- Direction CFrame
  380. return cfn(a,v3n(b.x,a.y,b.z))
  381. end
  382.  
  383. function weldall(q)
  384. if q == 1 then a,b = 1,2 else a,b = -1,0 end
  385. for i = a,b do lock.R(i) lock.L(i) end
  386. end
  387.  
  388. function speak(a,b)
  389. game:GetService('Chat'):Chat(p,a,b)
  390. end
  391. function FindPlayers(a,b,c) --- Finds Players near a part
  392. list = {}
  393. for _,v in pairs(Workspace:children()) do
  394. if v:IsA("Model") then
  395. for _,child in pairs(v:children()) do
  396. if child:IsA("Humanoid") then
  397. if c and child.Parent ~= char then
  398. if (a-child.Torso.Position).magnitude < b then
  399. table.insert(list,child.Parent)
  400. end
  401. elseif not c then
  402. if (a-child.Torso.Position).magnitude < b then
  403. table.insert(list,child.Parent)
  404. end
  405. end
  406. end
  407. end
  408. end
  409. end
  410. return list
  411. end
  412. --------UTILITIES END-------
  413. Staff = Instance.new("Model",m)
  414.  
  415. hdl = T.P(.5,4,.5,'White',0,false,false,Staff)
  416. T.FM(hdl,'cylinder',1,1,1)
  417. hw = T.W(hdl,rtorso,0,0,.75,0,0,M.D(-45))
  418.  
  419. p = T.P(2,2,2,'Black',0,false,false,Staff) p.Shape = 0
  420. T.W(p,hdl,0,3,0,0,0,0)
  421. p2 = T.P(1,1,1,'White',0,false,false,Staff)
  422. T.FM(p2,'crown',.9,.9,.9)
  423. T.W(p2,hdl,0,2,.2,math.pi,0,0)
  424.  
  425. hat = T.P(1,1,1,'White',0,false,false,Staff)
  426. T.FM(hat,49927327,1,1,1,'rainbow')
  427. T.W(hat,p,0,1.4,0,0,0,0)
  428. hat = T.P(1,1,1,'White',0,false,false,Staff)
  429. T.FM(hat,22053998,1.2,1,1,'rainbow')
  430.  
  431. T.W(hat,p,0,.5,-.5,0,0,0)
  432. p2 = T.P(.5,1.5,.4,'White',0,false,false,Staff)
  433. T.FM(p2,'sphere',1,1,1)
  434. T.W(p2,p,0,-1,-.75,0,0,0)
  435. mouth = T.P(.5,.1,.1,'Nougat',0,false,false,Staff)
  436. mouth_mesh = T.FM(mouth,'sphere',1,1,1)
  437. mouth_weld = T.W(mouth,p,0,-.5,-.8,0,0,0) mouth_weld_normal = mouth_weld.C1
  438.  
  439.  
  440. equipped = false
  441.  
  442. -----------ZOMBIE MAKER FUNCTION------------
  443. function Exorcism()
  444. pos = torso.Position+torso.CFrame.lookVector*3+v3n(0,-3,0)
  445.  
  446. person = Instance.new("Model",Workspace)
  447. person.Name = 'Zombie'
  448.  
  449. ----PARTS-------
  450. local hed = T.P(1,1,1,'White',0,true,false,person) hed.Name = 'Head'
  451. Instance.new("SpecialMesh",hed).Scale = v3n(1.25,1.25,1.25)
  452. local tor = T.P(2,2,1,'White',0,true,false,person) tor.Name = 'Torso'
  453. local ar = T.P(1,2,1,'White',0,true,false,person) ar.Name = 'Left Arm'
  454. q = T.W(ar,tor,-.5,0.5,0,0,math.pi/2,0,tor)
  455. q.C0 = cfn(1,0.5,0)*ang(0,math.pi/2,0)
  456. local ar = T.P(1,2,1,'White',0,true,false,person) ar.Name = 'Right Arm'
  457. q2 = T.W(ar,tor,.5,0.5,0,0,math.pi/2,0,tor)
  458. q2.C0 = cfn(-1,0.5,0)*ang(0,math.pi/2,0)
  459.  
  460. local ar = T.P(1,2,1,'White',0,true,false,person) ar.Name = 'Right Leg'
  461. T.W(ar,tor,-.5,-2,0,0,0,0,tor)
  462. local ar = T.P(1,2,1,'White',0,true,false,person) ar.Name = 'Left Leg'
  463. T.W(ar,tor,.5,-2,0,0,0,0,tor)
  464.  
  465. T.W(hed,tor,0,1.5,0,0,0,0,tor)
  466.  
  467. ----PARTS-------
  468.  
  469. q.MaxVelocity = .1
  470. q.DesiredAngle = math.pi/2
  471. q2.MaxVelocity = .1
  472. q2.DesiredAngle = math.pi/2
  473.  
  474. local hum = Instance.new("Humanoid",person)
  475. Instance.new("Skin",person).SkinColor = BrickColor.new('Earth green')
  476. tor.CFrame = calcp(torso.Position+torso.CFrame.lookVector*5,torso.Position)
  477.  
  478. shirt = Instance.new('Shirt',person)
  479. shirt.ShirtTemplate = 'http://www.roblox.com/asset/?id=79001892'
  480.  
  481. pants = Instance.new('Pants',person)
  482. pants.PantsTemplate = 'http://www.roblox.com/asset/?id=79001892'
  483. crown = T.P(1,1,1,'White',0,false,false)
  484. T.FM(crown,1031410,1,1,1,1031417)
  485. T.W(crown,hed,-.2,.85,0,0,0,M.D(20))
  486. face = T.Dec(hed,'Front','http://www.roblox.com/asset/?id=65180938')
  487.  
  488. ---DYING---
  489. hum.Died:connect(function() wait(2) hum.Parent:Remove() end)
  490. ---DYING---
  491. end
  492. -----------ZOMBIE MAKER FUNCTION------------
  493.  
  494.  
  495. function Equip()
  496. if not equipped then
  497. equipped = true
  498. hw.Part1 = rarm
  499. speak('At your service','Blue')
  500. hw.C1 = cfn(0,-1,0)*ang(-math.pi/2,0,0)
  501. elseif equipped then
  502. equipped = false
  503. hw.Part1 = rtorso
  504. hw.C1 = cfn(0,0,.75)*ang(0,0,M.D(-45))
  505. end
  506. normh = hw.C1
  507. end
  508. function Fly(mouse)
  509. bp = T.BP(torso,torso.Position)
  510. bg = T.BG(torso)
  511. holding = true
  512. lock.R(1) lock.L(1) lock.R(2) lock.L(2)
  513. rw.C1 = normposr*ang(0,0,M.D(30))
  514. lw.C1 = normposl*ang(0,0,M.D(-30))
  515. rhw.C1 = normposr2*ang(0,0,M.D(-30))*cfn(-.4,.1,0)
  516. lhw.C1 = normposl2*ang(0,0,M.D(30))*cfn(.4,.1,0)
  517. while holding do
  518. unit = (torso.Position-mouse.hit.p).unit
  519. bp.position = bp.position+unit*-5
  520. bg.cframe = cfn(torso.Position,mouse.hit.p)*ang(-math.pi/2,0,0)
  521. wait()
  522. end
  523. for i = -1,0 do lock.R(i) lock.L(i) end
  524. bp:Remove()
  525. bg:Remove()
  526. end
  527.  
  528. function earthdragon(mouse)
  529. local ground,_ = findground(torso.CFrame,10,{char})
  530. local mag = (torso.Position-mouse.hit.p).magnitude
  531. if ground then
  532. T.C(function()
  533. local dragon = Instance.new("Model",m)
  534. local main = T.P(1,1,1,'White',1,false,true)
  535. local old = main
  536. s = 10
  537. T.C(function()
  538. while wait() do
  539. wait()
  540. if #dragon:children() > 0 then
  541.  
  542. old.CFrame = cfn(main.Position,old.Position)
  543. for i,v in pairs(dragon:children()) do
  544. if i == #dragon:children() then
  545. old = v
  546. v.CFrame = cfn(old.Position,v.Position)*cfn(0,0,-s)
  547. else
  548. v.CFrame = cfn(old.Position,v.Position)*cfn(0,0,-s)
  549. end
  550. old = v
  551. end
  552. end
  553. end
  554. end)
  555.  
  556. for i = 1,mag/10 do
  557. local cube = genNew('Part',dragon,{
  558. BrickColor = ground.BrickColor;
  559. Size = v3n(s,s,s);
  560. Anchored = true;
  561. TopSurface = ground.TopSurface;
  562. BottomSurface = ground.BottomSurface;
  563. CanCollide = false;
  564. Material = ground.Material;
  565. })
  566. cube.CFrame = p.CFrame
  567. end
  568. local r = mag/2
  569. holding = true
  570.  
  571. local cf = cfn(torso.Position,mouse.hit.p)*cfn(0,0,-r)*ang(0,-math.pi/2,0)
  572. for i = 0,360-s,3 do
  573. wait()
  574. main.CFrame = cf*cfn(M.Cos(M.D(i))*r,M.Sin(M.D(i))*r,0)
  575. end
  576. dragon:Remove()
  577. end)
  578. end
  579. end
  580.  
  581. neck2 = _
  582. function necko(a) if a == 1 then neck2 = T.W(char.Head,faketorso,0,1.5,0,0,0,0) normposn2 = neck2.C0 elseif a == 0 then neck2:Remove() end end
  583.  
  584. ef = function(a)
  585. T.C(function()
  586. local p = T.P(1,1,1,'White',0,false,true)
  587. p.CFrame = a
  588. local msh = T.FM(p,'ring',1,1,1)
  589. for i,v in pairs(FindPlayers(p.Position,5)) do damage(v,5,.1) end
  590. for i = 1,5 do
  591. msh.Scale = v3n(i,i,1)
  592. p.Transparency = i/5
  593. wait()
  594. end
  595. p:Remove()
  596. end)
  597. end
  598.  
  599. function Punches()
  600. faketor()
  601. lock.R(1) lock.L(1)
  602. hw.Part1 = torso
  603. o = 1*.95
  604. for _ = 1,5 do
  605. speak('One','Red')
  606. T.S('hit',2)
  607. for i = 0,1,o do
  608. wait()
  609. rweld.C1 = cfn()*ang(0,M.D(40*i),0)
  610. rw.C1 = normposr*ang(M.D(90*i),0,M.D(40*i))
  611. lw.C1 = normposl*ang(M.D(90*i),0,M.D(40*i))
  612. end
  613.  
  614. ef(rarm.CFrame*cfn(0,-1,0)*ang(math.pi/2,0,0))
  615. for i = 1,0,-o do
  616. wait()
  617. rweld.C1 = cfn()*ang(0,M.D(40*i),0)
  618. rw.C1 = normposr*ang(M.D(90*i),0,M.D(40*i))
  619. lw.C1 = normposl*ang(M.D(90*i),0,M.D(40*i))
  620. end
  621. speak('Two','Red')
  622. T.S('hit',2)
  623. for i = 0,1,o do
  624. wait()
  625. rweld.C1 = cfn()*ang(0,M.D(-40*i),0)
  626. rw.C1 = normposr*ang(M.D(90*i),0,M.D(-40*i))
  627. lw.C1 = normposl*ang(M.D(90*i),0,M.D(-40*i))
  628. end
  629. ef(larm.CFrame*cfn(0,-1,0)*ang(math.pi/2,0,0))
  630. for i = 1,0,-o do
  631. wait()
  632. rweld.C1 = cfn()*ang(0,M.D(-40*i),0)
  633. rw.C1 = normposr*ang(M.D(90*i),0,M.D(-40*i))
  634. lw.C1 = normposl*ang(M.D(90*i),0,M.D(-40*i))
  635. end
  636. end
  637. replics = {'Even my granny punches harder!';'You Weakling!';'Do it H-A-R-D-E-R!';'U gotta do better!';'That wuldnt hurt a fly!';'YOU CANT BE SERIOUS!';'That was WAY TOO SLOW!';'You totally MISSED!';}
  638. speak(replics[math.random(#replics)],'Red')
  639. rweld.C1 = cfn()
  640. faketor()
  641. lock.R(0) lock.L(0)
  642. end
  643.  
  644. function Kick()
  645. faketor()
  646. necko(1)
  647. weldall(1)
  648. local con = lleg.Touched:connect(function(hit) hum = damage(hit.Parent,30,.5) if hum then
  649. hum.Sit = true
  650. hum.Torso.Velocity = calcp(torso.Position,hum.Torso.Position).lookVector*100+v3n(0,100,0)
  651. end
  652. end)
  653. o = 1/5
  654. for i = 0,1,o do
  655. lhw.C1 = normposl2*ang(M.D(-90*i),0,0)
  656. rhw.C1 = normposr2*ang(M.D(45*i),0,0)
  657. rw.C1 = normposr*ang(M.D(160*i),0,0)
  658. lw.C1 = normposl*ang(M.D(160*i),0,0)
  659. rweld.C1 = cfn()*ang(M.D(-20*i),0,0)
  660. neck2.C0 = normposn2*ang(M.D(20*i),0,0)*cfn(0,0,.3*i)
  661. wait()
  662. end
  663. for i = 1,0,-o do
  664. lhw.C1 = normposl2*ang(M.D(-90*i),0,0)
  665. rhw.C1 = normposr2*ang(M.D(45*i),0,0)
  666. rw.C1 = normposr*ang(M.D(160*i),0,0)
  667. lw.C1 = normposl*ang(M.D(160*i),0,0)
  668. rweld.C1 = cfn()*ang(M.D(-20*i),0,0)
  669. neck2.C0 = normposn2*ang(M.D(20*i),0,0)*cfn(0,0,.3*i)
  670. wait()
  671. end
  672.  
  673. for i = 0,1,o do
  674. rhw.C1 = normposr2*ang(M.D(-45*i),0,0)*cfn(0,0,.4*i)
  675. lhw.C1 = normposl2*ang(M.D(80*i),0,0)*cfn(0,-.3*i,-.2*i)
  676. rw.C1 = normposr*ang(M.D(-60*i),0,0)
  677. lw.C1 = normposl*ang(M.D(-60*i),0,0)
  678. rweld.C1 = cfn()*ang(M.D(30*i),0,0)
  679. neck2.C0 = normposn2*ang(M.D(-20*i),0,0)*cfn(0,0,-.2*i)
  680. wait()
  681. end
  682. for i = 1,0,-o do
  683. rhw.C1 = normposr2*ang(M.D(-45*i),0,0)*cfn(0,0,.4*i)
  684. lhw.C1 = normposl2*ang(M.D(80*i),0,0)*cfn(0,-.3*i,-.2*i)
  685. rw.C1 = normposr*ang(M.D(-60*i),0,0)
  686. lw.C1 = normposl*ang(M.D(-60*i),0,0)
  687. rweld.C1 = cfn()*ang(M.D(30*i),0,0)
  688. neck2.C0 = normposn2*ang(M.D(-20*i),0,0)*cfn(0,0,-.2*i)
  689. wait()
  690. end
  691. faketor() con:disconnect()
  692. weldall(0)
  693. end
  694.  
  695. sword = _
  696.  
  697. function SwordOut()
  698. lock.R(1)
  699. if not sword then
  700. speak('Time for sword training','Blue')
  701. for i = 0,1,.1 do
  702. rw.C1 = normposr*ang(M.D(90*i),0,0)
  703. wait()
  704. end
  705. for i = 0,1,.2 do
  706. rw.C1 = holdpos*ang(M.D(40*i),0,M.D(10*i))
  707. mouth_mesh.Scale = v3n(1,2*i,1)
  708. mouth_weld.C1 = mouth_weld_normal*cfn(0,.2*i,-.1*i)
  709. wait()
  710. end
  711. sword = Instance.new("Model",m)
  712. sword_hdl = T.P(.1,2,.1,'White',0,false,false,sword) T.FM(sword_hdl,'cylinder',1,1,1)
  713. sword_tip = T.P(.3,1,.3,'New Yeller',0,false,false,sword)
  714.  
  715. sword_hdl_wld = T.W(sword_hdl,mouth,0,0,0,math.pi/2,0,0)
  716. sword_tip_wld = T.W(sword_tip,sword_hdl,0,-2.5,0,0,0,0)
  717. for i = 0,1,.2 do
  718. sword_tip.Size = v3n(.3,5*i,.3)
  719. sword_tip_wld.Parent,sword_tip_wld.Part1 = m,sword_hdl
  720. sword_tip_wld.C1 = cfn(0,3*i,0)
  721. sword_hdl_wld.C1 = cfn(0,0,-1.25*i)*ang(-math.pi/2+M.D(90*i),0,M.D(45*i))
  722. wait()
  723. end
  724. sword_hdl_wld.Part1 = rarm
  725. sword_hdl_wld.C1 = cfn(0,-1,0)*ang(-math.pi/2,0,0) npos = sword_hdl_wld.C1
  726. for i = 1,0,-.2 do
  727. rw.C1 = holdpos*ang(M.D(40*i),0,M.D(10*i))
  728. mouth_mesh.Scale = v3n(1,(2*i)+1,1)
  729. mouth_weld.C1 = mouth_weld_normal*cfn(0,.2*i,-.1*i)
  730. wait()
  731. end
  732. rw.C1 = holdpos
  733. lock.R(0)
  734. else sword:Remove() sword = nil lock.R(0)
  735. end
  736. end
  737. function Slash()
  738. local con = sword_tip.Touched:connect(function(hit) damage(hit.Parent,10,.1) end)
  739. lock.R(1) T.S('slash',1)
  740. for i = 0,1,1/3 do
  741. rw.C1 = holdpos*ang( M.D(30*i),M.D(60*i),M.D(-40*i) )
  742. wait()
  743. end
  744. old = rw.C1
  745. for i = 0,1,1/3 do
  746. rw.C1 = old*ang(M.D(-120*i),0,0)
  747. wait()
  748. end
  749. for i = 1,0,-1/3 do
  750. rw.C1 = old*ang(M.D(-120*i),0,0)
  751. wait()
  752. end
  753. for i = 1,0,-1/3 do
  754. rw.C1 = holdpos*ang( M.D(30*i),M.D(60*i),M.D(-40*i) )
  755. wait()
  756. end
  757. lock.R(0)
  758. con:disconnect()
  759. end
  760.  
  761. function Grab()
  762. if not huma then
  763. found = _
  764. for i,v in pairs(FindPlayers(torso.Position,10,'')) do
  765. if not found then
  766. found = v
  767. end
  768. end
  769. if found then huma = found.Humanoid
  770. lock.R(1)
  771. huma_wld = T.W(huma.Torso,torso,0,.1,-1.1,0,0,0)
  772. rw.C1 = holdpos*ang(M.D(30),0,M.D(30))
  773. sword_hdl_wld.C1 = npos*ang(0,0,M.D(90))
  774. huma.PlatformStand = true
  775. huma_con = huma.Changed:connect(function(prop) if prop == 'PlatformStand' then huma.PlatformStand = true end end)
  776. end
  777. else
  778. speak('Muahahahaa!','Blue')
  779. f = T.F(p,5,3,'Magenta')
  780. wait(2)
  781. f.Parent = huma.Torso
  782. huma.Health = 0
  783. huma = _
  784. huma_wld:Remove()
  785. sword_hdl_wld.C1 = npos
  786. lock.R(0)
  787. end
  788. end
  789. function Release()
  790. if huma then
  791. huma_wld:Remove()
  792. huma_con:disconnect()
  793. huma.PlatformStand = false
  794. huma = nil
  795. sword_hdl_wld.C1 = npos
  796. lock.R(0)
  797. end
  798. end
  799.  
  800. function Dance()
  801. faketor()
  802. weldall(1)
  803. for _,v in pairs({{0,1,.2},{1,0,-.2}}) do
  804. for i = v[1],v[2],v[3] do
  805. rweld.C1 = cfn()*ang(0,M.D(90*i),0)
  806. rw.C1 = normposr*cfn(-.3*i,.4*i,0)*ang(0,0,M.D(120*i))
  807. lw.C1 = normposl*cfn(.3*i,0,0)*ang(0,0,M.D(-50*i))
  808. wait()
  809. end
  810. end
  811. for _,v in pairs({{0,1,.2},{1,0,-.2}}) do
  812. for i = v[1],v[2],v[3] do
  813. rweld.C1 = cfn()*ang(0,M.D(-90*i),0)
  814. lw.C1 = normposl*cfn(.3*i,0,0)*ang(0,0,M.D(-120*i))
  815. rw.C1 = normposr*cfn(-.3*i,.4*i,0)*ang(0,0,M.D(50*i))
  816. wait()
  817. end
  818. end
  819. faketor()
  820. weldall(0)
  821. end
  822. charge = 0
  823. function Rasengan()
  824. lock.R(1) lock.L(1)
  825. for i = 0,1,.1 do
  826. rw.C1 = normposr*cfn(-.2*i,0,-.3*i)*ang(M.D(90*i),0,M.D(-40*i))
  827. lw.C1 = normposl*cfn(.2*i,0,-.3*i)*ang(M.D(90*i),0,M.D(40*i))
  828. wait()
  829. end
  830. local brick = T.P(1,1,1,'Deep blue',.5,false,false)
  831. local wld = T.W(brick,larm,0,-1.5,0,0,0,0)
  832. local msh = T.FM(brick,'sphere',1,1,1)
  833. holding = true
  834. T.C(function() while holding do spaas(brick.Position,1,3,5,'New Yeller') wait(.3) end end)
  835. while holding do
  836. if charge < 5 then
  837. charge = charge+1
  838. msh.Scale = v3n(charge,charge,charge)
  839. else break
  840. end
  841. wait(.5)
  842. end
  843. for i = 1,-.5,-.1 do
  844. rw.C1 = normposr*cfn(-.2*i,0,-.3*i)*ang(M.D(90*i),0,M.D(-40*i))
  845. lw.C1 = normposl*cfn(.2*i,0,-.3*i)*ang(M.D(90*i),0,M.D(40*i))
  846. wait()
  847. end
  848. char.Humanoid.WalkSpeed = 100
  849. wait(1)
  850. for i = -.5,0,1/5 do
  851. rw.C1 = normposr*cfn(-.2*i,0,-.3*i)*ang(M.D(90*i),0,M.D(-40*i))
  852. lw.C1 = normposl*cfn(.2*i,0,-.3*i)*ang(M.D(90*i),0,M.D(40*i))
  853. wait()
  854. end
  855. for i = 0,1,1/5 do
  856. lw.C1 = normposl*ang(M.D(90*i),0,0)
  857. wait()
  858. end
  859. char.Humanoid.WalkSpeed = 16
  860. wld:Remove()
  861. brick.Anchored = true
  862. msh.MeshId = "rbxassetid://"..meshids['spikeb']
  863. local cha = charge
  864. T.C(function()
  865. for i = 0,70,2 do
  866. msh.Scale = v3n(cha+i/2,cha+i/2,cha+i/2)
  867. brick.Transparency = i/70
  868. wait()
  869. end
  870. brick:Remove()
  871. end)
  872. charge = 0
  873. lock.R(0) lock.L(0)
  874. end
  875.  
  876. ---GUIS---
  877. udim = function(a,b) return UDim2.new(a,0,b,0) end
  878.  
  879. beans,bar = 3,0
  880. pcall(function() ply.PlayerGui.lol:Remove() end)
  881. gui = Instance.new("ScreenGui",ply.PlayerGui)
  882. gui.Name = 'lol'
  883. mainframe = genNew('Frame',gui,{
  884. Size = udim(.1,.1);
  885. Position = udim(0,.5);})
  886. sensuframe = genNew('Frame',mainframe,{
  887. Size = udim(.7,1);
  888. Position = udim(0,0);})
  889. refillframe = genNew('Frame',mainframe,{
  890. Size = udim(.3,1);
  891. Position = udim(.7,0);})
  892.  
  893. function update(a) fr,huh,o = _,_,_
  894. if a == 'Beans' then o = 1/3 image = 'http://www.roblox.com/asset/?id=84570235' fr = sensuframe color = 'White' huh = beans tran = 1
  895. elseif a == 'Bar' then o = 1/5 image = '' fr = refillframe color = 'New Yeller' huh = bar tran = 0 end
  896. fr:ClearAllChildren()
  897. for i = 1-tran,huh do
  898. but = genNew('ImageLabel',fr,{
  899. Size = udim(o,1);
  900. Position = udim(o*(-1+i),0);
  901. Image = image;
  902. BackgroundTransparency = tran;
  903. BackgroundColor = BrickColor.new(color);
  904. })
  905. end
  906. end
  907. update('Beans')
  908. -----------
  909. sitbp = nil
  910. function sit()
  911. if not sitbp then
  912. lock.R(2) lock.L(2)
  913. sitbp = T.BP(torso,torso.Position)
  914. for i = 0,1,.1 do
  915. wait()
  916. rhw.C1 = normposr2*ang(M.D(90*i),0,M.D(-30*i))
  917. lhw.C1 = normposl2*ang(M.D(90*i),0,M.D(30*i))
  918. sitbp.position = torso.Position - v3n(0,.9*i,0)
  919. end
  920. elseif sitbp then
  921. for i = 1,0,-.1 do
  922. wait()
  923. rhw.C1 = normposr2*ang(M.D(90*i),0,M.D(-30*i))
  924. lhw.C1 = normposl2*ang(M.D(90*i),0,M.D(30*i))
  925. sitbp.position = torso.Position - v3n(0,.9*i,0)
  926. end
  927. lock.R(-1) lock.L(-1)
  928. sitbp:Remove() sitbp = nil
  929. end
  930. end
  931.  
  932. function Eat()
  933. if beans > 0 then
  934. lock.R(1)
  935. for i = 0,1,.1 do
  936. rw.C1 = normposr*ang(M.D(120*i),0,M.D(-40*i))
  937. wait()
  938. end
  939. T.S('crunch',1)
  940. beans = beans-1 update('Beans')
  941. hum = FindHumanoid(char,'')
  942. hum.Health = hum.MaxHealth
  943. for i = 1,0,-.1 do
  944. rw.C1 = normposr*ang(M.D(120*i),0,M.D(-40*i))
  945. wait()
  946. end
  947. lock.R(0)
  948. else
  949. sit()
  950. speak('Refilling','Green')
  951. while beans < 3 do for i = 1,5 do bar = i update('Bar') wait(1) end beans=beans+1 update('Beans') bar = 0 end
  952. bar = 0 refillframe:ClearAllChildren()
  953. sit()
  954. end
  955. end
  956.  
  957. klist = {
  958. {'r',function() if sword then Release() else Equip() end end};
  959. {'t',function(a) earthdragon(a) end,''};
  960. {'q',function() Punches() end};
  961. {'e',function() Kick() end};
  962. {'f',function() SwordOut() end};
  963. {'c',function() Rasengan() end,''};
  964. {'z',function() Eat() end};
  965. {'g',function() if sword then Grab() else Dance() end end};
  966. {'j',function() Exorcism() end};
  967. }
  968.  
  969. onButton1Down = function(mouse)
  970. if sword then
  971. Slash()
  972. else
  973. Fly(mouse)
  974. end
  975. end
  976.  
  977. hop.Deselected:connect(function() lock.R(0) lock.L(0) end)
  978. hop.Selected:connect(function(mouse)
  979. mouse.Button1Up:connect(function() holding = false end)
  980. mouse.KeyUp:connect(function(a) for i,v in pairs(klist) do if a == v[1] and v[3] ~= nil then holding = false end end end)
  981. mouse.KeyDown:connect(function(key)
  982. if attacking then return end
  983. for i,v in pairs(klist) do
  984. if key == v[1] then attacking = true v[2](mouse) attacking = false end
  985. end
  986. end)
  987. mouse.Button1Down:connect(function() if attacking then return end attacking = true onButton1Down(mouse) attacking = false end)
  988. end)
  989. --mediafire
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement