SHOW:
|
|
- or go back to the newest paste.
1 | - | -- a shotgun gun used to edit velocity and use vectors and working freezeing c02 |
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 -- a shotgun gun used to edit velocity and use vectors and working freezeing c02 | |
6 | lp=game.Players.LocalPlayer | |
7 | pl=lp.Character | |
8 | tol=Instance.new("HopperBin",lp.Backpack) | |
9 | tol.Name="L_Shotgun"--ContentDownloader | |
10 | Part = function(x,y,z,color,tr,cc,an,parent) | |
11 | local p = Instance.new('Part',parent or Weapon) | |
12 | p.formFactor = 'Custom' | |
13 | p.Size = Vector3.new(x,y,z) | |
14 | p.BrickColor = BrickColor.new(color) | |
15 | p.CanCollide = cc | |
16 | p.Transparency = tr | |
17 | p.Anchored = an | |
18 | p.TopSurface,p.BottomSurface = 0,0 | |
19 | return p | |
20 | end | |
21 | s = Instance.new("Sound")s.Name = "Sound" | |
22 | s.SoundId = "http://www.roblox.com/asset?id=131632972"s.Volume = 1 | |
23 | s.Pitch = 1 s.Looped = false s.PlayOnRemove = false s.archivable = false | |
24 | s.Parent = pl.Torso | |
25 | s2 = Instance.new("Sound")s.Name = "Sound" | |
26 | s2.SoundId = "http://roblox.com/asset/?id=131072992"s2.Volume = 1 | |
27 | s2.Pitch = 1 s2.Looped = false s2.PlayOnRemove = false s2.archivable = false | |
28 | s2.Parent = pl.Torso | |
29 | s3 = Instance.new("Sound")s.Name = "Sound" | |
30 | s3.SoundId = "http://www.roblox.com/asset/?id=30624262"s3.Volume = 1 | |
31 | s3.Pitch = .225 s3.Looped = false s3.PlayOnRemove = false s3.archivable = false | |
32 | s3.Parent = pl.Torso | |
33 | Lightning = function(Start,End,Times,Offset,Color,Thickness,Transparency) | |
34 | local magz = (Start - End).magnitude local curpos = Start local trz = {-Offset,Offset} | |
35 | for i=1,Times do | |
36 | local li = Instance.new("Part",workspace) li.TopSurface =0 li.BottomSurface = 0 li.Anchored = true li.Transparency = Transparency or 0.4 li.BrickColor = BrickColor.new(Color) | |
37 | li.formFactor = "Custom" li.CanCollide = false li.Size = Vector3.new(Thickness,Thickness,magz/Times) local ofz = Vector3.new(trz[math.random(1,2)],trz[math.random(1,2)],trz[math.random(1,2)]) | |
38 | function touch(hit) | |
39 | if hit.Parent:findFirstChild("Humanoid") ~= nil and hit.Parent ~=pl then | |
40 | hit.Parent:BreakJoints() | |
41 | end end li.Touched:connect(touch) | |
42 | local trolpos = CFrame.new(curpos,End)*CFrame.new(0,0,magz/Times).p+ofz | |
43 | if Times == i then | |
44 | local magz2 = (curpos - End).magnitude li.Size = Vector3.new(Thickness,Thickness,magz2) | |
45 | li.CFrame = CFrame.new(curpos,End)*CFrame.new(0,0,-magz2/2) | |
46 | else | |
47 | li.CFrame = CFrame.new(curpos,trolpos)*CFrame.new(0,0,magz/Times/2) | |
48 | end | |
49 | curpos = li.CFrame*CFrame.new(0,0,magz/Times/2).p game.Debris:AddItem(li,0.25) | |
50 | end | |
51 | end | |
52 | Weld = function(p0,p1,x,y,z,rx,ry,rz,par) | |
53 | p0.Position = p1.Position | |
54 | local w = Instance.new('Motor',par or p0) | |
55 | w.Part0 = p0 | |
56 | w.Part1 = p1 | |
57 | w.C1 = CFrame.new(x,y,z)*CFrame.Angles(rx,ry,rz) | |
58 | return w | |
59 | end | |
60 | Mesh = function(par,num,x,y,z) | |
61 | local msh = _ | |
62 | if num == 1 then msh = Instance.new("CylinderMesh",par) | |
63 | elseif num == 2 then msh = Instance.new("SpecialMesh",par) msh.MeshType = 3 | |
64 | elseif num == 3 then msh = Instance.new("BlockMesh",par) | |
65 | elseif type(num) == 'string' then msh = Instance.new("SpecialMesh",par) msh.MeshId = num | |
66 | end | |
67 | msh.Scale = Vector3.new(x,y,z) | |
68 | return msh | |
69 | end | |
70 | shotval=0 | |
71 | function onClicked(mouse) | |
72 | Debounce = true | |
73 | if shotval==2 then print("out") return end | |
74 | if shotval==0 then print("1") | |
75 | lod.BrickColor=BrickColor.new("")s:play() | |
76 | for i=1,5 do | |
77 | Lightning(shot1.Position,mouse.Hit.p,math.random(5,10),math.random(-2.5,2.5),"Royal purple",0.05,0.35)end end | |
78 | if shotval==1 then print("2") | |
79 | lod2.BrickColor=BrickColor.new("")s:play() | |
80 | for i=1,5 do | |
81 | Lightning(shot2.Position,mouse.Hit.p,math.random(5,10),math.random(-2.5,2.5),"Royal purple",0.05,0.35)end end | |
82 | shotval=shotval+1 | |
83 | end | |
84 | function onKeyDown(key) | |
85 | key = key:lower() | |
86 | if key == "r" then | |
87 | if shotval>=2 then | |
88 | shotval=-10900 | |
89 | lod.BrickColor=BrickColor.new("Really red")s2:play() | |
90 | wait(.75) | |
91 | lod2.BrickColor=BrickColor.new("Really red")s2:play() | |
92 | wait(1) | |
93 | smoke.Enabled=true | |
94 | s3:play() | |
95 | wait(1.5) | |
96 | smoke.Enabled=false | |
97 | shotval=0 | |
98 | end end end | |
99 | tol.Selected:connect(function(mouse) | |
100 | mouse.Button1Down:connect(function() onClicked(mouse) end) | |
101 | mouse.KeyDown:connect(onKeyDown) | |
102 | mo=Instance.new("Model",pl) | |
103 | pa1= Part(.3,.3,1,'Really black',0,false,false,mo) | |
104 | wl1= Weld(pa1,pl['Right Arm'],0,-1,0,0,0,0,mo) | |
105 | pa1= Part(.3,.3,.4,'Really black',0,false,false,mo) | |
106 | wl1= Weld(pa1,pl['Right Arm'],0,-1.2,-.5,-math.pi/5,0,0,mo) | |
107 | pa1= Part(.3,2,.3,'Really black',0,false,false,mo) | |
108 | wl1= Weld(pa1,pl['Right Arm'],0,-1.75,-.6,0,0,0,mo) | |
109 | pa1= Part(.4,2,.4,'Dark stone grey',0,false,false,mo)--pa1.Material="Neon" | |
110 | wl1= Weld(pa1,pl['Right Arm'],0.2,-2.25,-.6,0,0,0,mo) | |
111 | m1= Mesh(pa1,1,1,1,1) | |
112 | pa1= Part(.4,2,.4,'Dark stone grey',0,false,false,mo)--pa1.Material="Neon" | |
113 | wl1= Weld(pa1,pl['Right Arm'],-0.2,-2.25,-.6,0,0,0,mo) | |
114 | m1= Mesh(pa1,1,1,1,1) | |
115 | shot2= Part(.3,2,.3,'Really black',0,false,false,mo) | |
116 | wl1= Weld(shot2,pl['Right Arm'],0.2,-2.26,-.6,0,0,0,mo) | |
117 | m1= Mesh(shot2,1,1,1,1) | |
118 | shot1= Part(.3,2,.3,'Really black',0,false,false,mo) | |
119 | wl1= Weld(shot1,pl['Right Arm'],-0.2,-2.26,-.6,0,0,0,mo) | |
120 | m1= Mesh(shot1,1,1,1,1) | |
121 | pa1= Part(.2,.5,.2,'Really black',0,false,false,mo) | |
122 | wl1= Weld(pa1,pl['Right Arm'],-0.2,-1.25,-.6,0,0,-math.pi/5,mo) | |
123 | pa1= Part(.2,.5,.2,'Really black',0,false,false,mo) | |
124 | wl1= Weld(pa1,pl['Right Arm'],0.2,-1.25,-.6,0,0,math.pi/5,mo) | |
125 | pa1= Part(.3,.5,.3,'Really black',0,false,false,mo) | |
126 | wl1= Weld(pa1,pl['Right Arm'],0.2,-1.2,-.7,-math.pi/5,0,0,mo) | |
127 | m1= Mesh(pa1,1,1,1,1) | |
128 | pa1= Part(.3,.5,.3,'Really black',0,false,false,mo) | |
129 | wl1= Weld(pa1,pl['Right Arm'],-0.2,-1.2,-.7,-math.pi/5,0,0,mo) | |
130 | m1= Mesh(pa1,1,1,1,1) | |
131 | lod2= Part(.2,.5,.2,'Really red',0,false,false,mo) | |
132 | wl1= Weld(lod2,pl['Right Arm'],0.2,-1.15,-.75,-math.pi/5,0,0,mo) | |
133 | m1= Mesh(lod2,1,1,1,1) | |
134 | lod= Part(.2,.5,.2,'Really red',0,false,false,mo) | |
135 | wl1= Weld(lod,pl['Right Arm'],-0.2,-1.15,-.75,-math.pi/5,0,0,mo) | |
136 | m1= Mesh(lod,1,1,1,1) | |
137 | pa1= Part(.4,.5,.5,'',0,false,false,mo) | |
138 | wl1= Weld(pa1,pl['Right Arm'],0,-2.75,-.3,0,0,0,mo) | |
139 | pa1= Part(.3,.5,.3,'Really black',0,false,false,mo) | |
140 | wl1= Weld(pa1,pl['Right Arm'],0,-2.8,0,0,0,0,mo) | |
141 | m1= Mesh(pa1,1,1,1,1) | |
142 | pa1= Part(.1,.1,.1,'Really red',0.75,false,false,mo) | |
143 | wl1= Weld(pa1,pl['Right Arm'],0,-5.55,0,0,0,0,mo) | |
144 | m1= Mesh(pa1,1,.3,30,.3) | |
145 | bb= Part(.1,.1,.1,'Bright red',0,false,false,mo) | |
146 | wl1= Weld(bb,pl['Right Arm'],0,-2,0,-math.pi/3,0,0,mo) | |
147 | m1= Mesh(bb,2,2.5,2.5,2.5) | |
148 | pa1= Part(.5,1,.5,'Bright red',0,false,false,mo) | |
149 | wl1= Weld(pa1,bb,0,-.5,0,0,0,0,mo) | |
150 | m1= Mesh(pa1,1,1,1,1) | |
151 | pa1= Part(.3,.65,.3,'',0,false,false,mo) | |
152 | wl1= Weld(pa1,bb,0,.25,0,0,0,0,mo) | |
153 | m1= Mesh(pa1,1,1,1,1) | |
154 | pa1= Part(.3,.5,.3,'Dark stone grey',0,false,false,mo) | |
155 | wl1= Weld(pa1,bb,0.1,-.74,0,0,0,0,mo) | |
156 | pa1= Part(.1,.1,.1,'Really black',0,false,false,mo) | |
157 | wl1= Weld(pa1,bb,0.25,-.74,0,0,0,0,mo) | |
158 | m1= Mesh(pa1,3,.1,2,.1) | |
159 | pa1= Part(.1,.1,.1,'Really black',0,false,false,mo) | |
160 | wl1= Weld(pa1,bb,0.25,-.74,.05,0,0,0,mo) | |
161 | m1= Mesh(pa1,3,.1,2,.1) | |
162 | pa1= Part(.1,.1,.1,'Really black',0,false,false,mo) | |
163 | wl1= Weld(pa1,bb,0.25,-.74,-.05,0,0,0,mo) | |
164 | m1= Mesh(pa1,3,.1,2,.1) | |
165 | pa1= Part(.1,.1,.1,'Really black',0,false,false,mo) | |
166 | wl1= Weld(pa1,bb,0.25,-.74,.1,0,0,0,mo) | |
167 | m1= Mesh(pa1,3,.1,2,.1) | |
168 | pa1= Part(.1,.1,.1,'Really black',0,false,false,mo) | |
169 | wl1= Weld(pa1,bb,0.25,-.74,-.1,0,0,0,mo) | |
170 | m1= Mesh(pa1,3,.1,2,.1) | |
171 | pa1= Part(.2,.6,.2,'Really black',0,false,false,mo) | |
172 | wl1= Weld(pa1,pl['Right Arm'],0,-2.5,0,0,0,0,mo) | |
173 | pa1= Part(.3,.3,1,'Really black',0,false,false,mo) | |
174 | wl1= Weld(pa1,pl['Right Arm'],0,-1.2,0,math.pi/8,0,0,mo) | |
175 | m1= Mesh(pa1,3,1,.1,1) | |
176 | smo= Part(.1,.1,.1,'Dark stone grey',1,false,false,mo) | |
177 | wl1= Weld(smo,bb,0.1,-.74,0,0,0,-math.pi/2,mo) | |
178 | smoke=Instance.new("Smoke",smo) | |
179 | smoke.Color=Color3.new(.85,0,2.55) | |
180 | smoke.RiseVelocity=100 | |
181 | smoke.Enabled=false | |
182 | ||
183 | ||
184 | ||
185 | ||
186 | -- | |
187 | bas = Part(1,1,1,'',1,false,false,mo) | |
188 | bas:BreakJoints() | |
189 | fakel = Instance.new("Weld",mo) | |
190 | fakel.Part0 = pl.Torso | |
191 | fakel.Part1 = bas | |
192 | coroutine.wrap(function() | |
193 | for angle = 0, 95, 10 do | |
194 | fakel.C0 = CFrame.new(1.5, 0.5, 0) * CFrame.Angles(math.rad(angle),math.rad(angle/8),0) | |
195 | wait() | |
196 | end | |
197 | end)() | |
198 | welditbro = Instance.new("Weld", mo) | |
199 | welditbro.C0 = CFrame.new(0, 0.5, 0) | |
200 | welditbro.Part0 = pl['Right Arm'] | |
201 | welditbro.Part1 = bas | |
202 | bas2 = Part(1,1,1,'',1,false,false,mo) | |
203 | bas2:BreakJoints() | |
204 | fakel2 = Instance.new("Weld",mo) | |
205 | fakel2.Part0 = pl.Torso | |
206 | fakel2.Part1 = bas2 | |
207 | coroutine.wrap(function() | |
208 | for angle = 0, 30, 5 do | |
209 | fakel2.C0 = CFrame.new(-1.5, 0.5, 0) * CFrame.Angles(math.rad(-angle),math.rad(-angle/5),math.rad(-angle/5)) | |
210 | wait() | |
211 | end | |
212 | end)() | |
213 | welditbro2 = Instance.new("Weld", mo) | |
214 | welditbro2.C0 = CFrame.new(0, 0.5, 0) | |
215 | welditbro2.Part0 = pl['Left Arm'] | |
216 | welditbro2.Part1 = bas2 | |
217 | end) | |
218 | tol.Deselected:connect(function(mouse) | |
219 | loop=true | |
220 | mo:remove() | |
221 | end) |