Something I've wanted to do for a long time is duplicate existing NPCs and create new NPCs, but I have not been able to successfully do so. I'm sure that with a little work and clever searching it would be possible.
Some Facts And Info
-> Each NPC has a unique SID
-> NPCs are loaded in the gameserver on startup. Once you make a change to the NPC resource table, you have to restart the gameserver for it to take effect.
-> Copy/paste rows with different (and unused) SID/X-Y positions do not show up in the game.
Column Information and Schema
Arcadia.dbo.NPCResource
-> id, int. contains unique npc SID
-> text_id, int. contains the string id used to load conversation text
-> name_text_id, int. contains the string id used to load npc name and title
-> race_id, int. contains race id (asura, deva, gaia)
-> sexual_id, int. npc gender
-> x, int. position
-> y, int. position
-> z, int. position
-> face, int. loads facial texture
-> local_flag, int. unknown
-> is_periodic, bit. npc only appears in game at certain times
-> begin_of_period, datetime. time when npc first appears in-game (dependency: is_periodic=1)
-> end_of_period, datetime. time when npc disappears in-game (dependency: is_periodic=1)
-> face_x, int. unknown
-> face_y, int. unknown
-> face_z, int. unknown
-> model_file, varchar. contains npc model texture file name
-> hair_id, int. contains npc model texture file name
-> face_id, int. contains npc model texture file name
-> body_id, int. contains npc model texture file name
-> weapon_item_id, int. contains npc model texture file name
-> shield_item_id, int. contains npc model texture file name
-> clothes_item_id, int. contains npc model texture file name
-> helm_item_id, int. contains npc model texture file name
-> boots_item_id, int. contains npc model texture file name
-> belt_item_id, int. contains npc model texture file name
-> mantle_item_id, int. contains npc model texture file name
-> necklace_item_id, int. contains npc model texture file name
-> ring1_item_id, int. contains npc model texture file name
-> ring2_item_id, int. contains npc model texture file name
-> motion_id, int, unknown (speculation: contains npc movement/skill animation information)
-> is_roam, int, allows npc to roam (co-dependency: roaming_id)
-> roaming_id, int, loads roaming data (co-dependency: is_roam)
-> standard_walk_speed, int, the speed at which an npc walks (if roaming/moving)
-> standard_run_speed, int, the speed at which an npc runs (if roaming/moving)
-> walk_speed, int, the speed at which an npc walks (if roaming/moving) - duplicate reason unknown
-> run_speed, int, the speed at which an npc runs (if roaming/moving) - duplicate reason unknown
-> attackable, tinyint, if the npc is attackable by players
-> offensive_type, tinyint, unknown
-> spawn_type, int, unknown
-> chase_range, int, speculated range that an npc will follow attacking players
-> regen_time, int, speculated npc hp/mp regen
-> [level], int, npc level
-> stat_id, int, unknown
-> attack_range, int, range at which the npc will attack
-> attack_speed_type, int, speculated speed at which npc will attack
-> hp, int, max hp of npc
-> mp, int, max mp of npc
-> attack_point, int, physical attack power of npc
-> magic_point, int, magic attack power of npc
-> defense, int, physical defense power of npc
-> magic_defense, int, magical defense power of npc
-> attack_speed, int, physical attack speed of npc
-> magic_speed, int, cast speed of npc
-> accuracy, int, physical accuracy of npc
-> avoid, int, physical evasion of npc
-> magic_accuracy, int, magical accuracy of npc
-> magic_avoid, int, magical resistance of npc
-> ai_script, varchar, unknown (all current npcs have field empty)
-> contact_script, varchar, LUA function to call on NPC open/click
-> texture_group, int, unknown
Any ideas?
Post them! Let this be a constructive and helpful think tank to figure out how to create and recreate NPCs.






