Advertisement
SaitamaTheSenpai

heurag

Jan 21st, 2019
94
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 46.87 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. local chil = workspace:GetChildren()
  20. for i,v in pairs(chil) do
  21. if not (v==script or v:IsA("Camera") or v:IsA("Terrain") or game:GetService("Players"):GetPlayerFromCharacter(v)~=nil) then
  22. v:Destroy()
  23. end
  24. end
  25. Part0 = Instance.new("Part")
  26. Tool1 = Instance.new("Tool")
  27. Part2 = Instance.new("Part")
  28. Decal3 = Instance.new("Decal")
  29. Decal4 = Instance.new("Decal")
  30. Decal5 = Instance.new("Decal")
  31. Decal6 = Instance.new("Decal")
  32. Decal7 = Instance.new("Decal")
  33. Decal8 = Instance.new("Decal")
  34. BoolValue9 = Instance.new("BoolValue")
  35. ObjectValue10 = Instance.new("ObjectValue")
  36. Sound11 = Instance.new("Sound")
  37. Sound12 = Instance.new("Sound")
  38. ObjectValue13 = Instance.new("ObjectValue")
  39. ObjectValue14 = Instance.new("ObjectValue")
  40. Script15 = Instance.new("Script")
  41. LocalScript16 = Instance.new("LocalScript")
  42. Script17 = Instance.new("Script")
  43. LocalScript18 = Instance.new("LocalScript")
  44. ObjectValue19 = Instance.new("ObjectValue")
  45. ScreenGui20 = Instance.new("ScreenGui")
  46. TextLabel21 = Instance.new("TextLabel")
  47. BillboardGui22 = Instance.new("BillboardGui")
  48. ImageLabel23 = Instance.new("ImageLabel")
  49. Script24 = Instance.new("Script")
  50. BillboardGui25 = Instance.new("BillboardGui")
  51. ImageLabel26 = Instance.new("ImageLabel")
  52. Script27 = Instance.new("Script")
  53. Model28 = Instance.new("Model")
  54. LocalScript29 = Instance.new("LocalScript")
  55. Model30 = Instance.new("Model")
  56. LocalScript31 = Instance.new("LocalScript")
  57. Part0.Name = "Baseplate"
  58. Part0.Parent = mas
  59. Part0.BrickColor = BrickColor.new("Dark stone grey")
  60. Part0.Anchored = true
  61. Part0.Locked = true
  62. Part0.FormFactor = Enum.FormFactor.Symmetric
  63. Part0.Size = Vector3.new(512, 20, 512)
  64. Part0.CFrame = CFrame.new(0, -10, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  65. Part0.Color = Color3.new(0.388235, 0.372549, 0.384314)
  66. Part0.Position = Vector3.new(0, -10, 0)
  67. Part0.Color = Color3.new(0.388235, 0.372549, 0.384314)
  68. Tool1.Name = "Pokeball"
  69. Tool1.Parent = mas
  70. Tool1.GripPos = Vector3.new(0, 0, 0.400000006)
  71. Part2.Name = "Handle"
  72. Part2.Parent = Tool1
  73. Part2.BrickColor = BrickColor.new("White")
  74. Part2.Transparency = 1
  75. Part2.Rotation = Vector3.new(90, 90, 0)
  76. Part2.FormFactor = Enum.FormFactor.Symmetric
  77. Part2.Shape = Enum.PartType.Ball
  78. Part2.Size = Vector3.new(1, 1, 1)
  79. Part2.CFrame = CFrame.new(-2.5, 0.5, -11.5, 0, 0, 1, 1, 0, 0, 0, 1, 0)
  80. Part2.BottomSurface = Enum.SurfaceType.Smooth
  81. Part2.TopSurface = Enum.SurfaceType.Smooth
  82. Part2.Color = Color3.new(0.94902, 0.952941, 0.952941)
  83. Part2.Position = Vector3.new(-2.5, 0.5, -11.5)
  84. Part2.Orientation = Vector3.new(0, 90, 90)
  85. Part2.Color = Color3.new(0.94902, 0.952941, 0.952941)
  86. Decal3.Parent = Part2
  87. Decal3.Texture = "http://www.roblox.com/asset/?id=25770051"
  88. Decal3.Face = Enum.NormalId.Bottom
  89. Decal4.Parent = Part2
  90. Decal4.Texture = "http://www.roblox.com/asset/?id=25770081"
  91. Decal5.Parent = Part2
  92. Decal5.Texture = "http://www.roblox.com/asset/?id=25770106"
  93. Decal5.Face = Enum.NormalId.Left
  94. Decal6.Parent = Part2
  95. Decal6.Texture = "http://www.roblox.com/asset/?id=25770106"
  96. Decal6.Face = Enum.NormalId.Back
  97. Decal7.Parent = Part2
  98. Decal7.Texture = "http://www.roblox.com/asset/?id=25770106"
  99. Decal7.Face = Enum.NormalId.Right
  100. Decal8.Parent = Part2
  101. Decal8.Texture = "http://www.roblox.com/asset/?id=25770136"
  102. Decal8.Face = Enum.NormalId.Top
  103. BoolValue9.Name = "Capture"
  104. BoolValue9.Parent = Part2
  105. ObjectValue10.Name = "Player"
  106. ObjectValue10.Parent = Part2
  107. Sound11.Name = "CaptureSound"
  108. Sound11.Parent = Part2
  109. Sound11.Pitch = 7
  110. Sound11.SoundId = "http://www.roblox.com/asset/?id=1994345"
  111. Sound11.Volume = 0
  112. Sound12.Name = "Release"
  113. Sound12.Parent = Part2
  114. Sound12.Pitch = 2
  115. Sound12.SoundId = "http://www.roblox.com/asset/?id=3931318"
  116. Sound12.Volume = 0
  117. Sound12.PlayOnRemove = true
  118. ObjectValue13.Name = "Gui"
  119. ObjectValue13.Parent = Part2
  120. ObjectValue14.Name = "Players"
  121. ObjectValue14.Parent = Part2
  122. Script15.Name = "PokeScript"
  123. Script15.Parent = Tool1
  124. table.insert(cors,sandbox(Script15,function()
  125. local Tool = script.Parent;
  126. local Decals = Tool.Handle:GetChildren()
  127.  
  128. function fire(v)
  129. Tool.Parent.Torso["Right Shoulder"].MaxVelocity = 0.7
  130. Tool.Parent.Torso["Right Shoulder"].DesiredAngle = 3.6
  131. wait(.1)
  132. Tool.Parent.Torso["Right Shoulder"].MaxVelocity = 1
  133. local Ball = Tool.Handle:clone()
  134. local vCharacter = Tool.Parent
  135. local vPlayer = game.Players:GetPlayerFromCharacter(vCharacter)
  136.  
  137. local SpawnPos = vCharacter.PrimaryPart.Position
  138.  
  139. SpawnPos = SpawnPos + (v*8)
  140.  
  141. for _, v in pairs(Decals) do
  142. v.Parent = Tool
  143. end
  144.  
  145. Ball.Name = "Ball"
  146. Ball.Parent = Tool
  147. Ball.Position = SpawnPos
  148. Ball.Velocity = v * 100
  149.  
  150. local new = Tool.PokeBall:clone()
  151.  
  152. new.Disabled = false
  153. new.Parent = Ball
  154.  
  155. wait(4)
  156.  
  157. --Ball:remove()
  158.  
  159. for _, v in pairs(Decals) do
  160. v.Parent = Tool.Handle
  161. end
  162. end
  163.  
  164. function onActivated()
  165. if not Tool.Enabled then
  166. return
  167. end
  168.  
  169. Tool.Enabled = false
  170.  
  171. local targetPos = Tool.Parent.Humanoid.TargetPoint
  172. local lookAt = (targetPos - Tool.Parent.Head.Position).unit
  173.  
  174. fire(lookAt)
  175.  
  176. Tool.Enabled = true
  177. end
  178.  
  179. Tool.Activated:connect(onActivated)
  180.  
  181. local debounce = false
  182.  
  183. function getPlayer(humanoid)
  184. local players = game.Players:children()
  185. for i = 1, #players do
  186. if players[i].Character.Humanoid == humanoid then return players[i] end
  187. end
  188. return nil
  189. end
  190.  
  191. function onTouch(part)
  192.  
  193. local human = part.Parent:findFirstChild("Humanoid")
  194. if (human ~= nil) and debounce == false then
  195.  
  196. debounce = true
  197.  
  198. local player = getPlayer(human)
  199.  
  200. if (player == nil) then return end
  201.  
  202. script.Parent:clone().Parent = player.Backpack
  203.  
  204. wait(2)
  205. debounce = false
  206. end
  207. end
  208.  
  209.  
  210. script.Parent.Parent.Touched:connect(onTouch)
  211.  
  212. end))
  213. LocalScript16.Name = "Local Gui"
  214. LocalScript16.Parent = Tool1
  215. table.insert(cors,sandbox(LocalScript16,function()
  216. local Tool = script.Parent;
  217.  
  218. enabled = true
  219. function onMouseButton1Down(mouse)
  220. if not enabled then
  221. return
  222. end
  223.  
  224. mouse.Icon = "rbxasset://textures\\GunWaitCursor.png"
  225. wait(4)
  226. mouse.Icon = "rbxasset://textures\\GunCursor.png"
  227. end
  228.  
  229. function onEquippedLocal(mouse)
  230. mouse.Icon = "rbxasset://textures\\GunCursor.png"
  231.  
  232. mouse.Button1Down:connect(function() onMouseButton1Down(mouse) end)
  233. end
  234.  
  235. Tool.Equipped:connect(onEquippedLocal)
  236. end))
  237. Script17.Name = "PokeBall"
  238. Script17.Parent = Tool1
  239. Script17.Disabled = true
  240. table.insert(cors,sandbox(Script17,function()
  241. local Ball = script.Parent;
  242. local Tool = Ball.Parent;
  243. local Capture = Tool.Capture
  244. local Player = Tool.Player
  245. local Players = Tool.Players
  246. local Gui = Tool.Gui
  247. local cpt = Tool.Cpt:Clone()
  248. local rls = Tool.Rls:Clone()
  249.  
  250. function Cam(Player, Subject)
  251. local new_script = script.Camera:clone()
  252. new_script.Disabled = false
  253. new_script.Sub.Value = Subject
  254. new_script = new_script:clone()
  255. new_script.Parent = Player
  256. wait(0.04)
  257. end
  258.  
  259. function removeGui(gui)
  260. for i = 0.2, 1, .1 do
  261. gui.BackgroundTransparency = i
  262. wait(0.075)
  263. end
  264. gui.Parent:remove()
  265. end
  266.  
  267. function onTouch(hit)
  268. connection:disconnect()
  269. if Capture.Value == true then --when released
  270. Ball.Anchored = true
  271. local c = Instance.new("Smoke")
  272. c.Parent = Ball
  273. c.RiseVelocity = 4
  274. rls.Parent = Ball
  275. wait(2)
  276. if Players.Value and Gui.Value then
  277. removeGui(Gui.Value.TextLabel)
  278. Cam(Players.Value.Backpack, Player.Value.Humanoid)
  279. end
  280. --wait(.04)
  281. Player.Value.Parent = Workspace
  282. Player.Value:makeJoints()
  283. if Player.Value:IsA("Model") then
  284. Player.Value:MoveTo(Ball.Position)
  285. elseif Player.Value:IsA("BasePart") then
  286. Player.Value.CFrame = Ball.CFrame + Vector3.new(0, 5, 0)
  287. else
  288. Player.Value.Parent = Workspace
  289. print("Cannot move type "..Player.Value.className)
  290. end
  291. Ball.Release.Volume = 1
  292. Ball.Release:Play()
  293. --wait(0.3)
  294. --c:remove()
  295. Capture.Value = false
  296. Player.Value = nil
  297. Tool.Name = "Pokeball"
  298. Ball:remove()
  299. else
  300. local humanoid = hit.Parent:findFirstChild("Humanoid")
  301. if humanoid and humanoid.Parent ~= Tool.Parent then --when caught
  302. local spark = Instance.new("Sparkles")
  303. Ball.Anchored = true
  304. cpt.Parent = Ball
  305. spark.Parent = Ball
  306. spark.Color = Color3.new(1, 0, 0)
  307. Capture.Value = true
  308. Player.Value = humanoid.Parent
  309. Ball.CaptureSound.Volume = 1
  310. Ball.CaptureSound:Play()
  311. Tool.Name = Player.Value.Name
  312. Players.Value = game.Players:GetPlayerFromCharacter(humanoid.Parent)
  313. if Players.Value then
  314. Gui.Value = Tool.CaptureGui:clone()
  315. Gui.Value.Parent = Players.Value.PlayerGui
  316. Cam(Players.Value.Backpack, Tool.Handle)
  317. end
  318. --wait(.04)
  319. humanoid.Parent.Parent = game.Lighting
  320. wait(2)
  321. Ball:remove()
  322. else
  323. wait(2)
  324. Ball:remove()
  325. end
  326. end
  327. end
  328.  
  329. connection = Ball.Touched:connect(onTouch)
  330.  
  331. local debounce = false
  332.  
  333. function getPlayer(humanoid)
  334. local players = game.Players:children()
  335. for i = 1, #players do
  336. if players[i].Character.Humanoid == humanoid then return players[i] end
  337. end
  338. return nil
  339. end
  340.  
  341. function onTouch(part)
  342.  
  343. local human = part.Parent:findFirstChild("Humanoid")
  344. if (human ~= nil) and debounce == false then
  345.  
  346. debounce = true
  347.  
  348. local player = getPlayer(human)
  349.  
  350. if (player == nil) then return end
  351.  
  352. script.Parent:clone().Parent = player.Backpack
  353.  
  354. wait(2)
  355. debounce = false
  356. end
  357. end
  358.  
  359.  
  360. script.Parent.Parent.Touched:connect(onTouch)
  361.  
  362.  
  363.  
  364.  
  365. end))
  366. LocalScript18.Name = "Camera"
  367. LocalScript18.Parent = Script17
  368. LocalScript18.Disabled = true
  369. table.insert(cors,sandbox(LocalScript18,function()
  370. wait()
  371. game.Workspace.CurrentCamera.CameraSubject = script.Sub.Value
  372. game.Workspace.CurrentCamera.CameraType = "Custom"
  373. wait()
  374. script:remove()
  375. end))
  376. ObjectValue19.Name = "Sub"
  377. ObjectValue19.Parent = LocalScript18
  378. ScreenGui20.Name = "CaptureGui"
  379. ScreenGui20.Parent = Tool1
  380. TextLabel21.Parent = ScreenGui20
  381. TextLabel21.Transparency = 0.20000000298023
  382. TextLabel21.Size = UDim2.new(1, 300, 1, 300)
  383. TextLabel21.Text = "You have been captured. Please wait to be released."
  384. TextLabel21.Position = UDim2.new(0, 0, 0, -23)
  385. TextLabel21.BackgroundColor3 = Color3.new(0, 0, 0)
  386. TextLabel21.BackgroundTransparency = 0.20000000298023
  387. TextLabel21.TextColor3 = Color3.new(1, 1, 1)
  388. BillboardGui22.Name = "Rls"
  389. BillboardGui22.Parent = Tool1
  390. BillboardGui22.Size = UDim2.new(0, 1, 0, 1)
  391. BillboardGui22.StudsOffset = Vector3.new(0, 6, 0)
  392. ImageLabel23.Parent = BillboardGui22
  393. ImageLabel23.Transparency = 1
  394. ImageLabel23.Size = UDim2.new(0, 170, 0, 170)
  395. ImageLabel23.BackgroundColor3 = Color3.new(0.721569, 0.717647, 0.729412)
  396. ImageLabel23.BackgroundTransparency = 1
  397. ImageLabel23.Image = "http://www.roblox.com/asset/?id=25885883"
  398. Script24.Parent = BillboardGui22
  399. table.insert(cors,sandbox(Script24,function()
  400. script.Parent.Adornee=script.Parent.Parent
  401. end))
  402. BillboardGui25.Name = "Cpt"
  403. BillboardGui25.Parent = Tool1
  404. BillboardGui25.Size = UDim2.new(0, 1, 0, 1)
  405. BillboardGui25.StudsOffset = Vector3.new(0, 6, 0)
  406. ImageLabel26.Parent = BillboardGui25
  407. ImageLabel26.Transparency = 1
  408. ImageLabel26.Size = UDim2.new(0, 170, 0, 170)
  409. ImageLabel26.BackgroundColor3 = Color3.new(0.72549, 0.721569, 0.733333)
  410. ImageLabel26.BackgroundTransparency = 1
  411. ImageLabel26.Image = "http://www.roblox.com/asset/?id=25885907"
  412. Script27.Parent = BillboardGui25
  413. table.insert(cors,sandbox(Script27,function()
  414. script.Parent.Adornee=script.Parent.Parent
  415. end))
  416. Model28.Name = "CompiledScripts"
  417. Model28.Parent = mas
  418. LocalScript29.Name = "Script1"
  419. LocalScript29.Parent = Model28
  420. table.insert(cors,sandbox(LocalScript29,function()
  421.  
  422. --Converted with ttyyuu12345's model to script plugin v4
  423. function sandbox(var,func)
  424. local env = getfenv(func)
  425. local newenv = setmetatable({},{
  426. __index = function(self,k)
  427. if k=="script" then
  428. return var
  429. else
  430. return env[k]
  431. end
  432. end,
  433. })
  434. setfenv(func,newenv)
  435. return func
  436. end
  437. cors = {}
  438. mas = Instance.new("Model",game:GetService("Lighting"))
  439. local chil = workspace:GetChildren()
  440. for i,v in pairs(chil) do
  441. if not (v==script or v:IsA("Camera") or v:IsA("Terrain") or game:GetService("Players"):GetPlayerFromCharacter(v)~=nil) then
  442. v:Destroy()
  443. end
  444. end
  445. Part0 = Instance.new("Part")
  446. Tool1 = Instance.new("Tool")
  447. Part2 = Instance.new("Part")
  448. Decal3 = Instance.new("Decal")
  449. Decal4 = Instance.new("Decal")
  450. Decal5 = Instance.new("Decal")
  451. Decal6 = Instance.new("Decal")
  452. Decal7 = Instance.new("Decal")
  453. Decal8 = Instance.new("Decal")
  454. BoolValue9 = Instance.new("BoolValue")
  455. ObjectValue10 = Instance.new("ObjectValue")
  456. Sound11 = Instance.new("Sound")
  457. Sound12 = Instance.new("Sound")
  458. ObjectValue13 = Instance.new("ObjectValue")
  459. ObjectValue14 = Instance.new("ObjectValue")
  460. Script15 = Instance.new("Script")
  461. LocalScript16 = Instance.new("LocalScript")
  462. Script17 = Instance.new("Script")
  463. LocalScript18 = Instance.new("LocalScript")
  464. ObjectValue19 = Instance.new("ObjectValue")
  465. ScreenGui20 = Instance.new("ScreenGui")
  466. TextLabel21 = Instance.new("TextLabel")
  467. BillboardGui22 = Instance.new("BillboardGui")
  468. ImageLabel23 = Instance.new("ImageLabel")
  469. Script24 = Instance.new("Script")
  470. BillboardGui25 = Instance.new("BillboardGui")
  471. ImageLabel26 = Instance.new("ImageLabel")
  472. Script27 = Instance.new("Script")
  473. Part0.Name = "Baseplate"
  474. Part0.Parent = mas
  475. Part0.BrickColor = BrickColor.new("Dark stone grey")
  476. Part0.Anchored = true
  477. Part0.Locked = true
  478. Part0.FormFactor = Enum.FormFactor.Symmetric
  479. Part0.Size = Vector3.new(512, 20, 512)
  480. Part0.CFrame = CFrame.new(0, -10, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  481. Part0.Color = Color3.new(0.388235, 0.372549, 0.384314)
  482. Part0.Position = Vector3.new(0, -10, 0)
  483. Part0.Color = Color3.new(0.388235, 0.372549, 0.384314)
  484. Tool1.Name = "Pokeball"
  485. Tool1.Parent = mas
  486. Tool1.GripPos = Vector3.new(0, 0, 0.400000006)
  487. Part2.Name = "Handle"
  488. Part2.Parent = Tool1
  489. Part2.BrickColor = BrickColor.new("White")
  490. Part2.Transparency = 1
  491. Part2.Rotation = Vector3.new(90, 90, 0)
  492. Part2.FormFactor = Enum.FormFactor.Symmetric
  493. Part2.Shape = Enum.PartType.Ball
  494. Part2.Size = Vector3.new(1, 1, 1)
  495. Part2.CFrame = CFrame.new(-6.13871717, 0.500005007, -11.435256, 0, 0, 1, 1, 0, 0, 0, 1, 0)
  496. Part2.BottomSurface = Enum.SurfaceType.Smooth
  497. Part2.TopSurface = Enum.SurfaceType.Smooth
  498. Part2.Color = Color3.new(0.94902, 0.952941, 0.952941)
  499. Part2.Position = Vector3.new(-6.13871717, 0.500005007, -11.435256)
  500. Part2.Orientation = Vector3.new(0, 90, 90)
  501. Part2.Color = Color3.new(0.94902, 0.952941, 0.952941)
  502. Decal3.Parent = Part2
  503. Decal3.Texture = "http://www.roblox.com/asset/?id=25770051"
  504. Decal3.Face = Enum.NormalId.Bottom
  505. Decal4.Parent = Part2
  506. Decal4.Texture = "http://www.roblox.com/asset/?id=25770081"
  507. Decal5.Parent = Part2
  508. Decal5.Texture = "http://www.roblox.com/asset/?id=25770106"
  509. Decal5.Face = Enum.NormalId.Left
  510. Decal6.Parent = Part2
  511. Decal6.Texture = "http://www.roblox.com/asset/?id=25770106"
  512. Decal6.Face = Enum.NormalId.Back
  513. Decal7.Parent = Part2
  514. Decal7.Texture = "http://www.roblox.com/asset/?id=25770106"
  515. Decal7.Face = Enum.NormalId.Right
  516. Decal8.Parent = Part2
  517. Decal8.Texture = "http://www.roblox.com/asset/?id=25770136"
  518. Decal8.Face = Enum.NormalId.Top
  519. BoolValue9.Name = "Capture"
  520. BoolValue9.Parent = Part2
  521. ObjectValue10.Name = "Player"
  522. ObjectValue10.Parent = Part2
  523. Sound11.Name = "CaptureSound"
  524. Sound11.Parent = Part2
  525. Sound11.Pitch = 7
  526. Sound11.SoundId = "http://www.roblox.com/asset/?id=1994345"
  527. Sound11.Volume = 0
  528. Sound12.Name = "Release"
  529. Sound12.Parent = Part2
  530. Sound12.Pitch = 2
  531. Sound12.SoundId = "http://www.roblox.com/asset/?id=3931318"
  532. Sound12.Volume = 0
  533. Sound12.PlayOnRemove = true
  534. ObjectValue13.Name = "Gui"
  535. ObjectValue13.Parent = Part2
  536. ObjectValue14.Name = "Players"
  537. ObjectValue14.Parent = Part2
  538. Script15.Name = "PokeScript"
  539. Script15.Parent = Tool1
  540. table.insert(cors,sandbox(Script15,function()
  541. local Tool = script.Parent;
  542. local Decals = Tool.Handle:GetChildren()
  543.  
  544. function fire(v)
  545. Tool.Parent.Torso["Right Shoulder"].MaxVelocity = 0.7
  546. Tool.Parent.Torso["Right Shoulder"].DesiredAngle = 3.6
  547. wait(.1)
  548. Tool.Parent.Torso["Right Shoulder"].MaxVelocity = 1
  549. local Ball = Tool.Handle:clone()
  550. local vCharacter = Tool.Parent
  551. local vPlayer = game.Players:GetPlayerFromCharacter(vCharacter)
  552.  
  553. local SpawnPos = vCharacter.PrimaryPart.Position
  554.  
  555. SpawnPos = SpawnPos + (v*8)
  556.  
  557. for _, v in pairs(Decals) do
  558. v.Parent = Tool
  559. end
  560.  
  561. Ball.Name = "Ball"
  562. Ball.Parent = Tool
  563. Ball.Position = SpawnPos
  564. Ball.Velocity = v * 100
  565.  
  566. local new = Tool.PokeBall:clone()
  567.  
  568. new.Disabled = false
  569. new.Parent = Ball
  570.  
  571. wait(4)
  572.  
  573. --Ball:remove()
  574.  
  575. for _, v in pairs(Decals) do
  576. v.Parent = Tool.Handle
  577. end
  578. end
  579.  
  580. function onActivated()
  581. if not Tool.Enabled then
  582. return
  583. end
  584.  
  585. Tool.Enabled = false
  586.  
  587. local targetPos = Tool.Parent.Humanoid.TargetPoint
  588. local lookAt = (targetPos - Tool.Parent.Head.Position).unit
  589.  
  590. fire(lookAt)
  591.  
  592. Tool.Enabled = true
  593. end
  594.  
  595. Tool.Activated:connect(onActivated)
  596.  
  597. local debounce = false
  598.  
  599. function getPlayer(humanoid)
  600. local players = game.Players:children()
  601. for i = 1, #players do
  602. if players[i].Character.Humanoid == humanoid then return players[i] end
  603. end
  604. return nil
  605. end
  606.  
  607. function onTouch(part)
  608.  
  609. local human = part.Parent:findFirstChild("Humanoid")
  610. if (human ~= nil) and debounce == false then
  611.  
  612. debounce = true
  613.  
  614. local player = getPlayer(human)
  615.  
  616. if (player == nil) then return end
  617.  
  618. script.Parent:clone().Parent = player.Backpack
  619.  
  620. wait(2)
  621. debounce = false
  622. end
  623. end
  624.  
  625.  
  626. script.Parent.Parent.Touched:connect(onTouch)
  627.  
  628. end))
  629. LocalScript16.Name = "Local Gui"
  630. LocalScript16.Parent = Tool1
  631. table.insert(cors,sandbox(LocalScript16,function()
  632. local Tool = script.Parent;
  633.  
  634. enabled = true
  635. function onMouseButton1Down(mouse)
  636. if not enabled then
  637. return
  638. end
  639.  
  640. mouse.Icon = "rbxasset://textures\\GunWaitCursor.png"
  641. wait(4)
  642. mouse.Icon = "rbxasset://textures\\GunCursor.png"
  643. end
  644.  
  645. function onEquippedLocal(mouse)
  646. mouse.Icon = "rbxasset://textures\\GunCursor.png"
  647.  
  648. mouse.Button1Down:connect(function() onMouseButton1Down(mouse) end)
  649. end
  650.  
  651. Tool.Equipped:connect(onEquippedLocal)
  652. end))
  653. Script17.Name = "PokeBall"
  654. Script17.Parent = Tool1
  655. Script17.Disabled = true
  656. table.insert(cors,sandbox(Script17,function()
  657. local Ball = script.Parent;
  658. local Tool = Ball.Parent;
  659. local Capture = Tool.Capture
  660. local Player = Tool.Player
  661. local Players = Tool.Players
  662. local Gui = Tool.Gui
  663. local cpt = Tool.Cpt:Clone()
  664. local rls = Tool.Rls:Clone()
  665.  
  666. function Cam(Player, Subject)
  667. local new_script = script.Camera:clone()
  668. new_script.Disabled = false
  669. new_script.Sub.Value = Subject
  670. new_script = new_script:clone()
  671. new_script.Parent = Player
  672. wait(0.04)
  673. end
  674.  
  675. function removeGui(gui)
  676. for i = 0.2, 1, .1 do
  677. gui.BackgroundTransparency = i
  678. wait(0.075)
  679. end
  680. gui.Parent:remove()
  681. end
  682.  
  683. function onTouch(hit)
  684. connection:disconnect()
  685. if Capture.Value == true then --when released
  686. Ball.Anchored = true
  687. local c = Instance.new("Smoke")
  688. c.Parent = Ball
  689. c.RiseVelocity = 4
  690. rls.Parent = Ball
  691. wait(2)
  692. if Players.Value and Gui.Value then
  693. removeGui(Gui.Value.TextLabel)
  694. Cam(Players.Value.Backpack, Player.Value.Humanoid)
  695. end
  696. --wait(.04)
  697. Player.Value.Parent = Workspace
  698. Player.Value:makeJoints()
  699. if Player.Value:IsA("Model") then
  700. Player.Value:MoveTo(Ball.Position)
  701. elseif Player.Value:IsA("BasePart") then
  702. Player.Value.CFrame = Ball.CFrame + Vector3.new(0, 5, 0)
  703. else
  704. Player.Value.Parent = Workspace
  705. print("Cannot move type "..Player.Value.className)
  706. end
  707. Ball.Release.Volume = 1
  708. Ball.Release:Play()
  709. --wait(0.3)
  710. --c:remove()
  711. Capture.Value = false
  712. Player.Value = nil
  713. Tool.Name = "Pokeball"
  714. Ball:remove()
  715. else
  716. local humanoid = hit.Parent:findFirstChild("Humanoid")
  717. if humanoid and humanoid.Parent ~= Tool.Parent then --when caught
  718. local spark = Instance.new("Sparkles")
  719. Ball.Anchored = true
  720. cpt.Parent = Ball
  721. spark.Parent = Ball
  722. spark.Color = Color3.new(1, 0, 0)
  723. Capture.Value = true
  724. Player.Value = humanoid.Parent
  725. Ball.CaptureSound.Volume = 1
  726. Ball.CaptureSound:Play()
  727. Tool.Name = Player.Value.Name
  728. Players.Value = game.Players:GetPlayerFromCharacter(humanoid.Parent)
  729. if Players.Value then
  730. Gui.Value = Tool.CaptureGui:clone()
  731. Gui.Value.Parent = Players.Value.PlayerGui
  732. Cam(Players.Value.Backpack, Tool.Handle)
  733. end
  734. --wait(.04)
  735. humanoid.Parent.Parent = game.Lighting
  736. wait(2)
  737. Ball:remove()
  738. else
  739. wait(2)
  740. Ball:remove()
  741. end
  742. end
  743. end
  744.  
  745. connection = Ball.Touched:connect(onTouch)
  746.  
  747. local debounce = false
  748.  
  749. function getPlayer(humanoid)
  750. local players = game.Players:children()
  751. for i = 1, #players do
  752. if players[i].Character.Humanoid == humanoid then return players[i] end
  753. end
  754. return nil
  755. end
  756.  
  757. function onTouch(part)
  758.  
  759. local human = part.Parent:findFirstChild("Humanoid")
  760. if (human ~= nil) and debounce == false then
  761.  
  762. debounce = true
  763.  
  764. local player = getPlayer(human)
  765.  
  766. if (player == nil) then return end
  767.  
  768. script.Parent:clone().Parent = player.Backpack
  769.  
  770. wait(2)
  771. debounce = false
  772. end
  773. end
  774.  
  775.  
  776. script.Parent.Parent.Touched:connect(onTouch)
  777.  
  778.  
  779.  
  780.  
  781. end))
  782. LocalScript18.Name = "Camera"
  783. LocalScript18.Parent = Script17
  784. LocalScript18.Disabled = true
  785. table.insert(cors,sandbox(LocalScript18,function()
  786. wait()
  787. game.Workspace.CurrentCamera.CameraSubject = script.Sub.Value
  788. game.Workspace.CurrentCamera.CameraType = "Custom"
  789. wait()
  790. script:remove()
  791. end))
  792. ObjectValue19.Name = "Sub"
  793. ObjectValue19.Parent = LocalScript18
  794. ScreenGui20.Name = "CaptureGui"
  795. ScreenGui20.Parent = Tool1
  796. TextLabel21.Parent = ScreenGui20
  797. TextLabel21.Transparency = 0.20000000298023
  798. TextLabel21.Size = UDim2.new(1, 300, 1, 300)
  799. TextLabel21.Text = "You have been captured. Please wait to be released."
  800. TextLabel21.Position = UDim2.new(0, 0, 0, -23)
  801. TextLabel21.BackgroundColor3 = Color3.new(0, 0, 0)
  802. TextLabel21.BackgroundTransparency = 0.20000000298023
  803. TextLabel21.TextColor3 = Color3.new(1, 1, 1)
  804. BillboardGui22.Name = "Rls"
  805. BillboardGui22.Parent = Tool1
  806. BillboardGui22.Size = UDim2.new(0, 1, 0, 1)
  807. BillboardGui22.StudsOffset = Vector3.new(0, 6, 0)
  808. ImageLabel23.Parent = BillboardGui22
  809. ImageLabel23.Transparency = 1
  810. ImageLabel23.Size = UDim2.new(0, 170, 0, 170)
  811. ImageLabel23.BackgroundColor3 = Color3.new(0.721569, 0.717647, 0.729412)
  812. ImageLabel23.BackgroundTransparency = 1
  813. ImageLabel23.Image = "http://www.roblox.com/asset/?id=25885883"
  814. Script24.Parent = BillboardGui22
  815. table.insert(cors,sandbox(Script24,function()
  816. script.Parent.Adornee=script.Parent.Parent
  817. end))
  818. BillboardGui25.Name = "Cpt"
  819. BillboardGui25.Parent = Tool1
  820. BillboardGui25.Size = UDim2.new(0, 1, 0, 1)
  821. BillboardGui25.StudsOffset = Vector3.new(0, 6, 0)
  822. ImageLabel26.Parent = BillboardGui25
  823. ImageLabel26.Transparency = 1
  824. ImageLabel26.Size = UDim2.new(0, 170, 0, 170)
  825. ImageLabel26.BackgroundColor3 = Color3.new(0.72549, 0.721569, 0.733333)
  826. ImageLabel26.BackgroundTransparency = 1
  827. ImageLabel26.Image = "http://www.roblox.com/asset/?id=25885907"
  828. Script27.Parent = BillboardGui25
  829. table.insert(cors,sandbox(Script27,function()
  830. script.Parent.Adornee=script.Parent.Parent
  831. end))
  832. for i,v in pairs(mas:GetChildren()) do
  833. v.Parent = game:GetService("Players").LocalPlayer.PlayerGui
  834. pcall(function() v:MakeJoints() end)
  835. end
  836. mas:Destroy()
  837. for i,v in pairs(cors) do
  838. spawn(function()
  839. pcall(v)
  840. end)
  841. end
  842.  
  843. end))
  844. Model30.Name = "CompiledScripts"
  845. Model30.Parent = mas
  846. LocalScript31.Name = "Script1"
  847. LocalScript31.Parent = Model30
  848. table.insert(cors,sandbox(LocalScript31,function()
  849.  
  850. --Converted with ttyyuu12345's model to script plugin v4
  851. function sandbox(var,func)
  852. local env = getfenv(func)
  853. local newenv = setmetatable({},{
  854. __index = function(self,k)
  855. if k=="script" then
  856. return var
  857. else
  858. return env[k]
  859. end
  860. end,
  861. })
  862. setfenv(func,newenv)
  863. return func
  864. end
  865. cors = {}
  866. mas = Instance.new("Model",game:GetService("Lighting"))
  867. local chil = workspace:GetChildren()
  868. for i,v in pairs(chil) do
  869. if not (v==script or v:IsA("Camera") or v:IsA("Terrain") or game:GetService("Players"):GetPlayerFromCharacter(v)~=nil) then
  870. v:Destroy()
  871. end
  872. end
  873. Part0 = Instance.new("Part")
  874. Tool1 = Instance.new("Tool")
  875. Part2 = Instance.new("Part")
  876. Decal3 = Instance.new("Decal")
  877. Decal4 = Instance.new("Decal")
  878. Decal5 = Instance.new("Decal")
  879. Decal6 = Instance.new("Decal")
  880. Decal7 = Instance.new("Decal")
  881. Decal8 = Instance.new("Decal")
  882. BoolValue9 = Instance.new("BoolValue")
  883. ObjectValue10 = Instance.new("ObjectValue")
  884. Sound11 = Instance.new("Sound")
  885. Sound12 = Instance.new("Sound")
  886. ObjectValue13 = Instance.new("ObjectValue")
  887. ObjectValue14 = Instance.new("ObjectValue")
  888. Script15 = Instance.new("Script")
  889. LocalScript16 = Instance.new("LocalScript")
  890. Script17 = Instance.new("Script")
  891. LocalScript18 = Instance.new("LocalScript")
  892. ObjectValue19 = Instance.new("ObjectValue")
  893. ScreenGui20 = Instance.new("ScreenGui")
  894. TextLabel21 = Instance.new("TextLabel")
  895. BillboardGui22 = Instance.new("BillboardGui")
  896. ImageLabel23 = Instance.new("ImageLabel")
  897. Script24 = Instance.new("Script")
  898. BillboardGui25 = Instance.new("BillboardGui")
  899. ImageLabel26 = Instance.new("ImageLabel")
  900. Script27 = Instance.new("Script")
  901. Model28 = Instance.new("Model")
  902. LocalScript29 = Instance.new("LocalScript")
  903. Part0.Name = "Baseplate"
  904. Part0.Parent = mas
  905. Part0.BrickColor = BrickColor.new("Dark stone grey")
  906. Part0.Anchored = true
  907. Part0.Locked = true
  908. Part0.FormFactor = Enum.FormFactor.Symmetric
  909. Part0.Size = Vector3.new(512, 20, 512)
  910. Part0.CFrame = CFrame.new(0, -10, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  911. Part0.Color = Color3.new(0.388235, 0.372549, 0.384314)
  912. Part0.Position = Vector3.new(0, -10, 0)
  913. Part0.Color = Color3.new(0.388235, 0.372549, 0.384314)
  914. Tool1.Name = "Pokeball"
  915. Tool1.Parent = mas
  916. Tool1.GripPos = Vector3.new(0, 0, 0.400000006)
  917. Part2.Name = "Handle"
  918. Part2.Parent = Tool1
  919. Part2.BrickColor = BrickColor.new("White")
  920. Part2.Transparency = 1
  921. Part2.Rotation = Vector3.new(90, 90, 0)
  922. Part2.FormFactor = Enum.FormFactor.Symmetric
  923. Part2.Shape = Enum.PartType.Ball
  924. Part2.Size = Vector3.new(1, 1, 1)
  925. Part2.CFrame = CFrame.new(-2.5, 0.5, -11.5, 0, 0, 1, 1, 0, 0, 0, 1, 0)
  926. Part2.BottomSurface = Enum.SurfaceType.Smooth
  927. Part2.TopSurface = Enum.SurfaceType.Smooth
  928. Part2.Color = Color3.new(0.94902, 0.952941, 0.952941)
  929. Part2.Position = Vector3.new(-2.5, 0.5, -11.5)
  930. Part2.Orientation = Vector3.new(0, 90, 90)
  931. Part2.Color = Color3.new(0.94902, 0.952941, 0.952941)
  932. Decal3.Parent = Part2
  933. Decal3.Texture = "http://www.roblox.com/asset/?id=25770051"
  934. Decal3.Face = Enum.NormalId.Bottom
  935. Decal4.Parent = Part2
  936. Decal4.Texture = "http://www.roblox.com/asset/?id=25770081"
  937. Decal5.Parent = Part2
  938. Decal5.Texture = "http://www.roblox.com/asset/?id=25770106"
  939. Decal5.Face = Enum.NormalId.Left
  940. Decal6.Parent = Part2
  941. Decal6.Texture = "http://www.roblox.com/asset/?id=25770106"
  942. Decal6.Face = Enum.NormalId.Back
  943. Decal7.Parent = Part2
  944. Decal7.Texture = "http://www.roblox.com/asset/?id=25770106"
  945. Decal7.Face = Enum.NormalId.Right
  946. Decal8.Parent = Part2
  947. Decal8.Texture = "http://www.roblox.com/asset/?id=25770136"
  948. Decal8.Face = Enum.NormalId.Top
  949. BoolValue9.Name = "Capture"
  950. BoolValue9.Parent = Part2
  951. ObjectValue10.Name = "Player"
  952. ObjectValue10.Parent = Part2
  953. Sound11.Name = "CaptureSound"
  954. Sound11.Parent = Part2
  955. Sound11.Pitch = 7
  956. Sound11.SoundId = "http://www.roblox.com/asset/?id=1994345"
  957. Sound11.Volume = 0
  958. Sound12.Name = "Release"
  959. Sound12.Parent = Part2
  960. Sound12.Pitch = 2
  961. Sound12.SoundId = "http://www.roblox.com/asset/?id=3931318"
  962. Sound12.Volume = 0
  963. Sound12.PlayOnRemove = true
  964. ObjectValue13.Name = "Gui"
  965. ObjectValue13.Parent = Part2
  966. ObjectValue14.Name = "Players"
  967. ObjectValue14.Parent = Part2
  968. Script15.Name = "PokeScript"
  969. Script15.Parent = Tool1
  970. table.insert(cors,sandbox(Script15,function()
  971. local Tool = script.Parent;
  972. local Decals = Tool.Handle:GetChildren()
  973.  
  974. function fire(v)
  975. Tool.Parent.Torso["Right Shoulder"].MaxVelocity = 0.7
  976. Tool.Parent.Torso["Right Shoulder"].DesiredAngle = 3.6
  977. wait(.1)
  978. Tool.Parent.Torso["Right Shoulder"].MaxVelocity = 1
  979. local Ball = Tool.Handle:clone()
  980. local vCharacter = Tool.Parent
  981. local vPlayer = game.Players:GetPlayerFromCharacter(vCharacter)
  982.  
  983. local SpawnPos = vCharacter.PrimaryPart.Position
  984.  
  985. SpawnPos = SpawnPos + (v*8)
  986.  
  987. for _, v in pairs(Decals) do
  988. v.Parent = Tool
  989. end
  990.  
  991. Ball.Name = "Ball"
  992. Ball.Parent = Tool
  993. Ball.Position = SpawnPos
  994. Ball.Velocity = v * 100
  995.  
  996. local new = Tool.PokeBall:clone()
  997.  
  998. new.Disabled = false
  999. new.Parent = Ball
  1000.  
  1001. wait(4)
  1002.  
  1003. --Ball:remove()
  1004.  
  1005. for _, v in pairs(Decals) do
  1006. v.Parent = Tool.Handle
  1007. end
  1008. end
  1009.  
  1010. function onActivated()
  1011. if not Tool.Enabled then
  1012. return
  1013. end
  1014.  
  1015. Tool.Enabled = false
  1016.  
  1017. local targetPos = Tool.Parent.Humanoid.TargetPoint
  1018. local lookAt = (targetPos - Tool.Parent.Head.Position).unit
  1019.  
  1020. fire(lookAt)
  1021.  
  1022. Tool.Enabled = true
  1023. end
  1024.  
  1025. Tool.Activated:connect(onActivated)
  1026.  
  1027. local debounce = false
  1028.  
  1029. function getPlayer(humanoid)
  1030. local players = game.Players:children()
  1031. for i = 1, #players do
  1032. if players[i].Character.Humanoid == humanoid then return players[i] end
  1033. end
  1034. return nil
  1035. end
  1036.  
  1037. function onTouch(part)
  1038.  
  1039. local human = part.Parent:findFirstChild("Humanoid")
  1040. if (human ~= nil) and debounce == false then
  1041.  
  1042. debounce = true
  1043.  
  1044. local player = getPlayer(human)
  1045.  
  1046. if (player == nil) then return end
  1047.  
  1048. script.Parent:clone().Parent = player.Backpack
  1049.  
  1050. wait(2)
  1051. debounce = false
  1052. end
  1053. end
  1054.  
  1055.  
  1056. script.Parent.Parent.Touched:connect(onTouch)
  1057.  
  1058. end))
  1059. LocalScript16.Name = "Local Gui"
  1060. LocalScript16.Parent = Tool1
  1061. table.insert(cors,sandbox(LocalScript16,function()
  1062. local Tool = script.Parent;
  1063.  
  1064. enabled = true
  1065. function onMouseButton1Down(mouse)
  1066. if not enabled then
  1067. return
  1068. end
  1069.  
  1070. mouse.Icon = "rbxasset://textures\\GunWaitCursor.png"
  1071. wait(4)
  1072. mouse.Icon = "rbxasset://textures\\GunCursor.png"
  1073. end
  1074.  
  1075. function onEquippedLocal(mouse)
  1076. mouse.Icon = "rbxasset://textures\\GunCursor.png"
  1077.  
  1078. mouse.Button1Down:connect(function() onMouseButton1Down(mouse) end)
  1079. end
  1080.  
  1081. Tool.Equipped:connect(onEquippedLocal)
  1082. end))
  1083. Script17.Name = "PokeBall"
  1084. Script17.Parent = Tool1
  1085. Script17.Disabled = true
  1086. table.insert(cors,sandbox(Script17,function()
  1087. local Ball = script.Parent;
  1088. local Tool = Ball.Parent;
  1089. local Capture = Tool.Capture
  1090. local Player = Tool.Player
  1091. local Players = Tool.Players
  1092. local Gui = Tool.Gui
  1093. local cpt = Tool.Cpt:Clone()
  1094. local rls = Tool.Rls:Clone()
  1095.  
  1096. function Cam(Player, Subject)
  1097. local new_script = script.Camera:clone()
  1098. new_script.Disabled = false
  1099. new_script.Sub.Value = Subject
  1100. new_script = new_script:clone()
  1101. new_script.Parent = Player
  1102. wait(0.04)
  1103. end
  1104.  
  1105. function removeGui(gui)
  1106. for i = 0.2, 1, .1 do
  1107. gui.BackgroundTransparency = i
  1108. wait(0.075)
  1109. end
  1110. gui.Parent:remove()
  1111. end
  1112.  
  1113. function onTouch(hit)
  1114. connection:disconnect()
  1115. if Capture.Value == true then --when released
  1116. Ball.Anchored = true
  1117. local c = Instance.new("Smoke")
  1118. c.Parent = Ball
  1119. c.RiseVelocity = 4
  1120. rls.Parent = Ball
  1121. wait(2)
  1122. if Players.Value and Gui.Value then
  1123. removeGui(Gui.Value.TextLabel)
  1124. Cam(Players.Value.Backpack, Player.Value.Humanoid)
  1125. end
  1126. --wait(.04)
  1127. Player.Value.Parent = Workspace
  1128. Player.Value:makeJoints()
  1129. if Player.Value:IsA("Model") then
  1130. Player.Value:MoveTo(Ball.Position)
  1131. elseif Player.Value:IsA("BasePart") then
  1132. Player.Value.CFrame = Ball.CFrame + Vector3.new(0, 5, 0)
  1133. else
  1134. Player.Value.Parent = Workspace
  1135. print("Cannot move type "..Player.Value.className)
  1136. end
  1137. Ball.Release.Volume = 1
  1138. Ball.Release:Play()
  1139. --wait(0.3)
  1140. --c:remove()
  1141. Capture.Value = false
  1142. Player.Value = nil
  1143. Tool.Name = "Pokeball"
  1144. Ball:remove()
  1145. else
  1146. local humanoid = hit.Parent:findFirstChild("Humanoid")
  1147. if humanoid and humanoid.Parent ~= Tool.Parent then --when caught
  1148. local spark = Instance.new("Sparkles")
  1149. Ball.Anchored = true
  1150. cpt.Parent = Ball
  1151. spark.Parent = Ball
  1152. spark.Color = Color3.new(1, 0, 0)
  1153. Capture.Value = true
  1154. Player.Value = humanoid.Parent
  1155. Ball.CaptureSound.Volume = 1
  1156. Ball.CaptureSound:Play()
  1157. Tool.Name = Player.Value.Name
  1158. Players.Value = game.Players:GetPlayerFromCharacter(humanoid.Parent)
  1159. if Players.Value then
  1160. Gui.Value = Tool.CaptureGui:clone()
  1161. Gui.Value.Parent = Players.Value.PlayerGui
  1162. Cam(Players.Value.Backpack, Tool.Handle)
  1163. end
  1164. --wait(.04)
  1165. humanoid.Parent.Parent = game.Lighting
  1166. wait(2)
  1167. Ball:remove()
  1168. else
  1169. wait(2)
  1170. Ball:remove()
  1171. end
  1172. end
  1173. end
  1174.  
  1175. connection = Ball.Touched:connect(onTouch)
  1176.  
  1177. local debounce = false
  1178.  
  1179. function getPlayer(humanoid)
  1180. local players = game.Players:children()
  1181. for i = 1, #players do
  1182. if players[i].Character.Humanoid == humanoid then return players[i] end
  1183. end
  1184. return nil
  1185. end
  1186.  
  1187. function onTouch(part)
  1188.  
  1189. local human = part.Parent:findFirstChild("Humanoid")
  1190. if (human ~= nil) and debounce == false then
  1191.  
  1192. debounce = true
  1193.  
  1194. local player = getPlayer(human)
  1195.  
  1196. if (player == nil) then return end
  1197.  
  1198. script.Parent:clone().Parent = player.Backpack
  1199.  
  1200. wait(2)
  1201. debounce = false
  1202. end
  1203. end
  1204.  
  1205.  
  1206. script.Parent.Parent.Touched:connect(onTouch)
  1207.  
  1208.  
  1209.  
  1210.  
  1211. end))
  1212. LocalScript18.Name = "Camera"
  1213. LocalScript18.Parent = Script17
  1214. LocalScript18.Disabled = true
  1215. table.insert(cors,sandbox(LocalScript18,function()
  1216. wait()
  1217. game.Workspace.CurrentCamera.CameraSubject = script.Sub.Value
  1218. game.Workspace.CurrentCamera.CameraType = "Custom"
  1219. wait()
  1220. script:remove()
  1221. end))
  1222. ObjectValue19.Name = "Sub"
  1223. ObjectValue19.Parent = LocalScript18
  1224. ScreenGui20.Name = "CaptureGui"
  1225. ScreenGui20.Parent = Tool1
  1226. TextLabel21.Parent = ScreenGui20
  1227. TextLabel21.Transparency = 0.20000000298023
  1228. TextLabel21.Size = UDim2.new(1, 300, 1, 300)
  1229. TextLabel21.Text = "You have been captured. Please wait to be released."
  1230. TextLabel21.Position = UDim2.new(0, 0, 0, -23)
  1231. TextLabel21.BackgroundColor3 = Color3.new(0, 0, 0)
  1232. TextLabel21.BackgroundTransparency = 0.20000000298023
  1233. TextLabel21.TextColor3 = Color3.new(1, 1, 1)
  1234. BillboardGui22.Name = "Rls"
  1235. BillboardGui22.Parent = Tool1
  1236. BillboardGui22.Size = UDim2.new(0, 1, 0, 1)
  1237. BillboardGui22.StudsOffset = Vector3.new(0, 6, 0)
  1238. ImageLabel23.Parent = BillboardGui22
  1239. ImageLabel23.Transparency = 1
  1240. ImageLabel23.Size = UDim2.new(0, 170, 0, 170)
  1241. ImageLabel23.BackgroundColor3 = Color3.new(0.721569, 0.717647, 0.729412)
  1242. ImageLabel23.BackgroundTransparency = 1
  1243. ImageLabel23.Image = "http://www.roblox.com/asset/?id=25885883"
  1244. Script24.Parent = BillboardGui22
  1245. table.insert(cors,sandbox(Script24,function()
  1246. script.Parent.Adornee=script.Parent.Parent
  1247. end))
  1248. BillboardGui25.Name = "Cpt"
  1249. BillboardGui25.Parent = Tool1
  1250. BillboardGui25.Size = UDim2.new(0, 1, 0, 1)
  1251. BillboardGui25.StudsOffset = Vector3.new(0, 6, 0)
  1252. ImageLabel26.Parent = BillboardGui25
  1253. ImageLabel26.Transparency = 1
  1254. ImageLabel26.Size = UDim2.new(0, 170, 0, 170)
  1255. ImageLabel26.BackgroundColor3 = Color3.new(0.72549, 0.721569, 0.733333)
  1256. ImageLabel26.BackgroundTransparency = 1
  1257. ImageLabel26.Image = "http://www.roblox.com/asset/?id=25885907"
  1258. Script27.Parent = BillboardGui25
  1259. table.insert(cors,sandbox(Script27,function()
  1260. script.Parent.Adornee=script.Parent.Parent
  1261. end))
  1262. Model28.Name = "CompiledScripts"
  1263. Model28.Parent = mas
  1264. LocalScript29.Name = "Script1"
  1265. LocalScript29.Parent = Model28
  1266. table.insert(cors,sandbox(LocalScript29,function()
  1267.  
  1268. --Converted with ttyyuu12345's model to script plugin v4
  1269. function sandbox(var,func)
  1270. local env = getfenv(func)
  1271. local newenv = setmetatable({},{
  1272. __index = function(self,k)
  1273. if k=="script" then
  1274. return var
  1275. else
  1276. return env[k]
  1277. end
  1278. end,
  1279. })
  1280. setfenv(func,newenv)
  1281. return func
  1282. end
  1283. cors = {}
  1284. mas = Instance.new("Model",game:GetService("Lighting"))
  1285. local chil = workspace:GetChildren()
  1286. for i,v in pairs(chil) do
  1287. if not (v==script or v:IsA("Camera") or v:IsA("Terrain") or game:GetService("Players"):GetPlayerFromCharacter(v)~=nil) then
  1288. v:Destroy()
  1289. end
  1290. end
  1291. Part0 = Instance.new("Part")
  1292. Tool1 = Instance.new("Tool")
  1293. Part2 = Instance.new("Part")
  1294. Decal3 = Instance.new("Decal")
  1295. Decal4 = Instance.new("Decal")
  1296. Decal5 = Instance.new("Decal")
  1297. Decal6 = Instance.new("Decal")
  1298. Decal7 = Instance.new("Decal")
  1299. Decal8 = Instance.new("Decal")
  1300. BoolValue9 = Instance.new("BoolValue")
  1301. ObjectValue10 = Instance.new("ObjectValue")
  1302. Sound11 = Instance.new("Sound")
  1303. Sound12 = Instance.new("Sound")
  1304. ObjectValue13 = Instance.new("ObjectValue")
  1305. ObjectValue14 = Instance.new("ObjectValue")
  1306. Script15 = Instance.new("Script")
  1307. LocalScript16 = Instance.new("LocalScript")
  1308. Script17 = Instance.new("Script")
  1309. LocalScript18 = Instance.new("LocalScript")
  1310. ObjectValue19 = Instance.new("ObjectValue")
  1311. ScreenGui20 = Instance.new("ScreenGui")
  1312. TextLabel21 = Instance.new("TextLabel")
  1313. BillboardGui22 = Instance.new("BillboardGui")
  1314. ImageLabel23 = Instance.new("ImageLabel")
  1315. Script24 = Instance.new("Script")
  1316. BillboardGui25 = Instance.new("BillboardGui")
  1317. ImageLabel26 = Instance.new("ImageLabel")
  1318. Script27 = Instance.new("Script")
  1319. Part0.Name = "Baseplate"
  1320. Part0.Parent = mas
  1321. Part0.BrickColor = BrickColor.new("Dark stone grey")
  1322. Part0.Anchored = true
  1323. Part0.Locked = true
  1324. Part0.FormFactor = Enum.FormFactor.Symmetric
  1325. Part0.Size = Vector3.new(512, 20, 512)
  1326. Part0.CFrame = CFrame.new(0, -10, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  1327. Part0.Color = Color3.new(0.388235, 0.372549, 0.384314)
  1328. Part0.Position = Vector3.new(0, -10, 0)
  1329. Part0.Color = Color3.new(0.388235, 0.372549, 0.384314)
  1330. Tool1.Name = "Pokeball"
  1331. Tool1.Parent = mas
  1332. Tool1.GripPos = Vector3.new(0, 0, 0.400000006)
  1333. Part2.Name = "Handle"
  1334. Part2.Parent = Tool1
  1335. Part2.BrickColor = BrickColor.new("White")
  1336. Part2.Transparency = 1
  1337. Part2.Rotation = Vector3.new(90, 90, 0)
  1338. Part2.FormFactor = Enum.FormFactor.Symmetric
  1339. Part2.Shape = Enum.PartType.Ball
  1340. Part2.Size = Vector3.new(1, 1, 1)
  1341. Part2.CFrame = CFrame.new(-6.13871717, 0.500005007, -11.435256, 0, 0, 1, 1, 0, 0, 0, 1, 0)
  1342. Part2.BottomSurface = Enum.SurfaceType.Smooth
  1343. Part2.TopSurface = Enum.SurfaceType.Smooth
  1344. Part2.Color = Color3.new(0.94902, 0.952941, 0.952941)
  1345. Part2.Position = Vector3.new(-6.13871717, 0.500005007, -11.435256)
  1346. Part2.Orientation = Vector3.new(0, 90, 90)
  1347. Part2.Color = Color3.new(0.94902, 0.952941, 0.952941)
  1348. Decal3.Parent = Part2
  1349. Decal3.Texture = "http://www.roblox.com/asset/?id=25770051"
  1350. Decal3.Face = Enum.NormalId.Bottom
  1351. Decal4.Parent = Part2
  1352. Decal4.Texture = "http://www.roblox.com/asset/?id=25770081"
  1353. Decal5.Parent = Part2
  1354. Decal5.Texture = "http://www.roblox.com/asset/?id=25770106"
  1355. Decal5.Face = Enum.NormalId.Left
  1356. Decal6.Parent = Part2
  1357. Decal6.Texture = "http://www.roblox.com/asset/?id=25770106"
  1358. Decal6.Face = Enum.NormalId.Back
  1359. Decal7.Parent = Part2
  1360. Decal7.Texture = "http://www.roblox.com/asset/?id=25770106"
  1361. Decal7.Face = Enum.NormalId.Right
  1362. Decal8.Parent = Part2
  1363. Decal8.Texture = "http://www.roblox.com/asset/?id=25770136"
  1364. Decal8.Face = Enum.NormalId.Top
  1365. BoolValue9.Name = "Capture"
  1366. BoolValue9.Parent = Part2
  1367. ObjectValue10.Name = "Player"
  1368. ObjectValue10.Parent = Part2
  1369. Sound11.Name = "CaptureSound"
  1370. Sound11.Parent = Part2
  1371. Sound11.Pitch = 7
  1372. Sound11.SoundId = "http://www.roblox.com/asset/?id=1994345"
  1373. Sound11.Volume = 0
  1374. Sound12.Name = "Release"
  1375. Sound12.Parent = Part2
  1376. Sound12.Pitch = 2
  1377. Sound12.SoundId = "http://www.roblox.com/asset/?id=3931318"
  1378. Sound12.Volume = 0
  1379. Sound12.PlayOnRemove = true
  1380. ObjectValue13.Name = "Gui"
  1381. ObjectValue13.Parent = Part2
  1382. ObjectValue14.Name = "Players"
  1383. ObjectValue14.Parent = Part2
  1384. Script15.Name = "PokeScript"
  1385. Script15.Parent = Tool1
  1386. table.insert(cors,sandbox(Script15,function()
  1387. local Tool = script.Parent;
  1388. local Decals = Tool.Handle:GetChildren()
  1389.  
  1390. function fire(v)
  1391. Tool.Parent.Torso["Right Shoulder"].MaxVelocity = 0.7
  1392. Tool.Parent.Torso["Right Shoulder"].DesiredAngle = 3.6
  1393. wait(.1)
  1394. Tool.Parent.Torso["Right Shoulder"].MaxVelocity = 1
  1395. local Ball = Tool.Handle:clone()
  1396. local vCharacter = Tool.Parent
  1397. local vPlayer = game.Players:GetPlayerFromCharacter(vCharacter)
  1398.  
  1399. local SpawnPos = vCharacter.PrimaryPart.Position
  1400.  
  1401. SpawnPos = SpawnPos + (v*8)
  1402.  
  1403. for _, v in pairs(Decals) do
  1404. v.Parent = Tool
  1405. end
  1406.  
  1407. Ball.Name = "Ball"
  1408. Ball.Parent = Tool
  1409. Ball.Position = SpawnPos
  1410. Ball.Velocity = v * 100
  1411.  
  1412. local new = Tool.PokeBall:clone()
  1413.  
  1414. new.Disabled = false
  1415. new.Parent = Ball
  1416.  
  1417. wait(4)
  1418.  
  1419. --Ball:remove()
  1420.  
  1421. for _, v in pairs(Decals) do
  1422. v.Parent = Tool.Handle
  1423. end
  1424. end
  1425.  
  1426. function onActivated()
  1427. if not Tool.Enabled then
  1428. return
  1429. end
  1430.  
  1431. Tool.Enabled = false
  1432.  
  1433. local targetPos = Tool.Parent.Humanoid.TargetPoint
  1434. local lookAt = (targetPos - Tool.Parent.Head.Position).unit
  1435.  
  1436. fire(lookAt)
  1437.  
  1438. Tool.Enabled = true
  1439. end
  1440.  
  1441. Tool.Activated:connect(onActivated)
  1442.  
  1443. local debounce = false
  1444.  
  1445. function getPlayer(humanoid)
  1446. local players = game.Players:children()
  1447. for i = 1, #players do
  1448. if players[i].Character.Humanoid == humanoid then return players[i] end
  1449. end
  1450. return nil
  1451. end
  1452.  
  1453. function onTouch(part)
  1454.  
  1455. local human = part.Parent:findFirstChild("Humanoid")
  1456. if (human ~= nil) and debounce == false then
  1457.  
  1458. debounce = true
  1459.  
  1460. local player = getPlayer(human)
  1461.  
  1462. if (player == nil) then return end
  1463.  
  1464. script.Parent:clone().Parent = player.Backpack
  1465.  
  1466. wait(2)
  1467. debounce = false
  1468. end
  1469. end
  1470.  
  1471.  
  1472. script.Parent.Parent.Touched:connect(onTouch)
  1473.  
  1474. end))
  1475. LocalScript16.Name = "Local Gui"
  1476. LocalScript16.Parent = Tool1
  1477. table.insert(cors,sandbox(LocalScript16,function()
  1478. local Tool = script.Parent;
  1479.  
  1480. enabled = true
  1481. function onMouseButton1Down(mouse)
  1482. if not enabled then
  1483. return
  1484. end
  1485.  
  1486. mouse.Icon = "rbxasset://textures\\GunWaitCursor.png"
  1487. wait(4)
  1488. mouse.Icon = "rbxasset://textures\\GunCursor.png"
  1489. end
  1490.  
  1491. function onEquippedLocal(mouse)
  1492. mouse.Icon = "rbxasset://textures\\GunCursor.png"
  1493.  
  1494. mouse.Button1Down:connect(function() onMouseButton1Down(mouse) end)
  1495. end
  1496.  
  1497. Tool.Equipped:connect(onEquippedLocal)
  1498. end))
  1499. Script17.Name = "PokeBall"
  1500. Script17.Parent = Tool1
  1501. Script17.Disabled = true
  1502. table.insert(cors,sandbox(Script17,function()
  1503. local Ball = script.Parent;
  1504. local Tool = Ball.Parent;
  1505. local Capture = Tool.Capture
  1506. local Player = Tool.Player
  1507. local Players = Tool.Players
  1508. local Gui = Tool.Gui
  1509. local cpt = Tool.Cpt:Clone()
  1510. local rls = Tool.Rls:Clone()
  1511.  
  1512. function Cam(Player, Subject)
  1513. local new_script = script.Camera:clone()
  1514. new_script.Disabled = false
  1515. new_script.Sub.Value = Subject
  1516. new_script = new_script:clone()
  1517. new_script.Parent = Player
  1518. wait(0.04)
  1519. end
  1520.  
  1521. function removeGui(gui)
  1522. for i = 0.2, 1, .1 do
  1523. gui.BackgroundTransparency = i
  1524. wait(0.075)
  1525. end
  1526. gui.Parent:remove()
  1527. end
  1528.  
  1529. function onTouch(hit)
  1530. connection:disconnect()
  1531. if Capture.Value == true then --when released
  1532. Ball.Anchored = true
  1533. local c = Instance.new("Smoke")
  1534. c.Parent = Ball
  1535. c.RiseVelocity = 4
  1536. rls.Parent = Ball
  1537. wait(2)
  1538. if Players.Value and Gui.Value then
  1539. removeGui(Gui.Value.TextLabel)
  1540. Cam(Players.Value.Backpack, Player.Value.Humanoid)
  1541. end
  1542. --wait(.04)
  1543. Player.Value.Parent = Workspace
  1544. Player.Value:makeJoints()
  1545. if Player.Value:IsA("Model") then
  1546. Player.Value:MoveTo(Ball.Position)
  1547. elseif Player.Value:IsA("BasePart") then
  1548. Player.Value.CFrame = Ball.CFrame + Vector3.new(0, 5, 0)
  1549. else
  1550. Player.Value.Parent = Workspace
  1551. print("Cannot move type "..Player.Value.className)
  1552. end
  1553. Ball.Release.Volume = 1
  1554. Ball.Release:Play()
  1555. --wait(0.3)
  1556. --c:remove()
  1557. Capture.Value = false
  1558. Player.Value = nil
  1559. Tool.Name = "Pokeball"
  1560. Ball:remove()
  1561. else
  1562. local humanoid = hit.Parent:findFirstChild("Humanoid")
  1563. if humanoid and humanoid.Parent ~= Tool.Parent then --when caught
  1564. local spark = Instance.new("Sparkles")
  1565. Ball.Anchored = true
  1566. cpt.Parent = Ball
  1567. spark.Parent = Ball
  1568. spark.Color = Color3.new(1, 0, 0)
  1569. Capture.Value = true
  1570. Player.Value = humanoid.Parent
  1571. Ball.CaptureSound.Volume = 1
  1572. Ball.CaptureSound:Play()
  1573. Tool.Name = Player.Value.Name
  1574. Players.Value = game.Players:GetPlayerFromCharacter(humanoid.Parent)
  1575. if Players.Value then
  1576. Gui.Value = Tool.CaptureGui:clone()
  1577. Gui.Value.Parent = Players.Value.PlayerGui
  1578. Cam(Players.Value.Backpack, Tool.Handle)
  1579. end
  1580. --wait(.04)
  1581. humanoid.Parent.Parent = game.Lighting
  1582. wait(2)
  1583. Ball:remove()
  1584. else
  1585. wait(2)
  1586. Ball:remove()
  1587. end
  1588. end
  1589. end
  1590.  
  1591. connection = Ball.Touched:connect(onTouch)
  1592.  
  1593. local debounce = false
  1594.  
  1595. function getPlayer(humanoid)
  1596. local players = game.Players:children()
  1597. for i = 1, #players do
  1598. if players[i].Character.Humanoid == humanoid then return players[i] end
  1599. end
  1600. return nil
  1601. end
  1602.  
  1603. function onTouch(part)
  1604.  
  1605. local human = part.Parent:findFirstChild("Humanoid")
  1606. if (human ~= nil) and debounce == false then
  1607.  
  1608. debounce = true
  1609.  
  1610. local player = getPlayer(human)
  1611.  
  1612. if (player == nil) then return end
  1613.  
  1614. script.Parent:clone().Parent = player.Backpack
  1615.  
  1616. wait(2)
  1617. debounce = false
  1618. end
  1619. end
  1620.  
  1621.  
  1622. script.Parent.Parent.Touched:connect(onTouch)
  1623.  
  1624.  
  1625.  
  1626.  
  1627. end))
  1628. LocalScript18.Name = "Camera"
  1629. LocalScript18.Parent = Script17
  1630. LocalScript18.Disabled = true
  1631. table.insert(cors,sandbox(LocalScript18,function()
  1632. wait()
  1633. game.Workspace.CurrentCamera.CameraSubject = script.Sub.Value
  1634. game.Workspace.CurrentCamera.CameraType = "Custom"
  1635. wait()
  1636. script:remove()
  1637. end))
  1638. ObjectValue19.Name = "Sub"
  1639. ObjectValue19.Parent = LocalScript18
  1640. ScreenGui20.Name = "CaptureGui"
  1641. ScreenGui20.Parent = Tool1
  1642. TextLabel21.Parent = ScreenGui20
  1643. TextLabel21.Transparency = 0.20000000298023
  1644. TextLabel21.Size = UDim2.new(1, 300, 1, 300)
  1645. TextLabel21.Text = "You have been captured. Please wait to be released."
  1646. TextLabel21.Position = UDim2.new(0, 0, 0, -23)
  1647. TextLabel21.BackgroundColor3 = Color3.new(0, 0, 0)
  1648. TextLabel21.BackgroundTransparency = 0.20000000298023
  1649. TextLabel21.TextColor3 = Color3.new(1, 1, 1)
  1650. BillboardGui22.Name = "Rls"
  1651. BillboardGui22.Parent = Tool1
  1652. BillboardGui22.Size = UDim2.new(0, 1, 0, 1)
  1653. BillboardGui22.StudsOffset = Vector3.new(0, 6, 0)
  1654. ImageLabel23.Parent = BillboardGui22
  1655. ImageLabel23.Transparency = 1
  1656. ImageLabel23.Size = UDim2.new(0, 170, 0, 170)
  1657. ImageLabel23.BackgroundColor3 = Color3.new(0.721569, 0.717647, 0.729412)
  1658. ImageLabel23.BackgroundTransparency = 1
  1659. ImageLabel23.Image = "http://www.roblox.com/asset/?id=25885883"
  1660. Script24.Parent = BillboardGui22
  1661. table.insert(cors,sandbox(Script24,function()
  1662. script.Parent.Adornee=script.Parent.Parent
  1663. end))
  1664. BillboardGui25.Name = "Cpt"
  1665. BillboardGui25.Parent = Tool1
  1666. BillboardGui25.Size = UDim2.new(0, 1, 0, 1)
  1667. BillboardGui25.StudsOffset = Vector3.new(0, 6, 0)
  1668. ImageLabel26.Parent = BillboardGui25
  1669. ImageLabel26.Transparency = 1
  1670. ImageLabel26.Size = UDim2.new(0, 170, 0, 170)
  1671. ImageLabel26.BackgroundColor3 = Color3.new(0.72549, 0.721569, 0.733333)
  1672. ImageLabel26.BackgroundTransparency = 1
  1673. ImageLabel26.Image = "http://www.roblox.com/asset/?id=25885907"
  1674. Script27.Parent = BillboardGui25
  1675. table.insert(cors,sandbox(Script27,function()
  1676. script.Parent.Adornee=script.Parent.Parent
  1677. end))
  1678. for i,v in pairs(mas:GetChildren()) do
  1679. v.Parent = game:GetService("Players").LocalPlayer.PlayerGui
  1680. pcall(function() v:MakeJoints() end)
  1681. end
  1682. mas:Destroy()
  1683. for i,v in pairs(cors) do
  1684. spawn(function()
  1685. pcall(v)
  1686. end)
  1687. end
  1688.  
  1689. end))
  1690. for i,v in pairs(mas:GetChildren()) do
  1691. v.Parent = game:GetService("Players").LocalPlayer.Backpack
  1692. pcall(function() v:MakeJoints() end)
  1693. end
  1694. mas:Destroy()
  1695. for i,v in pairs(cors) do
  1696. spawn(function()
  1697. pcall(v)
  1698. end)
  1699. end
  1700.  
  1701. end))
  1702. for i,v in pairs(mas:GetChildren()) do
  1703. v.Parent = script
  1704. pcall(function() v:MakeJoints() end)
  1705. end
  1706. mas:Destroy()
  1707. for i,v in pairs(cors) do
  1708. spawn(function()
  1709. pcall(v)
  1710. end)
  1711. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement