SHOW:
|
|
- or go back to the newest paste.
1 | ||
2 | --https://github.com/Mokiros/roblox-FE-compatibility | |
3 | if game:GetService("RunService"):IsClient() then error("Script must be server-side in order to work; use h/ and not hl/") end | |
4 | local Player,Mouse,mouse,UserInputService,ContextActionService = owner | |
5 | local RealPlayer = Player | |
6 | 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 | |
7 | ||
8 | ||
9 | --By Ruffles14 | |
10 | mouse = game.Players.LocalPlayer:GetMouse() | |
11 | local rhandclone = game.Players.LocalPlayer.Character.Torso["Right Shoulder"]:Clone() | |
12 | local rhandweld = Instance.new("Weld", game.Players.LocalPlayer.Character.Torso) | |
13 | rhandweld.Part0 = game.Players.LocalPlayer.Character.Torso | |
14 | rhandweld.Part1 = game.Players.LocalPlayer.Character["Right Arm"] | |
15 | rhandweld.C0 = CFrame.new(1.5, 0, 0, 1, -1.6395192e-43, 0, -1.6395192e-43, 1, 0, 0, 0, 1) | |
16 | local lhandclone = game.Players.LocalPlayer.Character.Torso["Left Shoulder"]:Clone() | |
17 | local lhandweld = Instance.new("Weld", game.Players.LocalPlayer.Character.Torso) | |
18 | lhandweld.Part0 = game.Players.LocalPlayer.Character.Torso | |
19 | lhandweld.Part1 = game.Players.LocalPlayer.Character["Left Arm"] | |
20 | lhandweld.C0 = CFrame.new(-1.5, 0, 0, 1, -1.6395192e-43, 0, -1.6395192e-43, 1, 0, 0, 0, 1) | |
21 | local rootjointclone = game.Players.LocalPlayer.Character.HumanoidRootPart.RootJoint:Clone() | |
22 | game.Players.LocalPlayer.Character.HumanoidRootPart.RootJoint:Remove() | |
23 | local humanoidrootpart = Instance.new("Weld", game.Players.LocalPlayer.Character.Torso) | |
24 | humanoidrootpart.Part0 = game.Players.LocalPlayer.Character.HumanoidRootPart | |
25 | humanoidrootpart.Part1 = game.Players.LocalPlayer.Character.Torso | |
26 | local heed = game.Players.LocalPlayer.Character.Torso["Neck"]:Clone() | |
27 | local headweld = Instance.new("Weld", game.Players.LocalPlayer.Character.Torso) | |
28 | headweld.Part0 = game.Players.LocalPlayer.Character.Torso | |
29 | headweld.Part1 = game.Players.LocalPlayer.Character.Head | |
30 | headweld.C0 = headweld.C0 * CFrame.new(0,1.5,0) | |
31 | game.Players.LocalPlayer.Character.Torso.Neck:Remove() | |
32 | using = false | |
33 | --Converted with ttyyuu12345's model to script plugin v4 | |
34 | function sandbox(var,func) | |
35 | local env = getfenv(func) | |
36 | local newenv = setmetatable({},{ | |
37 | __index = function(self,k) | |
38 | if k=="script" then | |
39 | return var | |
40 | else | |
41 | return env[k] | |
42 | end | |
43 | end, | |
44 | }) | |
45 | setfenv(func,newenv) | |
46 | return func | |
47 | end | |
48 | cors = {} | |
49 | mas = Instance.new("Model",game:GetService("Lighting")) | |
50 | Part0 = Instance.new("Part") | |
51 | SpecialMesh1 = Instance.new("SpecialMesh") | |
52 | Part0.Parent = mas | |
53 | Part0.Rotation = Vector3.new(-17.039999, 72.0800018, -73.7399979) | |
54 | Part0.Size = Vector3.new(0.48999998, 2.96999931, 1.94999981) | |
55 | Part0.CFrame = CFrame.new(1.99671245, 4.08856773, -0.616976917, 0.0861581191, 0.29545939, 0.95146209, -0.99592489, 0, 0.090184398, 0.0266458243, -0.955355108, 0.294255406) | |
56 | Part0.BottomSurface = Enum.SurfaceType.Smooth | |
57 | Part0.TopSurface = Enum.SurfaceType.Smooth | |
58 | Part0.Position = Vector3.new(1.99671245, 4.08856773, -0.616976917) | |
59 | Part0.Orientation = Vector3.new(-5.17000008, 72.8099976, -90) | |
60 | Part0.CanCollide = false | |
61 | SpecialMesh1.Parent = Part0 | |
62 | SpecialMesh1.MeshId = "rbxassetid://441572308" | |
63 | SpecialMesh1.Scale = Vector3.new(0.0209999997, 0.0209999997, 0.0209999997) | |
64 | SpecialMesh1.TextureId = "rbxassetid://441572332" | |
65 | SpecialMesh1.MeshType = Enum.MeshType.FileMesh | |
66 | SpecialMesh1.Scale = Vector3.new(0.0209999997, 0.0209999997, 0.0209999997) | |
67 | for i,v in pairs(mas:GetChildren()) do | |
68 | v.Parent = game:GetService("Players").LocalPlayer.Character | |
69 | pcall(function() v:MakeJoints() end) | |
70 | end | |
71 | mas:Destroy() | |
72 | for i,v in pairs(cors) do | |
73 | spawn(function() | |
74 | pcall(v) | |
75 | end) | |
76 | end | |
77 | Part0:BreakJoints() | |
78 | cananimate = true | |
79 | canhit = false | |
80 | local weld = Instance.new("Weld", game.Players.LocalPlayer.Character["Right Arm"]) | |
81 | weld.Part0 = game.Players.LocalPlayer.Character["Right Arm"] | |
82 | weld.Part1 = Part0 | |
83 | weld.C0 = CFrame.new(0.0769970417, -1.17027426, -1.17937994, 0, 0, 1, -0.999999881, 0, 0, 0, -1, 0) | |
84 | for i = 0,1 , 0.03 do | |
85 | headweld.C0 = headweld.C0:lerp(CFrame.new(0, 1.5, 0, 0.962374032, 0, 0.271727562, 0, 1, 0, -0.271727562, 0, 0.962374032),i) | |
86 | humanoidrootpart.C0 = humanoidrootpart.C0:lerp(CFrame.new(0, 0, 0, 0.955355227, 0, -0.295459419, 0, 1, 0, 0.295459419, 0, 0.955355227),i) | |
87 | lhandweld.C0 = lhandweld.C0:lerp(CFrame.new(-1.53559077, 0.0383267403, 0, 0.997264206, 0.0739177391, 0, -0.0739177391, 0.997264266, 0, 2.98023224e-08, 1.86264515e-09, 0.999999881),i) | |
88 | rhandweld.C0 = rhandweld.C0:lerp(CFrame.new(1.54305458, 0.047129631, 2.98023224e-08, 0.99592495, -0.0901843905, 0, 0.090184398, 0.995925009, 0, 0, 0, 0.999999881),i) | |
89 | game:GetService("RunService").RenderStepped:wait() | |
90 | end | |
91 | function swing() | |
92 | if not using then | |
93 | using = true | |
94 | cananimate = false | |
95 | for i = 0,1 , 0.045 do | |
96 | weld.C0 = weld.C0:lerp(CFrame.new(0.958130836, -0.815908253, -0.0419664383, 0.379335552, 0.92491132, -0.0253674984, -0.913223445, 0.378668189, 0.150445476, 0.148754537, -0.0339030921, 0.988292694),i) | |
97 | headweld.C0 = headweld.C0:lerp(CFrame.new(-4.65661287e-10, 1.49999952, 0, 0.601507425, -2.32830644e-10, 0.798867226, 3.0559022e-10, 1, 0, -0.798867226, -4.65661287e-10, 0.601507425),i) | |
98 | humanoidrootpart.C0 = humanoidrootpart.C0:lerp(CFrame.new(0, 0, 0, 0.63088727, -0.00573391188, -0.775853336, 0, 0.999972701, -0.00739025697, 0.775874496, 0.00466241874, 0.630870044),i) | |
99 | lhandweld.C0 = lhandweld.C0:lerp(CFrame.new(0.0363237262, 0.350219727, -1.1563791, 0.495106995, -0.857149601, 0.1419992, 0.110766649, -0.0998312235, -0.988819599, 0.861742377, 0.505300522, 0.0455164276),i) | |
100 | rhandweld.C0 = rhandweld.C0:lerp(CFrame.new(1.50056481, 0.516354084, -0.499166548, 0.995925009, -0.00520473719, 0.09003409, 0.0901844054, 0.0574772507, -0.994265079, -2.98023224e-08, 0.998333335, 0.057712432),i) | |
101 | game:GetService("RunService").RenderStepped:wait() | |
102 | end | |
103 | canhit = true | |
104 | for i = 0,1 , 0.08 do | |
105 | weld.C0 = weld.C0:lerp(CFrame.new(0.968596578, -1.15575922, 0.178524971, 0.0531506836, 0.988890588, -0.13881819, -0.988834679, 0.0327400565, -0.145376131, -0.13921617, 0.144995078, 0.979589343),i) | |
106 | headweld.C0 = headweld.C0:lerp(CFrame.new(-0.0249017328, 1.48724031, 2.04332173e-06, 0.499998868, 0, -0.866026163, 0, 1, 0, 0.866026163, 0, 0.499998868),i) | |
107 | humanoidrootpart.C0 = humanoidrootpart.C0:lerp(CFrame.new(0, 0, 0, 0.305942208, 0, -0.952050149, 0, 1, 0, 0.952050149, 0, 0.305942208):inverse(),i) | |
108 | lhandweld.C0 = lhandweld.C0:lerp(CFrame.new(-1.07653618, 0.305679321, -0.818206966, 0.707105398, -0.707108259, 4.32133675e-07, 0.122787982, 0.122786887, -0.984807909, 0.696365714, 0.696363032, 0.173647687),i) | |
109 | rhandweld.C0 = rhandweld.C0:lerp(CFrame.new(0.74788636, 0.363031864, -0.7663396, 0.70710665, 0.707106948, -2.23517418e-08, -0.0616280138, 0.061627958, -0.99619478, -0.704416275, 0.704416037, 0.0871551335),i) | |
110 | game:GetService("RunService").RenderStepped:wait() | |
111 | end | |
112 | canhit = false | |
113 | using = false | |
114 | cananimate = true | |
115 | end | |
116 | end | |
117 | mouse.Button1Down:connect(swing) | |
118 | function hittie(part) | |
119 | if canhit then | |
120 | local humanoid = part.Parent:findFirstChildOfClass("Humanoid") | |
121 | if humanoid then | |
122 | canhit = false | |
123 | using = false | |
124 | local uptor = humanoid.Parent:findFirstChild("UpperTorso") | |
125 | if uptor and uptor.Parent.Name ~= game.Players.LocalPlayer.Name then | |
126 | humanoid.Parent:BreakJoints() | |
127 | while humanoid.Health >= 0.001 do | |
128 | game:GetService("RunService").RenderStepped:wait() | |
129 | end | |
130 | if humanoid.Parent:findFirstChild("HumanoidRootPart") then | |
131 | humanoid.Parent.HumanoidRootPart.CanCollide = false | |
132 | end | |
133 | local function makeballlimb(attachone, attachtwo, upperang, lowang, twist) | |
134 | local constraint = Instance.new("BallSocketConstraint", humanoid.Parent) | |
135 | constraint.Attachment0 = attachone | |
136 | constraint.Attachment1 = attachtwo | |
137 | constraint.LimitsEnabled = true | |
138 | constraint.TwistLimitsEnabled = true | |
139 | constraint.TwistLowerAngle = lowang | |
140 | constraint.TwistUpperAngle = upperang | |
141 | constraint.UpperAngle = twist | |
142 | end | |
143 | local function makehingelimb(attachone, attachtwo, upperang, lowang) | |
144 | local constraint = Instance.new("HingeConstraint", humanoid.Parent) | |
145 | constraint.Attachment0 = attachone | |
146 | constraint.Attachment1 = attachtwo | |
147 | constraint.LimitsEnabled = true | |
148 | constraint.LowerAngle = lowang | |
149 | constraint.UpperAngle = upperang | |
150 | end | |
151 | for i,v in pairs(humanoid.Parent:GetChildren()) do --scan player | |
152 | if v.ClassName == "Accessory" then | |
153 | local findhandle = v:findFirstChild("Handle") --finding handle in accesorry | |
154 | if findhandle then | |
155 | local attach = findhandle:findFirstChildOfClass("Attachment") | |
156 | for q,w in pairs(humanoid.Parent:GetChildren()) do --scan player | |
157 | if w.Name == "UpperTorso" or w.Name == "Head" then | |
158 | attach1 = w:findFirstChild(attach.Name) --finding attachment in head/uppertorso | |
159 | end | |
160 | end | |
161 | if attach and attach1 then | |
162 | local constraint = Instance.new("HingeConstraint", humanoid.Parent) --making fake weld | |
163 | constraint.Attachment0 = attach | |
164 | constraint.Attachment1 = attach1 | |
165 | constraint.LimitsEnabled = true | |
166 | constraint.LowerAngle = 0 | |
167 | constraint.UpperAngle = 0 | |
168 | end | |
169 | end | |
170 | end | |
171 | end | |
172 | if humanoid.Parent:findFirstChild("Head") and humanoid.Parent:findFirstChild("UpperTorso") then | |
173 | local attachment = Instance.new("Attachment", humanoid.Parent.Head) | |
174 | attachment.Position = Vector3.new(0, -0.5, 0) | |
175 | attachment.Name = "lol" | |
176 | attachment.Visible = false | |
177 | humanoid.Parent.UpperTorso.NeckAttachment.Visible = false | |
178 | humanoid.Parent.UpperTorso.NeckAttachment.Position = humanoid.Parent.UpperTorso.NeckAttachment.Position + Vector3.new(0,0,0) | |
179 | local ball = Instance.new("BallSocketConstraint", humanoid.Parent) | |
180 | ball.Attachment0 = humanoid.Parent.UpperTorso.NeckAttachment | |
181 | ball.Attachment1 = attachment | |
182 | ball.LimitsEnabled = true | |
183 | ball.TwistLimitsEnabled = true | |
184 | ball.UpperAngle = 40 | |
185 | ball.Restitution = 0.5 | |
186 | ball.TwistUpperAngle = 40 | |
187 | ball.TwistLowerAngle = -40 | |
188 | local collidepartofleftleg = Instance.new("Part", humanoid.Parent.UpperTorso) | |
189 | collidepartofleftleg.Name = "Bone" | |
190 | collidepartofleftleg.Size = Vector3.new(0.7,0.7,0.7) | |
191 | collidepartofleftleg.Transparency = 1 | |
192 | collidepartofleftleg:BreakJoints() | |
193 | local weeld = Instance.new("Weld", collidepartofleftleg) | |
194 | weeld.Part0 = collidepartofleftleg | |
195 | weeld.Part1 = humanoid.Parent["Head"] | |
196 | if humanoid.Parent.Head:findFirstChild("Neck") then | |
197 | humanoid.Parent.Head.Neck:destroy() | |
198 | end | |
199 | if humanoid.Parent.Head:findFirstChild("face") then | |
200 | humanoid.Parent.Head.face.Texture = "http://www.roblox.com/asset/?id=810245460" | |
201 | end | |
202 | end | |
203 | local LeftUpperLeg = humanoid.Parent:findFirstChild("LeftUpperLeg") | |
204 | local LeftLowerLeg = humanoid.Parent:findFirstChild("LeftLowerLeg") | |
205 | -- | |
206 | local RightUpperLeg = humanoid.Parent:findFirstChild("RightUpperLeg") | |
207 | local RightLowerLeg = humanoid.Parent:findFirstChild("RightLowerLeg") | |
208 | -- | |
209 | local RightUpperArm = humanoid.Parent:findFirstChild("RightUpperArm") | |
210 | local RightLowerArm = humanoid.Parent:findFirstChild("RightLowerArm") | |
211 | -- | |
212 | local LeftUpperArm = humanoid.Parent:findFirstChild("LeftUpperArm") | |
213 | local LeftLowerArm = humanoid.Parent:findFirstChild("LeftLowerArm") | |
214 | --Foot & Hands-- | |
215 | ||
216 | local LeftFoot = humanoid.Parent:findFirstChild("LeftFoot") | |
217 | local RightFoot = humanoid.Parent:findFirstChild("RightFoot") | |
218 | -- | |
219 | local LeftHand = humanoid.Parent:findFirstChild("LeftHand") | |
220 | local RightHand = humanoid.Parent:findFirstChild("RightHand") | |
221 | ||
222 | --END-- | |
223 | --TORSOS-- | |
224 | ||
225 | local UpperTorso = humanoid.Parent:findFirstChild("UpperTorso") | |
226 | local LowerTorso = humanoid.Parent:findFirstChild("LowerTorso") | |
227 | ||
228 | --END-- | |
229 | if LowerTorso then | |
230 | if LeftUpperLeg then | |
231 | makeballlimb(LowerTorso["LeftHipRigAttachment"], LeftUpperLeg["LeftHipRigAttachment"], 50,-50, 90) | |
232 | end | |
233 | if RightUpperLeg then | |
234 | makeballlimb(LowerTorso["RightHipRigAttachment"], RightUpperLeg["RightHipRigAttachment"], 50,-50, 90) | |
235 | end | |
236 | if LeftLowerLeg then | |
237 | makehingelimb(LeftUpperLeg["LeftKneeRigAttachment"], LeftLowerLeg["LeftKneeRigAttachment"], 0,-90) | |
238 | end | |
239 | if RightLowerLeg then | |
240 | makehingelimb(RightUpperLeg["RightKneeRigAttachment"], RightLowerLeg["RightKneeRigAttachment"], 0,-90) | |
241 | end | |
242 | if LeftFoot then | |
243 | makehingelimb(LeftLowerLeg["LeftAnkleRigAttachment"], LeftFoot["LeftAnkleRigAttachment"], 30, -30) | |
244 | end | |
245 | if RightFoot then | |
246 | makehingelimb(RightLowerLeg["RightAnkleRigAttachment"], RightFoot["RightAnkleRigAttachment"], 30, -30) | |
247 | end | |
248 | if UpperTorso then | |
249 | makehingelimb(UpperTorso["WaistRigAttachment"], LowerTorso["WaistRigAttachment"], 30, -30) | |
250 | end | |
251 | end | |
252 | if UpperTorso then | |
253 | local vel = Instance.new("BodyVelocity", UpperTorso) | |
254 | vel.MaxForce = Vector3.new(math.huge,math.huge,math.huge) | |
255 | vel.Velocity = game.Players.LocalPlayer.Character.Torso.CFrame.lookVector * 10 | |
256 | game.Debris:AddItem(vel, 0.1) | |
257 | local hitsound = Instance.new("Sound", UpperTorso) | |
258 | hitsound.SoundId = "http://www.roblox.com/asset/?id=148862502" | |
259 | hitsound:Play() | |
260 | hitsound.Volume = math.random(5,10) | |
261 | local canhit = true | |
262 | local hitval = 15 | |
263 | local uptor = humanoid.Parent.UpperTorso | |
264 | if RightUpperArm then | |
265 | makeballlimb(RightUpperArm["RightShoulderRigAttachment"], UpperTorso["RightShoulderRigAttachment"], 90,-50, 180) | |
266 | end | |
267 | if RightLowerArm then | |
268 | makehingelimb(RightLowerArm["RightElbowRigAttachment"], RightUpperArm["RightElbowRigAttachment"], 0,-90) | |
269 | end | |
270 | if RightHand then | |
271 | makehingelimb(RightHand["RightWristRigAttachment"], RightLowerArm["RightWristRigAttachment"], 30,30) | |
272 | end | |
273 | if LeftUpperArm then | |
274 | makeballlimb(LeftUpperArm["LeftShoulderRigAttachment"], UpperTorso["LeftShoulderRigAttachment"], 90,-50, 180) | |
275 | end | |
276 | if LeftLowerArm then | |
277 | makehingelimb(LeftLowerArm["LeftElbowRigAttachment"], LeftUpperArm["LeftElbowRigAttachment"], 0,-90) | |
278 | end | |
279 | if LeftHand then | |
280 | makehingelimb(LeftHand["LeftWristRigAttachment"], LeftLowerArm["LeftWristRigAttachment"], 30,30) | |
281 | end | |
282 | end | |
283 | else | |
284 | humanoid.Parent.Archivable = true | |
285 | humanoid.PlatformStand = true | |
286 | local clone = humanoid.Parent:Clone() | |
287 | clone.Parent = workspace | |
288 | game.Debris:AddItem(clone, 60) | |
289 | for i,v in pairs(clone:GetChildren()) do | |
290 | if v.ClassName == "Script" or v.ClassName == "LocalScript" then | |
291 | v:Remove() | |
292 | end | |
293 | for i,p in pairs(v:GetChildren()) do | |
294 | if p.ClassName == "Weld" or p.ClassName == "Motor6D" or p.ClassName == "BodyVelocity" then | |
295 | p:Remove() | |
296 | end | |
297 | end | |
298 | end | |
299 | for i,t in pairs(humanoid.Parent:GetChildren()) do | |
300 | if t.ClassName == "Accessory" or t.ClassName == "ForceField" then | |
301 | t:Remove() | |
302 | end | |
303 | end | |
304 | local vel = Instance.new("BodyVelocity", clone.Torso) | |
305 | vel.MaxForce = Vector3.new(math.huge,math.huge,math.huge) | |
306 | vel.Velocity = game.Players.LocalPlayer.Character.Torso.CFrame.lookVector * 15 | |
307 | game.Debris:AddItem(vel, 0.1) | |
308 | local hitsound = Instance.new("Sound", clone.Torso) | |
309 | hitsound.SoundId = "http://www.roblox.com/asset/?id=148862502" | |
310 | hitsound:Play() | |
311 | hitsound.Volume = math.random(5,10) | |
312 | vel = Instance.new("BodyVelocity", clone.Torso) | |
313 | vel.Velocity = clone.Torso.CFrame.lookVector * -5 | |
314 | vel.MaxForce = Vector3.new(math.huge,math.huge,math.huge) | |
315 | using = false | |
316 | hit = Instance.new("Sound", clone.Torso) | |
317 | hit.SoundId = "rbxassetid://260430060" | |
318 | hit.Volume = 0 | |
319 | hit1 = Instance.new("Sound", clone.Torso) | |
320 | hit1.SoundId = "rbxassetid://138087186" | |
321 | hit1.Volume = 0 | |
322 | hit2 = Instance.new("Sound", clone.Torso) | |
323 | hit2.SoundId = "rbxassetid://131237241" | |
324 | hit2.Volume = 0 | |
325 | hit3 = Instance.new("Sound", clone.Torso) | |
326 | hit3.SoundId = "rbxassetid://278062209" | |
327 | hit3.Volume = 0 | |
328 | hit3.TimePosition = 0.33 | |
329 | ded = Instance.new("Sound", clone.Torso) | |
330 | ded.SoundId = "rbxassetid://418892870" | |
331 | ded.Volume = 0 | |
332 | local leftarm = clone:findFirstChild("Left Arm") | |
333 | local rightrm = clone:findFirstChild("Right Arm") | |
334 | local leftleg = clone:findFirstChild("Left Leg") | |
335 | local rightleg = clone:findFirstChild("Right Leg") | |
336 | local head = clone:findFirstChild("Head") | |
337 | for i, g in pairs(humanoid.Parent:GetChildren()) do | |
338 | if g.ClassName == "Part" then | |
339 | g:destroy() | |
340 | end | |
341 | end | |
342 | for i, h in pairs(humanoid.Parent:GetChildren()) do | |
343 | if h.ClassName == "Accesory" then | |
344 | h:destroy() | |
345 | end | |
346 | end | |
347 | for z,x in pairs(clone:GetChildren()) do | |
348 | if x.ClassName == "Accessory" then | |
349 | local handle = x:findFirstChild("Handle") | |
350 | if handle then | |
351 | local attachment = handle:findFirstChildOfClass("Attachment") | |
352 | if attachment then | |
353 | for q,w in pairs(clone:GetChildren()) do | |
354 | if w.Name == "Torso" or w.Name == "Head" then | |
355 | local anotherone = w:findFirstChild(attachment.Name) | |
356 | if attachment and anotherone then | |
357 | local constraint = Instance.new("HingeConstraint", clone) --making fake weld | |
358 | constraint.Attachment0 = attachment | |
359 | constraint.Attachment1 = anotherone | |
360 | constraint.LimitsEnabled = true | |
361 | constraint.LowerAngle = 0 | |
362 | constraint.UpperAngle = 0 | |
363 | end | |
364 | end | |
365 | end | |
366 | end | |
367 | end | |
368 | end | |
369 | end | |
370 | if head and clone.Torso:findFirstChild("NeckAttachment") then | |
371 | local attachment = Instance.new("Attachment", clone.Head) | |
372 | attachment.Position = Vector3.new(0, -0.5, 0) | |
373 | attachment.Name = "lol" | |
374 | attachment.Visible = false | |
375 | clone.Torso.NeckAttachment.Visible = false | |
376 | clone.Torso.NeckAttachment.Position = clone.Torso.NeckAttachment.Position + Vector3.new(0,0,0) | |
377 | local ball = Instance.new("BallSocketConstraint", clone) | |
378 | ball.Attachment0 = clone.Torso.NeckAttachment | |
379 | ball.Attachment1 = attachment | |
380 | ball.LimitsEnabled = true | |
381 | ball.TwistLimitsEnabled = true | |
382 | ball.UpperAngle = 90 | |
383 | ball.Restitution = 0.5 | |
384 | ball.TwistUpperAngle = 90 | |
385 | ball.TwistLowerAngle = -90 | |
386 | local collidepartofleftleg = Instance.new("Part", clone.Torso) | |
387 | collidepartofleftleg.Name = "Bone" | |
388 | collidepartofleftleg.Size = Vector3.new(0.7,0.7,0.7) | |
389 | collidepartofleftleg.Transparency = 1 | |
390 | collidepartofleftleg:BreakJoints() | |
391 | local weeld = Instance.new("Weld", collidepartofleftleg) | |
392 | weeld.Part0 = collidepartofleftleg | |
393 | weeld.Part1 = clone["Head"] | |
394 | end | |
395 | if leftleg ~= nil then | |
396 | leftleg:BreakJoints() | |
397 | local glue = Instance.new("Glue", clone.Torso) | |
398 | glue.Part0 = clone.Torso | |
399 | glue.Part1 = leftleg | |
400 | glue.Name = "Left leg" | |
401 | local collider = Instance.new("Part", leftleg) | |
402 | collider.Position = Vector3.new(0,999,0) | |
403 | collider.Size = Vector3.new(1.5, 1, 1) | |
404 | collider.Shape = "Cylinder" | |
405 | local weld = Instance.new("Weld", collider) | |
406 | weld.Part0 = leftleg | |
407 | weld.Part1 = collider | |
408 | weld.C0 = CFrame.new(0,-0.2,0) * CFrame.fromEulerAnglesXYZ(0, 0, math.pi/2) | |
409 | collider.TopSurface = "Smooth" | |
410 | collider.BottomSurface = "Smooth" | |
411 | collider.formFactor = "Symmetric" | |
412 | glue.C0 = CFrame.new(-0.5, -1, 0, -0, -0, -1, 0, 1, 0, 1, 0, 0) | |
413 | glue.C1 = CFrame.new(-0, 1, 0, -0, -0, -1, 0, 1, 0, 1, 0, 0) | |
414 | collider.Transparency = 1 | |
415 | end | |
416 | ------------ | |
417 | if rightleg ~= nil then | |
418 | rightleg:BreakJoints() | |
419 | local glue1 = Instance.new("Glue", clone.Torso) | |
420 | glue1.Part0 = clone.Torso | |
421 | glue1.Part1 = rightleg | |
422 | glue1.Name = "Right leg" | |
423 | local collider1 = Instance.new("Part", rightleg) | |
424 | collider1.Position = Vector3.new(0,999,0) | |
425 | collider1.Size = Vector3.new(1.5, 1, 1) | |
426 | collider1.Shape = "Cylinder" | |
427 | local weld1 = Instance.new("Weld", collider1) | |
428 | weld1.Part0 = rightleg | |
429 | weld1.Part1 = collider1 | |
430 | weld1.C0 = CFrame.new(0,-0.2,0) * CFrame.fromEulerAnglesXYZ(0, 0, math.pi/2) | |
431 | collider1.TopSurface = "Smooth" | |
432 | collider1.BottomSurface = "Smooth" | |
433 | collider1.formFactor = "Symmetric" | |
434 | glue1.C0 = CFrame.new(0.5, -1, 0, 0, 0, 1, 0, 1, 0, -1, -0, -0) | |
435 | glue1.C1 = CFrame.new(0, 1, 0, 0, 0, 1, 0, 1, 0, -1, -0, -0) | |
436 | collider1.Transparency = 1 | |
437 | end | |
438 | ------------ | |
439 | if rightrm ~= nil then | |
440 | rightrm:BreakJoints() | |
441 | rightrm.CFrame = clone.Torso.CFrame * CFrame.new(1.7,0,0) | |
442 | local glue11 = Instance.new("Glue", clone.Torso) | |
443 | glue11.Part0 = clone.Torso | |
444 | glue11.Part1 = rightrm | |
445 | glue11.Name = "Right shoulder" | |
446 | local collider11 = Instance.new("Part", rightrm) | |
447 | collider11.Position = Vector3.new(0,9999,0) | |
448 | collider11.Size = Vector3.new(1.5,1,1) | |
449 | collider11.Shape = "Cylinder" | |
450 | local weld11 = Instance.new("Weld", collider11) | |
451 | weld11.Part0 = rightrm | |
452 | weld11.Part1 = collider11 | |
453 | weld11.C0 = CFrame.new(0,-0.2,0) * CFrame.fromEulerAnglesXYZ(0, 0, math.pi/2) | |
454 | collider11.TopSurface = "Smooth" | |
455 | collider11.BottomSurface = "Smooth" | |
456 | collider11.formFactor = "Symmetric" | |
457 | glue11.C0 = CFrame.new(1.5, 0.5, 0, 0, 0, 1, 0, 1, 0, -1, 0, 0) | |
458 | glue11.C1 = CFrame.new(0, 0.5, 0, 0, 0, 1, 0, 1, 0, -1, 0, 0) | |
459 | collider11.Transparency = 1 | |
460 | end | |
461 | ------------ | |
462 | if leftarm ~= nil then | |
463 | leftarm.CFrame = clone.Torso.CFrame * CFrame.new(-1.7,0,0) | |
464 | leftarm:BreakJoints() | |
465 | local glue111 = Instance.new("Glue", clone.Torso) | |
466 | glue111.Part0 = clone.Torso | |
467 | glue111.Part1 = leftarm | |
468 | glue111.Name = "Left shoulder" | |
469 | local collider111 = Instance.new("Part", leftarm) | |
470 | collider111.Position = Vector3.new(0,9999,0) | |
471 | collider111.Size = Vector3.new(1.5,1,1) | |
472 | collider111.Shape = "Cylinder" | |
473 | local weld111 = Instance.new("Weld", collider111) | |
474 | weld111.Part0 = leftarm | |
475 | weld111.Part1 = collider111 | |
476 | weld111.C0 = CFrame.new(0,-0.2,0) * CFrame.fromEulerAnglesXYZ(0, 0, math.pi/2) | |
477 | collider111.TopSurface = "Smooth" | |
478 | collider111.BottomSurface = "Smooth" | |
479 | collider111.formFactor = "Symmetric" | |
480 | glue111.C0 = CFrame.new(-1.5, 0.5, 0, 0, 0, -1, 0, 1, 0, 1, 0, 0) | |
481 | glue111.C1 = CFrame.new(0, 0.5, 0, 0, 0, -1, 0, 1, 0, 1, 0, 0) | |
482 | collider111.Transparency = 1 | |
483 | ---------------- | |
484 | sensoring = Instance.new("Part", clone.Torso) | |
485 | sensoring.Size = Vector3.new(1.2,1.1,0.8) | |
486 | sensoring.CanCollide = false | |
487 | sensoring.Position = clone.Torso.Position | |
488 | local welder = Instance.new("Weld", sensoring) | |
489 | welder.Part0 = clone.Torso | |
490 | welder.Part1 = sensoring | |
491 | welder.C0 = welder.C0 * CFrame.new(0,0,1.05) | |
492 | sensoring.Transparency = 1 | |
493 | ----------------- | |
494 | sensoring1 = Instance.new("Part", clone.Torso) | |
495 | sensoring1.Size = Vector3.new(1.2,1.1,0.8) | |
496 | sensoring1.CanCollide = false | |
497 | sensoring1.Position = clone.Torso.Position | |
498 | local welder1 = Instance.new("Weld", sensoring) | |
499 | welder1.Part0 = clone.Torso | |
500 | welder1.Part1 = sensoring1 | |
501 | welder1.C0 = welder1.C0 * CFrame.new(0,0,-1.05) | |
502 | sensoring1.Transparency = 1 | |
503 | end | |
504 | clone.Name = humanoid.Parent.Name.." (PANNED)" | |
505 | ded:Play() | |
506 | vel:destroy() | |
507 | wait(0.5) | |
508 | local function touch() | |
509 | if not using then | |
510 | using = true | |
511 | local Math = math.random(1,4) | |
512 | if Math == 1 then | |
513 | hit:Play() | |
514 | end | |
515 | if Math == 2 then | |
516 | hit1:Play() | |
517 | end | |
518 | if Math == 3 then | |
519 | hit2:Play() | |
520 | end | |
521 | if Math == 4 then | |
522 | hit3:Play() | |
523 | end | |
524 | wait(0.1) | |
525 | using = false | |
526 | end | |
527 | end | |
528 | sensoring.Touched:connect(touch) | |
529 | sensoring1.Touched:connect(touch) | |
530 | while true do | |
531 | if clone:findFirstChild("Head") then | |
532 | clone.Head.CanCollide = false | |
533 | end | |
534 | game:GetService("RunService").Stepped:wait() | |
535 | end | |
536 | end | |
537 | end | |
538 | end | |
539 | end | |
540 | Part0.Touched:connect(hittie) | |
541 | function ragdoll() | |
542 | game.Players.LocalPlayer.Character.Archivable = true | |
543 | clone = game.Players.LocalPlayer.Character:Clone() | |
544 | clone.Parent = workspace | |
545 | for i,v in pairs(clone:GetChildren()) do | |
546 | if v.ClassName == "Script" or v.ClassName == "LocalScript" then | |
547 | v:Remove() | |
548 | end | |
549 | for i,p in pairs(v:GetChildren()) do | |
550 | if p.ClassName == "Weld" or p.ClassName == "Motor6D" or p.ClassName == "BodyVelocity" then | |
551 | p:Remove() | |
552 | end | |
553 | end | |
554 | end | |
555 | for i,t in pairs(game.Players.LocalPlayer.Character:GetChildren()) do | |
556 | if t.ClassName == "Accessory" or t.ClassName == "ForceField" then | |
557 | t:Remove() | |
558 | end | |
559 | end | |
560 | vel = Instance.new("BodyVelocity", clone.Torso) | |
561 | vel.Velocity = clone.Torso.CFrame.lookVector * -5 | |
562 | vel.MaxForce = Vector3.new(math.huge,math.huge,math.huge) | |
563 | clone.Head.face.Texture = "http://www.roblox.com/asset/?id=161061608" | |
564 | using = false | |
565 | hit = Instance.new("Sound", clone.Torso) | |
566 | hit.SoundId = "rbxassetid://260430060" | |
567 | hit.Volume = 0 | |
568 | hit1 = Instance.new("Sound", clone.Torso) | |
569 | hit1.SoundId = "rbxassetid://138087186" | |
570 | hit1.Volume = 0 | |
571 | hit2 = Instance.new("Sound", clone.Torso) | |
572 | hit2.SoundId = "rbxassetid://131237241" | |
573 | hit2.Volume = 0 | |
574 | hit3 = Instance.new("Sound", clone.Torso) | |
575 | hit3.SoundId = "rbxassetid://278062209" | |
576 | hit3.Volume = 0 | |
577 | hit3.TimePosition = 0.33 | |
578 | ded = Instance.new("Sound", clone.Torso) | |
579 | ded.SoundId = "rbxassetid://337800380" | |
580 | ded.Volume = 5 | |
581 | local leftarm = clone:findFirstChild("Left Arm") | |
582 | local rightrm = clone:findFirstChild("Right Arm") | |
583 | local leftleg = clone:findFirstChild("Left Leg") | |
584 | local rightleg = clone:findFirstChild("Right Leg") | |
585 | local head = clone:findFirstChild("Head") | |
586 | for i, g in pairs(game.Players.LocalPlayer.Character:GetChildren()) do | |
587 | if g.ClassName == "Part" then | |
588 | g:destroy() | |
589 | end | |
590 | end | |
591 | for i, h in pairs(game.Players.LocalPlayer.Character:GetChildren()) do | |
592 | if h.ClassName == "Accesory" then | |
593 | h:destroy() | |
594 | end | |
595 | end | |
596 | game.Workspace.CurrentCamera.CameraSubject = head | |
597 | if head then | |
598 | local attachment = Instance.new("Attachment", clone.Head) | |
599 | attachment.Position = Vector3.new(0, -0.5, 0) | |
600 | attachment.Name = "lol" | |
601 | attachment.Visible = false | |
602 | clone.Torso.NeckAttachment.Visible = false | |
603 | clone.Torso.NeckAttachment.Position = clone.Torso.NeckAttachment.Position + Vector3.new(0,0,0) | |
604 | local ball = Instance.new("BallSocketConstraint", clone) | |
605 | ball.Attachment0 = clone.Torso.NeckAttachment | |
606 | ball.Attachment1 = attachment | |
607 | ball.LimitsEnabled = true | |
608 | ball.TwistLimitsEnabled = true | |
609 | ball.UpperAngle = 90 | |
610 | ball.Restitution = 0.5 | |
611 | ball.TwistUpperAngle = 90 | |
612 | ball.TwistLowerAngle = -90 | |
613 | local collidepartofleftleg = Instance.new("Part", clone.Torso) | |
614 | collidepartofleftleg.Name = "Bone" | |
615 | collidepartofleftleg.Size = Vector3.new(0.7,0.7,0.7) | |
616 | collidepartofleftleg.Transparency = 1 | |
617 | collidepartofleftleg:BreakJoints() | |
618 | local weeld = Instance.new("Weld", collidepartofleftleg) | |
619 | weeld.Part0 = collidepartofleftleg | |
620 | weeld.Part1 = clone["Head"] | |
621 | end | |
622 | if leftleg ~= nil then | |
623 | local glue = Instance.new("Glue", clone.Torso) | |
624 | glue.Part0 = clone.Torso | |
625 | glue.Part1 = leftleg | |
626 | glue.Name = "Left leg" | |
627 | local collider = Instance.new("Part", leftleg) | |
628 | collider.Position = Vector3.new(0,999,0) | |
629 | collider.Size = Vector3.new(1.5, 1, 1) | |
630 | collider.Shape = "Cylinder" | |
631 | local weld = Instance.new("Weld", collider) | |
632 | weld.Part0 = leftleg | |
633 | weld.Part1 = collider | |
634 | weld.C0 = CFrame.new(0,-0.2,0) * CFrame.fromEulerAnglesXYZ(0, 0, math.pi/2) | |
635 | collider.TopSurface = "Smooth" | |
636 | collider.BottomSurface = "Smooth" | |
637 | collider.formFactor = "Symmetric" | |
638 | glue.C0 = CFrame.new(-0.5, -1, 0, -0, -0, -1, 0, 1, 0, 1, 0, 0) | |
639 | glue.C1 = CFrame.new(-0, 1, 0, -0, -0, -1, 0, 1, 0, 1, 0, 0) | |
640 | collider.Transparency = 1 | |
641 | end | |
642 | ------------ | |
643 | if rightleg ~= nil then | |
644 | local glue1 = Instance.new("Glue", clone.Torso) | |
645 | glue1.Part0 = clone.Torso | |
646 | glue1.Part1 = rightleg | |
647 | glue1.Name = "Right leg" | |
648 | local collider1 = Instance.new("Part", rightleg) | |
649 | collider1.Position = Vector3.new(0,999,0) | |
650 | collider1.Size = Vector3.new(1.5, 1, 1) | |
651 | collider1.Shape = "Cylinder" | |
652 | local weld1 = Instance.new("Weld", collider1) | |
653 | weld1.Part0 = rightleg | |
654 | weld1.Part1 = collider1 | |
655 | weld1.C0 = CFrame.new(0,-0.2,0) * CFrame.fromEulerAnglesXYZ(0, 0, math.pi/2) | |
656 | collider1.TopSurface = "Smooth" | |
657 | collider1.BottomSurface = "Smooth" | |
658 | collider1.formFactor = "Symmetric" | |
659 | glue1.C0 = CFrame.new(0.5, -1, 0, 0, 0, 1, 0, 1, 0, -1, -0, -0) | |
660 | glue1.C1 = CFrame.new(0, 1, 0, 0, 0, 1, 0, 1, 0, -1, -0, -0) | |
661 | collider1.Transparency = 1 | |
662 | end | |
663 | ------------ | |
664 | if rightrm ~= nil then | |
665 | local glue11 = Instance.new("Glue", clone.Torso) | |
666 | glue11.Part0 = clone.Torso | |
667 | glue11.Part1 = rightrm | |
668 | glue11.Name = "Right shoulder" | |
669 | local collider11 = Instance.new("Part", rightrm) | |
670 | collider11.Position = Vector3.new(0,9999,0) | |
671 | collider11.Size = Vector3.new(1.5,1,1) | |
672 | collider11.Shape = "Cylinder" | |
673 | local weld11 = Instance.new("Weld", collider11) | |
674 | weld11.Part0 = rightrm | |
675 | weld11.Part1 = collider11 | |
676 | weld11.C0 = CFrame.new(0,-0.2,0) * CFrame.fromEulerAnglesXYZ(0, 0, math.pi/2) | |
677 | collider11.TopSurface = "Smooth" | |
678 | collider11.BottomSurface = "Smooth" | |
679 | collider11.formFactor = "Symmetric" | |
680 | glue11.C0 = CFrame.new(1.5, 0.5, 0, 0, 0, 1, 0, 1, 0, -1, 0, 0) | |
681 | glue11.C1 = CFrame.new(0, 0.5, 0, 0, 0, 1, 0, 1, 0, -1, 0, 0) | |
682 | collider11.Transparency = 1 | |
683 | end | |
684 | ------------ | |
685 | if leftarm ~= nil then | |
686 | local glue111 = Instance.new("Glue", clone.Torso) | |
687 | glue111.Part0 = clone.Torso | |
688 | glue111.Part1 = leftarm | |
689 | glue111.Name = "Left shoulder" | |
690 | local collider111 = Instance.new("Part", leftarm) | |
691 | collider111.Position = Vector3.new(0,9999,0) | |
692 | collider111.Size = Vector3.new(1.5,1,1) | |
693 | collider111.Shape = "Cylinder" | |
694 | local weld111 = Instance.new("Weld", collider111) | |
695 | weld111.Part0 = leftarm | |
696 | weld111.Part1 = collider111 | |
697 | weld111.C0 = CFrame.new(0,-0.2,0) * CFrame.fromEulerAnglesXYZ(0, 0, math.pi/2) | |
698 | collider111.TopSurface = "Smooth" | |
699 | collider111.BottomSurface = "Smooth" | |
700 | collider111.formFactor = "Symmetric" | |
701 | glue111.C0 = CFrame.new(-1.5, 0.5, 0, 0, 0, -1, 0, 1, 0, 1, 0, 0) | |
702 | glue111.C1 = CFrame.new(0, 0.5, 0, 0, 0, -1, 0, 1, 0, 1, 0, 0) | |
703 | collider111.Transparency = 1 | |
704 | ---------------- | |
705 | sensoring = Instance.new("Part", clone.Torso) | |
706 | sensoring.Size = Vector3.new(1.2,1.1,0.8) | |
707 | sensoring.CanCollide = false | |
708 | sensoring.Position = clone.Torso.Position | |
709 | local welder = Instance.new("Weld", sensoring) | |
710 | welder.Part0 = clone.Torso | |
711 | welder.Part1 = sensoring | |
712 | welder.C0 = welder.C0 * CFrame.new(0,0,1.05) | |
713 | sensoring.Transparency = 1 | |
714 | ----------------- | |
715 | sensoring1 = Instance.new("Part", clone.Torso) | |
716 | sensoring1.Size = Vector3.new(1.2,1.1,0.8) | |
717 | sensoring1.CanCollide = false | |
718 | sensoring1.Position = clone.Torso.Position | |
719 | local welder1 = Instance.new("Weld", sensoring) | |
720 | welder1.Part0 = clone.Torso | |
721 | welder1.Part1 = sensoring1 | |
722 | welder1.C0 = welder1.C0 * CFrame.new(0,0,-1.05) | |
723 | sensoring1.Transparency = 1 | |
724 | end | |
725 | clone.Name = game.Players.LocalPlayer.Character.Name.." (DEAD)" | |
726 | ded:Play() | |
727 | vel:destroy() | |
728 | wait(0.2) | |
729 | game.Debris:AddItem(clone,60) | |
730 | local function touch() | |
731 | if not using then | |
732 | using = true | |
733 | local Math = math.random(1,4) | |
734 | if Math == 1 then | |
735 | hit:Play() | |
736 | end | |
737 | if Math == 2 then | |
738 | hit1:Play() | |
739 | end | |
740 | if Math == 3 then | |
741 | hit2:Play() | |
742 | end | |
743 | if Math == 4 then | |
744 | hit3:Play() | |
745 | end | |
746 | wait(0.1) | |
747 | using = false | |
748 | end | |
749 | end | |
750 | sensoring.Touched:connect(touch) | |
751 | sensoring1.Touched:connect(touch) | |
752 | while true do | |
753 | clone.Head.CanCollide = false | |
754 | game:GetService("RunService").Stepped:wait() | |
755 | end | |
756 | end | |
757 | ||
758 | game.Players.LocalPlayer.Character.Humanoid.Died:connect(ragdoll) | |
759 | ||
760 | --di ent | |
761 | while true do | |
762 | if cananimate then | |
763 | if game.Players.LocalPlayer.Character.Torso.Velocity.x < -0.5 or game.Players.LocalPlayer.Character.Torso.Velocity.x > 0.5 or game.Players.LocalPlayer.Character.Torso.Velocity.z < -0.5 or game.Players.LocalPlayer.Character.Torso.Velocity.z > 0.5 and cananimate then | |
764 | for i = 0.1,0.3 , 0.008 do | |
765 | if cananimate and game.Players.LocalPlayer.Character.Torso.Velocity.x < -0.5 or game.Players.LocalPlayer.Character.Torso.Velocity.x > 0.5 or game.Players.LocalPlayer.Character.Torso.Velocity.z < -0.5 or game.Players.LocalPlayer.Character.Torso.Velocity.z > 0.5 and cananimate then | |
766 | lhandweld.C0 = lhandweld.C0:lerp(CFrame.new(-1.53402293, 0.0594797134, 0.144087285, 0.997264206, 0.0707819909, 0.0213012099, -0.0739177391, 0.9549582, 0.287386209, 2.98023224e-08, -0.28817457, 0.957577825),i) | |
767 | rhandweld.C0 = rhandweld.C0:lerp(CFrame.new(1.54035091, 0.0769848824, -0.170524538, 0.99592495, -0.0847774297, 0.0307573378, 0.090184398, 0.936214805, -0.339659303, 0, 0.341049016, 0.940045416),i) | |
768 | game:GetService("RunService").Stepped:wait() | |
769 | end | |
770 | end | |
771 | for i = 0.1,0.3 , 0.008 do | |
772 | if cananimate and game.Players.LocalPlayer.Character.Torso.Velocity.x < -0.5 or game.Players.LocalPlayer.Character.Torso.Velocity.x > 0.5 or game.Players.LocalPlayer.Character.Torso.Velocity.z < -0.5 or game.Players.LocalPlayer.Character.Torso.Velocity.z > 0.5 and cananimate then | |
773 | lhandweld.C0 = lhandweld.C0:lerp(CFrame.new(-1.53173375, 0.0903658867, -0.222393572, 0.997264206, 0.0662034005, -0.0328776538, -0.0739177391, 0.893185973, -0.443570435, 2.98023224e-08, 0.444787204, 0.895636141),i) | |
774 | rhandweld.C0 = rhandweld.C0:lerp(CFrame.new(1.54079688, 0.0720610619, 0.156226337, 0.99592495, -0.085669145, -0.0281783342, 0.090184398, 0.946062148, 0.311179608, 0, -0.312452823, 0.949932992),i) | |
775 | game:GetService("RunService").Stepped:wait() | |
776 | end | |
777 | end | |
778 | elseif game.Players.LocalPlayer.Character.Torso.Velocity.x > -0.5 or game.Players.LocalPlayer.Character.Torso.Velocity.x < 0.5 or game.Players.LocalPlayer.Character.Torso.Velocity.z > -0.5 or game.Players.LocalPlayer.Character.Torso.Velocity.z < 0.5 then | |
779 | for i = 0,1 , 0.1 do | |
780 | if cananimate and game.Players.LocalPlayer.Character.Torso.Velocity.x > -0.5 or game.Players.LocalPlayer.Character.Torso.Velocity.x < 0.5 or game.Players.LocalPlayer.Character.Torso.Velocity.z > -0.5 or game.Players.LocalPlayer.Character.Torso.Velocity.z < 0.5 and cananimate then | |
781 | weld.C0 = weld.C0:lerp(CFrame.new(0.0769970417, -1.17027426, -1.17937994, 0, 0, 1, -0.999999881, 0, 0, 0, -1, 0),i) | |
782 | headweld.C0 = headweld.C0:lerp(CFrame.new(0, 1.5, 0, 0.962374032, 0, 0.271727562, 0, 1, 0, -0.271727562, 0, 0.962374032),i) | |
783 | humanoidrootpart.C0 = humanoidrootpart.C0:lerp(CFrame.new(0, 0, 0, 0.955355227, 0, -0.295459419, 0, 1, 0, 0.295459419, 0, 0.955355227),i) | |
784 | lhandweld.C0 = lhandweld.C0:lerp(CFrame.new(-1.53559077, 0.0383267403, 0, 0.997264206, 0.0739177391, 0, -0.0739177391, 0.997264266, 0, 2.98023224e-08, 1.86264515e-09, 0.999999881),i) | |
785 | rhandweld.C0 = rhandweld.C0:lerp(CFrame.new(1.54305458, 0.047129631, 2.98023224e-08, 0.99592495, -0.0901843905, 0, 0.090184398, 0.995925009, 0, 0, 0, 0.999999881),i) | |
786 | game:GetService("RunService").RenderStepped:wait() | |
787 | end | |
788 | end | |
789 | end | |
790 | end | |
791 | wait() | |
792 | end |