Advertisement
tiptopfishes

Untitled

Aug 24th, 2016
97
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.97 KB | None | 0 0
  1. tool = Instance.new("Tool",game.Players.LocalPlayer.Backpack)
  2. tool.Name = "Teke"
  3. tool.RequiresHandle = false
  4. objmodel = Instance.new("ObjectValue")
  5. objmodel.Name = "OBJ"
  6. objmodel.Parent = game.Players.LocalPlayer.Character
  7. function equip()
  8. equipped = true
  9. end
  10. function unequip()
  11. equipped = false
  12. end
  13. equipped = false
  14. tool.Equipped:connect(equip)
  15. tool.Unequipped:connect(unequip)
  16. function unteke()
  17. player = game.Players.LocalPlayer
  18. mouse = player:GetMouse()
  19. target = mouse.Target
  20. object = player.Character.OBJ.Value
  21. if object ~= nil then
  22. object.Anchored = false
  23. if object:FindFirstChild("TEKECONTROL") then
  24. object.TEKECONTROL:Remove()
  25. end
  26. end
  27. player.Character.OBJ.Value = nil
  28. end
  29. tool.Unequipped:connect(unteke)
  30. function teke()
  31. player = game.Players.LocalPlayer
  32. mouse = player:GetMouse()
  33. target = mouse.Target
  34. if target ~= nil and player.Character:FindFirstChild("Torso") then
  35. notfound = true
  36. for i,v in pairs(game.Players:GetChildren()) do
  37. if v:FindFirstChild("OBJ") then
  38. if v.OBJ.Value == target then
  39. notfound = false
  40. end
  41. end
  42. end
  43. if target.Anchored == false and notfound == true then
  44. unteke()
  45. player.Character.OBJ.Value = target
  46. control = Instance.new("BodyPosition")
  47. control.Name = "TEKECONTROL"
  48. torso = player.Character.Torso
  49. tpos = target.Position
  50. control.Position = Vector3.new(tpos.X,tpos.Y + 5,tpos.Z)
  51. control.Parent = target
  52. control.MaxForce = Vector3.new(0,100000,0)
  53. control.P = 10000
  54. end
  55. end
  56. end
  57. tool.Activated:connect(teke)
  58. function keypress(inputObject,gameProcessedEvent)
  59. if not gameProcessedEvent and equipped == true then
  60. if inputObject.KeyCode == Enum.KeyCode.R then
  61. local object = player.Character.OBJ.Value
  62. if object ~= nil then
  63. if object.Anchored == false then
  64. object.Anchored = true
  65. else
  66. object.Anchored = false
  67. end
  68. end
  69. end
  70. if inputObject.KeyCode == Enum.KeyCode.T then
  71. local object = player.Character.OBJ.Value
  72. if object ~= nil then
  73. object.TEKECONTROL.Position = object.TEKECONTROL.Position + Vector3.new(0,10,0)
  74. end
  75. end
  76. if inputObject.KeyCode == Enum.KeyCode.Z then
  77. local object = player.Character.OBJ.Value
  78. if object ~= nil then
  79. velocity = Instance.new("BodyVelocity",object)
  80. velocity.Velocity = player.Character.Torso.CFrame.lookVector * 100 + Vector3.new(0,20,0)
  81. velocity.MaxForce = Vector3.new(1000000,1000000,1000000)
  82. game:GetService("Debris"):AddItem(velocity,0.1)
  83. end
  84. if object.Parent:FindFirstChild("Humanoid") then
  85. object.Parent.Humanoid.Sit = true
  86. end
  87. object.TEKECONTROL:Remove()
  88. player.OBJ.Character.Value = nil
  89. end
  90. if inputObject.KeyCode == Enum.KeyCode.X then
  91. local object = player.Character.OBJ.Value
  92. if object ~= nil then
  93. velocity = Instance.new("BodyVelocity",object)
  94. velocity.Velocity = player.Character.Torso.CFrame.lookVector * 300 + Vector3.new(0,20,0)
  95. velocity.MaxForce = Vector3.new(1000000,1000000,1000000)
  96. game:GetService("Debris"):AddItem(velocity,0.1)
  97. end
  98. if object.Parent:FindFirstChild("Humanoid") then
  99. object.Parent.Humanoid.Sit = true
  100. end
  101. object.TEKECONTROL:Remove()
  102. player.Character.OBJ.Value = nil
  103. end
  104. if inputObject.KeyCode == Enum.KeyCode.B then
  105. local object = player.Character.OBJ.Value
  106. print("pls")
  107. if object ~= nil then
  108. print("its something ;-;")
  109. object.TEKECONTROL.Position = (player.Character.Torso.CFrame * CFrame.new(0,0,-10)).p
  110. object.TEKECONTROL.MaxForce = Vector3.new(1000000,1000000,1000000)
  111. end
  112. end
  113. if inputObject.KeyCode == Enum.KeyCode.K then
  114. local object = player.Character.OBJ.Value
  115. if object ~= nil then
  116. clone = object:clone()
  117. clone.CanCollide = true
  118. object:Remove()
  119. clone.CFrame = object.CFrame
  120. clone.Parent = game.Workspace
  121. player.Character.OBJ.Value = clone
  122. object.TEKECONTROL.Parent = clone
  123. end
  124. end
  125. end
  126. end
  127. game:GetService("UserInputService").InputBegan:connect(keypress)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement