npcs.xml file format

This file describe npcs.

Example file:

npcs.xml
<?xml version="1.0"?>
<npcs>
  <npc id="100" sortOffsetY="30">
    <sprite variant="0">npcs/xml/interactive.xml</sprite>
  </npc>
  <npc id="101" avatar="1" hoverCursor="talk" targetOffsetX="10" nameOffsetX="10">
    <sprite variant="0">npcs/xml/unanimated.xml</sprite>
  </npc>
  <npc id="904" targetSelection="false">
    <sprite>npcs/xml/hammock-animated1.xml</sprite>
    <menu name="Talk" command="talk 'NAME'"/>
  </npc>
</npcs>

Each npc tag describe separate npc, inside tag describe npc sprite.

Npc tag attributes:

Parameter Description default value Comment
idnpc id0
avatarnpc avatar0
targetCursorselection cursor sizemediumpossible values: small, medium, large
targetSelectionis npc can be selectedtrue
hoverCursorcursor over npctalkpossible values see here
targetOffsetXselection cursor offset by x0
targetOffsetYselection cursor offset by y0
nameOffsetXnpc name offset by x0
nameOffsetYnpc name offset by y0
sortOffsetYnpc drawing order offset by y0

Menu tag describe npc context menu.

If menu tags misisng, used this tags:

npcs.xml
  <menu name="Talk" command="talk 'NAME'"/>
  <menu name="Buy" command="buy 'NAME'"/>
  <menu name="Sell" command="sell 'NAME'"/>

See also: being cursor types

Print/export
Languages