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: Why Wont This Script Work?

Previous Thread :: Next Thread 
RockDownBiever is not online. RockDownBiever
Joined: 09 Oct 2011
Total Posts: 84
05 Jul 2016 06:22 PM
Here is the script,

script.Parent.Touched:connect(function(part)
local character = part.Parent
if character:findFirstChild("Humanoid") then
character.Humanoid:MoveTo(Vector3.new(-21.11, 0.5, -43.465),script.Parent)
end
end)

its suppose to make you character walk to the coordinates you put in but it wont.


|Help A Homie Out|
Report Abuse
Service_Scripting is not online. Service_Scripting
Joined: 28 Mar 2013
Total Posts: 944
05 Jul 2016 06:25 PM
are you expecting it to walk there?
or teleport there?


ohno
Report Abuse
Silicti is not online. Silicti
Joined: 07 Nov 2012
Total Posts: 8242
05 Jul 2016 06:31 PM
You basically told the Workspace to move to a position.

You used parents incorrectly, at least it appears so.
Report Abuse
RockDownBiever is not online. RockDownBiever
Joined: 09 Oct 2011
Total Posts: 84
05 Jul 2016 06:37 PM
Im expecting it to walk there


|Help A Homie Out|
Report Abuse
kangerujack is not online. kangerujack
Joined: 08 Nov 2009
Total Posts: 690
05 Jul 2016 06:39 PM
This script works
Report Abuse
Service_Scripting is not online. Service_Scripting
Joined: 28 Mar 2013
Total Posts: 944
05 Jul 2016 06:39 PM
Well, you basically are teleporting the character,

You'll have to make it much more complicated to do that.


ohno
Report Abuse
kangerujack is not online. kangerujack
Joined: 08 Nov 2009
Total Posts: 690
05 Jul 2016 06:40 PM
He isn't teleporting the character, have you never worked with AI before? He's doing it correctly. :MoveTo() on Humanoid works differently than on a model.
Report Abuse
Service_Scripting is not online. Service_Scripting
Joined: 28 Mar 2013
Total Posts: 944
05 Jul 2016 06:42 PM
Yes, but he isn't gonna get there with this script


ohno
Report Abuse
kangerujack is not online. kangerujack
Joined: 08 Nov 2009
Total Posts: 690
05 Jul 2016 06:44 PM
Assuming nothing is in his characters path, yes he will.
Report Abuse
Service_Scripting is not online. Service_Scripting
Joined: 28 Mar 2013
Total Posts: 944
05 Jul 2016 06:48 PM
*cough* Then why isn't it working.


ohno
Report Abuse
kangerujack is not online. kangerujack
Joined: 08 Nov 2009
Total Posts: 690
05 Jul 2016 06:49 PM
I tested in Roblox Studio and it works.
Report Abuse
Service_Scripting is not online. Service_Scripting
Joined: 28 Mar 2013
Total Posts: 944
05 Jul 2016 06:49 PM
But it doesn't work for him.


ohno
Report Abuse
kangerujack is not online. kangerujack
Joined: 08 Nov 2009
Total Posts: 690
05 Jul 2016 06:51 PM
It does work for him, he has an outside factor messing it up. Nothing we do to this script will fix that.
Report Abuse
RockDownBiever is not online. RockDownBiever
Joined: 09 Oct 2011
Total Posts: 84
06 Jul 2016 08:19 AM
It works now but how can i make it so that the player cant change his direction or jump?


|Help A Homie Out|
Report Abuse
Service_Scripting is not online. Service_Scripting
Joined: 28 Mar 2013
Total Posts: 944
06 Jul 2016 01:21 PM
script.Parent.Touched:connect(function(part)
local character = part.Parent
if character:findFirstChild("Humanoid") then
character.Humanoid:MoveTo(Vector3.new(-21.11, 0.5, -43.465),script.Parent)
character.Humanoid.Jump = false
end
end)

I'll try to find out the only goes one direction thing.


ohno
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