Advertisement
cat568

Untitled

Feb 2nd, 2019
199
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.02 KB | None | 0 0
  1.  
  2. --Converted with ttyyuu12345's model to script plugin v4
  3. function sandbox(var,func)
  4. local env = getfenv(func)
  5. local newenv = setmetatable({},{
  6. __index = function(self,k)
  7. if k=="script" then
  8. return var
  9. else
  10. return env[k]
  11. end
  12. end,
  13. })
  14. setfenv(func,newenv)
  15. return func
  16. end
  17. cors = {}
  18. mas = Instance.new("Model",game:GetService("Lighting"))
  19. Tool0 = Instance.new("Tool")
  20. Part1 = Instance.new("Part")
  21. SpecialMesh2 = Instance.new("SpecialMesh")
  22. NumberValue3 = Instance.new("NumberValue")
  23. LocalScript4 = Instance.new("LocalScript")
  24. Tool0.Name = "Part Spawner"
  25. Tool0.Parent = mas
  26. Tool0.Grip = CFrame.new(0, 0, 0.5, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  27. Tool0.GripPos = Vector3.new(0, 0, 0.5)
  28. Part1.Name = "Handle"
  29. Part1.Parent = Tool0
  30. Part1.CFrame = CFrame.new(-19.75, 3.5999999, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  31. Part1.Position = Vector3.new(-19.75, 3.5999999, 0)
  32. Part1.Color = Color3.new(0.972549, 0.972549, 0.972549)
  33. Part1.Transparency = 0.5
  34. Part1.Size = Vector3.new(1, 1, 1)
  35. Part1.BottomSurface = Enum.SurfaceType.Smooth
  36. Part1.BrickColor = BrickColor.new("Institutional white")
  37. Part1.Material = Enum.Material.Neon
  38. Part1.TopSurface = Enum.SurfaceType.Smooth
  39. Part1.brickColor = BrickColor.new("Institutional white")
  40. Part1.FormFactor = Enum.FormFactor.Custom
  41. Part1.formFactor = Enum.FormFactor.Custom
  42. SpecialMesh2.Parent = Part1
  43. SpecialMesh2.MeshType = Enum.MeshType.Sphere
  44. NumberValue3.Name = "BlastRadius"
  45. NumberValue3.Parent = Tool0
  46. NumberValue3.Value = 1
  47. LocalScript4.Name = "ToolScript"
  48. LocalScript4.Parent = NumberValue3
  49. table.insert(cors,sandbox(LocalScript4,function()
  50. local BlastRadius = script.Parent
  51. local Tool = BlastRadius.Parent
  52.  
  53. local Mouse = nil
  54. --local Humanoid = nil
  55.  
  56. local function OnEquipped(mouse)
  57. Mouse = mouse
  58. --Humanoid = Tool.Parent.Humanoid
  59. end
  60.  
  61. local function OnActivated()
  62. local magic = Instance.new('Part')
  63. magic.BackSurface = "SmoothNoOutlines"
  64. magic.BottomSurface = "Inlet"
  65. magic.FrontSurface = "SmoothNoOutlines"
  66. magic.LeftSurface = "SmoothNoOutlines"
  67. magic.RightSurface = "SmoothNoOutlines"
  68. magic.TopSurface = "Studs"
  69.  
  70.  
  71.  
  72. magic.Material = "Plastic"
  73.  
  74. magic.Size = Vector3.new(2, 2, 2)
  75. magic.Transparency = 1
  76. magic.Anchored = false
  77.  
  78.  
  79. magic.Position = Mouse.Hit.p
  80. --magic.Position = Humanoid.TargetPoint
  81.  
  82.  
  83. magic.Parent = workspace
  84. magic.Anchored = true
  85. wait (.01)
  86. magic.Transparency = .9
  87. wait (.01)
  88. magic.Transparency = .8
  89. wait (.01)
  90. magic.Transparency = .7
  91. wait (.01)
  92. magic.Transparency = .6
  93. wait (.01)
  94. magic.Transparency = .5
  95. wait (.01)
  96. magic.Transparency = .4
  97.  
  98. wait (.01)
  99. magic.Transparency = .3
  100. wait (.01)
  101. magic.Transparency = .2
  102. wait (.01)
  103. magic.Transparency = .1
  104. wait (.01)
  105. magic.Transparency = 0
  106. magic.Anchored = true
  107. end
  108.  
  109. Tool.Equipped:connect(OnEquipped)
  110. Tool.Activated:connect(OnActivated)
  111.  
  112. end))
  113. for i,v in pairs(mas:GetChildren()) do
  114. v.Parent = workspace
  115. pcall(function() v:MakeJoints() end)
  116. end
  117. mas:Destroy()
  118. for i,v in pairs(cors) do
  119. spawn(function()
  120. pcall(v)
  121. end)
  122. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement