SHOW:
|
|
- or go back to the newest paste.
1 | - | local player=game:service'Players'.LocalPlayer |
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,Mouse,mouse,UserInputService,ContextActionService = owner | |
4 | local RealPlayer = Player | |
5 | do print("FE Compatibility code by Mokiros")local a=RealPlayer;script.Parent=a.Character;local b=Instance.new("RemoteEvent")b.Name="UserInput_Event"local function c()local d={_fakeEvent=true,Functions={},Connect=function(self,e)table.insert(self.Functions,e)end}d.connect=d.Connect;return d end;local f={Target=nil,Hit=CFrame.new(),KeyUp=c(),KeyDown=c(),Button1Up=c(),Button1Down=c(),Button2Up=c(),Button2Down=c()}local g={InputBegan=c(),InputEnded=c()}local CAS={Actions={},BindAction=function(self,h,i,j,...)CAS.Actions[h]=i and{Name=h,Function=i,Keys={...}}or nil end}CAS.UnbindAction=CAS.BindAction;local function k(self,l,...)local d=f[l]if d and d._fakeEvent then for m,e in pairs(d.Functions)do e(...)end end end;f.TrigEvent=k;g.TrigEvent=k;b.OnServerEvent:Connect(function(n,o)if n~=a then return end;f.Target=o.Target;f.Hit=o.Hit;if not o.isMouse then local p=o.UserInputState==Enum.UserInputState.Begin;if o.UserInputType==Enum.UserInputType.MouseButton1 then return f:TrigEvent(p and"Button1Down"or"Button1Up")end;if o.UserInputType==Enum.UserInputType.MouseButton2 then return f:TrigEvent(p and"Button2Down"or"Button2Up")end;for m,d in pairs(CAS.Actions)do for m,q in pairs(d.Keys)do if q==o.KeyCode then d.Function(d.Name,o.UserInputState,o)end end end;f:TrigEvent(p and"KeyDown"or"KeyUp",o.KeyCode.Name:lower())g:TrigEvent(p and"InputBegan"or"InputEnded",o,false)end end)b.Parent=NLS([==[local a=game:GetService("Players").LocalPlayer;local b=script:WaitForChild("UserInput_Event")local c=a:GetMouse()local d=game:GetService("UserInputService")local e=function(f,g)if g then return end;b:FireServer({KeyCode=f.KeyCode,UserInputType=f.UserInputType,UserInputState=f.UserInputState,Hit=c.Hit,Target=c.Target})end;d.InputBegan:Connect(e)d.InputEnded:Connect(e)local h,i;while wait(1/30)do if h~=c.Hit or i~=c.Target then h,i=c.Hit,c.Target;b:FireServer({isMouse=true,Target=i,Hit=h})end end]==],Player.Character)local r=game;local s={__index=function(self,q)local t=rawget(self,"_RealService")if t then return typeof(t[q])=="function"and function(m,...)return t[q](t,...)end or t[q]end end,__newindex=function(self,q,u)local t=rawget(self,"_RealService")if t then t[q]=u end end}local function v(d,w)d._RealService=typeof(w)=="string"and r:GetService(w)or w;return setmetatable(d,s)end;local x={GetService=function(self,t)return rawget(self,t)or r:GetService(t)end,Players=v({LocalPlayer=v({GetMouse=function(self)return f end},Player)},"Players"),UserInputService=v(g,"UserInputService"),ContextActionService=v(CAS,"ContextActionService"),RunService=v({_btrs={},RenderStepped=r:GetService("RunService").Heartbeat,BindToRenderStep=function(self,h,m,i)self._btrs[h]=self.Heartbeat:Connect(i)end,UnbindFromRenderStep=function(self,h)self._btrs[h]:Disconnect()end},"RunService")}rawset(x.Players,"localPlayer",x.Players.LocalPlayer)x.service=x.GetService;v(x,game)game,owner=x,x.Players.LocalPlayer end local player=game:service'Players'.LocalPlayer | |
6 | local char=player.Character | |
7 | local mouse=player:GetMouse() | |
8 | local tor = char.Torso | |
9 | local ra = char['Right Arm'] | |
10 | local la = char['Left Arm'] | |
11 | local attacking = false | |
12 | function weld(p0,p1,c0) | |
13 | local w=Instance.new("Weld",p0) | |
14 | w.Part0=p0 | |
15 | w.Part1=p1 | |
16 | w.C0=c0 | |
17 | return w | |
18 | end | |
19 | ||
20 | ---Clothing------------------------------------------------------ | |
21 | if char:findFirstChild("Shirt") then | |
22 | char.Shirt:Remove() | |
23 | end | |
24 | ||
25 | if char:findFirstChild("Pants") then | |
26 | char.Pants:Remove() | |
27 | end | |
28 | ||
29 | if char:findFirstChild("Shirt Graphic") then | |
30 | char["Shirt Graphic"]:Remove() | |
31 | end | |
32 | ||
33 | if char.Torso:findFirstChild("roblox") then | |
34 | char.Torso.roblox:Remove() | |
35 | end | |
36 | ||
37 | local Shirt = Instance.new("Shirt",char) | |
38 | local Pants = Instance.new("Pants",char) | |
39 | Shirt.ShirtTemplate = "http://www.roblox.com/asset/?id=188809505" | |
40 | Pants.PantsTemplate = "http://www.roblox.com/asset/?id=158093557" | |
41 | if char:FindFirstChild("Head") then char.Head.BrickColor = BrickColor.new("Sand red") end | |
42 | if char:FindFirstChild("Torso") then char.Torso.BrickColor = BrickColor.new("Sand red") end | |
43 | if char:FindFirstChild("Left Leg") then char["Left Leg"].BrickColor = BrickColor.new("Sand red") end | |
44 | if char:FindFirstChild("Right Leg") then char["Right Leg"].BrickColor = BrickColor.new("Sand red") end | |
45 | if char:FindFirstChild("Left Arm") then char["Left Arm"].BrickColor = BrickColor.new("Sand red") end | |
46 | if char:FindFirstChild("Right Arm") then char["Right Arm"].BrickColor = BrickColor.new("Sand red") end | |
47 | ----------------------------------------------------------------- | |
48 | --Health&Walkspeed-- | |
49 | char.Humanoid.MaxHealth = 1000 | |
50 | char.Humanoid.Health = 1000 | |
51 | char.Humanoid.WalkSpeed = 10 | |
52 | ---------- | |
53 | --Body | |
54 | local torso = char.Torso:Clone() | |
55 | torso.Size = Vector3.new(char.Torso.Size.x,char.Torso.Size.y,char.Torso.Size.z) | |
56 | torso.Transparency = 0 | |
57 | torso.CanCollide = false | |
58 | if torso:FindFirstChild("roblox") then torso.roblox:Remove() end | |
59 | torso.Parent = char | |
60 | torso.CanCollide = true | |
61 | torso.Name = "Torso" | |
62 | torso["Left Shoulder"]:Destroy() | |
63 | torso["Right Shoulder"]:Destroy() | |
64 | torso["Left Hip"]:Destroy() | |
65 | torso["Right Hip"]:Destroy() | |
66 | char.Torso.Transparency = 1 | |
67 | char.Torso.Name = "Torso2" | |
68 | ||
69 | ||
70 | local tweld = Instance.new("Weld",char.Torso) | |
71 | tweld.Name = "tweld" | |
72 | tweld.Part0 = char.Torso | |
73 | tweld.Part1 = char.Torso2 | |
74 | tweld.C0 = CFrame.new(0,0,0)*CFrame.Angles(math.rad(15),0,0) | |
75 | char.Torso2.Name = "Torso" | |
76 | ----- | |
77 | ---Hair------------------------------------------------------------------------------ | |
78 | for _,v in pairs(char:GetChildren()) do if v.ClassName=="Accessory" then v:remove() end end | |
79 | ||
80 | hair = Instance.new("Part", char.Head) | |
81 | hair.FormFactor = Enum.FormFactor.Plate | |
82 | hair.CanCollide = false | |
83 | hair.TopSurface = Enum.SurfaceType.Smooth | |
84 | hair.Size = Vector3.new(1, 0.8, 1) | |
85 | hair.Name = "Hair" | |
86 | hair.Friction = 0.3 | |
87 | hair.BottomSurface = Enum.SurfaceType.Smooth | |
88 | hair:BreakJoints() | |
89 | mesh = Instance.new("SpecialMesh", hair) | |
90 | mesh.Scale = Vector3.new(1.02, 1.05, 1.05) | |
91 | mesh.MeshId = "http://www.roblox.com/asset/?id=12259089" | |
92 | mesh.TextureId = "http://www.roblox.com/asset/?id=208214380" | |
93 | mesh.MeshType = Enum.MeshType.FileMesh | |
94 | ||
95 | local hatweld = Instance.new("Weld",hair) | |
96 | hatweld.Name = "Hatweld" | |
97 | hatweld.Part0 = hair | |
98 | hatweld.Part1 = char.Head | |
99 | hatweld.C0 = CFrame.new(0,-.4,0) | |
100 | char.Head.face.Texture = "http://www.roblox.com/asset/?id=133667125" | |
101 | hair:MakeJoints() | |
102 | ------------------------------------------------------------------------------------------- | |
103 | ---Music--------------------------------------------------------------------------------------------------- | |
104 | local music=Instance.new("Sound") | |
105 | music.SoundId="http://www.roblox.com/asset/?id=225920256" | |
106 | music.PlayOnRemove=false | |
107 | music.Volume=.8 | |
108 | music.Looped=true | |
109 | music.Pitch = 1 | |
110 | music.Parent=char.Head | |
111 | music.Name = "ScissormanTheme" | |
112 | music:Play() | |
113 | ||
114 | char.Humanoid.Died:connect(function(musicremoval) | |
115 | music:Stop() | |
116 | wait() | |
117 | music:Destroy() | |
118 | end) | |
119 | ----------------------------------------------------------------------------------------------------------- | |
120 | ||
121 | --Model Build-- | |
122 | local scissors = Instance.new("Model", char) | |
123 | scissors.Name = "Scissors" | |
124 | ||
125 | local blade2 = Instance.new("Model", scissors) | |
126 | blade2.Name = "Blade2" | |
127 | ||
128 | blade = Instance.new("Part", blade2) | |
129 | blade.FormFactor = Enum.FormFactor.Custom | |
130 | blade.LeftSurface = Enum.SurfaceType.SmoothNoOutlines | |
131 | blade.TopSurface = Enum.SurfaceType.SmoothNoOutlines | |
132 | blade.Anchored = false | |
133 | blade.Material = Enum.Material.Metal | |
134 | blade.Size = Vector3.new(0.41, 2.581, 0.512) | |
135 | blade.Name = "Blade" | |
136 | blade.FrontSurface = Enum.SurfaceType.SmoothNoOutlines | |
137 | blade.CFrame = CFrame.new(81.752, 5.278, 34.598)* CFrame.Angles(-2.6529195308685, 0, -3.1415927410126) | |
138 | blade.RightSurface = Enum.SurfaceType.SmoothNoOutlines | |
139 | blade.BackSurface = Enum.SurfaceType.SmoothNoOutlines | |
140 | blade.BrickColor = BrickColor.new("Fossil") | |
141 | blade.Friction = 0.3 | |
142 | blade.CanCollide = false | |
143 | blade.BottomSurface = Enum.SurfaceType.SmoothNoOutlines | |
144 | ||
145 | mesh = Instance.new("SpecialMesh", blade) | |
146 | mesh.MeshType = Enum.MeshType.Wedge | |
147 | ||
148 | part = Instance.new("Part", blade2) | |
149 | part.FormFactor = Enum.FormFactor.Custom | |
150 | part.LeftSurface = Enum.SurfaceType.SmoothNoOutlines | |
151 | part.TopSurface = Enum.SurfaceType.SmoothNoOutlines | |
152 | part.Anchored = false | |
153 | part.Material = Enum.Material.Metal | |
154 | part.Size = Vector3.new(0.41, 1.721, 0.512) | |
155 | part.FrontSurface = Enum.SurfaceType.SmoothNoOutlines | |
156 | part.CFrame = CFrame.new(81.752, 3.379, 33.589)* CFrame.Angles(0.48867347836494, 0, -0) | |
157 | part.RightSurface = Enum.SurfaceType.SmoothNoOutlines | |
158 | part.BackSurface = Enum.SurfaceType.SmoothNoOutlines | |
159 | part.BrickColor = BrickColor.new("Fossil") | |
160 | part.Friction = 0.3 | |
161 | part.BottomSurface = Enum.SurfaceType.SmoothNoOutlines | |
162 | ||
163 | mesh_2 = Instance.new("BlockMesh", part) | |
164 | ||
165 | handle1 = Instance.new("Part", blade2) | |
166 | handle1.FormFactor = Enum.FormFactor.Custom | |
167 | handle1.LeftSurface = Enum.SurfaceType.SmoothNoOutlines | |
168 | handle1.TopSurface = Enum.SurfaceType.SmoothNoOutlines | |
169 | handle1.Anchored = false | |
170 | handle1.Material = Enum.Material.Metal | |
171 | handle1.Size = Vector3.new(0.41, 2.721, 0.512) | |
172 | handle1.Name = "Handle1" | |
173 | handle1.FrontSurface = Enum.SurfaceType.SmoothNoOutlines | |
174 | handle1.CFrame = CFrame.new(81.747, 1.366, 32.744)* CFrame.Angles(-2.7924835681915, 0, -0) | |
175 | handle1.RightSurface = Enum.SurfaceType.SmoothNoOutlines | |
176 | handle1.BackSurface = Enum.SurfaceType.SmoothNoOutlines | |
177 | handle1.BrickColor = BrickColor.new("Fossil") | |
178 | handle1.Friction = 0.3 | |
179 | handle1.BottomSurface = Enum.SurfaceType.SmoothNoOutlines | |
180 | ||
181 | mesh_3 = Instance.new("BlockMesh", handle1) | |
182 | ||
183 | handle1pos = Instance.new("Part", scissors) | |
184 | handle1pos.FormFactor = Enum.FormFactor.Custom | |
185 | handle1pos.LeftSurface = Enum.SurfaceType.SmoothNoOutlines | |
186 | handle1pos.TopSurface = Enum.SurfaceType.SmoothNoOutlines | |
187 | handle1pos.Anchored = false | |
188 | handle1pos.Transparency = 1 | |
189 | handle1pos.CanCollide = false | |
190 | handle1pos.Material = Enum.Material.Metal | |
191 | handle1pos.Size = Vector3.new(0.41, 2.721, 0.512) | |
192 | handle1pos.Name = "handle1pos" | |
193 | handle1pos.FrontSurface = Enum.SurfaceType.SmoothNoOutlines | |
194 | handle1pos.CFrame = CFrame.new(81.747, 1.366, 32.744)* CFrame.Angles(-2.7924835681915, 0, -0) | |
195 | handle1pos.RightSurface = Enum.SurfaceType.SmoothNoOutlines | |
196 | handle1pos.BackSurface = Enum.SurfaceType.SmoothNoOutlines | |
197 | handle1pos.BrickColor = BrickColor.new("Fossil") | |
198 | handle1pos.Friction = 0.3 | |
199 | handle1pos.BottomSurface = Enum.SurfaceType.SmoothNoOutlines | |
200 | ||
201 | handle = Instance.new("Part", scissors) | |
202 | handle.FormFactor = Enum.FormFactor.Custom | |
203 | handle.LeftSurface = Enum.SurfaceType.SmoothNoOutlines | |
204 | handle.TopSurface = Enum.SurfaceType.SmoothNoOutlines | |
205 | handle.Anchored = false | |
206 | handle.Material = Enum.Material.Metal | |
207 | handle.Size = Vector3.new(0.41, 0.41, 0.41) | |
208 | handle.Name = "Handle" | |
209 | handle.FrontSurface = Enum.SurfaceType.SmoothNoOutlines | |
210 | handle.CFrame = CFrame.new(81.852, 2.992, 33.43)* CFrame.Angles(-2.8078470230103, 1.5037103891373, 1.2398878335953) | |
211 | handle.RightSurface = Enum.SurfaceType.SmoothNoOutlines | |
212 | handle.BackSurface = Enum.SurfaceType.SmoothNoOutlines | |
213 | handle.BrickColor = BrickColor.new("Dark stone grey") | |
214 | handle.Friction = 0.3 | |
215 | handle.BottomSurface = Enum.SurfaceType.SmoothNoOutlines | |
216 | ||
217 | mesh_4 = Instance.new("SpecialMesh", handle) | |
218 | mesh_4.Scale = Vector3.new(1, 1.2, 1) | |
219 | mesh_4.MeshType = Enum.MeshType.Sphere | |
220 | ||
221 | local blade1 = Instance.new("Model", scissors) | |
222 | blade1.Name = "Blade1" | |
223 | ||
224 | blade_2 = Instance.new("Part", blade1) | |
225 | blade_2.FormFactor = Enum.FormFactor.Custom | |
226 | blade_2.LeftSurface = Enum.SurfaceType.SmoothNoOutlines | |
227 | blade_2.TopSurface = Enum.SurfaceType.SmoothNoOutlines | |
228 | blade_2.Anchored = false | |
229 | blade_2.Material = Enum.Material.Metal | |
230 | blade_2.Size = Vector3.new(0.41, 2.581, 0.512) | |
231 | blade_2.Name = "Blade" | |
232 | blade_2.CanCollide = false | |
233 | blade_2.FrontSurface = Enum.SurfaceType.SmoothNoOutlines | |
234 | blade_2.CFrame = CFrame.new(81.752, 5.304, 32.333)* CFrame.Angles(-0.46782538294792, 0, -0) | |
235 | blade_2.RightSurface = Enum.SurfaceType.SmoothNoOutlines | |
236 | blade_2.BackSurface = Enum.SurfaceType.SmoothNoOutlines | |
237 | blade_2.BrickColor = BrickColor.new("Fossil") | |
238 | blade_2.Friction = 0.3 | |
239 | blade_2.BottomSurface = Enum.SurfaceType.SmoothNoOutlines | |
240 | ||
241 | mesh_5 = Instance.new("SpecialMesh", blade_2) | |
242 | mesh_5.MeshType = Enum.MeshType.Wedge | |
243 | ||
244 | part_2 = Instance.new("Part", blade1) | |
245 | part_2.FormFactor = Enum.FormFactor.Custom | |
246 | part_2.LeftSurface = Enum.SurfaceType.SmoothNoOutlines | |
247 | part_2.TopSurface = Enum.SurfaceType.SmoothNoOutlines | |
248 | part_2.Anchored = false | |
249 | part_2.Material = Enum.Material.Metal | |
250 | part_2.Size = Vector3.new(0.41, 1.721, 0.512) | |
251 | part_2.FrontSurface = Enum.SurfaceType.SmoothNoOutlines | |
252 | part_2.CFrame = CFrame.new(81.752, 3.385, 33.302)* CFrame.Angles(2.6737668514252, 0, -3.1415927410126) | |
253 | part_2.RightSurface = Enum.SurfaceType.SmoothNoOutlines | |
254 | part_2.BackSurface = Enum.SurfaceType.SmoothNoOutlines | |
255 | part_2.BrickColor = BrickColor.new("Fossil") | |
256 | part_2.Friction = 0.3 | |
257 | part_2.BottomSurface = Enum.SurfaceType.SmoothNoOutlines | |
258 | ||
259 | mesh_6 = Instance.new("BlockMesh", part_2) | |
260 | ||
261 | handle1_2 = Instance.new("Part", blade1) | |
262 | handle1_2.FormFactor = Enum.FormFactor.Custom | |
263 | handle1_2.LeftSurface = Enum.SurfaceType.SmoothNoOutlines | |
264 | handle1_2.TopSurface = Enum.SurfaceType.SmoothNoOutlines | |
265 | handle1_2.Anchored = false | |
266 | handle1_2.Material = Enum.Material.Metal | |
267 | handle1_2.Size = Vector3.new(0.41, 2.721, 0.512) | |
268 | handle1_2.Name = "Handle1" | |
269 | handle1_2.FrontSurface = Enum.SurfaceType.SmoothNoOutlines | |
270 | handle1_2.CFrame = CFrame.new(81.747, 1.366, 34.144)* CFrame.Angles(2.7925736904144, 0, -0) | |
271 | handle1_2.RightSurface = Enum.SurfaceType.SmoothNoOutlines | |
272 | handle1_2.BackSurface = Enum.SurfaceType.SmoothNoOutlines | |
273 | handle1_2.BrickColor = BrickColor.new("Fossil") | |
274 | handle1_2.Friction = 0.3 | |
275 | handle1_2.BottomSurface = Enum.SurfaceType.SmoothNoOutlines | |
276 | ||
277 | mesh_7 = Instance.new("BlockMesh", handle1_2) | |
278 | ||
279 | handle1_2pos = Instance.new("Part", scissors) | |
280 | handle1_2pos.FormFactor = Enum.FormFactor.Custom | |
281 | handle1_2pos.LeftSurface = Enum.SurfaceType.SmoothNoOutlines | |
282 | handle1_2pos.TopSurface = Enum.SurfaceType.SmoothNoOutlines | |
283 | handle1_2pos.Anchored = false | |
284 | handle1_2pos.Transparency = 1 | |
285 | handle1_2pos.CanCollide = false | |
286 | handle1_2pos.Material = Enum.Material.Metal | |
287 | handle1_2pos.Size = Vector3.new(0.41, 2.721, 0.512) | |
288 | handle1_2pos.Name = "handle2pos" | |
289 | handle1_2pos.FrontSurface = Enum.SurfaceType.SmoothNoOutlines | |
290 | handle1_2pos.CFrame = CFrame.new(81.747, 1.366, 34.144)* CFrame.Angles(2.7925736904144, 0, -0) | |
291 | handle1_2pos.RightSurface = Enum.SurfaceType.SmoothNoOutlines | |
292 | handle1_2pos.BackSurface = Enum.SurfaceType.SmoothNoOutlines | |
293 | handle1_2pos.BrickColor = BrickColor.new("Fossil") | |
294 | handle1_2pos.Friction = 0.3 | |
295 | handle1_2pos.BottomSurface = Enum.SurfaceType.SmoothNoOutlines | |
296 | ||
297 | part_3 = Instance.new("Part", scissors) | |
298 | part_3.FormFactor = Enum.FormFactor.Custom | |
299 | part_3.LeftSurface = Enum.SurfaceType.SmoothNoOutlines | |
300 | part_3.TopSurface = Enum.SurfaceType.SmoothNoOutlines | |
301 | part_3.Anchored = false | |
302 | part_3.Material = Enum.Material.Metal | |
303 | part_3.Size = Vector3.new(0.41, 0.41, 0.41) | |
304 | part_3.FrontSurface = Enum.SurfaceType.SmoothNoOutlines | |
305 | part_3.CFrame = CFrame.new(81.652, 3.002, 33.43)* CFrame.Angles(-2.8078470230103, 1.5037103891373, 1.2398878335953) | |
306 | part_3.RightSurface = Enum.SurfaceType.SmoothNoOutlines | |
307 | part_3.BackSurface = Enum.SurfaceType.SmoothNoOutlines | |
308 | part_3.BrickColor = BrickColor.new("Dark stone grey") | |
309 | part_3.Friction = 0.3 | |
310 | part_3.BottomSurface = Enum.SurfaceType.SmoothNoOutlines | |
311 | ||
312 | mesh_8 = Instance.new("SpecialMesh", part_3) | |
313 | mesh_8.Scale = Vector3.new(1, 1.2, 1) | |
314 | mesh_8.MeshType = Enum.MeshType.Sphere | |
315 | scissors:BreakJoints() | |
316 | blade1:BreakJoints() | |
317 | blade2:BreakJoints() | |
318 | ||
319 | local prev | |
320 | local parts = scissors:GetChildren() | |
321 | ||
322 | for i = 1,#parts do | |
323 | if (parts[i].className == "Part") or (parts[i].className == "WedgePart") or (parts[i].className == "Seat") or (parts[i].className == "VehicleSeat") or (parts[i].className == "CornerWedgePart") then | |
324 | if (prev ~= nil)then | |
325 | if parts[i]:FindFirstChild("Weld") then parts[i]:FindFirstChild("Weld"):Destroy() end | |
326 | local weld = Instance.new("Weld") | |
327 | weld.Part0 = prev | |
328 | weld.Part1 = parts[i] | |
329 | weld.C0 = prev.CFrame:inverse() | |
330 | weld.C1 = parts[i].CFrame:inverse() | |
331 | weld.Parent = prev | |
332 | end | |
333 | prev = parts[i] | |
334 | end | |
335 | end | |
336 | scissors:MakeJoints() | |
337 | ||
338 | local prev | |
339 | local parts = blade1:GetChildren() | |
340 | ||
341 | for i = 1,#parts do | |
342 | if (parts[i].className == "Part") or (parts[i].className == "WedgePart") or (parts[i].className == "Seat") or (parts[i].className == "VehicleSeat") or (parts[i].className == "CornerWedgePart") then | |
343 | if (prev ~= nil)then | |
344 | if parts[i]:FindFirstChild("Weld") then parts[i]:FindFirstChild("Weld"):Destroy() end | |
345 | local weld = Instance.new("Weld") | |
346 | weld.Part0 = prev | |
347 | weld.Part1 = parts[i] | |
348 | weld.C0 = prev.CFrame:inverse() | |
349 | weld.C1 = parts[i].CFrame:inverse() | |
350 | weld.Parent = prev | |
351 | end | |
352 | prev = parts[i] | |
353 | end | |
354 | end | |
355 | blade1:MakeJoints() | |
356 | local prev | |
357 | local parts = blade2:GetChildren() | |
358 | ||
359 | for i = 1,#parts do | |
360 | if (parts[i].className == "Part") or (parts[i].className == "WedgePart") or (parts[i].className == "Seat") or (parts[i].className == "VehicleSeat") or (parts[i].className == "CornerWedgePart") then | |
361 | if (prev ~= nil)then | |
362 | if parts[i]:FindFirstChild("Weld") then parts[i]:FindFirstChild("Weld"):Destroy() end | |
363 | local weld = Instance.new("Weld") | |
364 | weld.Part0 = prev | |
365 | weld.Part1 = parts[i] | |
366 | weld.C0 = prev.CFrame:inverse() | |
367 | weld.C1 = parts[i].CFrame:inverse() | |
368 | weld.Parent = prev | |
369 | end | |
370 | prev = parts[i] | |
371 | end | |
372 | end | |
373 | blade2:MakeJoints() | |
374 | ||
375 | local particleemitter = Instance.new("ParticleEmitter", scissors.Handle) | |
376 | particleemitter.VelocitySpread = 200 | |
377 | particleemitter.Speed = NumberRange.new(10) | |
378 | particleemitter.Size = NumberSequence.new({NumberSequenceKeypoint.new(0, 0.2), NumberSequenceKeypoint.new(1, 0.2)}) | |
379 | particleemitter.Rate = 10 | |
380 | particleemitter.Texture = "http://www.roblox.com/asset/?id=311395391" | |
381 | particleemitter.Color = ColorSequence.new(Color3.new(1, 0.666667, 0), Color3.new(1, 0.666667, 0)) | |
382 | particleemitter.Enabled = false | |
383 | ||
384 | scissors.Handle.Weld.Name = "Weld2" | |
385 | weld(blade1.Handle1, scissors.handle1pos, CFrame.new(0,0,0)*CFrame.Angles(math.rad(0),0,0)) | |
386 | weld(blade2.Handle1, scissors.handle2pos, CFrame.new(0,0,0)*CFrame.Angles(math.rad(0),0,0)) | |
387 | ---Model Build End--- | |
388 | weld(tor, ra, CFrame.new(1,0,-1)*CFrame.Angles(math.rad(90),0,0)) | |
389 | weld(la, ra, CFrame.new(2,0,0)*CFrame.Angles(math.rad(0),0,0)) | |
390 | weld(scissors.Handle, tor, CFrame.new(4,0,-.2)*CFrame.Angles(math.rad(95),(math.rad(90)),0)) | |
391 | local sc1 = Instance.new("Sound") | |
392 | sc1.SoundId="rbxassetid://357622136" | |
393 | sc1.PlayOnRemove=false | |
394 | sc1.Volume=0.7 | |
395 | sc1.Looped=false | |
396 | sc1.Pitch = 1 | |
397 | sc1.Parent=scissors.Handle | |
398 | local sc2 = Instance.new("Sound") | |
399 | sc2.SoundId="rbxassetid://240785604" | |
400 | sc2.PlayOnRemove=false | |
401 | sc2.Volume=0.7 | |
402 | sc2.Looped=false | |
403 | sc2.Pitch = 1 | |
404 | sc2.Parent=scissors.Handle | |
405 | ||
406 | local open = true | |
407 | function scissoropen() | |
408 | open = true | |
409 | blade2.Handle1.Weld.C0 = CFrame.new(0,0,0)*CFrame.Angles(math.rad(2),0,0) | |
410 | blade1.Handle1.Weld.C0 = CFrame.new(0,0,0)*CFrame.Angles(math.rad(-2),0,0) | |
411 | wait() | |
412 | blade2.Handle1.Weld.C0 = CFrame.new(0,0,0)*CFrame.Angles(math.rad(4),0,0) | |
413 | blade1.Handle1.Weld.C0 = CFrame.new(0,0,0)*CFrame.Angles(math.rad(-4),0,0) | |
414 | wait() | |
415 | blade2.Handle1.Weld.C0 = CFrame.new(0,0,0)*CFrame.Angles(math.rad(6),0,0) | |
416 | blade1.Handle1.Weld.C0 = CFrame.new(0,0,0)*CFrame.Angles(math.rad(-6),0,0) | |
417 | end | |
418 | ||
419 | function scissorclose() | |
420 | open = false | |
421 | attacking = true | |
422 | sc1:Play() | |
423 | blade2.Handle1.Weld.C0 = CFrame.new(0,0,0)*CFrame.Angles(math.rad(-2),0,0) | |
424 | blade1.Handle1.Weld.C0 = CFrame.new(0,0,0)*CFrame.Angles(math.rad(2),0,0) | |
425 | wait() | |
426 | blade2.Handle1.Weld.C0 = CFrame.new(0,0,0)*CFrame.Angles(math.rad(-4),0,0) | |
427 | blade1.Handle1.Weld.C0 = CFrame.new(0,0,0)*CFrame.Angles(math.rad(4),0,0) | |
428 | wait() | |
429 | blade2.Handle1.Weld.C0 = CFrame.new(0,0,0)*CFrame.Angles(math.rad(-6),0,0) | |
430 | blade1.Handle1.Weld.C0 = CFrame.new(0,0,0)*CFrame.Angles(math.rad(6),0,0) | |
431 | attacking = false | |
432 | end | |
433 | ||
434 | mouse.Button2Down:connect(function() | |
435 | if open == false then | |
436 | scissoropen() | |
437 | end | |
438 | end) | |
439 | mouse.Button1Down:connect(function() | |
440 | if open == true then | |
441 | scissorclose() | |
442 | end | |
443 | end) | |
444 | ||
445 | local blood = Instance.new("ParticleEmitter") | |
446 | blood.VelocitySpread = 180 | |
447 | blood.Lifetime = NumberRange.new(1, 2) | |
448 | blood.Speed = NumberRange.new(10) | |
449 | blood.Size = NumberSequence.new({NumberSequenceKeypoint.new(0, 0.1), NumberSequenceKeypoint.new(1, 0.1)}) | |
450 | blood.Acceleration = Vector3.new(0, -10, 0) | |
451 | blood.RotSpeed = NumberRange.new(260) | |
452 | blood.Texture = "http://www.roblox.com/asset/?id=176677966" | |
453 | ||
454 | blade.Touched:connect(function(h) | |
455 | if attacking == true then | |
456 | if h.Parent:FindFirstChild("Humanoid") then | |
457 | if h.Parent:FindFirstChild("Torso") then | |
458 | local pclone = blood:Clone() | |
459 | pclone.Parent = h | |
460 | game.Debris:AddItem(pclone,1) | |
461 | end | |
462 | if h.Parent.Humanoid.Parent:FindFirstChild("ForceField") then h.Parent.ForceField:Destroy() end | |
463 | if h.Name == "Torso" then h.Parent.Humanoid:TakeDamage(math.random(20,40)) end | |
464 | if h.Name == "Left Arm" then local clone = h:Clone() clone.Parent = workspace clone.Position = h.Position clone.CanCollide = true h:Destroy() end | |
465 | if h.Name == "Right Arm" then local clone = h:Clone() clone.Parent = workspace clone.Position = h.Position clone.CanCollide = true h:Destroy() end | |
466 | if h.Name == "Left Leg" then local clone = h:Clone() clone.Parent = workspace clone.Position = h.Position clone.CanCollide = true h:Destroy() end | |
467 | if h.Name == "Right Leg" then local clone = h:Clone() clone.Parent = workspace clone.Position = h.Position clone.CanCollide = true h:Destroy() end | |
468 | if h.Name == "Head" then local clone = h:Clone() clone.Parent = workspace clone.Position = h.Position clone.CanCollide = true h:Destroy() end | |
469 | end | |
470 | end | |
471 | end) | |
472 | blade_2.Touched:connect(function(h) | |
473 | if attacking == true then | |
474 | --if h.Parent:FindFirstChild("Humanoid") == nil and not h.Name:lower():find("base") then | |
475 | --h.Anchored = false | |
476 | --h.Velocity = char.Head.CFrame.lookVector*30 | |
477 | --h:BreakJoints() | |
478 | --end | |
479 | if h.Parent:FindFirstChild("Humanoid") then | |
480 | if h.Parent:FindFirstChild("Torso") then | |
481 | local pclone = blood:Clone() | |
482 | pclone.Parent = h | |
483 | game.Debris:AddItem(pclone,1) | |
484 | end | |
485 | if h.Parent.Humanoid.Parent:FindFirstChild("ForceField") then h.Parent.ForceField:Destroy() end | |
486 | if h.Name == "Torso" then h.Parent.Humanoid:TakeDamage(math.random(20,40)) end | |
487 | if h.Name == "Left Arm" then local clone = h:Clone() clone.Parent = workspace clone.Position = h.Position clone.CanCollide = true h:Destroy() end | |
488 | if h.Name == "Right Arm" then local clone = h:Clone() clone.Parent = workspace clone.Position = h.Position clone.CanCollide = true h:Destroy() end | |
489 | if h.Name == "Left Leg" then local clone = h:Clone() clone.Parent = workspace clone.Position = h.Position clone.CanCollide = true h:Destroy() end | |
490 | if h.Name == "Right Leg" then local clone = h:Clone() clone.Parent = workspace clone.Position = h.Position clone.CanCollide = true h:Destroy() end | |
491 | if h.Name == "Head" then local clone = h:Clone() clone.Parent = workspace clone.Position = h.Position clone.CanCollide = true h:Destroy() end | |
492 | end | |
493 | end | |
494 | end) | |
495 | ||
496 | local fpressed = 0 | |
497 | mouse.KeyDown:connect(function(key) | |
498 | if key == "f" then | |
499 | fpressed = fpressed + 1 | |
500 | if fpressed == 1 then | |
501 | tor.Weld.C0 = CFrame.new(1,.5,-1)*CFrame.Angles(math.rad(100),0,0) | |
502 | scissors.Handle.Weld.C0 = CFrame.new(4,0,-.8)*CFrame.Angles(math.rad(95),(math.rad(90)),0) | |
503 | end | |
504 | if fpressed ==2 then | |
505 | tor.Weld.C0 = CFrame.new(1,-.5,-1)*CFrame.Angles(math.rad(90),0,0) | |
506 | scissors.Handle.Weld.C0 = CFrame.new(4,0,.4)*CFrame.Angles(math.rad(95),(math.rad(90)),0) | |
507 | end | |
508 | if fpressed == 3 then | |
509 | fpressed = 0 | |
510 | tor.Weld.C0 = CFrame.new(1,0,-1)*CFrame.Angles(math.rad(90),0,0) | |
511 | scissors.Handle.Weld.C0 = CFrame.new(4,0,-.2)*CFrame.Angles(math.rad(95),(math.rad(90)),0) | |
512 | end | |
513 | end | |
514 | end) |