View difference between Paste ID: HwyZCpYC and CGPWBjg6
SHOW: | | - or go back to the newest paste.
1
local Plr = game.Players.LocalPlayer
2
local Char =  Plr.Character
3
local Cam = game.Workspace.CurrentCamera
4
local Run = game:GetService('RunService')
5
local Path = nil
6
local Cv = false
7
local visenable = false
8
local Clr = 'Really red'
9
local TBox = nil
10
11
local Songs = {142404192,178043049,180440170,180442904,180466429}
12
local ID = 000000
13
14
local mr = math.rad
15
Char.HumanoidRootPart.RootJoint.C0 = CFrame.new(mr(-1.56),mr(-.3),mr(1.5))
16
Char.Humanoid.WalkSpeed = -16
17
18
function Armor(Part,Size,Color,Val,VColor)
19
	
20
	local P = Instance.new('Part')
21
	P.Name = tostring(Part)..'Armor'
22
	P.CanCollide = false
23
	P.BrickColor =  BrickColor.new(Color)
24
	P.Parent = Char
25
	P.FormFactor = 'Custom'
26
	P.Anchored = false
27
	P.Size = Size
28
	P.BottomSurface = 'Smooth'
29
	P.TopSurface = 'Smooth'
30
	P.Locked = true
31
	Path = P
32
	
33
	if Val then
34
		local Box = Instance.new('SelectionBox',P)
35
		Box.Adornee = P
36
		Box.Color = BrickColor.new(VColor)
37
		Box.Transparency = .5
38
		TBox = Box
39
	end
40
	
41
	local Weld = Instance.new('Weld')
42
	Weld.Parent = P
43
	Weld.Part0 = Part
44
	Weld.Part1 = P
45
end
46
47
Plr:GetMouse().KeyDown:connect(function(key)
48
	if key == 'm' then
49
		ID = nil
50
		ID = Songs[math.random(1,#Songs)]
51
		for _,v in pairs(Plr.Character.Head:GetChildren()) do
52
			if v.ClassName == 'Sound' then
53
				v.Looped=false
54
				v.PlayOnRemove=false
55
				v:Pause()
56
				wait()
57
				v:remove()
58
			end
59
		end
60
		local S=Instance.new('Sound',Plr.Character.Head)
61
		S.Volume=1
62
		S.SoundId='rbxassetid://'..ID
63
		wait()
64
		Chat('Now playing '..game:GetService("MarketplaceService"):GetProductInfo(ID)['Name'])
65
		S:Play()
66
	elseif key == 'n' then
67
		for _,v in pairs(Plr.Character.Head:GetChildren()) do
68
			if v.ClassName == 'Sound' then
69
				v.Looped=false
70
				v.PlayOnRemove=false
71
				v:Pause()
72
				wait()
73
				v:remove()
74
			end
75
		end
76
	elseif key == 'v' then
77
		TBox.Transparency = 0
78
		for _,v in pairs(Plr.Character:GetChildren()) do
79
			if v.ClassName == 'Part'  then
80
				spawn(function()
81
					for i = 0,1,.1 do
82
						v.Transparency = v.Transparency + .1
83
						TBox.Transparency = TBox.Transparency + .1
84
						Plr.Character.Humanoid.WalkSpeed = Plr.Character.Humanoid.WalkSpeed + 1
85
						Plr.Character.Head.face.Transparency = Plr.Character.Head.face.Transparency + .1
86
						wait()
87
					end
88
				end)
89
			end
90
		end
91
	elseif key == "b" then
92
		TBox.Transparency = 1
93
		for _,v in pairs(Plr.Character:GetChildren()) do
94
			if v.ClassName == 'Part'  then
95
				spawn(function()
96
					for i = 0,1,.1 do
97
						v.Transparency = v.Transparency - .1
98
						TBox.Transparency = TBox.Transparency - .1
99
						Plr.Character.Humanoid.WalkSpeed = Plr.Character.Humanoid.WalkSpeed - 1
100
						Plr.Character.Head.face.Transparency = Plr.Character.Head.face.Transparency - 1
101
						wait()
102
					end
103
				end)
104
			end
105
		end
106
	end
107
	Plr.Character.Humanoid.WalkSpeed=16
108
end)
109
110
Plr.Character.Humanoid.Died:connect(function()
111
	for _,v in pairs(Plr.Character.Head:GetChildren()) do
112
		if v.ClassName == 'Sound' then
113
			v.Looped=false
114
			v.PlayOnRemove=false
115
			v:Pause()
116
			wait()
117
			v:remove()
118
		end
119
	end
120
end)
121
122
function Chat(msg)
123
	if Char.Head.Parent then
124
	pcall(function()
125
	local Gui = Instance.new('BillboardGui',Char.Head)
126
	Gui.ExtentsOffset = Vector3.new(0,3,0)
127
	Gui.Size = UDim2.new(0,200,0,300)
128
	local Frame = Instance.new('Frame',Gui)
129
	Frame.BackgroundTransparency = 1
130
	Frame.Size = UDim2.new(1,0,1,0)
131
	local Txt = Instance.new('TextLabel',Frame)
132
	Txt.BackgroundTransparency = 1
133
	Txt.Size = UDim2.new(1,0,1,0)
134
	Txt.Font = 'ArialBold'
135
	Txt.FontSize = 'Size24'
136
	Txt.Text = ''
137
	Txt.TextColor3 = Color3.new(255/255,255/255,255/255)
138
	Txt.TextStrokeColor3 = Color3.new(0/255,0/255,0/255)
139
	Txt.TextStrokeTransparency = .5
140
	Txt.TextWrapped = true
141
	Txt.TextScaled = false
142
	delay(wait(),function()
143
		for v = 1, #msg do
144
			Txt.Text=string.sub(msg,1,v)
145
			wait(.07)
146
		end;
147
		wait(1)
148
		for v = 1, #Txt.Text do
149
			Txt.Text=string.sub(msg,-1,v)
150
			wait(.05)
151
		end;
152
		Gui:remove()
153
	end)
154
	end)
155
	else
156
	end
157
end
158
159
Plr.Chatted:connect(function(msg)
160
	Chat(msg)
161
end)
162
163
function SetHeadPos()
164
local run,error = ypcall(function()
165
	local Weld = Instance.new("Weld")
166
	Weld.Part0 = Char.Torso
167
	Weld.Part1 = Char["Head"]
168
	Weld.C0 = CFrame.new(0, 1.4, 0)
169
	Weld.Parent = Weld.Part0
170
	
171
	pcall(function()
172
		for _,v in pairs(Char.Head:GetChildren()) do
173
			if v.ClassName=='SpecialMesh' then
174
				v:remove()
175
			end
176
		end
177
	end)
178
		
179
	if Char:findFirstChild('Head') then
180
		pcall(function()
181
			for _,v in pairs(Char:GetChildren()) do
182
				if v.ClassName == 'Hat' or v.ClassName == 'SpecialMesh' then
183
					v:remove()
184
				end
185
			end
186
			local jointPosition = Weld.Part0.CFrame:toWorldSpace(CFrame.new(0, 1.5, 0))
187
			local cframe = CFrame.new(jointPosition.p,Plr:GetMouse().Hit.p)
188
			Weld.C0 = Weld.Part0.CFrame:toObjectSpace(cframe)
189
		end)
190
	end
191
end)
192
if not run then end
193
end
194
195
Run.Heartbeat:connect(SetHeadPos)
196
197
wait() -- Black armor--
198
Armor(Char['Right Arm'],Vector3.new(1.1,2.1,1.1),'Really black',false,Clr)
199
Armor(Char['Left Arm'],Vector3.new(1.1,2.1,1.1),'Really black',false,Clr)
200
Armor(Char['Torso'],Vector3.new(2.01,2.01,1.01),'Really black',true,Clr)
201
Armor(Char['Head'],Vector3.new(1.5,1.5,1.5),'Really black',false,Clr)
202
Armor(Char['Right Leg'],Vector3.new(1.1,2.1,1.1),'Really black',false,Clr)
203
Armor(Char['Left Leg'],Vector3.new(1.1,2.1,1.1),'Really black',false,Clr)
204
205
206
-- Tool --
207
local T=Instance.new('HopperBin',Plr.Backpack)
208
T.Name='Boom'
209
210
T.Selected:connect(function(MSE)
211
	MSE.Button1Down:connect(function()
212
		
213
		local Bullet = nil
214
		local Client = MSE.Target.Position
215
		
216
		if Client == nil then return end
217
		
218
		local P=Instance.new('Part',workspace)
219
		P.Transparency=1
220
		P.Name='Bullet'
221
		P.Anchored=false
222
		P.Position=Vector3.new(Plr.Character['Right Arm'].Position.X, Plr.Character['Right Arm'].Position.Y, Plr.Character['Right Arm'].Position.Z)
223
		P.CanCollide=true
224
		P.Locked=true
225
		P.FormFactor='Custom'
226
		P.Size=Vector3.new(0.32, 0.29, 1.48)
227
		local Pos = Instance.new("BodyPosition",P)
228
		Pos.position = Vector3.new(Client.X,Client.Y,Client.Z)	
229
	
230
		local Box=Instance.new('SelectionBox',P)
231
		Box.Adornee=P
232
		Box.Color=BrickColor.new('Teal')
233
		Box.Transparency=.5
234
		
235
		P.Touched:connect(function(objp)
236
			objp.Anchored=true
237
			wait(.3)
238
			objp.Anchored=false
239
		end)
240
241
		P.Touched:connect(function(part)
242
			Box.Transparency=1
243
			P.Transparency=1
244
			
245
			local function asd()
246
				coroutine.resume(coroutine.create(function()
247
				local PA=Instance.new('Part',workspace)
248
				PA.Transparency=1
249
				local Box2=Instance.new('SelectionBox',PA)
250
				Box2.Adornee=PA
251
				Box2.Color=BrickColor.new('Teal')
252
				Box2.Transparency=.1
253
				PA.Anchored=false
254
				PA.CanCollide=false
255
				PA.Locked=true
256
				PA.Name = 'Bullet_Explosion'
257
				PA.FormFactor='Custom'
258
				PA.Position=Vector3.new(part.Position.X,part.Position.Y,part.Position.Z)
259
				PA.Size=Vector3.new(math.random(1,8.5),math.random(1,8.5),math.random(1,8.5))
260
				PA.Rotation=Vector3.new(math.random(1.5,275),math.random(1.5,215),math.random(1.5,200))
261
	
262
				Bullet = PA
263
	
264
				if part.ClassName == 'Humanoid' then
265
					part.Health:TakeDamage(5)
266
				end
267
	
268
				part.Touched:connect(function(p2)
269
					if not p2.Name=='Base' or p2.Name=='Baseplate' or p2.Name=='Bullet_Explosion' then
270
					pcall(function() p2.Anchored=false end)
271
					end
272
				end)	
273
	
274
				local S=Instance.new('Sound',PA)
275
				S.Volume=1
276
				S.SoundId='rbxassetid://165969964'
277
				wait()
278
				S:Play()
279
				wait(S.TimeLength)
280
				S:Pause()
281
		
282
				end))
283
			end --function asd end
284
			
285
			for i = 0,4,1 do
286
				asd()
287
			end
288
			
289
			wait(math.random(.1,1))
290
			P:remove()
291
			Bullet:remove()
292
					
293
		end)
294
		
295
	end)
296
end)
297
--