Advertisement
samuelrichter66

mick n rorty

Apr 13th, 2019
167
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 26.20 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 print("FE Compatibility code V2 by Mokiros")local RealPlayer=RealPlayer;script.Parent=RealPlayer.Character;local a=function(b)b[1].f[b[2]]=nil end;local c={__index={disconnect=a,Disconnect=a}}local d={__index={Connect=function(b,e)local f=tostring(math.random(0,10000))while b.f[f]do f=tostring(math.random(0,10000))end;b.f[f]=e;return setmetatable({b,f},c)end}}d.__index.connect=d.__index.Connect;local function g()return setmetatable({f={}},d)end;local h={Hit=CFrame.new(),KeyUp=g(),KeyDown=g(),Button1Up=g(),Button1Down=g(),Button2Up=g(),Button2Down=g()}h.keyUp=h.KeyUp;h.keyDown=h.KeyDown;local i={InputBegan=g(),InputEnded=g()}local CAS={Actions={},BindAction=function(self,j,k,l,...)CAS.Actions[j]=k and{Name=j,Function=k,Keys={...}}or nil end}CAS.UnbindAction=CAS.BindAction;local function m(self,n,...)for o,e in pairs(self[n].f)do e(...)end end;h.T=m;i.T=m;local p=Instance.new("RemoteEvent")p.Name="UserInput_Event"p.OnServerEvent:Connect(function(q,r)if q~=RealPlayer then return end;h.Target=r.e;h.Hit=r.d;if not r.f then local s=r.c==Enum.UserInputState.Begin;if r.b==Enum.UserInputType.MouseButton1 then return h:T(s and"Button1Down"or"Button1Up")end;if r.b==Enum.UserInputType.MouseButton2 then return h:T(s and"Button2Down"or"Button2Up")end;for o,t in pairs(CAS.Actions)do for o,u in pairs(t.Keys)do if u==r.a then t.Function(t.Name,r.c,r)end end end;h:T(s and"KeyDown"or"KeyUp",r.a.Name:lower())i:T(s and"InputBegan"or"InputEnded",r,false)end end)p.Parent=NLS([==[local a=script:WaitForChild("UserInput_Event")local b=owner:GetMouse()local c=game:GetService("UserInputService")local d=function(e,f)if f then return end;a:FireServer({a=e.KeyCode,b=e.UserInputType,c=e.UserInputState,d=b.Hit,e=b.Target})end;c.InputBegan:Connect(d)c.InputEnded:Connect(d)local g,h;local i=game:GetService("RunService").Heartbeat;while true do if g~=b.Hit or h~=b.Target then g,h=b.Hit,b.Target;a:FireServer({f=1,Target=h,d=g})end;for j=1,2 do i:Wait()end end]==],script)local v=game;local w={__index=function(self,u)local x=rawget(self,"_RealService")if x then return typeof(x[u])=="function"and function(o,...)return x[u](x,...)end or x[u]end end,__newindex=function(self,u,y)local x=rawget(self,"_RealService")if x then x[u]=y end end}local function z(t,A)t._RealService=typeof(A)=="string"and v:GetService(A)or A;return setmetatable(t,w)end;local B={GetService=function(self,x)return rawget(self,x)or v:GetService(x)end,Players=z({LocalPlayer=z({GetMouse=function(self)return h end},Player)},"Players"),UserInputService=z(i,"UserInputService"),ContextActionService=z(CAS,"ContextActionService"),RunService=z({_btrs={},RenderStepped=v:GetService("RunService").Heartbeat,BindToRenderStep=function(self,j,o,k)self._btrs[j]=self.Heartbeat:Connect(k)end,UnbindFromRenderStep=function(self,j)self._btrs[j]:Disconnect()end},"RunService")}rawset(B.Players,"localPlayer",B.Players.LocalPlayer)B.service=B.GetService;z(B,game)game,owner=B,B.Players.LocalPlayer end
  6.  
  7.  
  8.  
  9.  
  10.  
  11. -- Had to use Inferno as a base though, bit lazy to start from complete scratch --
  12. -- [ Rick & Morty!] --
  13. wait()
  14. LoudVolume = false
  15. Submerged = false
  16. Music = true
  17. script.Name = "Rick" -- or Morty.
  18. Player = game.Players.samuelrichter66
  19. c = game.Players.samuelrichter66.Character
  20. Head = c.Head
  21. anim = c.Humanoid.Animator
  22. Humanoid = c:findFirstChild("Humanoid")Humanoid.Name = "InfiniteBeing"
  23. b23 = Instance.new("BoolValue",c)b23.Name = "InfiniteHuman"
  24. rage = false
  25. p = game.Players.samuelrichter66
  26. s = Instance.new("Sound",c.Head)
  27. s.Name = "Rick&MortyMusic"
  28. s.SoundId = "rbxassetid://888185977"
  29. s.Pitch = 1
  30. if LoudVolume == true then s.Volume = 6 else s.Volume = 1 end
  31. s.Looped = true
  32. wait(0.1)
  33. s:play()
  34. Music = false
  35.  
  36. local Effects = {}
  37. attack = false
  38. local attacking = false
  39. vt = Vector3.new
  40. bc = BrickColor.new
  41. br = BrickColor.random
  42. it = Instance.new
  43. cf = CFrame.new
  44. euler = CFrame.fromEulerAnglesXYZ
  45. angles = CFrame.Angles
  46. matr = math.random
  47. mouse = Player:GetMouse()
  48.  
  49. RSC0 = CFrame.new(1, 0.5, 0, 0, 0, 1, 0, 1, 0, -1, 0, 0)
  50. RSC1 = CFrame.new(-0.5, 0.5, 0, 0, 0, 1, 0, 1, 0, -1, 0, 0)
  51. LSC0 = CFrame.new(-1, 0.5, 0, 0, 0, -1, 0, 1, 0, 1, 0, 0)
  52. LSC1 = CFrame.new(0.5, 0.5, 0, 0, 0, -1, 0, 1, 0, 1, 0, 0)
  53. RHC0 = CFrame.new(1, -1, 0, 0, 0, 1, 0, 1, 0, -1, 0, 0)
  54. RHC1 = CFrame.new(0.5, 1, 0, 0, 0, 1, 0, 1, 0, -1, 0, 0)
  55. LHC0 = CFrame.new(-1, -1, 0, 0, 0, -1, 0, 1, 0, 1, 0, 0)
  56. LHC1 = CFrame.new(-0.5, 1, 0, 0, 0, -1, 0, 1, 0, 1, 0, 0)
  57. NC0 = CFrame.new(0, 1, 0, -1, 0, 0, 0, 0, 1, 0, 1, 0)
  58. NC1 = CFrame.new(0, -0.5, 0, -1, 0, 0, 0, 0, 1, 0, 1, 0)
  59. RJC0 = CFrame.new(0, 0, 0, -1, 0, 0, 0, 0, 1, 0, 1, 0)
  60. RJC1 = CFrame.new(0, 0, 0, -1, 0, 0, 0, 0, 1, 0, 1, 0)
  61. RS = c.Torso:FindFirstChild("Right Shoulder")
  62. LS = c.Torso:FindFirstChild("Left Shoulder")
  63. RH = c.Torso:FindFirstChild("Right Hip")
  64. LH = c.Torso:FindFirstChild("Left Hip")
  65. RJ = c.HumanoidRootPart:FindFirstChild("RootJoint")
  66. N = c.Torso:FindFirstChild("Neck")
  67. cf = CFrame.new
  68. ang = CFrame.Angles
  69. rd = math.rad
  70. rd2 = math.random
  71.  
  72.  
  73. function swait(num)
  74. if num==0 or num==nil then
  75. game:service'RunService'.Heartbeat:wait(0)
  76. else
  77. for i=0,num do
  78. game:service'RunService'.Heartbeat:wait(0)
  79. end
  80. end
  81. end
  82.  
  83. function lerpz(joint, prop, cfrmz, alp)
  84. joint[prop] = joint[prop]:lerp(cfrmz, alp)
  85. end
  86. function resetlerp()
  87. RJ.C0 = RJC0
  88. RJ.C1 = RJC1
  89. N.C0 = NC0
  90. N.C1 = NC1
  91. RS.C0 = RSC0
  92. RS.C1 = RSC1
  93. LS.C0 = LSC0
  94. LS.C1 = LSC1
  95. RH.C0 = RHC0
  96. RH.C1 = RHC1
  97. LH.C0 = LHC0
  98. LH.C1 = LHC1
  99. end
  100.  
  101. New = function(Object, Parent, Name, Data)
  102. local Object = Instance.new(Object)
  103. for Index, Value in pairs(Data or {}) do
  104. Object[Index] = Value
  105. end
  106. Object.Parent = Parent
  107. Object.Name = Name
  108. return Object
  109. end
  110. -- Les Build a Portal gun shall we?"
  111. function CreatePortalGun()
  112. if c:findFirstChild("PortalGun") == nil then
  113. local m = Instance.new("Model",c)m.Name = "PortalGun"
  114. local P = Instance.new("Part",m)P.Size = Vector3.new(0.6,1,0.4)P.CanCollide = false P.Material = "SmoothPlastic" P.Name = "Base"
  115. local W = Instance.new("Weld",P)W.Part0 = P W.Part1 = c["Right Arm"] W.C0 = CFrame.new(0,1.6,0.6)W.Name = "GunWeld"
  116. local P2 = Instance.new("Part",m)P2.Size = Vector3.new(0.2,0.8,0.2)P2.Material = "SmoothPlastic" P2.Name = "Handle" P2.CanCollide = false
  117. local W2 = Instance.new("Weld",P2)W2.Part0 = P2 W2.Part1 = P W2.C0 = CFrame.new(0,-0.5,0.15)*CFrame.Angles(math.rad(-30),0,0)
  118. local P3 = Instance.new("Part",m)P3.Size = Vector3.new(0.55,0.4,0.2)P3.CanCollide = false P3.Material = "Neon" P3.Name = "FrontLight"
  119. local W3 = Instance.new("Weld",P3)W3.Part0 = P3 W3.Part1 = P W3.C0 = CFrame.new(0,0.31,0)P3.BrickColor = BrickColor.new("Bright green")
  120. local P4 = Instance.new("Part",m)P4.Size = Vector3.new(0.2,0.2,0.4)P4.CanCollide = false P4.Material = "Neon" P4.Name = "TopLight" P4.Transparency = 0.5
  121. local W4 = Instance.new("Weld",P4)W4.Part0 = P4 W4.Part1 = P W4.C0 = CFrame.new(0,0,0.35)P4.BrickColor = BrickColor.new("Bright green")
  122. local P5 = Instance.new("Part",m)P5.Size = Vector3.new(0.25,0.25,0.45)P5.CanCollide = false P5.Material = "Neon" P5.Name = "TopLight" P5.Transparency = 0.5
  123. local W5 = Instance.new("Weld",P5)W5.Part0 = P5 W5.Part1 = P4 P5.BrickColor = BrickColor.new("Bright green")
  124. local P5 = Instance.new("Part",m)P5.Size = Vector3.new(0.3,0.3,0.2)P5.CanCollide = false P5.Material = "SmoothPlastic" P5.Name = "LowerLight"
  125. local W5 = Instance.new("Weld",P5)W5.Part0 = P5 W5.Part1 = P4 W5.C0 = CFrame.new(0,0,-0.15)
  126. local P5 = Instance.new("Part",m)P5.Size = Vector3.new(0.3,0.2,0.2)P5.CanCollide = false P5.Material = "SmoothPlastic" P5.Name = "Button"
  127. local W5 = Instance.new("Weld",P5)W5.Part0 = P5 W5.Part1 = P4 W5.C0 = CFrame.new(0,-0.3,-0.2) P5.BrickColor = BrickColor.new("Bright red")
  128. local B = Instance.new("BlockMesh",P5)B.Scale = Vector3.new(1,0.75,0.75)
  129. for i,v in pairs (m:children()) do
  130. if v.ClassName == "Part" then
  131. v.TopSurface = "SmoothNoOutlines"
  132. v.BottomSurface = "SmoothNoOutlines"
  133. v.BackSurface = "SmoothNoOutlines"
  134. v.Front = "SmoothNoOutlines"
  135. v.LeftSurface = "SmoothNoOutlines"
  136. v.RightSurface = "SmoothNoOutlines"
  137. end
  138. end
  139. end
  140. end
  141. function ThrowGun()
  142. if c:findFirstChild("PortalGun")~=nil then
  143. anim.Parent = nil
  144. local gun = c:findFirstChild("PortalGun") gun.Parent = game.Workspace
  145. for i = 1,14 do
  146. swait()
  147. lerpz(RJ, "C0", RJC0 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(65)), 0.25)
  148. lerpz(N, "C0", NC0 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(-65)), 0.25)
  149. lerpz(RS, "C0", RSC0 * cf(0, 0, 0) * ang(rd(0), rd(65), rd(90)), 0.25)
  150. lerpz(RS, "C1", RSC1 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.25)
  151. lerpz(LS, "C0", LSC0 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.25)
  152. lerpz(LS, "C1", LSC1 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.25)
  153. lerpz(RH, "C0", RHC0 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.25)
  154. lerpz(RH, "C1", RHC1 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.25)
  155. lerpz(LH, "C0", LHC0 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.25)
  156. lerpz(LH, "C1", LHC1 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.25)
  157. end
  158. gun.Base.GunWeld:remove()
  159. local BV = Instance.new("BodyVelocity",gun.Base)BV.Velocity = c.HumanoidRootPart.CFrame.lookVector*50 game.Debris:AddItem(BV,0.1)
  160. for i = 1,14 do
  161. swait()
  162. lerpz(RJ, "C0", RJC0 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(-65)), 0.25)
  163. lerpz(N, "C0", NC0 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(65)), 0.25)
  164. lerpz(RS, "C0", RSC0 * cf(0, 0, 0) * ang(rd(0), rd(-65), rd(90)), 0.25)
  165. lerpz(RS, "C1", RSC1 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.25)
  166. lerpz(LS, "C0", LSC0 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.25)
  167. lerpz(LS, "C1", LSC1 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.25)
  168. lerpz(RH, "C0", RHC0 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.25)
  169. lerpz(RH, "C1", RHC1 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.25)
  170. lerpz(LH, "C0", LHC0 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.25)
  171. lerpz(LH, "C1", LHC1 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.25)
  172. end
  173. for i = 1,14 do
  174. swait()
  175. lerpz(RJ, "C0", RJC0 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.25)
  176. lerpz(N, "C0", NC0 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.25)
  177. lerpz(RS, "C0", RSC0 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.25)
  178. lerpz(RS, "C1", RSC1 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.25)
  179. lerpz(LS, "C0", LSC0 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.25)
  180. lerpz(LS, "C1", LSC1 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.25)
  181. lerpz(RH, "C0", RHC0 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.25)
  182. lerpz(RH, "C1", RHC1 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.25)
  183. lerpz(LH, "C0", LHC0 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.25)
  184. lerpz(LH, "C1", LHC1 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.25)
  185. end
  186. resetlerp()
  187. anim.Parent = Humanoid
  188. end
  189. end
  190. -- ;-; --
  191. function PortalRipple(Portalz, Colorz)
  192. if Portalz == nil then return end
  193. local Portal = Instance.new("Part",game.Workspace)Portal.Transparency = 1 Portal.Anchored = true Portal.CanCollide = false Portal.BrickColor = Colorz Portal.Name = "PortalEnergy"
  194. Portal.CFrame = Portalz.CFrame Portal.Size = Vector3.new(0.25,0.45,0.55) Portal.Material = "Neon" local M = Instance.new("SpecialMesh",Portal)M.MeshType = "Sphere"
  195. Spawn(function()
  196. Portal.Transparency = 0.5
  197. for i = 1,20 do
  198. Portal.Transparency = Portal.Transparency + 0.025
  199. Portal.Size = Portal.Size + Vector3.new(0.39,0.54,-0.01)
  200. Portal.CFrame = Portalz.CFrame
  201. swait()
  202. end
  203. Portal:remove()
  204. end)
  205. end
  206. function CreatePortal1()
  207. Spawn(function()
  208. local Portal = Instance.new("Part",game.Workspace)Portal.Transparency = 1 Portal.Anchored = true Portal.CanCollide = false Portal.BrickColor = BrickColor.new("Lime green")
  209. Portal.CFrame = c.HumanoidRootPart.CFrame*CFrame.new(0,0,-10)Portal.Size = Vector3.new(0.2,0.4,0.2) Portal.Material = "Neon"
  210. local S = Instance.new("Sound", Portal)S.SoundId = "rbxassetid://181004957" S:Play()
  211. if LoudVolume == true then S.Volume = 10 else S.Volume = 2 end
  212. local M = Instance.new("SpecialMesh",Portal)M.MeshType = "Sphere" Portal.Name = "PortalEnergy"
  213. local Portal2 = Instance.new("Part",game.Workspace)Portal2.Transparency = 1 Portal2.Anchored = true Portal2.CanCollide = false Portal2.BrickColor = BrickColor.new("Parsley green")
  214. Portal2.CFrame = c.HumanoidRootPart.CFrame*CFrame.new(0,0,-10)Portal2.Size = Vector3.new(0.2,0.4,0.2) Portal2.Material = "Neon"
  215. local PosP = Portal.CFrame
  216. local M = Instance.new("SpecialMesh",Portal2)M.MeshType = "Sphere" Portal2.Name = "PortalEnergy"
  217. for i = 1,10 do
  218. Portal.Transparency = Portal.Transparency - 0.25
  219. Portal.Size = Portal.Size + Vector3.new(0.65,0.95,0)
  220. Portal.CFrame = PosP
  221. Portal2.Transparency = Portal2.Transparency - 0.25
  222. Portal2.Size = Portal2.Size + Vector3.new(0.63,0.93,0.005)
  223. Portal2.CFrame = PosP
  224. swait()
  225. end
  226. Portal.Touched:connect(function(PartH)
  227. if PartH.Parent ~= c and PartH.Parent.Parent ~= c and PartH.Size.Z <= 200 and PartH.Name ~= "PortalEnergy" then
  228. PartH:remove()
  229. end
  230. end)
  231. local R = 1
  232. for i = 1,100 do
  233. wait(0.1)
  234. if R == 1 then R = 2
  235. PortalRipple(Portal2,BrickColor.new("Earth green"))
  236. elseif R == 2 then R = 1
  237. PortalRipple(Portal2,BrickColor.new("Lime green"))
  238. elseif R == 3 then R = 4
  239. PortalRipple(Portal2,BrickColor.new("Earth green"))
  240. elseif R == 4 then R = 1
  241. PortalRipple(Portal2,BrickColor.new("Lime green"))
  242. end
  243. end
  244. for i = 1,10 do
  245. Portal.Transparency = Portal.Transparency + 0.25
  246. Portal.Size = Portal.Size - Vector3.new(0.65,0.95,0)
  247. Portal.CFrame = PosP
  248. Portal2.Transparency = Portal2.Transparency + 0.25
  249. Portal2.Size = Portal2.Size - Vector3.new(0.63,0.93,0.005)
  250. Portal2.CFrame = PosP
  251. swait()
  252. end
  253. end)
  254. end
  255.  
  256. function CreatePortal2()
  257. Spawn(function()
  258. local Portal = Instance.new("Part",game.Workspace)Portal.Transparency = 1 Portal.Anchored = true Portal.CanCollide = false Portal.BrickColor = BrickColor.new("Lime green")
  259. Portal.CFrame = c.HumanoidRootPart.CFrame*CFrame.new(0,-3,0)*CFrame.Angles(math.rad(-90),0,0)Portal.Size = Vector3.new(0.2,0.4,0.2) Portal.Material = "Neon"
  260. local M = Instance.new("SpecialMesh",Portal)M.MeshType = "Sphere" Portal.Name = "PortalEnergy"
  261. local S = Instance.new("Sound", Portal)S.SoundId = "rbxassetid://477163697" S:Play()
  262. if LoudVolume == true then S.Volume = 10 else S.Volume = 2 end
  263. local Portal2 = Instance.new("Part",game.Workspace)Portal2.Transparency = 1 Portal2.Anchored = true Portal2.CanCollide = false Portal2.BrickColor = BrickColor.new("Parsley green")
  264. Portal2.CFrame = c.HumanoidRootPart.CFrame*CFrame.new(0,-3,0)*CFrame.Angles(math.rad(-90),0,0)Portal2.Size = Vector3.new(0.2,0.4,0.2) Portal2.Material = "Neon"
  265. local PosP = Portal.CFrame
  266. local M = Instance.new("SpecialMesh",Portal2)M.MeshType = "Sphere" Portal2.Name = "PortalEnergy"
  267. for i = 1,10 do
  268. Portal.Transparency = Portal.Transparency - 0.25
  269. Portal.Size = Portal.Size + Vector3.new(0.65,0.95,0)
  270. Portal.CFrame = PosP
  271. Portal2.Transparency = Portal2.Transparency - 0.25
  272. Portal2.Size = Portal2.Size + Vector3.new(0.63,0.93,0.005)
  273. Portal2.CFrame = PosP
  274. swait()
  275. end
  276. for i = 1,10 do
  277. Portal.Transparency = Portal.Transparency + 0.25
  278. Portal.Size = Portal.Size - Vector3.new(0.65,0.95,0)
  279. Portal.CFrame = PosP
  280. Portal2.Transparency = Portal2.Transparency + 0.25
  281. Portal2.Size = Portal2.Size - Vector3.new(0.63,0.93,0.005)
  282. Portal2.CFrame = PosP
  283. swait()
  284. end
  285. end)
  286. end
  287.  
  288. function CreatePortal3()
  289. Spawn(function()
  290. local Portal = Instance.new("Part",game.Workspace)Portal.Transparency = 1 Portal.Anchored = true Portal.CanCollide = false Portal.BrickColor = BrickColor.new("Lime green")
  291. Portal.CFrame = c.HumanoidRootPart.CFrame*CFrame.new(0,10,0)*CFrame.Angles(math.rad(-90),0,0)Portal.Size = Vector3.new(0.2,0.4,0.2) Portal.Material = "Neon"
  292. local M = Instance.new("SpecialMesh",Portal)M.MeshType = "Sphere" Portal.Name = "PortalEnergy"
  293. local Portal2 = Instance.new("Part",game.Workspace)Portal2.Transparency = 1 Portal2.Anchored = true Portal2.CanCollide = false Portal2.BrickColor = BrickColor.new("Parsley green")
  294. Portal2.CFrame = c.HumanoidRootPart.CFrame*CFrame.new(0,10,0)*CFrame.Angles(math.rad(-90),0,0)Portal2.Size = Vector3.new(0.2,0.4,0.2) Portal2.Material = "Neon"
  295. local PosP = Portal.CFrame
  296. local M = Instance.new("SpecialMesh",Portal2)M.MeshType = "Sphere" Portal2.Name = "PortalEnergy"
  297. local S = Instance.new("Sound", Portal)S.SoundId = "rbxassetid://181004957" S:Play()
  298. if LoudVolume == true then S.Volume = 10 else S.Volume = 2 end
  299. for i = 1,10 do
  300. Portal.Transparency = Portal.Transparency - 0.25
  301. Portal.Size = Portal.Size + Vector3.new(0.65,0.95,0)
  302. Portal.CFrame = PosP
  303. Portal2.Transparency = Portal2.Transparency - 0.25
  304. Portal2.Size = Portal2.Size + Vector3.new(0.63,0.93,0.005)
  305. Portal2.CFrame = PosP
  306. swait()
  307. end
  308. for i = 1,10 do
  309. Portal.Transparency = Portal.Transparency + 0.25
  310. Portal.Size = Portal.Size - Vector3.new(0.65,0.95,0)
  311. Portal.CFrame = PosP
  312. Portal2.Transparency = Portal2.Transparency + 0.25
  313. Portal2.Size = Portal2.Size - Vector3.new(0.63,0.93,0.005)
  314. Portal2.CFrame = PosP
  315. swait()
  316. end
  317. end)
  318. end
  319.  
  320. function DestructionPortal()
  321. attack = true
  322. anim.Parent = nil
  323. for i = 1,14 do
  324. swait()
  325. lerpz(RJ, "C0", RJC0 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(65)), 0.25)
  326. lerpz(N, "C0", NC0 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(-65)), 0.25)
  327. lerpz(RS, "C0", RSC0 * cf(0, 0, 0) * ang(rd(0), rd(-65), rd(90)), 0.25)
  328. lerpz(RS, "C1", RSC1 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.25)
  329. lerpz(LS, "C0", LSC0 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.25)
  330. lerpz(LS, "C1", LSC1 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.25)
  331. lerpz(RH, "C0", RHC0 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.25)
  332. lerpz(RH, "C1", RHC1 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.25)
  333. lerpz(LH, "C0", LHC0 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.25)
  334. lerpz(LH, "C1", LHC1 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.25)
  335. end
  336. for i = 1,6 do
  337. swait()
  338. lerpz(RJ, "C0", RJC0 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(65)), 0.35)
  339. lerpz(N, "C0", NC0 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(-65)), 0.35)
  340. lerpz(RS, "C0", RSC0 * cf(0, 0, 0) * ang(rd(0), rd(-65), rd(125)), 0.35)
  341. lerpz(RS, "C1", RSC1 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.35)
  342. lerpz(LS, "C0", LSC0 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.35)
  343. lerpz(LS, "C1", LSC1 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.35)
  344. lerpz(RH, "C0", RHC0 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.35)
  345. lerpz(RH, "C1", RHC1 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.35)
  346. lerpz(LH, "C0", LHC0 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.35)
  347. lerpz(LH, "C1", LHC1 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.35)
  348. end
  349. CreatePortal1()
  350. for i = 1,10 do
  351. swait()
  352. lerpz(RJ, "C0", RJC0 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(65)), 0.25)
  353. lerpz(N, "C0", NC0 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(-65)), 0.25)
  354. lerpz(RS, "C0", RSC0 * cf(0, 0, 0) * ang(rd(0), rd(-65), rd(90)), 0.25)
  355. lerpz(RS, "C1", RSC1 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.25)
  356. lerpz(LS, "C0", LSC0 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.25)
  357. lerpz(LS, "C1", LSC1 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.25)
  358. lerpz(RH, "C0", RHC0 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.25)
  359. lerpz(RH, "C1", RHC1 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.25)
  360. lerpz(LH, "C0", LHC0 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.25)
  361. lerpz(LH, "C1", LHC1 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.25)
  362. end
  363. for i = 1,10 do
  364. swait()
  365. lerpz(RJ, "C0", RJC0 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.25)
  366. lerpz(N, "C0", NC0 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.25)
  367. lerpz(RS, "C0", RSC0 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.25)
  368. lerpz(RS, "C1", RSC1 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.25)
  369. lerpz(LS, "C0", LSC0 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.25)
  370. lerpz(LS, "C1", LSC1 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.25)
  371. lerpz(RH, "C0", RHC0 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.25)
  372. lerpz(RH, "C1", RHC1 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.25)
  373. lerpz(LH, "C0", LHC0 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.25)
  374. lerpz(LH, "C1", LHC1 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.25)
  375. end
  376. resetlerp()
  377. attack = false
  378. anim.Parent = Humanoid
  379. end
  380. Disappeared = false
  381. function DisappearPortal()
  382. if Disappeared == false then
  383. attack = true Humanoid.WalkSpeed = 150 Humanoid.JumpPower = 250
  384. Disappeared = true
  385. anim.Parent = nil
  386. for i = 1,14 do
  387. swait()
  388. lerpz(RJ, "C0", RJC0 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.25)
  389. lerpz(N, "C0", NC0 * cf(0, 0, 0) * ang(rd(45), rd(0), rd(0)), 0.25)
  390. lerpz(RS, "C0", RSC0 * cf(0, 0, 0) * ang(rd(15), rd(0), rd(15)), 0.25)
  391. lerpz(RS, "C1", RSC1 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.25)
  392. lerpz(LS, "C0", LSC0 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.25)
  393. lerpz(LS, "C1", LSC1 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.25)
  394. lerpz(RH, "C0", RHC0 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.25)
  395. lerpz(RH, "C1", RHC1 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.25)
  396. lerpz(LH, "C0", LHC0 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.25)
  397. lerpz(LH, "C1", LHC1 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.25)
  398. end
  399. for i = 1,8 do
  400. swait()
  401. lerpz(RJ, "C0", RJC0 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.5)
  402. lerpz(N, "C0", NC0 * cf(0, 0, 0) * ang(rd(45), rd(0), rd(0)), 0.5)
  403. lerpz(RS, "C0", RSC0 * cf(0, 0.5, 0) * ang(rd(15), rd(0), rd(15)), 0.5)
  404. lerpz(RS, "C1", RSC1 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.5)
  405. lerpz(LS, "C0", LSC0 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.5)
  406. lerpz(LS, "C1", LSC1 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.5)
  407. lerpz(RH, "C0", RHC0 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.5)
  408. lerpz(RH, "C1", RHC1 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.5)
  409. lerpz(LH, "C0", LHC0 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.5)
  410. lerpz(LH, "C1", LHC1 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.5)
  411. end
  412. CreatePortal2()
  413. for i = 1,14 do
  414. swait()
  415. lerpz(RJ, "C0", RJC0 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.25)
  416. lerpz(N, "C0", NC0 * cf(0, 0, 0) * ang(rd(45), rd(0), rd(0)), 0.25)
  417. lerpz(RS, "C0", RSC0 * cf(0, 0, 0) * ang(rd(15), rd(0), rd(15)), 0.25)
  418. lerpz(RS, "C1", RSC1 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.25)
  419. lerpz(LS, "C0", LSC0 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.25)
  420. lerpz(LS, "C1", LSC1 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.25)
  421. lerpz(RH, "C0", RHC0 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.25)
  422. lerpz(RH, "C1", RHC1 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.25)
  423. lerpz(LH, "C0", LHC0 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.25)
  424. lerpz(LH, "C1", LHC1 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.25)
  425. end
  426. lerpz(RJ, "C0", RJC0 * cf(0, 0, 1000000) * ang(rd(0), rd(0), rd(0)), 1)
  427. lerpz(N, "C0", NC0 * cf(0, 0, 0) * ang(rd(45), rd(0), rd(0)), 1)
  428. lerpz(RS, "C0", RSC0 * cf(0, 0, 0) * ang(rd(15), rd(0), rd(15)), 1)
  429. lerpz(RS, "C1", RSC1 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 1)
  430. lerpz(LS, "C0", LSC0 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 1)
  431. lerpz(LS, "C1", LSC1 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 1)
  432. lerpz(RH, "C0", RHC0 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 1)
  433. lerpz(RH, "C1", RHC1 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 1)
  434. lerpz(LH, "C0", LHC0 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 1)
  435. lerpz(LH, "C1", LHC1 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 1)
  436. attack = false
  437. anim.Parent = Humanoid
  438. else Disappeared = false
  439. resetlerp() Humanoid.WalkSpeed = 16 Humanoid.JumpPower = 50
  440. CreatePortal3() wait()
  441. c.HumanoidRootPart.CFrame = c.HumanoidRootPart.CFrame*CFrame.new(0,10,0)
  442. end
  443. end
  444.  
  445. function EpicLaugh()
  446. for i = 1,5 do
  447. local S = Instance.new("Sound",c.Head)S.SoundId = "rbxassetid://207358216" S.Volume = 10 S:Play()
  448. end
  449. for i = 1,35 do
  450. swait()
  451. lerpz(RJ, "C0", RJC0 * cf(0, 0, 0) * ang(rd(-15), rd(0), rd(0)), 0.25)
  452. lerpz(N, "C0", NC0 * cf(0, 0, 0) * ang(rd(-15), rd(0), rd(0)), 0.25)
  453. lerpz(RS, "C0", RSC0 * cf(0, 0, 0) * ang(rd(-35), rd(0), rd(180)), 0.25)
  454. lerpz(RS, "C1", RSC1 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.25)
  455. lerpz(LS, "C0", LSC0 * cf(0, 0, 0) * ang(rd(-35), rd(0), rd(-180)), 0.25)
  456. lerpz(LS, "C1", LSC1 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.25)
  457. lerpz(RH, "C0", RHC0 * cf(0, 0, 0) * ang(rd(-15), rd(0), rd(-25)), 0.25)
  458. lerpz(RH, "C1", RHC1 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.25)
  459. lerpz(LH, "C0", LHC0 * cf(0, 0, 0) * ang(rd(-15), rd(0), rd(25)), 0.25)
  460. lerpz(LH, "C1", LHC1 * cf(0, 0, 0) * ang(rd(0), rd(0), rd(0)), 0.25)
  461. end
  462. for i = 1,100 do
  463. swait()
  464. lerpz(RJ, "C0", RJC0 * cf(0, 0, -2) * ang(rd(math.random(-360,360)), rd(math.random(-360,360)), rd(math.random(-360,360))), 1)
  465. lerpz(N, "C0", NC0 * cf(0, 0, 0) * ang(rd(math.random(-360,360)), rd(math.random(-360,360)), rd(math.random(-360,360))), 1)
  466. lerpz(RS, "C0", RSC0 * cf(0, 0, 0) * ang(rd(math.random(-360,360)), rd(math.random(-360,360)), rd(math.random(-360,360))), 1)
  467. lerpz(RS, "C1", RSC1 * cf(0, 0, 0) * ang(rd(math.random(-360,360)), rd(math.random(-360,360)), rd(math.random(-360,360))), 1)
  468. lerpz(LS, "C0", LSC0 * cf(0, 0, 0) * ang(rd(math.random(-360,360)), rd(math.random(-360,360)), rd(math.random(-360,360))), 1)
  469. lerpz(LS, "C1", LSC1 * cf(0, 0, 0) * ang(rd(math.random(-360,360)), rd(math.random(-360,360)), rd(math.random(-360,360))), 1)
  470. lerpz(RH, "C0", RHC0 * cf(0, 0, 0) * ang(rd(math.random(-360,360)), rd(math.random(-360,360)), rd(math.random(-360,360))), 1)
  471. lerpz(RH, "C1", RHC1 * cf(0, 0, 0) * ang(rd(math.random(-360,360)), rd(math.random(-360,360)), rd(math.random(-360,360))), 1)
  472. lerpz(LH, "C0", LHC0 * cf(0, 0, 0) * ang(rd(math.random(-360,360)), rd(math.random(-360,360)), rd(math.random(-360,360))), 1)
  473. lerpz(LH, "C1", LHC1 * cf(0, 0, 0) * ang(rd(math.random(-360,360)), rd(math.random(-360,360)), rd(math.random(-360,360))), 1)
  474. end
  475. resetlerp()
  476. end
  477.  
  478. function MuteMusic()
  479. if s.Volume > 0 then
  480. s.Volume = 0
  481. else
  482. if LoudVolume == true then
  483. s.Volume = 6
  484. else
  485. s.Volume = 1
  486. end
  487. end
  488. end
  489.  
  490. mouse.KeyDown:connect(function(key)
  491. if attack == true then return end
  492. if c:findFirstChild("PortalGun")~=nil then
  493. if Disappeared == false then
  494. if key == "z" then
  495. DestructionPortal()
  496. end
  497. end
  498. if key == "x" then
  499. DisappearPortal()
  500. end
  501. end
  502. if Disappeared == false then
  503. if key == "q" then
  504. CreatePortalGun()
  505. end
  506. if key == "e" then
  507. ThrowGun()
  508. end
  509. end
  510. if key == "l" then
  511. MuteMusic()
  512. end
  513. if key == "m" then
  514. EpicLaugh()
  515. end
  516. end)
  517.  
  518. game:GetService("RunService").RenderStepped:connect(function()
  519. Humanoid.MaxHealth = Humanoid.MaxHealth*2
  520. Humanoid.Health = Humanoid.MaxHealth*2
  521. for i,v in pairs (c:children()) do
  522. if v.ClassName == "Accessory" then
  523. for i,v2 in pairs (v:children()) do
  524. if v2.ClassName == "Part" then
  525. v2.Anchored = false
  526. end
  527. end
  528. end
  529. end
  530. for i,v in pairs (c:children()) do
  531. if v.ClassName == "Part" then
  532. v.Anchored = false
  533. end
  534. end
  535. end)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement