You almost have it there Loriel, but not quite.
Since mapnotes are the last entry in any .are file, you don't have to worry about updating any other offsets (including the automap offset).
Here's some updated code that works:
COPY_EXISTING ~ar0700.are~ ~override/ar0700.are~
READ_LONG "0xc4" "automapoffset" // Read in the automap offset
READ_LONG "0xc8" "#automap" // Read in the # of automaps
INSERT_BYTES "%automapoffset%" 0x34 // Insert our bytes for the automap entry at the automap offset
WRITE_SHORT "%automapoffset%" 1000 // X co-ordinate
WRITE_SHORT ("%automapoffset%" + 0x2) 1000 // Y co-ordinate
SAY ("%automapoffset%" + 0x4) ~This is the automap text.~ // Automap text
WRITE_BYTE ("%automapoffset%" + 0x8) 1 // This is 1 for every automap
WRITE_SHORT ("%automapoffset%" + 0xa) 2 // Automap icon colour
WRITE_LONG 0xc8 ("%#automap%" + 1) // Update the # of automap entries
Adding in say, an actor is a little more complex since you have to update any offset that occurs *after* the actor offset.
So, if you were to add one actor using WeiDU, you would have to update the following offsets by 272 bytes (the length of an actor entry):[ul][li]Info/Travel/Proximity Trigger[/li][li]Spawn Points[/li][li]Entrances[/li][li]Containers[/li][li]Items[/li][li]Ambients[/li][li]Variables[/li][li]Doors[/li][li]Tiled Objects[/li][li]Vertices[/li][li]Animations[/li][li]Explored Bitmap[/li][li]Songs[/li][li]Rest Spawn[/li][li]Automap[/li][/ul]That's the order that they occur in the file as well. So, for example, if you were to add an animation, then you would only have to update the following offsets (since anything occuring before the animation will be pointing to the correct spot):[ul][li]Explored Bitmap[/li][li]Songs[/li][li]Rest Spawn[/li][li]Automap[/li][/ul]And... that's about it really.
japh