generic image
Processing...
  • Games
  • Catalog
  • Develop
  • Robux
  • Search in Players
  • Search in Games
  • Search in Catalog
  • Search in Groups
  • Search in Library
  • Log In
  • Sign Up
  • Games
  • Catalog
  • Develop
  • Robux
   
ROBLOX Forum » Game Creation and Development » Scripters
Home Search
 

Re: Works in Studio but not in game

Previous Thread :: Next Thread 
Holtbyism is not online. Holtbyism
Joined: 01 Feb 2013
Total Posts: 2621
01 Jul 2016 11:17 AM

local force = 1
script.Parent.Parent.Equipped:connect(function(mouse)
mouse.KeyDown:connect(function(key)
if key=="r" then
force=300
end

print(force)
end)
end)
script.Parent.Touched:connect(function(part)
if part.Name == "Puck" then
local bp=Instance.new("BodyPosition")
bp.maxForce=Vector3.new(force,0,force)
bp.Parent=part
bp.position=part.Position+script.Parent.Parent.Parent.Torso.CFrame.lookVector*10000000
wait(1)
force = 0
bp:remove()
end
end)

What do I need to do? It's not giving me any output errors either on the RemoteError GUI that I have in game.
Report Abuse
Soybeen is not online. Soybeen
Joined: 17 Feb 2010
Total Posts: 21462
01 Jul 2016 11:22 AM
Local or server script?


Report Abuse
Holtbyism is not online. Holtbyism
Joined: 01 Feb 2013
Total Posts: 2621
01 Jul 2016 11:30 AM
Server
Report Abuse
Soybeen is not online. Soybeen
Joined: 17 Feb 2010
Total Posts: 21462
01 Jul 2016 11:31 AM
needs to be local to get the player's mouse


Report Abuse
Holtbyism is not online. Holtbyism
Joined: 01 Feb 2013
Total Posts: 2621
01 Jul 2016 11:59 AM
thxs
Report Abuse
Previous Thread :: Next Thread 
Page 1 of 1
 
 
ROBLOX Forum » Game Creation and Development » Scripters
   
 
   
  • About Us
  • Jobs
  • Blog
  • Parents
  • Help
  • Terms
  • Privacy

©2017 Roblox Corporation. Roblox, the Roblox logo, Robux, Bloxy, and Powering Imagination are among our registered and unregistered trademarks in the U.S. and other countries.



Progress
Starting Roblox...
Connecting to Players...
R R

Roblox is now loading. Get ready to play!

R R

You're moments away from getting into the game!

Click here for help

Check Remember my choice and click Launch Application in the dialog box above to join games faster in the future!

Gameplay sponsored by:
Loading 0% - Starting game...
Get more with Builders Club! Join Builders Club
Choose Your Avatar
I have an account
generic image