SHOW:
|
|
- or go back to the newest paste.
1 | - | p = game.Players.LocalPlayer |
1 | + | if game:GetService("RunService"):IsClient() then error("Script must be server-side in order to work; use h/ and not hl/") end |
2 | local Player,Mouse,mouse,UserInputService,ContextActionService = owner | |
3 | do | |
4 | print("FE Compatibility code by Mokiros") | |
5 | script.Parent = Player.Character | |
6 | ||
7 | --RemoteEvent for communicating | |
8 | local Event = Instance.new("RemoteEvent") | |
9 | Event.Name = "UserInput_Event" | |
10 | ||
11 | --Fake event to make stuff like Mouse.KeyDown work | |
12 | local function fakeEvent() | |
13 | local t = {_fakeEvent=true,Connect=function(self,f)self.Function=f end} | |
14 | t.connect = t.Connect | |
15 | return t | |
16 | end | |
17 | ||
18 | --Creating fake input objects with fake variables | |
19 | local m = {Target=nil,Hit=CFrame.new(),KeyUp=fakeEvent(),KeyDown=fakeEvent(),Button1Up=fakeEvent(),Button1Down=fakeEvent()} | |
20 | local UIS = {InputBegan=fakeEvent(),InputEnded=fakeEvent()} | |
21 | local CAS = {Actions={},BindAction=function(self,name,fun,touch,...) | |
22 | CAS.Actions[name] = fun and {Name=name,Function=fun,Keys={...}} or nil | |
23 | end} | |
24 | --Merged 2 functions into one by checking amount of arguments | |
25 | CAS.UnbindAction = CAS.BindAction | |
26 | ||
27 | --This function will trigger the events that have been :Connect()'ed | |
28 | local function te(self,ev,...) | |
29 | local t = m[ev] | |
30 | if t and t._fakeEvent and t.Function then | |
31 | t.Function(...) | |
32 | end | |
33 | end | |
34 | m.TrigEvent = te | |
35 | UIS.TrigEvent = te | |
36 | ||
37 | Event.OnServerEvent:Connect(function(plr,io) | |
38 | if plr~=Player then return end | |
39 | if io.isMouse then | |
40 | m.Target = io.Target | |
41 | m.Hit = io.Hit | |
42 | else | |
43 | local b = io.UserInputState == Enum.UserInputState.Begin | |
44 | if io.UserInputType == Enum.UserInputType.MouseButton1 then | |
45 | return m:TrigEvent(b and "Button1Down" or "Button1Up") | |
46 | end | |
47 | for _,t in pairs(CAS.Actions) do | |
48 | for _,k in pairs(t.Keys) do | |
49 | if k==io.KeyCode then | |
50 | t.Function(t.Name,io.UserInputState,io) | |
51 | end | |
52 | end | |
53 | end | |
54 | m:TrigEvent(b and "KeyDown" or "KeyUp",io.KeyCode.Name:lower()) | |
55 | UIS:TrigEvent(b and "InputBegan" or "InputEnded",io,false) | |
56 | end | |
57 | end) | |
58 | Event.Parent = NLS([==[ | |
59 | local Player = game:GetService("Players").LocalPlayer | |
60 | local Event = script:WaitForChild("UserInput_Event") | |
61 | ||
62 | local UIS = game:GetService("UserInputService") | |
63 | local input = function(io,a) | |
64 | if a then return end | |
65 | --Since InputObject is a client-side instance, we create and pass table instead | |
66 | Event:FireServer({KeyCode=io.KeyCode,UserInputType=io.UserInputType,UserInputState=io.UserInputState}) | |
67 | end | |
68 | UIS.InputBegan:Connect(input) | |
69 | UIS.InputEnded:Connect(input) | |
70 | ||
71 | local Mouse = Player:GetMouse() | |
72 | local h,t | |
73 | --Give the server mouse data 30 times every second, but only if the values changed | |
74 | --If player is not moving their mouse, client won't fire events | |
75 | while wait(1/30) do | |
76 | if h~=Mouse.Hit or t~=Mouse.Target then | |
77 | h,t=Mouse.Hit,Mouse.Target | |
78 | Event:FireServer({isMouse=true,Target=t,Hit=h}) | |
79 | end | |
80 | end]==],Player.Character) | |
81 | Mouse,mouse,UserInputService,ContextActionService = m,m,UIS,CAS | |
82 | end | |
83 | ||
84 | p = owner | |
85 | char = p.Character | |
86 | local char = p.Character | |
87 | torso = char.Torso | |
88 | neck = char.Torso.Neck | |
89 | hum = char.Humanoid | |
90 | Player = game:GetService("Players").LocalPlayer | |
91 | Character = Player.Character | |
92 | tors = Character.Torso | |
93 | root = Character.HumanoidRootPart | |
94 | lleg = Character["Left Leg"] | |
95 | hed = Character.Head | |
96 | rleg = Character["Right Leg"] | |
97 | rarm = Character["Right Arm"] | |
98 | larm = Character["Left Arm"] | |
99 | ||
100 | ypcall(function() | |
101 | for i,v in pairs(Character:children()) do | |
102 | if v:IsA("Hat") then | |
103 | v:Destroy() | |
104 | end | |
105 | end | |
106 | for i,v in pairs(Character:children()) do | |
107 | if v:IsA("Accessory") then | |
108 | v:Destroy() | |
109 | end | |
110 | end | |
111 | for i,v in pairs(Character:children()) do | |
112 | if v:IsA("Hair") then | |
113 | v:Destroy() | |
114 | end | |
115 | end | |
116 | end) | |
117 | ||
118 | CV="Hot pink" | |
119 | ||
120 | local txt = Instance.new("BillboardGui", char) | |
121 | txt.Adornee = char .Head | |
122 | txt.Name = "_status" | |
123 | txt.Size = UDim2.new(2, 0, 1.2, 0) | |
124 | txt.StudsOffset = Vector3.new(-9, 8, 0) | |
125 | local text = Instance.new("TextLabel", txt) | |
126 | text.Size = UDim2.new(10, 0, 7, 0) | |
127 | text.FontSize = "Size24" | |
128 | text.TextScaled = true | |
129 | text.TextTransparency = 0 | |
130 | text.BackgroundTransparency = 1 | |
131 | text.TextTransparency = 0 | |
132 | text.TextStrokeTransparency = 0 | |
133 | text.Font = "Highway" | |
134 | text.TextStrokeColor3 = BrickColor.new("Really black").Color | |
135 | ||
136 | v=Instance.new("Part") | |
137 | v.Name = "ColorBrick" | |
138 | v.Parent=p.Character | |
139 | v.FormFactor="Symmetric" | |
140 | v.Anchored=true | |
141 | v.CanCollide=false | |
142 | v.BottomSurface="Smooth" | |
143 | v.TopSurface="Smooth" | |
144 | v.Size=Vector3.new(10,5,3) | |
145 | v.Transparency=1 | |
146 | v.CFrame=char.Torso.CFrame | |
147 | v.BrickColor=BrickColor.new(CV) | |
148 | v.Transparency=1 | |
149 | text.TextColor3 = BrickColor.new("Deep orange").Color | |
150 | v.Shape="Block" | |
151 | text.Text = "Sun Gawd" | |
152 | ||
153 | hed.face.Texture = "http://www.roblox.com/asset/?id=0" | |
154 | hed.Transparency = 1 | |
155 | rleg.Transparency = 1 | |
156 | rarm.Transparency = 1 | |
157 | larm.Transparency = 1 | |
158 | lleg.Transparency = 1 | |
159 | tors.Transparency = 1 | |
160 | ||
161 | Player = game:GetService("Players").LocalPlayer | |
162 | Character = Player.Character | |
163 | rarm = Character["Right Arm"] | |
164 | larm = Character["Left Arm"] | |
165 | vt = Vector3.new | |
166 | bc = BrickColor.new | |
167 | wit = bc("Deep orange").Color | |
168 | - | local mouse = game.Players.LocalPlayer:GetMouse() |
168 | + | |
169 | local prth = Instance.new("Part",Character) | |
170 | prth.Size = vt(1.25,1.25,1.25) | |
171 | prth.CanCollide = false | |
172 | prth.Material = "Neon" | |
173 | prth.Transparency = 0.5 | |
174 | prth.BrickColor = bc("Deep orange") | |
175 | local wldh = Instance.new("Weld",Character) | |
176 | wldh.Part0 = hed | |
177 | wldh.Part1 = prth | |
178 | ||
179 | local prtrm = Instance.new("Part",Character) | |
180 | prtrm.Size = vt(2.1,2.1,1.1) | |
181 | prtrm.CanCollide = false | |
182 | prtrm.Transparency = 0.5 | |
183 | prtrm.Material = "Neon" | |
184 | prtrm.BrickColor = bc("Deep orange") | |
185 | local wldm = Instance.new("Weld",Character) | |
186 | wldm.Part0 = root | |
187 | wldm.Part1 = prtrm | |
188 | ||
189 | local prtr = Instance.new("Part",Character) | |
190 | prtr.Size = vt(1.1,2.1,1.1) | |
191 | prtr.CanCollide = false | |
192 | prtr.Transparency = 0.5 | |
193 | prtr.Material = "Neon" | |
194 | prtr.BrickColor = bc("Deep orange") | |
195 | local prtrl = Instance.new("Part",Character) | |
196 | prtrl.Size = vt(1.1,2.1,1.1) | |
197 | prtrl.CanCollide = false | |
198 | prtrl.Transparency = 0.5 | |
199 | prtrl.Material = "Neon" | |
200 | prtrl.BrickColor = bc("Deep orange") | |
201 | local eff = Instance.new("ParticleEmitter",prtr) | |
202 | eff.LightEmission = 1 | |
203 | eff.Texture = "rbxassetid://284205403" | |
204 | eff.Color = ColorSequence.new(wit) | |
205 | eff.Size = NumberSequence.new(0.5,1) | |
206 | eff.Acceleration = vt(0,25,0) | |
207 | eff.Speed = NumberRange.new(-5) | |
208 | eff.LockedToPart = false | |
209 | eff.Transparency = NumberSequence.new(0.95) | |
210 | eff.Lifetime = NumberRange.new(0.5) | |
211 | eff.Rate = 100000 | |
212 | eff.VelocitySpread = 25 | |
213 | local wld = Instance.new("Weld",Character) | |
214 | wld.Part0 = rarm | |
215 | wld.Part1 = prtr | |
216 | local wldl = Instance.new("Weld",Character) | |
217 | wldl.Part0 = rleg | |
218 | wldl.Part1 = prtrl | |
219 | ||
220 | local prtr2 = Instance.new("Part",Character) | |
221 | prtr2.Size = vt(1.1,2.1,1.1) | |
222 | prtr2.CanCollide = false | |
223 | prtr2.Transparency = 0.5 | |
224 | prtr2.Material = "Neon" | |
225 | prtr2.BrickColor = bc("Deep orange") | |
226 | local prtrl2 = Instance.new("Part",Character) | |
227 | prtrl2.Size = vt(1.1,2.1,1.1) | |
228 | prtrl2.CanCollide = false | |
229 | prtrl2.Transparency = 0.5 | |
230 | prtrl2.Material = "Neon" | |
231 | prtrl2.BrickColor = bc("Deep orange") | |
232 | local eff2 = Instance.new("ParticleEmitter",prtr2) | |
233 | eff2.LightEmission = 1 | |
234 | eff2.Texture = "rbxassetid://284205403" | |
235 | eff2.Color = ColorSequence.new(wit) | |
236 | eff2.Size = NumberSequence.new(0.5,1) | |
237 | eff2.Acceleration = vt(0,25,0) | |
238 | eff2.Speed = NumberRange.new(-5) | |
239 | eff2.LockedToPart = false | |
240 | eff2.Transparency = NumberSequence.new(0.95) | |
241 | eff2.Lifetime = NumberRange.new(0.5) | |
242 | eff2.Rate = 100000 | |
243 | eff2.VelocitySpread = 25 | |
244 | local wld2 = Instance.new("Weld",Character) | |
245 | wld2.Part0 = larm | |
246 | wld2.Part1 = prtr2 | |
247 | local wldl2 = Instance.new("Weld",Character) | |
248 | wldl2.Part0 = lleg | |
249 | wldl2.Part1 = prtrl2 | |
250 | ||
251 | tors = game.Players.LocalPlayer.Character.Torso | |
252 | vt = Vector3.new | |
253 | bc = BrickColor.new | |
254 | ||
255 | local Effect = Instance.new("Part",game.Lighting) | |
256 | Effect.BrickColor = bc("Deep orange") | |
257 | Effect.Transparency = 1 | |
258 | Effect.Anchored = true | |
259 | Effect.CanCollide = false | |
260 | Effect.Material = "Neon" | |
261 | Effect.Shape = "Ball" | |
262 | Effect.Size = vt(5,5,5) | |
263 | local fire1 = Instance.new("Fire",Effect) | |
264 | fire1.Name = "Fire" | |
265 | fire1.Heat = 0 | |
266 | fire1.Size = 30 | |
267 | fire1.SecondaryColor = bc("Really black").Color | |
268 | fire1.Color = bc("Deep orange").Color | |
269 | local fire2 = Instance.new("Fire",Effect) | |
270 | fire2.Name = "Fire2" | |
271 | fire2.Heat = 0 | |
272 | fire2.Size = 25 | |
273 | fire2.SecondaryColor = bc("Really black").Color | |
274 | fire2.Color = bc("Neon orange").Color | |
275 | ||
276 | function Explode(rad,par) | |
277 | local expart = Instance.new("Part",script.Parent) | |
278 | local expart2 = Instance.new("Part",script.Parent) | |
279 | local snd = Instance.new("Sound",expart) | |
280 | - | mouse.KeyDown:connect(function(k) |
280 | + | |
281 | snd.Volume = 2.5 | |
282 | local partMesh = Instance.new("SpecialMesh",expart) | |
283 | partMesh.MeshType = "Sphere" | |
284 | local partMesh2 = Instance.new("SpecialMesh",expart2) | |
285 | partMesh2.MeshType = "Sphere" | |
286 | local expld = Instance.new("Explosion", script.Parent) | |
287 | expld.BlastRadius = rad | |
288 | expld.Position = par.Position | |
289 | partMesh.Scale = vt(rad,rad,rad) | |
290 | expart.Size = vt(1,1,1)*1.5 | |
291 | expart.Transparency = 0.5 | |
292 | expart.Anchored = true | |
293 | expart.Material = "Neon" | |
294 | expart.BrickColor = bc("Deep orange") | |
295 | expart.CFrame = par.CFrame | |
296 | partMesh2.Scale = vt(rad,rad,rad) | |
297 | expart2.Size = vt(1.15,1.15,1.15)*1.5 | |
298 | expart2.Transparency = 0.5 | |
299 | expart2.Anchored = true | |
300 | expart2.Material = "Neon" | |
301 | expart2.BrickColor = bc("Bright orange") | |
302 | expart2.CFrame = par.CFrame | |
303 | snd:Play() | |
304 | for i = 0, 100 do | |
305 | expart.Transparency = expart.Transparency + 0.005 | |
306 | partMesh.Scale = partMesh.Scale + vt(0.25,0.25,0.25) | |
307 | expart.CFrame = expart.CFrame | |
308 | expart2.Transparency = expart.Transparency + 0.005 | |
309 | partMesh2.Scale = partMesh2.Scale + vt(0.25,0.25,0.25) | |
310 | expart2.CFrame = expart.CFrame | |
311 | wait(0) | |
312 | end | |
313 | snd.Parent = nil | |
314 | expart.Parent = nil | |
315 | expart2.Parent = nil | |
316 | expld.Parent = nil | |
317 | end | |
318 | ||
319 | function Explode2(rad,par) | |
320 | local expart = Instance.new("Part",script.Parent) | |
321 | local expart2 = Instance.new("Part",script.Parent) | |
322 | local snd = Instance.new("Sound",expart) | |
323 | snd.SoundId = "rbxassetid://165969964" | |
324 | snd.Volume = 3 | |
325 | local partMesh = Instance.new("SpecialMesh",expart) | |
326 | partMesh.MeshType = "Sphere" | |
327 | local partMesh2 = Instance.new("SpecialMesh",expart2) | |
328 | partMesh2.MeshType = "Sphere" | |
329 | local expld = Instance.new("Explosion", script.Parent) | |
330 | expld.BlastRadius = rad | |
331 | expld.Position = par.Position | |
332 | partMesh.Scale = vt(rad,rad,rad) | |
333 | expart.Size = vt(1,1,1)*1.5 | |
334 | expart.Transparency = 0.5 | |
335 | expart.Anchored = true | |
336 | expart.Material = "Neon" | |
337 | expart.BrickColor = bc("Deep orange") | |
338 | expart.CFrame = par.CFrame | |
339 | partMesh2.Scale = vt(rad,rad,rad) | |
340 | expart2.Size = vt(1.15,1.15,1.15)*1.5 | |
341 | expart2.Transparency = 0.5 | |
342 | expart2.Anchored = true | |
343 | expart2.Material = "Neon" | |
344 | expart2.BrickColor = bc("Bright orange") | |
345 | expart2.CFrame = par.CFrame | |
346 | snd:Play() | |
347 | for i = 0, 100 do | |
348 | expart.Transparency = expart.Transparency + 0.005 | |
349 | partMesh.Scale = partMesh.Scale + vt(0.25,0.25,0.25) | |
350 | expart.CFrame = expart.CFrame | |
351 | expart2.Transparency = expart.Transparency + 0.005 | |
352 | partMesh2.Scale = partMesh2.Scale + vt(0.25,0.25,0.25) | |
353 | expart2.CFrame = expart.CFrame | |
354 | wait(0) | |
355 | end | |
356 | snd.Parent = nil | |
357 | expart.Parent = nil | |
358 | expart2.Parent = nil | |
359 | expld.Parent = nil | |
360 | end | |
361 | ||
362 | Mouse.KeyDown:connect(function(k) | |
363 | ||
364 | k = k:lower() | |
365 | if k == "q" then | |
366 | local spart = Effect:Clone() | |
367 | spart.Parent = game.Players.LocalPlayer.Character | |
368 | spart.Transparency = 0 | |
369 | spart.Position = game.Players.LocalPlayer.Character.Torso.Position + game.Players.LocalPlayer.Character.Torso.CFrame.lookVector*5 | |
370 | wait() | |
371 | spart.Position = game.Players.LocalPlayer.Character.Torso.Position + game.Players.LocalPlayer.Character.Torso.CFrame.lookVector*15 | |
372 | wait() | |
373 | spart.Position = game.Players.LocalPlayer.Character.Torso.Position + game.Players.LocalPlayer.Character.Torso.CFrame.lookVector*25 | |
374 | wait() | |
375 | spart.Position = game.Players.LocalPlayer.Character.Torso.Position + game.Players.LocalPlayer.Character.Torso.CFrame.lookVector*35 | |
376 | wait() | |
377 | spart.Position = game.Players.LocalPlayer.Character.Torso.Position + game.Players.LocalPlayer.Character.Torso.CFrame.lookVector*45 | |
378 | wait() | |
379 | spart.Position = game.Players.LocalPlayer.Character.Torso.Position + game.Players.LocalPlayer.Character.Torso.CFrame.lookVector*55 | |
380 | wait() | |
381 | spart.Position = game.Players.LocalPlayer.Character.Torso.Position + game.Players.LocalPlayer.Character.Torso.CFrame.lookVector*65 | |
382 | wait() | |
383 | spart.Position = game.Players.LocalPlayer.Character.Torso.Position + game.Players.LocalPlayer.Character.Torso.CFrame.lookVector*75 | |
384 | wait() | |
385 | spart.Position = game.Players.LocalPlayer.Character.Torso.Position + game.Players.LocalPlayer.Character.Torso.CFrame.lookVector*85 | |
386 | wait() | |
387 | spart.Position = game.Players.LocalPlayer.Character.Torso.Position + game.Players.LocalPlayer.Character.Torso.CFrame.lookVector*95 | |
388 | wait() | |
389 | spart.Position = game.Players.LocalPlayer.Character.Torso.Position + game.Players.LocalPlayer.Character.Torso.CFrame.lookVector*105 | |
390 | spart.Transparency = 1 | |
391 | spart.Fire2:Destroy() | |
392 | spart.Fire:Destroy() | |
393 | Explode(25,spart) | |
394 | spart:Destroy() | |
395 | end | |
396 | if k == "e" then | |
397 | local spart = Effect:Clone() | |
398 | spart.Parent = game.Players.LocalPlayer.Character | |
399 | spart.Transparency = 0 | |
400 | spart.Anchored = false | |
401 | spart.Position = game.Players.LocalPlayer.Character.Torso.Position + game.Players.LocalPlayer.Character.Torso.CFrame.lookVector*0 | |
402 | spart.Position = spart.Position + vt(0,100,0) | |
403 | spart.Velocity = game.Players.LocalPlayer.Character.Torso.CFrame.lookVector*150 | |
404 | wait(1) | |
405 | spart.Transparency = 1 | |
406 | spart.Fire2:Destroy() | |
407 | spart.Fire:Destroy() | |
408 | Explode2(75,spart) | |
409 | spart:Destroy() | |
410 | end | |
411 | if k == "r" then | |
412 | local ff = Instance.new("ForceField",game.Players.LocalPlayer.Character) | |
413 | game.Players.LocalPlayer.Character.Torso.Velocity = game.Players.LocalPlayer.Character.Torso.CFrame.lookVector*275 | |
414 | wait(0.75) | |
415 | game.Players.LocalPlayer.Character.Torso.Velocity = game.Players.LocalPlayer.Character.Torso.CFrame.lookVector*-165 | |
416 | Explode(30,game.Players.LocalPlayer.Character.Torso) | |
417 | wait(0.5) | |
418 | ff:Destroy() | |
419 | end | |
420 | if k == "f" then | |
421 | local ff = Instance.new("ForceField",game.Players.LocalPlayer.Character) | |
422 | for i = 0, 10 do | |
423 | game.Players.LocalPlayer.Character.Torso.CFrame = game.Players.LocalPlayer.Character.Torso.CFrame + Vector3.new(0,10,0) | |
424 | wait(0) | |
425 | end | |
426 | for i = 0, 5 do | |
427 | game.Players.LocalPlayer.Character.Torso.CFrame = game.Players.LocalPlayer.Character.Torso.CFrame + Vector3.new(0,1,0) | |
428 | wait(0) | |
429 | end | |
430 | game.Players.LocalPlayer.Character.Torso.Anchored = true | |
431 | wait(1.5) | |
432 | game.Players.LocalPlayer.Character.Torso.Anchored = false | |
433 | for i = 0, 10 do | |
434 | game.Players.LocalPlayer.Character.Torso.CFrame = game.Players.LocalPlayer.Character.Torso.CFrame + Vector3.new(0,-1,0) | |
435 | wait(0) | |
436 | end | |
437 | wait(0.25) | |
438 | Explode2(62.5,game.Players.LocalPlayer.Character.Torso) | |
439 | wait(0.5) | |
440 | ff:Destroy() | |
441 | end | |
442 | end) |