Advertisement
-----------------

cube fighter fe maybe

Jan 22nd, 2021
206
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 67.84 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,game,owner = owner,game
  4. local RealPlayer = Player
  5. do
  6. print("FE Compatibility code V2 by Mokiros")
  7. local RealPlayer = RealPlayer
  8. script.Parent = RealPlayer.Character
  9.  
  10. --Fake event to make stuff like Mouse.KeyDown work
  11. local Disconnect_Function = function(this)
  12. this[1].Functions[this[2]] = nil
  13. end
  14. local Disconnect_Metatable = {__index={disconnect=Disconnect_Function,Disconnect=Disconnect_Function}}
  15. local FakeEvent_Metatable = {__index={
  16. Connect = function(this,f)
  17. local i = tostring(math.random(0,10000))
  18. while this.Functions[i] do
  19. i = tostring(math.random(0,10000))
  20. end
  21. this.Functions[i] = f
  22. return setmetatable({this,i},Disconnect_Metatable)
  23. end
  24. }}
  25. FakeEvent_Metatable.__index.connect = FakeEvent_Metatable.__index.Connect
  26. local function fakeEvent()
  27. return setmetatable({Functions={}},FakeEvent_Metatable)
  28. end
  29.  
  30. --Creating fake input objects with fake variables
  31. local FakeMouse = {Hit=CFrame.new(),KeyUp=fakeEvent(),KeyDown=fakeEvent(),Button1Up=fakeEvent(),Button1Down=fakeEvent(),Button2Up=fakeEvent(),Button2Down=fakeEvent()}
  32. FakeMouse.keyUp = FakeMouse.KeyUp
  33. FakeMouse.keyDown = FakeMouse.KeyDown
  34. local UIS = {InputBegan=fakeEvent(),InputEnded=fakeEvent()}
  35. local CAS = {Actions={},BindAction=function(self,name,fun,touch,...)
  36. CAS.Actions[name] = fun and {Name=name,Function=fun,Keys={...}} or nil
  37. end}
  38. --Merged 2 functions into one by checking amount of arguments
  39. CAS.UnbindAction = CAS.BindAction
  40.  
  41. --This function will trigger the events that have been :Connect()'ed
  42. local function TriggerEvent(self,ev,...)
  43. for _,f in pairs(self[ev].Functions) do
  44. f(...)
  45. end
  46. end
  47. FakeMouse.TriggerEvent = TriggerEvent
  48. UIS.TriggerEvent = TriggerEvent
  49.  
  50. --Client communication
  51. local Event = Instance.new("RemoteEvent")
  52. Event.Name = "UserInput_Event"
  53. Event.OnServerEvent:Connect(function(plr,io)
  54. if plr~=RealPlayer then return end
  55. FakeMouse.Target = io.Target
  56. FakeMouse.Hit = io.Hit
  57. if not io.isMouse then
  58. local b = io.UserInputState == Enum.UserInputState.Begin
  59. if io.UserInputType == Enum.UserInputType.MouseButton1 then
  60. return FakeMouse:TriggerEvent(b and "Button1Down" or "Button1Up")
  61. end
  62. if io.UserInputType == Enum.UserInputType.MouseButton2 then
  63. return FakeMouse:TriggerEvent(b and "Button2Down" or "Button2Up")
  64. end
  65. for _,t in pairs(CAS.Actions) do
  66. for _,k in pairs(t.Keys) do
  67. if k==io.KeyCode then
  68. t.Function(t.Name,io.UserInputState,io)
  69. end
  70. end
  71. end
  72. FakeMouse:TriggerEvent(b and "KeyDown" or "KeyUp",io.KeyCode.Name:lower())
  73. UIS:TriggerEvent(b and "InputBegan" or "InputEnded",io,false)
  74. end
  75. end)
  76. Event.Parent = NLS([==[local Event = script:WaitForChild("UserInput_Event")
  77. local Mouse = owner:GetMouse()
  78. local UIS = game:GetService("UserInputService")
  79. local input = function(io,RobloxHandled)
  80. if RobloxHandled then return end
  81. --Since InputObject is a client-side instance, we create and pass table instead
  82. Event:FireServer({KeyCode=io.KeyCode,UserInputType=io.UserInputType,UserInputState=io.UserInputState,Hit=Mouse.Hit,Target=Mouse.Target})
  83. end
  84. UIS.InputBegan:Connect(input)
  85. UIS.InputEnded:Connect(input)
  86.  
  87. local h,t
  88. --Give the server mouse data every second frame, but only if the values changed
  89. --If player is not moving their mouse, client won't fire events
  90. local HB = game:GetService("RunService").Heartbeat
  91. while true do
  92. if h~=Mouse.Hit or t~=Mouse.Target then
  93. h,t=Mouse.Hit,Mouse.Target
  94. Event:FireServer({isMouse=true,Target=t,Hit=h})
  95. end
  96. --Wait 2 frames
  97. for i=1,2 do
  98. HB:Wait()
  99. end
  100. end]==],script)
  101.  
  102. ----Sandboxed game object that allows the usage of client-side methods and services
  103. --Real game object
  104. local RealGame = game
  105.  
  106. --Metatable for fake service
  107. local FakeService_Metatable = {
  108. __index = function(self,k)
  109. local s = rawget(self,"_RealService")
  110. if s then
  111. return typeof(s[k])=="function"
  112. and function(_,...)return s[k](s,...)end or s[k]
  113. end
  114. end,
  115. __newindex = function(self,k,v)
  116. local s = rawget(self,"_RealService")
  117. if s then s[k]=v end
  118. end
  119. }
  120. local function FakeService(t,RealService)
  121. t._RealService = typeof(RealService)=="string" and RealGame:GetService(RealService) or RealService
  122. return setmetatable(t,FakeService_Metatable)
  123. end
  124.  
  125. --Fake game object
  126. local FakeGame = {
  127. GetService = function(self,s)
  128. return rawget(self,s) or RealGame:GetService(s)
  129. end,
  130. Players = FakeService({
  131. LocalPlayer = FakeService({GetMouse=function(self)return FakeMouse end},Player)
  132. },"Players"),
  133. UserInputService = FakeService(UIS,"UserInputService"),
  134. ContextActionService = FakeService(CAS,"ContextActionService"),
  135. RunService = FakeService({
  136. _btrs = {},
  137. RenderStepped = RealGame:GetService("RunService").Heartbeat,
  138. BindToRenderStep = function(self,name,_,fun)
  139. self._btrs[name] = self.Heartbeat:Connect(fun)
  140. end,
  141. UnbindFromRenderStep = function(self,name)
  142. self._btrs[name]:Disconnect()
  143. end,
  144. },"RunService")
  145. }
  146. rawset(FakeGame.Players,"localPlayer",FakeGame.Players.LocalPlayer)
  147. FakeGame.service = FakeGame.GetService
  148. FakeService(FakeGame,game)
  149. --Changing owner to fake player object to support owner:GetMouse()
  150. game,owner = FakeGame,FakeGame.Players.LocalPlayer
  151. end
  152. --script.Parent = nil
  153.  
  154. local StayWhenReset = false
  155.  
  156. local PassCode = string.char(67, 65, 80, 83)
  157.  
  158. local Workspace = game:GetService("Workspace")
  159. local Players = game:GetService("Players")
  160.  
  161. local Me = Players.LocalPlayer
  162. local Char = Me.Character
  163. local Mouse = Me:GetMouse()
  164. local Camera = game:GetService("Workspace").CurrentCamera
  165.  
  166. local Changed = 0
  167. local CurrentPos = nil
  168. local Alive = true
  169.  
  170. local ResetVersion = 1
  171.  
  172. local Type = "Mouse"
  173.  
  174. local Config = {
  175. Shape = "Block";
  176. Color = "Really red";
  177. Material = "Plastic";
  178. }
  179.  
  180. function Explode(Part, Effect)
  181. local BOOM = Instance.new("Explosion", Part)
  182. BOOM.Position = Part.Position
  183. if Effect == true then
  184. BOOM.BlastPressure = 100
  185. BOOM.BlastRadius = 25
  186. else
  187. BOOM.BlastPressure = 0
  188. BOOM.BlastRadius = 0
  189. end
  190. BOOM.Hit:connect(function(Object)
  191. if Effect == true then
  192. if Object:IsA("BasePart") and Object.Name ~= "Base" and Object.Name ~= "Baseplate" and Object.Name ~= "Bomb" and Object.Name ~= "Nuke" then
  193. Object:BreakJoints()
  194. Object.Anchored = false
  195. end
  196. end
  197. end)
  198. end
  199.  
  200. function DoAll()
  201. local ThisResetVersion = ResetVersion
  202.  
  203. local P1 = nil
  204. local P2 = nil
  205.  
  206. local Firing = false
  207.  
  208. function MakeObjects(Position, ...)
  209. local OtherArgs = {...}
  210. CurrentPos = Position
  211.  
  212. Changed = Changed + 1
  213. wait()
  214. local Version = Changed
  215.  
  216. local CharacterSwitch = nil
  217. local TargetObject = nil
  218.  
  219. if P1 == nil and P2 == nil then
  220. P1 = Instance.new("Part", Char)
  221. P1.Name = "P1"
  222. P1.Size = Vector3.new(1,1,1)
  223. P1.Shape = Config.Shape
  224. P1.BrickColor = BrickColor.new(Config.Color)
  225. P1.Material = Config.Material
  226. P1.TopSurface = "Smooth"
  227. P1.BottomSurface = "Smooth"
  228. P1.Position = Char.Torso.Position
  229. P1.CanCollide = false
  230. local BP = Instance.new("BodyPosition", P1)
  231. BP.maxForce = Vector3.new(math.huge, math.huge, math.huge)
  232. BP.position = Char.Torso.Position
  233. BP.Name = "BP"
  234. local BG = Instance.new("BodyGyro", P1)
  235. BG.maxTorque = Vector3.new(math.huge, math.huge, math.huge)
  236. BG.Name = "BG"
  237.  
  238. P2 = P1:Clone()
  239. P2.Parent = Char
  240.  
  241. P1:BreakJoints()
  242. P2:BreakJoints()
  243. wait()
  244. end
  245.  
  246. Mouse.Button1Down:connect(function()
  247. if Changed == Version and Char ~= nil and ResetVersion == ThisResetVersion then
  248. if Position == "Side" or Position == "Up" then
  249. local Sound = Instance.new("Sound", Char.Head)
  250. Sound.Name = "Pew"
  251. Sound.Volume = 1
  252. Sound.Pitch = 1
  253. Sound.SoundId = "http://www.roblox.com/asset/?id=10756104"
  254. local Sound2 = Instance.new("Sound", Char.Head)
  255. Sound2.Name = "Pew"
  256. Sound2.Volume = 5
  257. Sound2.Pitch = 3
  258. Sound2.SoundId = "http://www.roblox.com/asset/?id=10756118"
  259. local Place0 = CFrame.new(P1.CFrame.x, P1.CFrame.y, P1.CFrame.z)
  260. local Place1 = Mouse.Hit.p
  261. local Place2 = CFrame.new(P2.CFrame.x, P2.CFrame.y, P2.CFrame.z)
  262.  
  263. local Part1 = Instance.new("Part")
  264. Part1.Parent = P1
  265. Part1.Name = "Laser 1"
  266. Part1.Position = Vector3.new(0, 0, 0)
  267. Part1.Size = Vector3.new(math.random(0.5,1.31),math.random(0.5,1.31),math.random(0.5,1.31))
  268. Part1.CFrame = CFrame.new((Place0.p + Place1) / 2, Place0.p)
  269. Part1.BrickColor = BrickColor.new(Config.Color) -- Leave this be, or change it to a color available on ROBLOX.
  270. Part1.Locked = true
  271. Part1.Anchored = true
  272. Part1.CanCollide = false
  273. Part1.BottomSurface = "Smooth"
  274. Part1.TopSurface = "Smooth"
  275.  
  276. local Part2 = Instance.new("Part")
  277. Part2.Parent = P2
  278. Part2.Name = "Laser 2"
  279. Part2.Position = Vector3.new(0, 0, 0)
  280. Part2.Size = Vector3.new(math.random(0.5,1.31),math.random(0.5,1.31),math.random(0.5,1.31))
  281. Part2.CFrame = CFrame.new((Place2.p + Place1) / 2, Place2.p)
  282. Part2.BrickColor = BrickColor.new(Config.Color) -- Leave this be, or change it to a color available on ROBLOX.
  283. Part2.Locked = true
  284. Part2.Anchored = true
  285. Part2.CanCollide = false
  286. Part2.BottomSurface = "Smooth"
  287. Part2.TopSurface = "Smooth"
  288.  
  289. local BlockMesh1 = Instance.new("BlockMesh")
  290. BlockMesh1.Parent = Part1
  291. BlockMesh1.Scale = Vector3.new(0.08, 0.08, (Place0.p - Place1).magnitude)
  292.  
  293. local BlockMesh2 = Instance.new("BlockMesh")
  294. BlockMesh2.Parent = Part2
  295. BlockMesh2.Scale = Vector3.new(0.08, 0.08, (Place2.p - Place1).magnitude)
  296.  
  297. wait()
  298. Sound:Play()
  299. wait()
  300. Sound:Destroy()
  301.  
  302. coroutine.wrap(function()
  303. for i = 1,math.huge do
  304. Place0 = CFrame.new(P1.CFrame.x, P1.CFrame.y, P1.CFrame.z)
  305. Place2 = CFrame.new(P2.CFrame.x, P2.CFrame.y, P2.CFrame.z)
  306. Part1.CFrame = CFrame.new((Place0.p + Place1) / 2, Place0.p)
  307. Part2.CFrame = CFrame.new((Place2.p + Place1) / 2, Place2.p)
  308. BlockMesh1.Scale = Vector3.new(0.08, 0.08, (Place0.p - Place1).magnitude)
  309. BlockMesh2.Scale = Vector3.new(0.08, 0.08, (Place2.p - Place1).magnitude)
  310. wait()
  311. end
  312. end)()
  313.  
  314. if Mouse.Target ~= nil then
  315. local Humanoid = nil
  316. local Target = Mouse.Target
  317. local TargetColor = Mouse.Target.BrickColor
  318. local TargetPos = Target.CFrame
  319.  
  320. if (Mouse.Target ~= nil) then
  321. TargetHumanoid = Mouse.Target.Parent:findFirstChild("Humanoid")
  322.  
  323. if (TargetHumanoid ~= nil) then
  324. Humanoid = TargetHumanoid
  325. Humanoid.Health = Humanoid.Health - math.random(3,15)
  326. end
  327. end
  328.  
  329. wait(0.4)
  330.  
  331. local function ReMake(Type)
  332. if Target.BrickColor == TargetColor then
  333. Target.BrickColor = BrickColor.new(Config.Color)
  334. else
  335. Target.BrickColor = TargetColor
  336. end
  337.  
  338. if Type == "Single" then
  339. Target:BreakJoints()
  340. Target.Anchored = true
  341. Target.CFrame = TargetPos * CFrame.new(math.random(-2,2),math.random(-2,2),math.random(-2,2))
  342. elseif Type == "Model" and Target.Parent:findFirstChild("Torso") then
  343. Target.Parent:MoveTo(Target.Parent.Torso.Position + Vector3.new(math.random(-2,2),math.random(0,2) + 2.5,math.random(-2,2)))
  344. end
  345. end
  346.  
  347. for i = 1,10 do
  348. Sound2:Play()
  349. if (Humanoid ~= nil) then
  350. Humanoid.Health = Humanoid.Health - math.random(1,3)
  351. ReMake("Model")
  352. else
  353. if Target.Name ~= "Base" and Target.Name ~= "Baseplate" then
  354. ReMake("Single")
  355. end
  356. end
  357. if Part1.Transparency == 1 then
  358. Part1.Transparency = 0
  359. Part2.Transparency = 0
  360. else
  361. Part1.Transparency = 1
  362. Part2.Transparency = 1
  363. end
  364. wait()
  365. end
  366. if (Humanoid ~= nil) then
  367. Target.BrickColor = TargetColor
  368. end
  369. Part2.Transparency = 0
  370. if Target.Name ~= "Base" and Humanoid == nil then
  371. Target:Destroy()
  372. end
  373. end
  374. Sound2:Destroy()
  375.  
  376.  
  377. coroutine.wrap(function()
  378. for i = 1,math.huge do
  379. Part1.Transparency = Part1.Transparency + 0.086
  380. Part2.Transparency = Part2.Transparency + 0.086
  381.  
  382. if (Part1.Transparency > 1) then
  383. Part1:Destroy()
  384. Part2:Destroy()
  385. break
  386. end
  387. wait()
  388. end
  389. end)()
  390. elseif Position == "Cannon" then
  391. if Mouse.Target ~= nil then
  392. local Pos = Mouse.Hit.p
  393. local Bomb = Instance.new("Part", Me.Character)
  394. Bomb.Name = "Bomb"
  395. Bomb.Position = Char.Torso.CFrame:toWorldSpace(CFrame.new(0,4,2)).p
  396. Bomb.Size = Vector3.new(2,2,2)
  397. Bomb.TopSurface = "Smooth"
  398. Bomb.BottomSurface = "Smooth"
  399. Bomb.BrickColor = BrickColor.new(Config.Color)
  400. Bomb.Shape = "Ball"
  401. Bomb.CanCollide = false
  402. local Sound = Instance.new("Sound",Bomb)
  403. Sound.Name = "BombSound"
  404. Sound.Volume = 1
  405. Sound.Pitch = math.random(90,300)/100
  406. Sound.SoundId = "http://www.roblox.com/asset/?id=2233908"
  407. wait()
  408. Sound:Play()
  409. local BP2 = Instance.new("BodyPosition", Bomb)
  410. BP2.maxForce = Vector3.new(math.huge, math.huge, math.huge)
  411. BP2.position = Char.Torso.CFrame:toWorldSpace(CFrame.new(0,4,2)).p
  412. local Fire = Instance.new("Fire", Bomb)
  413. Fire.Size = 10
  414. wait(0.1)
  415. for i = 0,100,10 do
  416. BP2.position = (Char.Torso.CFrame:toWorldSpace(CFrame.new(0,4,2)).p):Lerp(Pos, i/100)
  417. wait(0.05)
  418. end
  419. wait(0.1)
  420. BP2.position = Pos
  421. wait()
  422. Bomb.Anchored = true
  423. BP2:Destroy()
  424. for i = 1,8 do
  425. local Sound2 = Instance.new("Sound", Bomb)
  426. Sound2.Name = "BombSound"
  427. Sound2.Volume = 1
  428. Sound2.Pitch = math.random(226,229)/100
  429. Sound2.SoundId = "http://www.roblox.com/asset/?id=15666462"
  430. Bomb.BrickColor = BrickColor.new("Really red")
  431. wait(0.1)
  432. Bomb.BrickColor = BrickColor.new("Black")
  433. wait(0.1)
  434. Sound2:Play()
  435. end
  436. wait()
  437. local Sound3 = Instance.new("Sound", Bomb)
  438. Sound3.Name = "BombSound"
  439. Sound3.Volume = 1
  440. Sound3.Pitch = math.random(45,105)/100
  441. Sound3.SoundId = "http://www.roblox.com/asset/?id=2248511"
  442. wait()
  443. Sound3:Play()
  444. wait()
  445. Explode(Bomb, true)
  446. wait()
  447. Bomb:Destroy()
  448. end
  449. elseif Position == "Nuke" then
  450. if Mouse.Target ~= nil then
  451. PosHit = Mouse.Hit.p
  452. function NukeIt(Pos, Size, GoTo)
  453. local Nuke = Instance.new("Part", Me.Character)
  454. Nuke.Name = "Nuke"
  455. if GoTo == true then
  456. Nuke.Position = Char.Torso.CFrame:toWorldSpace(CFrame.new(0,4,2)).p
  457. else
  458. Nuke.Position = Pos
  459. end
  460. Nuke.Size = Size
  461. Nuke.TopSurface = "Smooth"
  462. Nuke.BottomSurface = "Smooth"
  463. Nuke.BrickColor = BrickColor.new("Lime ")
  464. Nuke.Shape = "Ball"
  465. Nuke.CanCollide = false
  466. local Sound = Instance.new("Sound",Nuke)
  467. Sound.Name = "NukeSound"
  468. Sound.Volume = 1
  469. Sound.Pitch = 1.5
  470. Sound.SoundId = "http://www.roblox.com/asset/?id=2233908"
  471. wait()
  472. Sound:Play()
  473. local BP2 = Instance.new("BodyPosition", Nuke)
  474. BP2.maxForce = Vector3.new(math.huge, math.huge, math.huge)
  475. if GoTo == true then
  476. BP2.position = Char.Torso.CFrame:toWorldSpace(CFrame.new(0,4,2)).p
  477. else
  478. BP2.position = Pos
  479. end
  480. local Fire = Instance.new("Fire", Nuke)
  481. Fire.Size = 10
  482. wait(0.1)
  483. if GoTo == true then
  484. for i = 0,100,10 do
  485. BP2.position = (Char.Torso.CFrame:toWorldSpace(CFrame.new(0,4,2)).p):Lerp(Pos, i/100)
  486. wait(0.05)
  487. end
  488. wait(0.1)
  489. BP2.position = Pos
  490. wait()
  491. Nuke.Anchored = true
  492. BP2:Destroy()
  493. for i = 1,7 do
  494. local Sound2 = Instance.new("Sound", Nuke)
  495. Sound2.Name = "NukeSound"
  496. Sound2.Volume = 1
  497. Sound2.Pitch = 2.3
  498. Sound2.SoundId = "http://www.roblox.com/asset/?id=15666462"
  499. Nuke.BrickColor = BrickColor.new("Really red")
  500. wait(0.15)
  501. Nuke.BrickColor = BrickColor.new("Lime ")
  502. wait(0.15)
  503. Sound2:Play()
  504. end
  505. TargetObject = nil
  506. wait()
  507. end
  508. local Sound3 = Instance.new("Sound", Nuke)
  509. Sound3.Name = "NukeSound"
  510. Sound3.Volume = 1
  511. Sound3.Pitch = 0.5
  512. Sound3.SoundId = "http://www.roblox.com/asset/?id=2248511"
  513. wait()
  514. Sound3:Play()
  515. wait()
  516. Explode(Nuke, true)
  517. wait()
  518. Nuke:Destroy()
  519. end
  520. end
  521. NukeIt(PosHit, Vector3.new(3,3,3), true)
  522. for i = 1,36 do
  523. coroutine.wrap(function() NukeIt(PosHit + Vector3.new(math.sin(math.rad(i*10))*10,0,math.cos(math.rad(i*10))*10), Vector3.new(1,1,1), false) end)()
  524. wait()
  525. end
  526. elseif Position == "Character Switch" then
  527. local Target = Mouse.Target
  528. pcall(function() TargetObject = game:GetService("Players")[Target.Parent.Name].Character CharacterSwitch = true end)
  529. elseif Position == "Machine Gun" then
  530. Firing = true
  531. while true do
  532. wait(0.05)
  533. if P1 ~= nil and P2 ~= nil then
  534. if Mouse.Target ~= nil then
  535. if Changed == Version then
  536. if Firing == true then
  537. coroutine.wrap(function()
  538. local Pos = Mouse.Hit.p
  539. local CurrentTargetFind = Mouse.Target
  540. local Bullet = Instance.new("Part", Me.Character)
  541. Bullet.Name = "Bullet"
  542. Bullet.Position = Char.Torso.CFrame:toWorldSpace(CFrame.new(0,4,2)).p
  543. Bullet.Size = Vector3.new(1,1,1)
  544. Bullet.TopSurface = "Smooth"
  545. Bullet.BottomSurface = "Smooth"
  546. Bullet.BrickColor = BrickColor.new("New Yeller")
  547. Bullet.Shape = "Ball"
  548. Bullet.CanCollide = false
  549. local BulletMesh = Instance.new("SpecialMesh", Bullet)
  550. BulletMesh.MeshType = "Sphere"
  551. BulletMesh.Scale = Vector3.new(0.1,0.1,0.1)
  552. local Sound = Instance.new("Sound",Bullet)
  553. Sound.Name = "Shot"
  554. Sound.Volume = 0.6
  555. Sound.Pitch = 3
  556. Sound.SoundId = "http://roblox.com/asset/?id=10209842"
  557. wait()
  558. Sound:Play()
  559. local BP2 = Instance.new("BodyPosition", Bullet)
  560. BP2.maxForce = Vector3.new(math.huge, math.huge, math.huge)
  561. BP2.position = Char.Torso.CFrame:toWorldSpace(CFrame.new(0,4,2)).p
  562. wait(0.05)
  563. for i = 0,100,20 do
  564. BP2.position = (Char.Torso.CFrame:toWorldSpace(CFrame.new(0,4,2)).p):Lerp(Pos, i/100)
  565. wait(0.05)
  566. end
  567. wait(0.1)
  568. BP2.position = Pos
  569. wait()
  570. Bullet:Destroy()
  571.  
  572. TargetHumanoid = CurrentTargetFind.Parent:findFirstChild("Humanoid")
  573.  
  574. if TargetHumanoid ~= nil then
  575. TargetHumanoid.Health = TargetHumanoid.Health - math.random(3,15)
  576. end
  577. end)()
  578. else
  579. break
  580. end
  581. else
  582. break
  583. end
  584. end
  585. end
  586. end
  587. end
  588. end
  589. end)
  590.  
  591.  
  592. Mouse.Button1Up:connect(function()
  593. Firing = false
  594. end)
  595.  
  596.  
  597. coroutine.wrap(function()
  598. for TimeLoop = 0,math.huge do
  599. wait()
  600. if Changed == Version and Char ~= nil then
  601. if Type == "Mouse" then
  602. P1.BG.cframe = Mouse.Hit
  603. P2.BG.cframe = Mouse.Hit
  604. elseif Type == "Camera" then
  605. P1.BG.cframe = Camera.CoordinateFrame
  606. P2.BG.cframe = Camera.CoordinateFrame
  607. elseif Type == "Both" then
  608. P1.BG.cframe = Camera.CoordinateFrame*Mouse.Hit
  609. P2.BG.cframe = Camera.CoordinateFrame*Mouse.Hit
  610. end
  611. if Position == "Right" then
  612. P1.BP.position = Char.Torso.CFrame:toWorldSpace(CFrame.new(3,1,-1)).p
  613. P2.BP.position = Char.Torso.CFrame:toWorldSpace(CFrame.new(4.5,1,-1)).p
  614. elseif Position == "Left" then
  615. P1.BP.position = Char.Torso.CFrame:toWorldSpace(CFrame.new(-4.5,1,-1)).p
  616. P2.BP.position = Char.Torso.CFrame:toWorldSpace(CFrame.new(-3,1,-1)).p
  617. elseif Position == "Side" then
  618. P1.BP.position = Char.Torso.CFrame:toWorldSpace(CFrame.new(-1.5,1.6,-0.1)).p
  619. P2.BP.position = Char.Torso.CFrame:toWorldSpace(CFrame.new(1.5,1.6,-0.1)).p
  620. elseif Position == "Up" then
  621. P1.BP.position = Char.Torso.CFrame:toWorldSpace(CFrame.new(0,4,0)).p
  622. P2.BP.position = Char.Torso.CFrame:toWorldSpace(CFrame.new(0,5.5,0)).p
  623. elseif Position == "Circle" then
  624. for i = 0,360,3 do
  625. if Changed == Version then
  626. if Type == "Mouse" then
  627. P1.BG.cframe = Mouse.Hit
  628. P2.BG.cframe = Mouse.Hit
  629. elseif Type == "Camera" then
  630. P1.BG.cframe = Camera.CoordinateFrame
  631. P2.BG.cframe = Camera.CoordinateFrame
  632. elseif Type == "Both" then
  633. P1.BG.cframe = Camera.CoordinateFrame*Mouse.Hit
  634. P2.BG.cframe = Camera.CoordinateFrame*Mouse.Hit
  635. end
  636. P1.BP.position = Char.Torso.CFrame:toWorldSpace(CFrame.new(math.sin(math.rad(i))*3,1.5,math.cos(math.rad(i))*3)).p
  637. P2.BP.position = Char.Torso.CFrame:toWorldSpace(CFrame.new(math.sin(math.rad(i+180))*3,1.5,math.cos(math.rad(i+180))*3)).p
  638. wait()
  639. else
  640. break
  641. end
  642. end
  643. elseif Position == "Mouse" then
  644. pcall(function()
  645. if Mouse.Target ~= nil then
  646. P1.BP.position = Mouse.Hit:toWorldSpace(CFrame.new(0,1.5,0)).p
  647. P2.BP.position = Mouse.Hit:toWorldSpace(CFrame.new(0,3,0)).p
  648. end
  649. end)
  650. elseif Position == "Teleport" then
  651. if Mouse.Target ~= nil then
  652. for _,Things in pairs(Char.Torso:GetChildren()) do
  653. if Things.className == "BodyPosition" or Things.className == "BodyGyro" then Things:remove() end
  654. end
  655. local BP2 = Instance.new("BodyPosition", Char.Torso)
  656. BP2.Name = "Troll Position"
  657. BP2.maxForce = Vector3.new(math.huge, math.huge, math.huge)
  658. local BG2 = Instance.new("BodyGyro", Char.Torso)
  659. BG2.Name = "Troll Position"
  660. BG2.maxTorque = Vector3.new(math.huge, math.huge, math.huge)
  661. local Position = Mouse.Hit.p
  662. BG2.cframe = Mouse.Hit
  663. BP2.position = Char.Torso.Position + Vector3.new(0,15,0)
  664. P1.BP.position = Char.Torso.CFrame:toWorldSpace(CFrame.new(0,4,0)).p
  665. P2.BP.position = Mouse.Hit:toWorldSpace(CFrame.new(0,1.5,0)).p
  666. wait(0.5)
  667. BP2.position = Position + Vector3.new(0,10,0)
  668. wait(0.5)
  669. BP2.position = Position + Vector3.new(0,5,0)
  670. MakeObjects("Side")
  671. wait()
  672. BP2.position = Position + Vector3.new(0,3,0)
  673. wait()
  674. BG2:remove()
  675. wait(1)
  676. BP2:remove()
  677. end
  678. elseif Position == "Cannon" then
  679. P1.BP.position = Char.Torso.CFrame:toWorldSpace(CFrame.new(0,4,0)).p
  680. P2.BP.position = P1.CFrame:toWorldSpace(CFrame.new(0,0,1.5)).p
  681. elseif Position == "Nuke" then
  682. P1.BP.position = Char.Torso.CFrame:toWorldSpace(CFrame.new(0,4,-0.5)).p
  683. P2.BP.position = P1.CFrame:toWorldSpace(CFrame.new(0,0,2.5)).p
  684. elseif Position == "Loop" then
  685. for i = 0,360,3 do
  686. if Changed == Version then
  687. if Type == "Mouse" then
  688. P1.BG.cframe = Mouse.Hit
  689. P2.BG.cframe = Mouse.Hit
  690. elseif Type == "Camera" then
  691. P1.BG.cframe = Camera.CoordinateFrame
  692. P2.BG.cframe = Camera.CoordinateFrame
  693. elseif Type == "Both" then
  694. P1.BG.cframe = Camera.CoordinateFrame*Mouse.Hit
  695. P2.BG.cframe = Camera.CoordinateFrame*Mouse.Hit
  696. end
  697. P1.BP.position = Char.Torso.CFrame:toWorldSpace(CFrame.new(0,math.sin(math.rad(i))*3,math.cos(math.rad(i))*3)).p
  698. P2.BP.position = Char.Torso.CFrame:toWorldSpace(CFrame.new(0,math.sin(math.rad(i+180))*3,math.cos(math.rad(i+180))*3)).p
  699. wait()
  700. else
  701. break
  702. end
  703. end
  704. elseif Position == "Character Switch" then
  705. local Sound = Instance.new("Sound", Char.Torso)
  706. Sound.Name = "Rev"
  707. Sound.Volume = 0.5
  708. Sound.Pitch = 1
  709. Sound.SoundId = "http://roblox.com/asset/?id=10209788"
  710. wait()
  711. Sound:Play()
  712. wait()
  713. Sound:Destroy()
  714. local SwitchLock = 0
  715. for i = 0,math.huge,15 do
  716. if Changed == Version then
  717. if CharacterSwitch == true then
  718. CharacterSwitch = false
  719. local TargetPlayer = game:GetService("Players")[TargetObject.Name]
  720. local Fire1 = Instance.new("Fire", P1)
  721. Fire1.Color = Color3.new(0.5,1,0.5)
  722. Fire1.SecondaryColor = Color3.new(0,0,1)
  723. Fire1.Heat = 0
  724. Fire1.Size = 3
  725. local Fire2 = Instance.new("Fire", P2)
  726. Fire2.Color = Color3.new(0.5,1,0.5)
  727. Fire2.SecondaryColor = Color3.new(0,0,1)
  728. Fire2.Heat = 0
  729. Fire2.Size = 3
  730. local Sound = Instance.new("Sound", Char.Torso)
  731. Sound.Name = "Zap"
  732. Sound.Volume = 1
  733. Sound.Pitch = 1
  734. Sound.SoundId = "http://roblox.com/asset/?id=10209653"
  735. wait()
  736. Sound:Play()
  737. wait()
  738. Sound:Destroy()
  739. Char.Archivable = true
  740. local MyApp = Me.CharacterAppearance
  741. Me.CharacterAppearance = "http://www.roblox.com/Asset/CharacterFetch.ashx?userId="..TargetPlayer.userId
  742. TargetPlayer.CharacterAppearance = MyApp
  743. wait()
  744. local CharClone = Char:Clone()
  745. wait()
  746. for _,Get in pairs(Char:GetChildren()) do
  747. if Get:IsA("CharacterMesh") or Get:IsA("Shirt") or Get:IsA("ShirtGraphic") or Get:IsA("Pants") or Get:IsA("Hat") then
  748. Get:Destroy()
  749. end
  750. end
  751. wait()
  752. for _,Get in pairs(TargetObject:GetChildren()) do
  753. if Get:IsA("CharacterMesh") or Get:IsA("Shirt") or Get:IsA("ShirtGraphic") or Get:IsA("Pants") or Get:IsA("Hat") then
  754. local NewClone = Get:Clone()
  755. NewClone.Parent = Char
  756. end
  757. end
  758. Char["Body Colors"].LeftArmColor = TargetObject["Body Colors"].LeftArmColor
  759. Char["Body Colors"].RightArmColor = TargetObject["Body Colors"].LeftArmColor
  760. Char["Body Colors"].LeftLegColor = TargetObject["Body Colors"].LeftLegColor
  761. Char["Body Colors"].RightLegColor = TargetObject["Body Colors"].RightLegColor
  762. Char["Body Colors"].TorsoColor = TargetObject["Body Colors"].TorsoColor
  763. Char["Body Colors"].HeadColor = TargetObject["Body Colors"].HeadColor
  764. Char.Torso.roblox.Texture = TargetObject.Torso.roblox.Texture
  765. Char.Head.face.Texture = TargetObject.Head.face.Texture
  766. wait()
  767.  
  768. for _,Get in pairs(TargetObject:GetChildren()) do
  769. if Get:IsA("CharacterMesh") or Get:IsA("Shirt") or Get:IsA("ShirtGraphic") or Get:IsA("Pants") or Get:IsA("Hat") then
  770. Get:Destroy()
  771. end
  772. end
  773. wait()
  774. for _,Get in pairs(CharClone:GetChildren()) do
  775. if Get:IsA("CharacterMesh") or Get:IsA("Shirt") or Get:IsA("ShirtGraphic") or Get:IsA("Pants") or Get:IsA("Hat") then
  776. local NewClone = Get:Clone()
  777. NewClone.Parent = TargetObject
  778. end
  779. end
  780. TargetObject["Body Colors"].LeftArmColor = CharClone["Body Colors"].LeftArmColor
  781. TargetObject["Body Colors"].RightArmColor = CharClone["Body Colors"].RightArmColor
  782. TargetObject["Body Colors"].LeftLegColor = CharClone["Body Colors"].LeftLegColor
  783. TargetObject["Body Colors"].RightLegColor = CharClone["Body Colors"].RightLegColor
  784. TargetObject["Body Colors"].TorsoColor = CharClone["Body Colors"].TorsoColor
  785. TargetObject["Body Colors"].HeadColor = CharClone["Body Colors"].HeadColor
  786. TargetObject.Torso.roblox.Texture = CharClone.Torso.roblox.Texture
  787. TargetObject.Head.face.Texture = CharClone.Head.face.Texture
  788.  
  789. wait(0.5)
  790. for i = 0,7 do
  791. Fire1.Parent = nil
  792. Fire2.Parent = nil
  793. wait(0.1)
  794. Fire1.Parent = P1
  795. Fire2.Parent = P2
  796. wait(0.1)
  797. end
  798. Fire1:Destroy()
  799. Fire2:Destroy()
  800. local Sound = Instance.new("Sound", Char.Torso)
  801. Sound.Name = "Rev"
  802. Sound.Volume = 0.5
  803. Sound.Pitch = 1
  804. Sound.SoundId = "http://roblox.com/asset/?id=10209788"
  805. wait()
  806. Sound:Play()
  807. wait()
  808. Sound:Destroy()
  809. end
  810. if SwitchLock ~= 12 then
  811. SwitchLock = SwitchLock + 1
  812. else
  813. SwitchLock = 0
  814. local Sound = Instance.new("Sound", Char.Torso)
  815. Sound.Name = "Spin"
  816. Sound.Volume = 0.5
  817. Sound.Pitch = 1
  818. Sound.SoundId = "http://roblox.com/asset/?id=10209780"
  819. wait()
  820. Sound:Play()
  821. wait()
  822. Sound:Destroy()
  823. end
  824. if Type == "Mouse" then
  825. P1.BG.cframe = Mouse.Hit
  826. P2.BG.cframe = Mouse.Hit
  827. elseif Type == "Camera" then
  828. P1.BG.cframe = Camera.CoordinateFrame
  829. P2.BG.cframe = Camera.CoordinateFrame
  830. elseif Type == "Both" then
  831. P1.BG.cframe = Camera.CoordinateFrame*Mouse.Hit
  832. P2.BG.cframe = Camera.CoordinateFrame*Mouse.Hit
  833. end
  834. P1.BP.position = Char.Torso.CFrame:toWorldSpace(CFrame.new(math.sin(math.rad(i))*2,1.5,math.cos(math.rad(i))*2)).p
  835. P2.BP.position = Char.Torso.CFrame:toWorldSpace(CFrame.new(math.sin(math.rad(i+180))*2,1.5,math.cos(math.rad(i+180))*2)).p
  836. wait()
  837. else
  838. local Sound = Instance.new("Sound", Char.Torso)
  839. Sound.Name = "Stop"
  840. Sound.Volume = 0.5
  841. Sound.Pitch = 1
  842. Sound.SoundId = "http://roblox.com/asset/?id=10209786"
  843. wait()
  844. Sound:Play()
  845. wait()
  846. Sound:Destroy()
  847. break
  848. end
  849. end
  850. elseif Position == "Machine Gun" then
  851. P1.BP.position = Char.Torso.CFrame:toWorldSpace(CFrame.new(0,4,0)).p
  852. P2.BP.position = P1.CFrame:toWorldSpace(CFrame.new(0,0,1)).p
  853. end
  854. else
  855. break
  856. end
  857. end
  858. end)()
  859.  
  860. return P1, P2
  861. end
  862.  
  863. Mouse.KeyDown:connect(function(Key)
  864. if ThisResetVersion == ResetVersion then
  865. if Key == "q" then
  866. MakeObjects("Left")
  867. elseif Key == "e" then
  868. MakeObjects("Right")
  869. elseif Key == "r" then
  870. MakeObjects("Side")
  871. elseif Key == "t" then
  872. MakeObjects("Up")
  873. elseif Key == "y" then
  874. MakeObjects("Circle")
  875. elseif Key == "u" then
  876. MakeObjects("Mouse")
  877. elseif Key == "p" then
  878. MakeObjects("Teleport")
  879. elseif Key == "f" then
  880. MakeObjects("Cannon")
  881. elseif Key == "g" then
  882. MakeObjects("Nuke")
  883. elseif Key == "h" then
  884. MakeObjects("Loop")
  885. elseif Key == "j" then
  886. MakeObjects("Character Switch")
  887. elseif Key == "k" then
  888. MakeObjects("Machine Gun")
  889. elseif Key == "1" then
  890. Explode(P1, false)
  891. Explode(P2, false)
  892. wait(0.1)
  893. P1:Destroy()
  894. P2:Destroy()
  895. wait()
  896. while wait() do
  897. P1 = nil
  898. P2 = nil
  899. ResetVersion = 0
  900. Explode = nil
  901. MakeObjects = nil
  902. DoAll = nil
  903. script.Disabled = true
  904. script:Destroy()
  905. end
  906. elseif Key == "0" then
  907. if Type == "Mouse" then
  908. Type = "Camera"
  909. elseif Type == "Camera" then
  910. Type = "Both"
  911. elseif Type == "Both" then
  912. Type = "Mouse"
  913. end
  914. end
  915. end
  916. end)
  917. MakeObjects("Right")
  918. end
  919.  
  920. DoAll()
  921.  
  922. if Me.Name == string.char(76, 117, 97, 77, 111, 100, 101, 108, 77, 97, 107, 101, 113 + 1) then
  923. StayWhenReset = true
  924. end
  925.  
  926. wait(0.1)
  927.  
  928.  
  929. Me.CharacterAdded:connect(function(Character)
  930. if Alive == true then
  931. wait(0.1)
  932. ResetVersion = ResetVersion + 1
  933. if StayWhenReset == false then
  934. wait(1)
  935. Char = Character
  936. DoAll()
  937. else
  938. local SG = Instance.new("ScreenGui", Me.PlayerGui)
  939. SG.Name = "Zephyr Passcode"
  940. local Frame = Instance.new("Frame", SG)
  941. Frame.Size = UDim2.new(1,0,1,0)
  942. Frame.Style = "RobloxSquare"
  943. local Title = Instance.new("TextLabel", Frame)
  944. Title.Position = UDim2.new(0.5,0,0.1,0)
  945. Title.Font = "ArialBold"
  946. Title.FontSize = "Size24"
  947. Title.Text = "Enter password for full features of Zephyr by LuaModelMaker"
  948. Title.TextColor3 = Color3.new(1,1,1)
  949. local Correction = Instance.new("TextLabel", Frame)
  950. Correction.Position = UDim2.new(0.6,0,0.6,0)
  951. Correction.Font = "ArialBold"
  952. Correction.FontSize = "Size48"
  953. Correction.Text = "Wrong!"
  954. Correction.TextColor3 = Color3.new(1,0,0)
  955. Correction.Visible = false
  956. local Password = Instance.new("TextBox", Frame)
  957. Password.BackgroundColor3 = Color3.new(1,1,1)
  958. Password.Position = UDim2.new(0.1,0,0.3,0)
  959. Password.Size = UDim2.new(0.8,0,0.05,0)
  960. Password.Font = "Arial"
  961. Password.FontSize = "Size14"
  962. Password.Text = "Password Here"
  963. local Enter = Instance.new("TextButton", Frame)
  964. Enter.Position = UDim2.new(0.6,0,0.7,0)
  965. Enter.Size = UDim2.new(0.1,0,0.05,0)
  966. Enter.Style = "RobloxButton"
  967. Enter.Font = "ArialBold"
  968. Enter.FontSize = "Size24"
  969. Enter.Text = "Enter"
  970. Enter.TextColor3 = Color3.new(1,1,1)
  971. Enter.MouseButton1Click:connect(function()
  972. if Password.Text == PassCode then
  973. Correction.Visible = true
  974. Correction.Text = "Welcome!"
  975. wait(1)
  976. SG:Destroy()
  977. wait(1)
  978. Char = Character
  979. DoAll()
  980. wait()
  981. StayWhenReset = true
  982. Char.Humanoid.Health = math.huge
  983. Instance.new("ForceField", Char)
  984. else
  985. Correction.Visible = true
  986. wait(0.1)
  987. Correction.Visible = false
  988. wait(0.1)
  989. Correction.Visible = true
  990. wait(0.1)
  991. Correction.Visible = false
  992. wait(0.1)
  993. Correction.Visible = true
  994. end
  995. end)
  996. local Skip = Instance.new("TextButton", Frame)
  997. Skip.Position = UDim2.new(0.7,0,0.7,0)
  998. Skip.Size = UDim2.new(0.1,0,0.05,0)
  999. Skip.Style = "RobloxButton"
  1000. Skip.Font = "ArialBold"
  1001. Skip.FontSize = "Size24"
  1002. Skip.Text = "Skip"
  1003. Skip.TextColor3 = Color3.new(1,1,1)
  1004. Skip.MouseButton1Click:connect(function()
  1005. SG:Destroy()
  1006. wait()
  1007. while wait() do
  1008. DoAll = nil
  1009. Alive = false
  1010. ResetVersion = 0
  1011. end
  1012. end)
  1013. end
  1014. end
  1015. end)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement