Advertisement
The_God_M8

SMTH ELSE

May 11th, 2019
212
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 16.35 KB | None | 0 0
  1. --]]
  2. --//====================================================\\--
  3. --|| CREATED BY SHACKLUSTER
  4. --\\====================================================//--
  5. if game:GetService("RunService"):IsClient() then error("Script must be server-side in order to work; use h/ and not hl/") end
  6. local Player,game,owner = owner,game
  7. local RealPlayer = Player
  8. do
  9. print("FE Compatibility code by Mokiros")
  10. local rp = RealPlayer
  11. script.Parent = rp.Character
  12.  
  13. --RemoteEvent for communicating
  14. local Event = Instance.new("RemoteEvent")
  15. Event.Name = "UserInput_Event"
  16.  
  17. --Fake event to make stuff like Mouse.KeyDown work
  18. local function fakeEvent()
  19. local t = {_fakeEvent=true,Functions={},Connect=function(self,f)table.insert(self.Functions,f) end}
  20. t.connect = t.Connect
  21. return t
  22. end
  23.  
  24. --Creating fake input objects with fake variables
  25. local m = {Target=nil,Hit=CFrame.new(),KeyUp=fakeEvent(),KeyDown=fakeEvent(),Button1Up=fakeEvent(),Button1Down=fakeEvent()}
  26. local UIS = {InputBegan=fakeEvent(),InputEnded=fakeEvent()}
  27. local CAS = {Actions={},BindAction=function(self,name,fun,touch,...)
  28. CAS.Actions[name] = fun and {Name=name,Function=fun,Keys={...}} or nil
  29. end}
  30. --Merged 2 functions into one by checking amount of arguments
  31. CAS.UnbindAction = CAS.BindAction
  32.  
  33. --This function will trigger the events that have been :Connect()'ed
  34. local function te(self,ev,...)
  35. local t = m[ev]
  36. if t and t._fakeEvent then
  37. for _,f in pairs(t.Functions) do
  38. f(...)
  39. end
  40. end
  41. end
  42. m.TrigEvent = te
  43. UIS.TrigEvent = te
  44.  
  45. Event.OnServerEvent:Connect(function(plr,io)
  46. if plr~=rp then return end
  47. m.Target = io.Target
  48. m.Hit = io.Hit
  49. if not io.isMouse then
  50. local b = io.UserInputState == Enum.UserInputState.Begin
  51. if io.UserInputType == Enum.UserInputType.MouseButton1 then
  52. return m:TrigEvent(b and "Button1Down" or "Button1Up")
  53. end
  54. for _,t in pairs(CAS.Actions) do
  55. for _,k in pairs(t.Keys) do
  56. if k==io.KeyCode then
  57. t.Function(t.Name,io.UserInputState,io)
  58. end
  59. end
  60. end
  61. m:TrigEvent(b and "KeyDown" or "KeyUp",io.KeyCode.Name:lower())
  62. UIS:TrigEvent(b and "InputBegan" or "InputEnded",io,false)
  63. end
  64. end)
  65. Event.Parent = NLS([==[
  66. local Player = game:GetService("Players").LocalPlayer
  67. local Event = script:WaitForChild("UserInput_Event")
  68.  
  69. local Mouse = Player:GetMouse()
  70. local UIS = game:GetService("UserInputService")
  71. local input = function(io,a)
  72. if a then return end
  73. --Since InputObject is a client-side instance, we create and pass table instead
  74. Event:FireServer({KeyCode=io.KeyCode,UserInputType=io.UserInputType,UserInputState=io.UserInputState,Hit=Mouse.Hit,Target=Mouse.Target})
  75. end
  76. UIS.InputBegan:Connect(input)
  77. UIS.InputEnded:Connect(input)
  78.  
  79. local h,t
  80. --Give the server mouse data 30 times every second, but only if the values changed
  81. --If player is not moving their mouse, client won't fire events
  82. while wait(1/30) do
  83. if h~=Mouse.Hit or t~=Mouse.Target then
  84. h,t=Mouse.Hit,Mouse.Target
  85. Event:FireServer({isMouse=true,Target=t,Hit=h})
  86. end
  87. end]==],Player.Character)
  88.  
  89. ----Sandboxed game object that allows the usage of client-side methods and services
  90. --Real game object
  91. local _rg = game
  92.  
  93. --Metatable for fake service
  94. local fsmt = {
  95. __index = function(self,k)
  96. local s = rawget(self,"_RealService")
  97. if s then return s[k] end
  98. end,
  99. __newindex = function(self,k,v)
  100. local s = rawget(self,"_RealService")
  101. if s then s[k]=v end
  102. end,
  103. __call = function(self,...)
  104. local s = rawget(self,"_RealService")
  105. if s then return s(...) end
  106. end
  107. }
  108. local function FakeService(t,RealService)
  109. t._RealService = typeof(RealService)=="string" and _rg:GetService(RealService) or RealService
  110. return setmetatable(t,fsmt)
  111. end
  112.  
  113. --Fake game object
  114. local g = {
  115. GetService = function(self,s)
  116. return self[s]
  117. end,
  118. Players = FakeService({
  119. LocalPlayer = FakeService({GetMouse=function(self)return m end},Player)
  120. },"Players"),
  121. UserInputService = FakeService(UIS,"UserInputService"),
  122. ContextActionService = FakeService(CAS,"ContextActionService"),
  123. }
  124. rawset(g.Players,"localPlayer",g.Players.LocalPlayer)
  125. g.service = g.GetService
  126.  
  127. g.RunService = FakeService({
  128. RenderStepped = _rg:GetService("RunService").Heartbeat,
  129. BindToRenderStep = function(self,name,_,fun)
  130.  
  131. end,
  132. UnbindFromRenderStep = function(self,name)
  133. self._btrs[name]:Disconnect()
  134. end,
  135. },"RunService")
  136.  
  137. setmetatable(g,{
  138. __index=function(self,s)
  139. return _rg:GetService(s) or typeof(_rg[s])=="function"
  140. and function(_,...)return _rg[s](_rg,...)end or _rg[s]
  141. end,
  142. __newindex = fsmt.__newindex,
  143. __call = fsmt.__call
  144. })
  145. --Changing owner to fake player object to support owner:GetMouse()
  146. game,owner = g,g.Players.LocalPlayer
  147. end
  148.  
  149. wait(1) --For running in rbx studio
  150. mee = owner
  151. pistol = Instance.new("Tool", mee.Backpack)
  152. pistol.GripForward = Vector3.new(-0.149, 0.984, -0.099)
  153. pistol.GripPos = Vector3.new(0.1, -0.55, -0.2)
  154. pistol.GripRight = Vector3.new(0.989, 0.148, -0.015)
  155. pistol.GripUp = Vector3.new(0, 0.1, 0.995)
  156. pistol.ToolTip = "Hmm? Mitu is kinda lazy"
  157. pistol.Name = "Pistol"
  158. pistolpart = Instance.new("Part", pistol)
  159. pistolpart.Name = "Handle"
  160. pistolpart.BrickColor = BrickColor.new("Black")
  161. pistolpart.Material = "SmoothPlastic"
  162. pistolpart.Orientation = Vector3.new(-88.99, 152.78, 135.7)
  163. pistolpart.Size = Vector3.new(0.2, 1.12, 0.6)
  164. pistolmesh = Instance.new("SpecialMesh", pistolpart)
  165. pistolmesh.MeshId = "rbxassetid://430060386"
  166. pistolmesh.Scale = Vector3.new(2, 2, 2)
  167. pistolmesh.TextureId = "rbxassetid://430060404"
  168. pistolmesh.VertexColor = Vector3.new(2, 2, 2)
  169. gunshotsound = Instance.new("Sound", pistolpart)
  170. gunshotsound.SoundId = "rbxassetid://213603013"
  171.  
  172.  
  173. pistol.Equipped:connect(function(mouse)
  174. local torso = mee.Character.HumanoidRootPart
  175. local mouseturning = owner:GetMouse()
  176.  
  177. end)
  178. local mouse = owner:GetMouse()
  179. mouse.Button1Down:connect(function()
  180. gunshotsound:Play()
  181. MakeShell()
  182. local ray = Ray.new(pistol.Handle.CFrame.p, (mouse.Hit.p - pistol.Handle.CFrame.p).unit * 300)
  183. local part, position = workspace:FindPartOnRay(ray, mee.Character, false, true)
  184.  
  185. local beam = Instance.new("Part", workspace)
  186. beam.BrickColor = BrickColor.new("White")
  187. beam.FormFactor = "Custom"
  188. beam.Material = "Neon"
  189. beam.Transparency = 0.7
  190. beam.Anchored = true
  191. beam.Locked = true
  192. beam.CanCollide = false
  193.  
  194. local distance = (pistol.Handle.CFrame.p - position).magnitude
  195. beam.Size = Vector3.new(0.3, 0.3, distance)
  196. beam.CFrame = CFrame.new(pistol.Handle.CFrame.p, position) * CFrame.new(0, 0, -distance / 2)
  197.  
  198. game:GetService("Debris"):AddItem(beam, 0.1)
  199.  
  200. if part then
  201. local humanoid = part.Parent:FindFirstChild("Humanoid")
  202.  
  203. if not humanoid then
  204. humanoid = part.Parent.Parent:FindFirstChild("Humanoid")
  205. end
  206.  
  207. if humanoid then
  208. plrmodel = humanoid.Parent
  209. if plrmodel.Humanoid.Health ~= 0 then
  210. --blood
  211. plrmodel.Archivable = true
  212. local Char = plrmodel
  213. local Hum = Char:FindFirstChild("Humanoid")
  214. local Tor = Char:FindFirstChild("Torso") or Char:FindFirstChild("UpperTorso")
  215. local Health = Hum.Health
  216.  
  217. local M = math.random
  218. local R = math.rad
  219. local rates = {.05, .075, .1, .15}
  220.  
  221. local smooth = function(P)
  222. local SM = Enum.SurfaceType.SmoothNoOutlines
  223. P.TopSurface = SM
  224. P.BottomSurface = SM
  225. P.RightSurface = SM
  226. P.LeftSurface = SM
  227. P.FrontSurface = SM
  228. P.BackSurface = SM
  229. end
  230.  
  231. local function BloodPool(Part,Size)
  232. local Torso = Char:FindFirstChild("Torso") or Char:FindFirstChild("UpperTorso")
  233. local Pool = Instance.new("Part",game.Workspace)
  234. Pool.TopSurface = 0
  235. Pool.BrickColor = BrickColor.new("Crimson")
  236. Pool.Transparency = 0
  237. Pool.Anchored = true
  238. Pool.Material = Enum.Material.Granite
  239. Pool.CanCollide = false
  240. local cyl = Instance.new('CylinderMesh',Pool)
  241. Pool.Name = "BloodPoolPart"
  242. smooth(Pool)
  243.  
  244. cyl.Scale = Vector3.new(1,0.1,1)
  245. Pool.FormFactor = Enum.FormFactor.Custom
  246. Pool.Size = Vector3.new(1,0.2,1)
  247.  
  248. local c = Part.CFrame*CFrame.new(M(-3.01,3.01),-2.9,M(-3.01,3.01))
  249. coroutine.resume(coroutine.create(function()
  250. local rate = rates[M(1,#rates)]
  251. game.Debris:AddItem(Pool,15)
  252. for i = 1,M(25,70) do
  253. wait()
  254. Pool.CFrame = c
  255. Pool.Size = Pool.Size+Vector3.new(rate,0,rate)
  256. end
  257.  
  258. wait(5)
  259. Pool.Transparency = 0.1
  260. wait(0.1)
  261. Pool.Transparency=0.2
  262. wait(0.1)
  263. Pool.Transparency=0.3
  264. wait(0.1)
  265. Pool.Transparency=0.4
  266. wait(0.1)
  267. Pool.Transparency=0.5
  268. wait(0.1)
  269. Pool.Transparency=0.6
  270. wait(0.1)
  271. Pool.Transparency=0.7
  272. wait(0.1)
  273. Pool.Transparency=0.8
  274. wait(0.1)
  275. Pool.Transparency=0.9
  276. wait(0.1)
  277. Pool.Transparency=1
  278. wait(5)
  279. Pool:Destroy()
  280. end))
  281. end
  282. local function BloodDrops(Size,Area)
  283. local Blood = Instance.new("Part",game.Workspace)
  284. Blood.BrickColor = BrickColor.new("Crimson")
  285. Blood.Parent = plrmodel
  286. Blood.TopSurface = 0
  287. Blood.CanCollide = false
  288. Blood.Anchored = false
  289. Blood.FormFactor = Enum.FormFactor.Custom
  290. Blood.Size = Size
  291. Blood.CFrame = Area*CFrame.new(M(-1.00,1.00),M(-1.00,1.00),M(-1.00,1.00))
  292. return Blood
  293. end
  294.  
  295. Hum.Changed:connect(function()
  296. if Hum.Health < Health then
  297. Health = Hum.Health
  298. for i = 1, math.random(4,10)do
  299. local Size = Vector3.new(M(-0.25,0.25),.2,M(-.25,.25))
  300. local Blood = BloodDrops(Size,Tor.CFrame)
  301. local Stopper = false
  302. local Size2 = Vector3.new(M(-0.25,0.25),.2,M(-.25,.25))
  303. BloodPool(Tor,Size2)
  304. end
  305. end
  306. end)
  307. end
  308.  
  309. --Ragdoll
  310. wait()
  311. function getAttachment0(attachmentName)
  312. for _,child in next,plrmodel:GetChildren() do
  313. local attachment = child:FindFirstChild(attachmentName)
  314. if attachment then
  315. return attachment
  316. end
  317. end
  318. end
  319. plrmodel.Humanoid.Died:Connect(function(var)
  320. local removeHRP = true
  321. local head = plrmodel["Head"]
  322. local leftarm = plrmodel["Left Arm"]
  323. local leftleg = plrmodel["Left Leg"]
  324. local rightleg = plrmodel["Right Leg"]
  325. local rightarm = plrmodel["Right Arm"]
  326. local torso = plrmodel.Torso
  327. local root = plrmodel.HumanoidRootPart
  328. if removeHRP == true then
  329. root:Destroy()
  330. end
  331. local rootA =Instance.new("Attachment")
  332. local HeadA = Instance.new("Attachment")
  333. local LeftArmA = Instance.new("Attachment")
  334. local LeftLegA = Instance.new("Attachment")
  335. local RightArmA = Instance.new("Attachment")
  336. local RightLegA = Instance.new("Attachment")
  337. local TorsoA = Instance.new("Attachment")
  338. local TorsoA1 = Instance.new("Attachment")
  339. local TorsoA2 = Instance.new("Attachment")
  340. local TorsoA3 = Instance.new("Attachment")
  341. local TorsoA4 = Instance.new("Attachment")
  342. local TorsoA5 = Instance.new("Attachment")
  343. local function set1()
  344. HeadA.Name = "HeadA"
  345. HeadA.Parent = head
  346. HeadA.Position = Vector3.new(0, -0.5, 0)
  347. HeadA.Rotation = Vector3.new(0, 0, 0)
  348. HeadA.Axis = Vector3.new(1, 0, 0)
  349. HeadA.SecondaryAxis = Vector3.new(0, 1, 0)
  350. LeftArmA.Name = "LeftArmA"
  351. LeftArmA.Parent = leftarm
  352. LeftArmA.Position = Vector3.new(0.5, 1, 0)
  353. LeftArmA.Rotation = Vector3.new(0, 0, 0)
  354. LeftArmA.Axis = Vector3.new(1, 0, 0)
  355. LeftArmA.SecondaryAxis = Vector3.new(0, 1, 0)
  356. LeftLegA.Name = "LeftLegA"
  357. LeftLegA.Parent = leftleg
  358. LeftLegA.Position = Vector3.new(0, 1, 0)
  359. LeftLegA.Rotation = Vector3.new(0, 0, 0)
  360. LeftLegA.Axis = Vector3.new(1, 0, 0)
  361. LeftLegA.SecondaryAxis = Vector3.new(0, 1, 0)
  362. RightArmA.Name = "RightArmA"
  363. RightArmA.Parent = rightarm
  364. RightArmA.Position = Vector3.new(-0.5, 1, 0)
  365. RightArmA.Rotation = Vector3.new(0, 0, 0)
  366. RightArmA.Axis = Vector3.new(1, 0, 0)
  367. RightArmA.SecondaryAxis = Vector3.new(0, 1, 0)
  368. RightLegA.Name = "RightLegA"
  369. RightLegA.Parent = rightleg
  370. RightLegA.Position = Vector3.new(0, 1, 0)
  371. RightLegA.Rotation = Vector3.new(0, 0, 0)
  372. RightLegA.Axis = Vector3.new(1, 0, 0)
  373. RightLegA.SecondaryAxis = Vector3.new(0, 1, 0)
  374. rootA.Name= "rootA"
  375. rootA.Parent = root
  376. rootA.Position = Vector3.new(0, 0, 0)
  377. rootA.Rotation = Vector3.new(0, 90, 0)
  378. rootA.Axis = Vector3.new(0, 0, -1)
  379. rootA.SecondaryAxis = Vector3.new(0, 1, 0)
  380. end
  381. local function set2()
  382. TorsoA.Name = "TorsoA"
  383. TorsoA.Parent = torso
  384. TorsoA.Position = Vector3.new(0.5, -1, 0)
  385. TorsoA.Rotation = Vector3.new(0, 0, 0)
  386. TorsoA.Axis = Vector3.new(1, 0, 0)
  387. TorsoA.SecondaryAxis = Vector3.new(0, 1, 0)
  388. TorsoA1.Name = "TorsoA1"
  389. TorsoA1.Parent = torso
  390. TorsoA1.Position = Vector3.new(-0.5, -1, 0)
  391. TorsoA1.Rotation = Vector3.new(0, 0, 0)
  392. TorsoA1.Axis = Vector3.new(1, 0, 0)
  393. TorsoA1.SecondaryAxis = Vector3.new(0, 1, 0)
  394. TorsoA2.Name = "TorsoA2"
  395. TorsoA2.Parent = torso
  396. TorsoA2.Position = Vector3.new(-1, 1, 0)
  397. TorsoA2.Rotation = Vector3.new(0, 0, 0)
  398. TorsoA2.Axis = Vector3.new(1, 0, 0)
  399. TorsoA2.SecondaryAxis = Vector3.new(0, 1, 0)
  400. TorsoA3.Name = "TorsoA3"
  401. TorsoA3.Parent = torso
  402. TorsoA3.Position = Vector3.new(1, 1, 0)
  403. TorsoA3.Rotation = Vector3.new(0, 0, 0)
  404. TorsoA3.Axis = Vector3.new(1, 0, 0)
  405. TorsoA3.SecondaryAxis = Vector3.new(0, 1, 0)
  406. TorsoA4.Name = "TorsoA4"
  407. TorsoA4.Parent = torso
  408. TorsoA4.Position = Vector3.new(0, 1, 0)
  409. TorsoA4.Rotation = Vector3.new(0, 0, 0)
  410. TorsoA4.Axis = Vector3.new(1, 0, 0)
  411. TorsoA4.SecondaryAxis = Vector3.new(0, 1, 0)
  412. TorsoA5.Name = "TorsoA5"
  413. TorsoA5.Parent = torso
  414. TorsoA5.Position = Vector3.new(0, 0, 0)
  415. TorsoA5.Rotation = Vector3.new(0, 90, 0)
  416. TorsoA5.Axis = Vector3.new(0, 0, -1)
  417. TorsoA5.SecondaryAxis = Vector3.new(0, 1, 0)
  418. end
  419. local function set3()
  420. end
  421. spawn(set1);
  422. spawn(set2);
  423. local HA = Instance.new("HingeConstraint")
  424. HA.Parent = head
  425. HA.Attachment0 = HeadA
  426. HA.Attachment1 = TorsoA4
  427. HA.Enabled = true
  428. HA.LimitsEnabled=true
  429. HA.LowerAngle=0
  430. HA.UpperAngle=0
  431. local LAT = Instance.new("BallSocketConstraint")
  432. LAT.Parent = leftarm
  433. LAT.Attachment0 = LeftArmA
  434. LAT.Attachment1 = TorsoA2
  435. LAT.Enabled = true
  436. LAT.LimitsEnabled=true
  437. LAT.UpperAngle=90
  438. local RAT = Instance.new("BallSocketConstraint")
  439. RAT.Parent = rightarm
  440. RAT.Attachment0 = RightArmA
  441. RAT.Attachment1 = TorsoA3
  442. RAT.Enabled = true
  443. RAT.LimitsEnabled=true
  444. RAT.UpperAngle=90
  445. local HA = Instance.new("BallSocketConstraint")
  446. HA.Parent = head
  447. HA.Attachment0 = HeadA
  448. HA.Attachment1 = TorsoA4
  449. HA.Enabled = true
  450. local TLL = Instance.new("BallSocketConstraint")
  451. TLL.Parent = torso
  452. TLL.Attachment0 = TorsoA1
  453. TLL.Attachment1 = LeftLegA
  454. TLL.Enabled = true
  455. TLL.LimitsEnabled=true
  456. TLL.UpperAngle=90
  457. local TRL = Instance.new("BallSocketConstraint")
  458. TRL.Parent = torso
  459. TRL.Attachment0 = TorsoA
  460. TRL.Attachment1 = RightLegA
  461. TRL.Enabled = true
  462. TRL.LimitsEnabled=true
  463. TRL.UpperAngle=90
  464. local RTA = Instance.new("BallSocketConstraint")
  465. RTA.Parent = root
  466. RTA.Attachment0 = rootA
  467. RTA.Attachment1 = TorsoA5
  468. RTA.Enabled = true
  469. RTA.LimitsEnabled=true
  470. RTA.UpperAngle=0
  471. head.Velocity = head.CFrame.lookVector*30
  472.  
  473. for _,child in next,plrmodel:GetChildren() do
  474. if child:IsA("Accoutrement") then
  475. for _,part in next,child:GetChildren() do
  476. if part:IsA("BasePart") then
  477. part.Parent = plrmodel
  478. child:remove()
  479. local attachment1 = part:FindFirstChildOfClass("Attachment")
  480. local attachment0 = getAttachment0(attachment1.Name)
  481. if attachment0 and attachment1 then
  482. local constraint = Instance.new("HingeConstraint")
  483. constraint.Attachment0 = attachment0
  484. constraint.Attachment1 = attachment1
  485. constraint.LimitsEnabled = true
  486. constraint.UpperAngle = 0
  487. constraint.LowerAngle = 0
  488. constraint.Parent = plrmodel
  489. end
  490. end
  491. end
  492. end
  493. end
  494. end)
  495.  
  496. end
  497. if humanoid.Health ~= 0 then
  498. humanoid.Sit = true
  499. humanoid.WalkSpeed = 4
  500. humanoid.JumpPower = 0
  501. humanoid.Health = 50
  502. wait(30)
  503. while true do
  504. if humanoid.Health ~= 0 then
  505. humanoid.Health = 0 --This loop is a strange kill system I know, but this prevents doing 99 damage instead of 100 for some reason.s
  506. else
  507. break
  508. end
  509. wait(0.3)
  510. end
  511. end
  512. end
  513. end)
  514.  
  515. pistol.Unequipped:connect(function()
  516. wait(0.2)
  517.  
  518. end)
  519. function MakeShell()
  520. Shell = Instance.new("Part", workspace)
  521. Shell.Size = Vector3.new(0.2, 0.2, 0.6)
  522. ShellMesh = Instance.new("SpecialMesh", Shell)
  523. ShellMesh.MeshId = "http://www.roblox.com/asset/?id=94295100"
  524. ShellMesh.Scale = Vector3.new(4, 4, 4)
  525. ShellMesh.TextureId = "http://www.roblox.com/asset/?id=94287792"
  526. Shell.Position = pistolpart.Position
  527. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement