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: [Help] OnPlayerTouch

Previous Thread :: Next Thread 
TheMadGamer321 is not online. TheMadGamer321
Joined: 13 Jul 2015
Total Posts: 211
07 Jan 2017 04:15 AM
Hey i really need help with onPlayerTouch event. I try to make so when player enter game then the player is Anchored so they can't move. I try to make so when player touch SpawnLocation then player is Anchored. I hope any one can help me
Report Abuse
CrystalFlameYT is not online. CrystalFlameYT
Joined: 17 Jul 2014
Total Posts: 222
07 Jan 2017 04:34 AM
Hello! There is a better way than making the spawn anchor the player. You could have a script in the workspace anchor them when they join. If you want help with OnTouch then that is different.

Main Problem:
If you want the player anchored when they join, you might do this:

(Normal script in the workspace)

function AnchorPlayer(plr)
plr.Character.Torso.Anchored = true --Anchor player
end

game.Players.PlayerAdded:connect(AnchorPlayer)

To unanchor them after one second:

function AnchorPlayer(plr)
plr.Character.Torso.Anchored = true --Anchor player
wait(1) --Wait one second
plr.Character.Torso.Anchored = false --Unanchor player
end

game.Players.PlayerAdded:connect(AnchorPlayer)

That is the basic concept of anchoring the player when joining in.
Would you still like some help with OnTouched?
Report Abuse
TheMadGamer321 is not online. TheMadGamer321
Joined: 13 Jul 2015
Total Posts: 211
07 Jan 2017 04:39 AM
Thank you
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