Advertisement
bmrx13

ok maybe not

Aug 31st, 2018
84
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 13.08 KB | None | 0 0
  1. --Converted with ttyyuu12345's model to script plugin v4
  2. function sandbox(var,func)
  3. local env = getfenv(func)
  4. local newenv = setmetatable({},{
  5. __index = function(self,k)
  6. if k=="script" then
  7. return var
  8. else
  9. return env[k]
  10. end
  11. end,
  12. })
  13. setfenv(func,newenv)
  14. return func
  15. end
  16. cors = {}
  17. mas = Instance.new("Model",game:GetService("Lighting"))
  18. Tool0 = Instance.new("Tool")
  19. Part1 = Instance.new("Part")
  20. SpecialMesh2 = Instance.new("SpecialMesh")
  21. ParticleEmitter3 = Instance.new("ParticleEmitter")
  22. ParticleEmitter4 = Instance.new("ParticleEmitter")
  23. Sound5 = Instance.new("Sound")
  24. Sound6 = Instance.new("Sound")
  25. Sound7 = Instance.new("Sound")
  26. Sound8 = Instance.new("Sound")
  27. Script9 = Instance.new("Script")
  28. Script10 = Instance.new("Script")
  29. LocalScript11 = Instance.new("LocalScript")
  30. RemoteFunction12 = Instance.new("RemoteFunction")
  31. LocalScript13 = Instance.new("LocalScript")
  32. Animation14 = Instance.new("Animation")
  33. Animation15 = Instance.new("Animation")
  34. Animation16 = Instance.new("Animation")
  35. Tool0.Name = "OmegaRainbowKatana"
  36. Tool0.Parent = mas
  37. Tool0.TextureId = "http://www.roblox.com/asset/?id= 340606193"
  38. Tool0.GripForward = Vector3.new(-1, -0, -0)
  39. Tool0.GripPos = Vector3.new(0, 0, -1.70000005)
  40. Tool0.GripRight = Vector3.new(0, 1, 0)
  41. Tool0.GripUp = Vector3.new(0, 0, 1)
  42. Tool0.ToolTip = "Drops from the dank god himself..."
  43. Part1.Name = "Handle"
  44. Part1.Parent = Tool0
  45. Part1.BrickColor = BrickColor.new("Dark stone grey")
  46. Part1.Rotation = Vector3.new(-45, 0, 90)
  47. Part1.FormFactor = Enum.FormFactor.Plate
  48. Part1.Size = Vector3.new(1, 0.800000012, 5)
  49. Part1.CFrame = CFrame.new(-17.2664642, 2.1213119, 37.3462181, -7.89036335e-07, -0.999995291, -1.01327896e-06, 0.707104445, -2.9670727e-07, 0.707103789, -0.707103252, -4.19789131e-07, 0.707105577)
  50. Part1.BottomSurface = Enum.SurfaceType.Smooth
  51. Part1.TopSurface = Enum.SurfaceType.Smooth
  52. Part1.Color = Color3.new(0.388235, 0.372549, 0.384314)
  53. Part1.Position = Vector3.new(-17.2664642, 2.1213119, 37.3462181)
  54. Part1.Orientation = Vector3.new(-45, 0, 90)
  55. Part1.Color = Color3.new(0.388235, 0.372549, 0.384314)
  56. SpecialMesh2.Parent = Part1
  57. SpecialMesh2.MeshId = "http://www.roblox.com/asset/?id=11442510"
  58. SpecialMesh2.Scale = Vector3.new(1.70000005, 1.70000005, 1.70000005)
  59. SpecialMesh2.TextureId = "http://www.roblox.com/asset/?id=340575861"
  60. SpecialMesh2.MeshType = Enum.MeshType.FileMesh
  61. SpecialMesh2.Scale = Vector3.new(1.70000005, 1.70000005, 1.70000005)
  62. ParticleEmitter3.Parent = Part1
  63. ParticleEmitter3.Transparency = NumberSequence.new(0,0,1)
  64. ParticleEmitter3.Size = NumberSequence.new(0.15000000596046,0.15000000596046)
  65. ParticleEmitter3.Color = ColorSequence.new(Color3.new(0.937255, 0.45098, 0),Color3.new(0.898039, 0.0235294, 0.0392157))
  66. ParticleEmitter3.Texture = "http://www.roblox.com/asset/?id=173990220"
  67. ParticleEmitter3.Lifetime = NumberRange.new(0.60000002384186, 0.60000002384186)
  68. ParticleEmitter3.Rate = 35
  69. ParticleEmitter3.Speed = NumberRange.new(-0.75, 0.75)
  70. ParticleEmitter3.Color = ColorSequence.new(Color3.new(0.937255, 0.45098, 0),Color3.new(0.898039, 0.0235294, 0.0392157))
  71. ParticleEmitter4.Parent = Part1
  72. ParticleEmitter4.Transparency = NumberSequence.new(0,0,1)
  73. ParticleEmitter4.Size = NumberSequence.new(0.15000000596046,0.15000000596046)
  74. ParticleEmitter4.Color = ColorSequence.new(Color3.new(0, 1, 0.968628),Color3.new(0.113725, 0, 0.780392))
  75. ParticleEmitter4.Texture = "http://www.roblox.com/asset/?id=173990220"
  76. ParticleEmitter4.Lifetime = NumberRange.new(0.60000002384186, 0.60000002384186)
  77. ParticleEmitter4.Rate = 35
  78. ParticleEmitter4.Speed = NumberRange.new(-0.75, 0.75)
  79. ParticleEmitter4.Color = ColorSequence.new(Color3.new(0, 1, 0.968628),Color3.new(0.113725, 0, 0.780392))
  80. Sound5.Name = "dash"
  81. Sound5.Parent = Part1
  82. Sound5.SoundId = "rbxassetid://25256253"
  83. Sound6.Name = "lunge"
  84. Sound6.Parent = Part1
  85. Sound6.SoundId = "rbxassetid://220833976"
  86. Sound6.Volume = 1
  87. Sound7.Name = "overhead"
  88. Sound7.Parent = Part1
  89. Sound7.SoundId = "rbxassetid://220834000"
  90. Sound7.Volume = 1
  91. Sound8.Name = "slash"
  92. Sound8.Parent = Part1
  93. Sound8.SoundId = "rbxassetid://220833967"
  94. Sound8.Volume = 1
  95. Script9.Name = "ServerMain"
  96. Script9.Parent = Tool0
  97. table.insert(cors,sandbox(Script9,function()
  98. local tool=script.Parent
  99. local handle=tool.Handle
  100.  
  101. local remotefunction=tool.RemoteFunction
  102. local debris=game:GetService("Debris")
  103.  
  104. function hit(humanoid,damage,player)
  105. humanoid:TakeDamage(damage)
  106. for _,instance in pairs(humanoid:GetChildren()) do
  107. if instance.Name=="creator" then
  108. instance:Destroy()
  109. end
  110. end
  111. local creator=Instance.new("ObjectValue",humanoid)
  112. creator.Name="creator"
  113. creator.Value=player
  114. end
  115.  
  116. function remotefunction.OnServerInvoke(player,command,value)
  117. if command=="hit" then
  118. hit(value[1],value[2],player)
  119. elseif command=="trip" then
  120. value.CFrame=value.CFrame*CFrame.Angles(0,0,math.rad(180))+Vector3.new(0,3,0)
  121. elseif command=="meteor" then
  122. local meteor=Instance.new("Part")
  123. meteor.Name="meteor"
  124. meteor.TopSurface="Smooth"
  125. meteor.BottomSurface="Smooth"
  126. meteor.Size=Vector3.new(5,7,6)
  127. meteor.CanCollide=false
  128. meteor.Shape="Ball"
  129. meteor.BrickColor=BrickColor.new("Deep orange")
  130. meteor.Material="Granite"
  131. meteor.CFrame=CFrame.new(handle.Position+Vector3.new(math.random(-10,10),20,math.random(-10,10)))
  132. meteor.Parent=workspace
  133.  
  134. local rocketpropulsion=Instance.new("RocketPropulsion",meteor)
  135. rocketpropulsion.TargetRadius=5
  136. rocketpropulsion.MaxSpeed=150
  137. rocketpropulsion.MaxTorque=Vector3.new(40,40,0)
  138. rocketpropulsion.MaxThrust=50000
  139. rocketpropulsion.ThrustP=100
  140. rocketpropulsion.ThrustD=5
  141. rocketpropulsion.Target=value[2]
  142. rocketpropulsion:Fire()
  143.  
  144. rocketpropulsion.ReachedTarget:connect(function(part)
  145. if value[2].Parent then
  146. local hum=value[2].Parent:FindFirstChild("Humanoid")
  147. local hitplayer=game.Players:GetPlayerFromCharacter(value[2].Parent)
  148. if hum~=nil then
  149. if hum.Health>0 then
  150. if hitplayer~=nil then
  151. if hitplayer.TeamColor~=player.TeamColor and hitplayer:FindFirstChild("nopvp")==nil and player:FindFirstChild("nopvp")==nil then
  152. hit(hum,value[1],player)
  153. end
  154. else
  155. hit(hum,value[1],player)
  156. end
  157. end
  158. meteor:Destroy()
  159. end
  160. end
  161. end)
  162.  
  163. debris:AddItem(meteor,999999999999999999)
  164. end
  165. end
  166.  
  167. end))
  168. Script10.Name = "Weld"
  169. Script10.Parent = Tool0
  170. table.insert(cors,sandbox(Script10,function()
  171. -- Weld script used by Immi, I did not made this. Credits to the original maker.
  172.  
  173. --[[ Here is how it works:
  174.  
  175. 1. Place this script into a model.
  176. 2. Anchor all parts that you are going to use for this car and build the car!
  177. 3. Place the parts that are going to be welded into the model. (NOT THE WHEELS OR ANY ROTATING PARTS!)
  178. 4. That's it, every time the game runs, the parts will all get welded together and then get unanchored. Your car will remain in top quality!
  179.  
  180. Additional info:
  181. - To clear up: You don't have to run the script when you finished your car! It will auto-weld every time a game starts!
  182. - This script is made so you only have to anchor the parts before building the car (this is to prevent an artifact called 'cracking'), SO DO IT!
  183. - No other specific things are needed, great for the lazy folks.
  184. - Welds all parts together in a sequential order.
  185. - Parts will weld, even when they do not touch.
  186. - WARNING: if ony parts get deleted, the sequence will get broken and is likely to break your car in two parts.
  187. - NOTE: This script is not recursive, meaning it will not weld parts in a model placed in this model.
  188. ]]
  189.  
  190. local all,last = {}
  191. function scan(p)
  192. for _,v in pairs(p:GetChildren()) do
  193. if (v:IsA("BasePart")) then
  194. if (last) then
  195. local w = Instance.new("Weld")
  196. w.Part0,w.Part1 = last,v
  197. w.C0 = v.CFrame:toObjectSpace(last.CFrame):inverse()
  198. w.Parent = last
  199. end
  200. table.insert(all,v)
  201. last = v
  202. end
  203. scan(v)
  204. end
  205. end
  206. scan(script.Parent)
  207. wait(1)
  208. for _,v in pairs(all) do v.Anchored = false end
  209. end))
  210. LocalScript11.Name = "MouseIcon"
  211. LocalScript11.Parent = Tool0
  212. table.insert(cors,sandbox(LocalScript11,function()
  213. local MOUSE_ICON = 'rbxasset://textures/GunCursor.png'
  214. local RELOADING_ICON = 'rbxasset://textures/GunWaitCursor.png'
  215.  
  216. local Tool = script.Parent
  217.  
  218. local Mouse = nil
  219.  
  220. local function UpdateIcon()
  221. if Mouse then
  222. Mouse.Icon = Tool.Enabled and MOUSE_ICON or RELOADING_ICON
  223. end
  224. end
  225.  
  226. local function OnEquipped(mouse)
  227. Mouse = mouse
  228. UpdateIcon()
  229. end
  230.  
  231. local function OnChanged(property)
  232. if property == 'Enabled' then
  233. UpdateIcon()
  234. end
  235. end
  236.  
  237. Tool.Equipped:connect(OnEquipped)
  238. Tool.Changed:connect(OnChanged)
  239.  
  240. end))
  241. RemoteFunction12.Parent = Tool0
  242. LocalScript13.Name = "SwordControl"
  243. LocalScript13.Parent = Tool0
  244. table.insert(cors,sandbox(LocalScript13,function()
  245. wait()
  246. player = owner
  247. local character=player.Character
  248. local mouse=player:GetMouse()
  249. local myhum=character.Humanoid
  250.  
  251. local tool=script.Parent
  252. local handle=tool.Handle
  253.  
  254. local sword=handle:Clone()
  255.  
  256. local event=tool:WaitForChild("RemoteFunction")
  257. local damage=81000 --damage dealt
  258. local speed=9.5 --how fast the weapon is
  259. local charge=true --can the weapon charge??
  260. local auto=true --can the weapon swing automatically?
  261.  
  262. local equipped=false
  263. local clicked=false
  264. local animations={}
  265. local sounds={}
  266.  
  267. local debris=game:GetService("Debris")
  268.  
  269. tool.Equipped:connect(function()
  270. animations[1]=myhum:LoadAnimation(tool.slashAnim)
  271. animations[2]=myhum:LoadAnimation(tool.thrustAnim)
  272. animations[3]=myhum:LoadAnimation(tool.overheadAnim)
  273. sounds[1]=handle.slash
  274. sounds[2]=handle.lunge
  275. sounds[3]=handle.overhead
  276. equipped=true
  277. end)
  278.  
  279. tool.Unequipped:connect(function()
  280. for i,animation in pairs(animations) do
  281. animation:Stop()
  282. end
  283. equipped=false
  284. end)
  285.  
  286. handle.Touched:connect(function(part)
  287. local hum=part.Parent:FindFirstChild("Humanoid")
  288. local head=part.Parent:FindFirstChild("Head")
  289. local hitplayer=game.Players:GetPlayerFromCharacter(part.Parent)
  290. if clicked and hum~=nil and head~=nil then
  291. if hum.Health>0 then
  292. if hitplayer~=nil then
  293. if hitplayer.TeamColor~=player.TeamColor and hitplayer:FindFirstChild("nopvp")==nil and player:FindFirstChild("nopvp")==nil then
  294. event:InvokeServer("hit",{hum,damage})
  295. end
  296. else
  297. event:InvokeServer("hit",{hum,damage})
  298. end
  299. end
  300. end
  301. end)
  302.  
  303. local soundstage=1
  304. local animstage=1
  305. local chargeready=true
  306. local down=false
  307. local ready=true
  308.  
  309. mouse.Button1Down:connect(function()
  310. down=true
  311. while down and tool.Parent.ClassName=="Model" do
  312. local mytorso=character:FindFirstChild("Torso")
  313. if mytorso then
  314. delay(0,function()
  315. if clicked then
  316. if chargeready and charge then
  317. chargeready=false
  318. --charging
  319. local chargeforce=Instance.new('BodyVelocity',mytorso)
  320. chargeforce.Name="ChargeVelocity"
  321. chargeforce.maxForce=Vector3.new(100000, 100000, 100000)
  322. chargeforce.velocity=(mouse.Hit.p*Vector3.new(1,0,1)-mytorso.CFrame.p*Vector3.new(1,0,1)).unit*150
  323. mytorso.CFrame=CFrame.new(mytorso.CFrame.p,mytorso.CFrame.p+chargeforce.velocity)
  324. debris:AddItem(chargeforce,0.2)
  325. wait(1/speed)
  326. chargeready=true
  327. if clicked then
  328. handle.dash:Play()
  329. end
  330. end
  331. end
  332. end)
  333. wait()
  334. if clicked==false then
  335. sounds[soundstage]:Play()
  336. animations[animstage]:Play()
  337. animations[animstage]:AdjustSpeed(speed)
  338. clicked=true
  339.  
  340. spawn(function()
  341. local target
  342. local closest=120
  343. for _,instance in pairs(workspace:GetChildren()) do
  344. local hum=instance:FindFirstChild("Humanoid")
  345. local head=instance:FindFirstChild("Head")
  346. if hum and head and instance~=character then
  347. local dist=(head.Position-handle.Position).magnitude
  348. if hum.Health>0 and dist<closest then
  349. local hitplayer=game.Players:GetPlayerFromCharacter(instance)
  350. if hitplayer~=nil then
  351. if hitplayer.TeamColor~=player.TeamColor and hitplayer:FindFirstChild("nopvp")==nil and player:FindFirstChild("nopvp")==nil then
  352. target=head
  353. closest=dist
  354. end
  355. else
  356. target=head
  357. closest=dist
  358. end
  359. end
  360. end
  361. end
  362.  
  363. if target then
  364. for i=10,20 do
  365. spawn(function() event:InvokeServer("meteor",{damage,target}) end)
  366. wait(.5/speed)
  367. end
  368. end
  369. end)
  370.  
  371. wait(1/speed)
  372. if soundstage==3 then soundstage=1 else soundstage=soundstage+1 end
  373. clicked=false
  374. if animstage==3 then animstage=1 else animstage=animstage+1 end
  375. else
  376. break
  377. end
  378. end
  379. if not auto then break end
  380. end
  381. end)
  382.  
  383. mouse.Button1Up:connect(function()
  384. down=false
  385. end)
  386. end))
  387. Animation14.Name = "overheadAnim"
  388. Animation14.Parent = Tool0
  389. Animation14.AnimationId = "http://www.roblox.com/Asset?ID=94160738"
  390. Animation15.Name = "slashAnim"
  391. Animation15.Parent = Tool0
  392. Animation15.AnimationId = "rbxassetid://94161088"
  393. Animation16.Name = "thrustAnim"
  394. Animation16.Parent = Tool0
  395. Animation16.AnimationId = "rbxassetid://94161333"
  396. for i,v in pairs(mas:GetChildren()) do
  397. player = owner
  398. pcall(function() v:MakeJoints() end)
  399. end
  400. mas:Destroy()
  401. for i,v in pairs(cors) do
  402. spawn(function()
  403. pcall(v)
  404. end)
  405. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement