SHOW:
|
|
- or go back to the newest paste.
1 | --Revolvar u derpnobs | |
2 | --[[By madiik and don't even steal eet durp or i'll make an another skrept | |
3 | that will insult Yoo and i'll follow yoo everywhere, so don't even try nub | |
4 | nobs = stealarz]]-- | |
5 | local plr = game:service'Players'.LocalPlayer | |
6 | local char = plr.Character | |
7 | - | local mouse = plr:GetMouse() |
7 | + | |
8 | local head = char.Head | |
9 | local ra = char:findFirstChild("Right Arm") | |
10 | local la = char:findFirstChild("Left Arm") | |
11 | local rl = char:findFirstChild("Right Leg") | |
12 | local ll = char:findFirstChild("Left Leg") | |
13 | local rs = torso:findFirstChild("Right Shoulder") | |
14 | local ls = torso:findFirstChild("Left Shoulder") | |
15 | local neck = torso:findFirstChild("Neck") | |
16 | ||
17 | local spread = -1 | |
18 | local spread2 = 1 | |
19 | local used = false | |
20 | local shootdebounce = false | |
21 | local sound = Instance.new("Sound", head) | |
22 | local ammo = 6 | |
23 | sound.SoundId = "http://roblox.com/asset/?id=10209875" | |
24 | sound.Volume = 0.5 | |
25 | local sound2 = Instance.new("Sound", head) | |
26 | sound2.SoundId = "http://roblox.com/asset/?id=10209590" | |
27 | sound2.Volume = 1 | |
28 | local Screen = Instance.new("ScreenGui", plr:findFirstChild("PlayerGui")) | |
29 | local TextBox = Instance.new("TextLabel", Screen) | |
30 | TextBox.Position = UDim2.new(0.1, 0, 0.95, 0) | |
31 | TextBox.Size = UDim2.new(0, 200, 0.05, 0) | |
32 | TextBox.BackgroundTransparency = 1 | |
33 | game:service'RunService'.Stepped:connect(function() | |
34 | TextBox.Text = ("Ammo: "..ammo) | |
35 | end) | |
36 | TextBox.Font = "SourceSansBold" | |
37 | TextBox.TextColor3 = Color3.new(1, 1, 1) | |
38 | TextBox.FontSize = "Size36" | |
39 | TextBox.TextStrokeTransparency = 0 | |
40 | TextBox.BackgroundColor = BrickColor.new("Navy blue") | |
41 | pcall(function() | |
42 | char:findFirstChild("REVOLVER24/7"):Destroy() | |
43 | end) | |
44 | local main = Instance.new("Model", char) | |
45 | main.Name = "REVOLVER24/7" | |
46 | function part(parent, size, formfactor, color, collide, transparency) | |
47 | local p=Instance.new("Part", parent) | |
48 | p.FormFactor=formfactor | |
49 | p.CanCollide=false | |
50 | p.Size=size | |
51 | p.Locked=true | |
52 | p.Transparency=transparency | |
53 | p.Position=torso.Position | |
54 | p.BrickColor=color | |
55 | p.FrontSurface="SmoothNoOutlines" | |
56 | p.BackSurface="SmoothNoOutlines" | |
57 | p.LeftSurface="SmoothNoOutlines" | |
58 | p.BottomSurface="SmoothNoOutlines" | |
59 | p.TopSurface="SmoothNoOutlines" | |
60 | p.RightSurface="SmoothNoOutlines" | |
61 | return p | |
62 | end | |
63 | function wedge(parent, size, formfactor, color, collide) | |
64 | local p=Instance.new("Wedge", parent) | |
65 | p.FormFactor=formfactor | |
66 | p.CanCollide=false | |
67 | p.Size=size | |
68 | p.Locked=true | |
69 | p.Position = torso.Position | |
70 | p.BrickColor=color | |
71 | p.FrontSurface="SmoothNoOutlines" | |
72 | p.BackSurface="SmoothNoOutlines" | |
73 | p.LeftSurface="SmoothNoOutlines" | |
74 | p.BottomSurface="SmoothNoOutlines" | |
75 | p.TopSurface="SmoothNoOutlines" | |
76 | p.RightSurface="SmoothNoOutlines" | |
77 | return p | |
78 | end | |
79 | function weld(c0, c1, part1, part0) | |
80 | local wel=Instance.new("Weld", main) | |
81 | wel.Part0 = part0 | |
82 | wel.Part1 = part1 | |
83 | wel.C0 = c0 | |
84 | wel.C1 = c1 | |
85 | return wel | |
86 | end | |
87 | function specialmesh(parent, meshType, scale, meshId, texture) | |
88 | local mesh = Instance.new("SpecialMesh", parent) | |
89 | mesh.Scale = scale | |
90 | mesh.MeshType = meshType | |
91 | mesh.MeshId = meshId | |
92 | mesh.TextureId = texture | |
93 | return mesh | |
94 | end | |
95 | ||
96 | ||
97 | local p = part(main, Vector3.new(0.3, 0.9, 0.3), "Custom", BrickColor.Black(), false, 0) | |
98 | local w = weld(CFrame.new(0, -.2, 0.9) * CFrame.Angles(math.rad(105), 0, 0), CFrame.new(), ra, p) | |
99 | local p1 = part(main, Vector3.new(0.3, 0.5, 0.3), "Custom", BrickColor.Black(), false, 0) | |
100 | local w1 = weld(CFrame.new(0, -.4, -.1) * CFrame.Angles(math.rad(30), 0, 0), CFrame.new(), p, p1) | |
101 | local p2 = part(main, Vector3.new(0.2, 1, 0.4), "Custom", BrickColor.Gray(), false, 0) | |
102 | local w2 = weld(CFrame.new(0, -.2, 0.9) * CFrame.Angles(math.rad(105), 0, 0), CFrame.new(), ra, p2) | |
103 | local p3 = part(main, Vector3.new(0.2, 0.6, 0.4), "Custom", BrickColor.Gray(), false, 0) | |
104 | local w3 = weld(CFrame.new(0, -.4, -.1) * CFrame.Angles(math.rad(30), 0, 0), CFrame.new(), p2, p3) | |
105 | local p4 = part(main, Vector3.new(0.205, 1.2, 0.3), "Custom", BrickColor.Gray(), false, 0) | |
106 | local w4 = weld(CFrame.new(0, 1.65, 0.55), CFrame.new(), ra, p4) | |
107 | local p5 = part(main, Vector3.new(0.2, 1.2, 0.2), "Custom", BrickColor.Gray(), false, 0) | |
108 | local w5 = weld(CFrame.new(0, 0.05, 0.1), CFrame.new(), p4, p5) | |
109 | local p6 = part(main, Vector3.new(0.2, 1.2, 0.2), "Custom", BrickColor.Black(), false, 0) | |
110 | Instance.new("CylinderMesh", p6).Scale = Vector3.new(0.5, 1, 0.5) | |
111 | local w6 = weld(CFrame.new(0, 0.002, 0.02), CFrame.new(), p5, p6) | |
112 | local p7 = part(main, Vector3.new(0.34, 0.37, 0.34), "Custom", BrickColor.Gray(), false, 0) | |
113 | local p7mesh = Instance.new("CylinderMesh", p7) | |
114 | local w7 = weld(CFrame.new(0, 0, 0), CFrame.new(), p6, p7) | |
115 | local p8 = part(main, Vector3.new(0.2, 1.2, 0.2), "Custom", BrickColor.Gray(), false, 0) | |
116 | local p8mesh = Instance.new("CylinderMesh", p8) | |
117 | local w8 = weld(CFrame.new(0, -0.01, 0.05), CFrame.new(), p6, p8) | |
118 | ||
119 | ||
120 | function equip() | |
121 | ar = Instance.new("Part", main) | |
122 | ar.FormFactor = "Custom" | |
123 | ar.Size = Vector3.new(1, 1, 1) | |
124 | ar.Transparency = 1 | |
125 | ar.CanCollide = false | |
126 | ar.Locked = true | |
127 | ar:breakJoints() | |
128 | ||
129 | ||
130 | fakel = Instance.new("Weld", main) | |
131 | fakel.Part0 = char.Torso | |
132 | fakel.Part1 = ar | |
133 | fakel.C0 = CFrame.new(1.5, 0.5, 0) | |
134 | welditbro = Instance.new("Weld", main) | |
135 | welditbro.C0 = CFrame.new(0, 0.5, 0) | |
136 | welditbro.Part0 = ra | |
137 | welditbro.Part1 = ar | |
138 | ||
139 | coroutine.wrap(function() | |
140 | for angle = 0, 70, 10 do | |
141 | neck.C0 = neck.C0 * CFrame.Angles(0, 0, -math.rad(10)) | |
142 | wait() | |
143 | end | |
144 | end)() | |
145 | coroutine.wrap(function() | |
146 | for i = 0, 90, 10 do | |
147 | fakel.C0 = CFrame.new(1.5, 0.5, 0) * CFrame.Angles(math.rad(i), 0, math.rad(i)) | |
148 | wait() | |
149 | end | |
150 | end)() | |
151 | ||
152 | bg2 = Instance.new("BodyGyro", torso) | |
153 | bg2.P = 9999 | |
154 | bg2.D = 2000 | |
155 | bg2.maxTorque = Vector3.new(4e+005,4e+005,4e+005)*math.huge | |
156 | ||
157 | for i = 0, 90, 10 do | |
158 | bg2.cframe = CFrame.new(torso.Position,Vector3.new(mouse.hit.p.x,torso.Position.y,mouse.hit.p.z)) * CFrame.Angles(0, math.rad(i), 0) | |
159 | wait() | |
160 | end | |
161 | coroutine.wrap(function() | |
162 | while used do | |
163 | bg2.cframe = CFrame.new(torso.Position,Vector3.new(mouse.hit.p.x,torso.Position.y,mouse.hit.p.z)) * CFrame.Angles(0, math.rad(90), 0) | |
164 | game:service'RunService'.Stepped:wait() | |
165 | end | |
166 | end)() | |
167 | debounce = false | |
168 | end | |
169 | ||
170 | ||
171 | function reload() | |
172 | if not used then return end | |
173 | local ar2 = Instance.new("Part", main) | |
174 | ar2.FormFactor = "Custom" | |
175 | ar2.Size = Vector3.new(1, 1, 1) | |
176 | ar2.Transparency = 1 | |
177 | ar2.CanCollide = false | |
178 | ar2.Locked = true | |
179 | ar2:breakJoints() | |
180 | ||
181 | ||
182 | local fakel2 = Instance.new("Weld", main) | |
183 | fakel2.Part0 = char.Torso | |
184 | fakel2.Part1 = ar2 | |
185 | fakel2.C0 = CFrame.new(-1.5, 0.5, 0) | |
186 | local welditbro2 = Instance.new("Weld", main) | |
187 | welditbro2.C0 = CFrame.new(0, 0.5, 0) | |
188 | welditbro2.Part0 = la | |
189 | welditbro2.Part1 = ar2 | |
190 | ||
191 | coroutine.wrap(function() | |
192 | for angle = 0, 70, 10 do | |
193 | neck.C0 = neck.C0 * CFrame.Angles(0, 0, math.rad(10)) | |
194 | wait() | |
195 | end | |
196 | for angle = 0, 70, 10 do | |
197 | neck.C0 = neck.C0 * CFrame.Angles(math.rad(5), 0, 0) | |
198 | wait() | |
199 | end | |
200 | end)() | |
201 | coroutine.wrap(function() | |
202 | for angle = 90, -60, -10 do | |
203 | fakel.C0 = CFrame.new(1.5, 0.5, 0) * CFrame.Angles(math.rad(angle + 80), 0, math.rad(angle)) | |
204 | wait() | |
205 | end | |
206 | end)() | |
207 | for angle = 0, 60, 10 do | |
208 | fakel2.C0 = CFrame.new(-1.5, 0.5, 0) * CFrame.Angles(math.rad(angle), 0, math.rad(angle)) | |
209 | wait() | |
210 | end | |
211 | wait(2) | |
212 | ammo = 6 | |
213 | coroutine.wrap(function() | |
214 | for angle = -60, 90, 10 do | |
215 | fakel.C0 = CFrame.new(1.5, 0.5, 0) * CFrame.Angles(math.rad(angle + 80), 0, math.rad(angle)) | |
216 | wait() | |
217 | end | |
218 | fakel.C0 = CFrame.new(1.5, 0.5, 0) * CFrame.Angles(math.rad(90), 0, math.rad(90)) | |
219 | end)() | |
220 | coroutine.wrap(function() | |
221 | for angle = 0, 70, 10 do | |
222 | neck.C0 = neck.C0 * CFrame.Angles(-math.rad(5), 0, 0) | |
223 | wait() | |
224 | end | |
225 | for angle = 0, 70, 10 do | |
226 | neck.C0 = neck.C0 * CFrame.Angles(0, 0,-math.rad(10)) | |
227 | wait() | |
228 | end | |
229 | end)() | |
230 | for angle = 60, 0, -10 do | |
231 | fakel2.C0 = CFrame.new(-1.5, 0.5, 0) * CFrame.Angles(math.rad(angle), 0, math.rad(angle)) | |
232 | wait() | |
233 | end | |
234 | pcall(function() | |
235 | ar2:Destroy() | |
236 | fakel2:Destory() | |
237 | welditbro2:Destroy() | |
238 | end) | |
239 | shootdebounce = false | |
240 | ||
241 | end | |
242 | function unequip() | |
243 | coroutine.wrap(function() | |
244 | for angle = 0, 70, 10 do | |
245 | neck.C0 = neck.C0 * CFrame.Angles(0, 0, math.rad(10)) | |
246 | wait() | |
247 | end | |
248 | end)() | |
249 | coroutine.wrap(function() | |
250 | for i = 90, 0, -10 do | |
251 | fakel.C0 = CFrame.new(1.5, 0.5, 0) * CFrame.Angles(math.rad(i), 0, math.rad(i)) | |
252 | wait() | |
253 | end | |
254 | end)() | |
255 | for i = 90, 0, -10 do | |
256 | bg2.cframe = CFrame.new(torso.Position,Vector3.new(mouse.hit.p.x,torso.Position.y,mouse.hit.p.z)) * CFrame.Angles(0, math.rad(i), 0) | |
257 | wait() | |
258 | end | |
259 | pcall(function() | |
260 | bg2:Destroy() | |
261 | fakel:Destroy() | |
262 | welditbro:Destroy() | |
263 | ar:Destroy() | |
264 | end) | |
265 | end | |
266 | ||
267 | ||
268 | mouse.KeyDown:connect(function(key) | |
269 | if key == "q" then | |
270 | if shootdebounce then return end | |
271 | if debounce then return end | |
272 | used = not used | |
273 | if used then | |
274 | debounce = true | |
275 | equip() | |
276 | else | |
277 | debounce = true | |
278 | used = false | |
279 | unequip() | |
280 | debounce = false | |
281 | end | |
282 | ||
283 | end | |
284 | if key == "r" then | |
285 | if shootdebounce then return end | |
286 | if debounce then return end | |
287 | if not used then return end | |
288 | shootdebounce = true | |
289 | reload() | |
290 | end | |
291 | end) | |
292 | ||
293 | ||
294 | mouse.Button1Down:connect(function(mouse) | |
295 | if not used then return end | |
296 | if shootdebounce then return end | |
297 | if ammo < 1 then sound2:play() return end | |
298 | if debounce then return end | |
299 | shootdebounce = true | |
300 | coroutine.wrap(function() | |
301 | sound:play() | |
302 | ||
303 | ammo = ammo - 1 | |
304 | local muz = part(main, Vector3.new(0.8, 1.2, 0.8), "Custom", BrickColor.Yellow(), false, 0) | |
305 | muz.Transparency = 0.2 | |
306 | specialmesh(muz, "Sphere", Vector3.new(1, 1, 1), "", "") | |
307 | local localweld = weld(CFrame.new(0, 1.2, 0), CFrame.new(), p5, muz) | |
308 | local muzflash = Instance.new("PointLight", muz) | |
309 | muzflash.Color = Color3.new(1, 1, 0) | |
310 | muzflash.Range = 19 | |
311 | ||
312 | pcall(function() | |
313 | local ray = Ray.new(muz.CFrame.p, ((plr:GetMouse().Hit.p + Vector3.new(math.random(spread,spread2), math.random(spread,spread2), math.random(spread,spread2))/4) - muz.CFrame.p).unit*1000) | |
314 | local hit, position = game.Workspace:FindPartOnRay(ray, char) | |
315 | ||
316 | ||
317 | --do damage to any humanoids hit | |
318 | pcall(function() | |
319 | ||
320 | if hit.Parent:IsA("Hat") then | |
321 | hit.Parent.Parent:findFirstChild("Humanoid"):TakeDamage(30) | |
322 | end | |
323 | if hit:IsA("Part") and hit.Name == "Head" then | |
324 | hit.Parent:findFirstChild("Humanoid"):TakeDamage(50) | |
325 | end | |
326 | ||
327 | if hit:IsA("Part") and hit.Name == "Torso" then | |
328 | coroutine.wrap(function() | |
329 | local restored = hit.Parent:findFirstChild("Humanoid").WalkSpeed | |
330 | hit.Parent:findFirstChild("Humanoid"):TakeDamage(30) | |
331 | hit.Parent:findFirstChild("Humanoid").PlatformStand = true | |
332 | wait(1) | |
333 | hit.Parent:findFirstChild("Humanoid").WalkSpeed = 4 | |
334 | hit.Parent:findFirstChild("Humanoid").PlatformStand = false | |
335 | wait(8) | |
336 | hit.Parent:findFirstChild("Humanoid").WalkSpeed = restored | |
337 | end)() | |
338 | end | |
339 | ||
340 | if hit:IsA("Part") and hit.Name == "Left Leg" or hit.Name == "Right Leg" then | |
341 | hit.Parent:findFirstChild("Humanoid"):TakeDamage(10) | |
342 | hit.Parent:findFirstChild("Humanoid").WalkSpeed = hit.Parent:findFirstChild("Humanoid").WalkSpeed - 1 | |
343 | end | |
344 | if hit:IsA("Part") and hit.Name == "Left Arm" or hit.Name == "Right Arm" then | |
345 | hit.Parent:findFirstChild("Humanoid"):TakeDamage(10) | |
346 | hit.Parent:findFirstChild("Humanoid").WalkSpeed = hit.Parent:findFirstChild("Humanoid").WalkSpeed - 0.2 | |
347 | end | |
348 | end) | |
349 | ||
350 | --draw the ray | |
351 | ||
352 | local distance = (position - muz.CFrame.p).magnitude | |
353 | local rayPart = Instance.new("Part", char) | |
354 | rayPart.Name = "RayPart" | |
355 | rayPart.BrickColor = BrickColor.new("White") | |
356 | rayPart.Transparency = 0 | |
357 | rayPart.Anchored = true | |
358 | rayPart.CanCollide = false | |
359 | ||
360 | rayPart.TopSurface = Enum.SurfaceType.Smooth | |
361 | rayPart.BottomSurface = Enum.SurfaceType.Smooth | |
362 | rayPart.formFactor = Enum.FormFactor.Custom | |
363 | rayPart.Size = Vector3.new(0.2, distance, 0.2) | |
364 | Instance.new("CylinderMesh", rayPart) | |
365 | rayPart.CFrame = CFrame.new(position, muz.CFrame.p) * CFrame.new(0, 0, -distance/2) * CFrame.Angles(math.pi/2, 0, 0) | |
366 | ||
367 | ||
368 | coroutine.wrap(function() | |
369 | for i = 0, 30 do | |
370 | if rayPart == nil then return end | |
371 | rayPart.Transparency = rayPart.Transparency + 0.1 | |
372 | if muz == nil then return end | |
373 | muz.Transparency = muz.Transparency + 0.2 | |
374 | wait() | |
375 | end | |
376 | end)() | |
377 | end) | |
378 | wait(0.05) | |
379 | muz:Destroy() | |
380 | localweld:Destroy() | |
381 | game:service'Debris':AddItem(rayPart, 0) | |
382 | end)() | |
383 | for i = 0, 30, 15 do | |
384 | fakel.C0 = CFrame.new(1.5, 0.5, 0) * CFrame.Angles(math.rad(90), math.rad(i), math.rad(90)) | |
385 | wait() | |
386 | end | |
387 | wait() | |
388 | for i = 30, 0, -10 do | |
389 | fakel.C0 = CFrame.new(1.5, 0.5, 0) * CFrame.Angles(math.rad(90), math.rad(i), math.rad(90)) | |
390 | wait() | |
391 | end | |
392 | shootdebounce = false | |
393 | ||
394 | end) |