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: How to move a humanoid on click

Previous Thread :: Next Thread 
iSentinels is online. iSentinels
Joined: 03 Jan 2009
Total Posts: 28706
26 Jan 2016 04:01 PM
just running a simple script for now, will add more later, but:

local man = game.Workspace.Man

local Player = game.Players.LocalPlayer
local Mouse = Player:GetMouse()
Mouse.Button1Down:connect(function()
man:MoveTo(Mouse.hit.p)
end)


This just ends up making wherever you click in the game, the humanoid teleports to where you click.

If you change the variable man to game.Workspace.Man.Humanoid, then you can't move the model at all.

Any suggestions?
Report Abuse
jumpykilldestroy is not online. jumpykilldestroy
Joined: 15 Jul 2012
Total Posts: 12319
26 Jan 2016 04:04 PM
is man a model

if it is then its teleporting because :MoveTo is also a function on models that teleports them to the location
Report Abuse
iSentinels is online. iSentinels
Joined: 03 Jan 2009
Total Posts: 28706
26 Jan 2016 04:04 PM
ye its a model
Report Abuse
iSentinels is online. iSentinels
Joined: 03 Jan 2009
Total Posts: 28706
26 Jan 2016 04:06 PM
How would I make it work then while being in a model?

Sorry I'm new to this
Report Abuse
iSentinels is online. iSentinels
Joined: 03 Jan 2009
Total Posts: 28706
26 Jan 2016 04:26 PM
bump
Report Abuse
Crimsonal is not online. Crimsonal
Joined: 23 Apr 2011
Total Posts: 1795
26 Jan 2016 04:30 PM
local man = game.Workspace.Man

local Player = game.Players.LocalPlayer
local Mouse = Player:GetMouse()
Mouse.Button1Down:connect(function()
man.Humanoid:MoveTo(Mouse.hit.p)
end)



Btw, is the Model's humanoid walkspeed set to 16?


Report Abuse
iSentinels is online. iSentinels
Joined: 03 Jan 2009
Total Posts: 28706
26 Jan 2016 04:35 PM
walkspeed is 16, no errors in output.

could it be due to the fact that his legs are for whatever reason stuck inside the baseplate?
Report Abuse
Gensoki is not online. Gensoki
Joined: 15 Feb 2014
Total Posts: 1982
26 Jan 2016 04:35 PM
WalkToPoint or sumthing


http://www.roblox.com/Schwarzesmarken-Opening-TV-Size-item?id=345656154 #code "Let's just say goodbye"
Report Abuse
Crimsonal is not online. Crimsonal
Joined: 23 Apr 2011
Total Posts: 1795
26 Jan 2016 04:37 PM
Could be a broken NPC


This one is good as it has updated animations: http://www.roblox.com/Animation-NPC-item?id=273736968


Report Abuse
iSentinels is online. iSentinels
Joined: 03 Jan 2009
Total Posts: 28706
26 Jan 2016 04:41 PM
using that, once I scaled it down to the size I needed it just broke apart
Report Abuse
Crimsonal is not online. Crimsonal
Joined: 23 Apr 2011
Total Posts: 1795
26 Jan 2016 04:42 PM
Are you using a plugin or script?


Report Abuse
iSentinels is online. iSentinels
Joined: 03 Jan 2009
Total Posts: 28706
26 Jan 2016 04:42 PM
plugin
Report Abuse
Crimsonal is not online. Crimsonal
Joined: 23 Apr 2011
Total Posts: 1795
26 Jan 2016 04:45 PM
Oh idk, I just tried it in studio and it worked


Report Abuse
iSentinels is online. iSentinels
Joined: 03 Jan 2009
Total Posts: 28706
26 Jan 2016 04:46 PM
I want them to be smaller, but once I made them small the legs seem to just stay inside of the baseplate.

If I use the plugin to make the NPC you sent me smaller, the whole model breaks apart
Report Abuse
iSentinels is online. iSentinels
Joined: 03 Jan 2009
Total Posts: 28706
26 Jan 2016 04:51 PM
meh
Report Abuse
iSentinels is online. iSentinels
Joined: 03 Jan 2009
Total Posts: 28706
26 Jan 2016 04:57 PM
I checked the WalkToPoint and the coordinates are correct, just the model itself isn't moving, only the humanoid inside it
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