ID:168650
![]() Sep 13 2005, 6:34 am
|
|
Hey.How do i let an NPC walk random
|
![]() Sep 13 2005, 7:04 am
|
|
Call an AI (Artificial Intelligence) proc in New(). The actual proc to make the mob move is called step_rand(). You should look up all the step() procs and walk() procs too by the way.
|
DeathAwaitsU wrote:
Call an AI (Artificial Intelligence) proc in New(). The actual proc to make the mob move is called step_rand(). You should look up all the step() procs and walk() procs too by the way. I tried evry way i know but it dosent work. Wolf icon='wolf.dmi' icon_state="brown" What do i need to add it to it |
Halovader wrote:
DeathAwaitsU wrote: You, should use <*dm> and <*/dm> tags (without the *'s). But, anyways heres an example how to put it in. mob/Wolf |
You forgot to indent after that spawn. =)
Plus, instead of calling the procedure again I'd say it'd be better form to use a while loop, like so: mob/Wolf |
I would suggest you use the example from lummox jrs green tutor tutorial.Its has some problems (grammatical) but nothing a few tests shouldnt fix.
Try to be sure to learn it as its a real good method compared to some other games Ive seen. (overview) It makes the movable walk around randomly but only when a player is in the said area.meaning that you get less overhead (much less). (bugs) I had to edit the code a bit for it to actually work,nothing a little determination couldnt fix. (The other areas dont wake up. and some others but I'll leave them to you to find.) Itanium |