Page 1 of 1

NPC move

Posted: Tue Jan 25, 2011 3:24 pm
by igoooor
If you want to receive support we need this info to help you properly.
ยป Find Revision
L2J Revision 4486:
L2JDP Revision 7756:

Hello all, I have some question about NPC moves.
I would like that my npc (monster), don't move until I attack him.
I can do this : can_move = 1, walkspd = 1, runspd = 180 for exemple
(For what I understood, walkspd is when is not under attack, and runspd when attacked)
With that configuration, when npc is not attacked, I see them legs move (like when he's walking) but he don't really move.
I would like to have the npc legs don't moving. Is there any way to do this ?
If I put can_move = 0, then when I attack him, he don't move, and if i put walkspd = 0, my client crash when i see the npc.

And the last thing : is there any way to define the move range from the spawn point ?

Re: NPC move

Posted: Wed Jan 26, 2011 12:09 pm
by igoooor
Nobody have an answer ? Really ?
My question is so weird ?^^

Re: NPC move

Posted: Wed Jan 26, 2011 12:22 pm
by Nik
# Maximum distance mobs can randomly go from spawn point.
# DEFAULT NEEDS TO BE VERIFIED, MUST BE CHANGED HERE AND IN CONFIG.JAVA IF NOT CORRECT
# Default: 300
MaxDriftRange = 300

set this to 0

Re: NPC move

Posted: Wed Jan 26, 2011 12:59 pm
by igoooor
Ok thanks =) So there is no way to define this point for a specific mob right ?

Re: NPC move

Posted: Wed Jan 26, 2011 1:23 pm
by Nik
use a script for individual NPCs, set this
npc.setIsNoRndWalk(true);