Figured out how to make an NPC follow you, persistently (even if you save or change maps).
[video=youtube;5VAs68XQKUg]
I'll post more about it once I figure out a little bit more. It's pretty simple when it comes to scripting...
Might as well explain how (now that I have a better understanding)
Relevant portion Hugh's script @ 854:
Note: Bianca does it too in reversal mountain @ 1078, and the Humilau Meinfoo @ 940. Bianca can detach at 1072_#176d. Hugh also can do it for the Sewers, but I didn't bother checking.
Script that is called with the CallStd-> 1275:
So for the parameters of the CallStd (the 0x250 routine):
Haven't bothered looking at the detachment. Couldn't get the game to not double battle everything wild, so it's stuck requiring a trainer# to battle with. The whole command would have to be edited/tinkered with to prevent doing so for a HGSS style follow me (such that param4=FFFF -> don't force).
Example script:
50 02 Command
01 00 overworld NPC to attach
02 00 ???
01 00 Persistent Flag (yes)
01 00 Trainer to enter a double battle with
2C 29 Script to call when interacted with
2E 02 FE 00 Pretty sure this sets the NPC Overworld ID to 254
whenever the map is changed (does the adding?)
Non-commented:
50 02 01 00 02 00 01 00 01 00 2C 29 2E 02 FE 00