• Making NPC move to x y z
    7 replies, posted
first I have an entity spawned with something like [lua] g = ents.Create("npc_zombie") g:SetPos(v:GetPos()) g:Activate() g:Spawn() [/lua] but then how would I make g (the npc) walk to x y z?
[lua]g:SetPos(Vector(x, y, z))[/lua]
I think he means making it walk to x y z.
yeah, walk to it
[lua] g:SetLastPosition( vector( 0, 0, 0 ) ); g:SetSchedule( SCHED_FORCED_GO ); [/lua] There you go. :)
thanks! [editline]11:13AM[/editline] is it possible to have like a crate floating in air, and then have it hover to a point?
where do you add [LUA] # g = ents.Create("npc_zombie") # g:SetPos( Vector(-6987.968750, -4647.343750, 136.031250)) # g:Activate() # g:Spawn() [/LUA] to and would the setpos work? [editline]02:02AM[/editline] -Bump- Help please?
what? the zombie making is just triggered from my gamemode
Sorry, you need to Log In to post a reply to this thread.