How to Move Npcs

From DSP Wiki
Revision as of 22:24, 26 July 2013 by Lautan (Talk | contribs) (= Making NPCs Movable)

Jump to: navigation, search

Whats up? This will walk you through the process of making npcs and mobs move.

Making NPCs Walkable

Making NPCs Movable

By default a npc will not be in the server update loop. This means the npc cannot move around.

First find the id of the npc you want to update. Find your npc by looking in 'sql/npc_list.sql'. Search for your npcs name and copy the id.

npc_dummies currently uses the old npc format so you'll have to transform the npc id through this function: npcid + (4096 * zoneid) + 0x1000000).

Then put that inside a new row:

INSERT INTO `npc_dummies` VALUES('your_id_here');

Migrate the table and you're done.

Examples

NPC Example

Mob Example

Pathfind Interface

Pathfind Events

OnPath

OnMobRoamAction

OnMobRoam