ok
sorry it took me so long to get back to you.
your still on the right path so don't worry
first an aside on regular expressions
the when branches you're seeing are employing regular expressions. regular expressions are a language so to speak that describes how language is constructed and are typically used to define patterns to match against strings. Regexp, as they are sometimes called, as they are implemented today and in ruby in particular arose from the perl language.
in ruby strings delimited by // are considered regular expressions, there are other ways of constructing an regexp object by putting // around some text is by far the easiest
RMXP's help manual has a section on Regexp and you can google around for a multitude of references and tutorials
Here are the basics
there are special characters and sequences in regexp that define specific behavior the "\" character is probably the most important as it is used to escape other characters to form special charters.
for example the "\A" at the beginning of the regexp above matches the beginning of a string. "^" is somewhat similar except it matches the beginning of a line otherwise know as the beginning of a string or just after a "\n" also knows as a "new line" or a "line feed". additionally the "\t" references a tab character.
in regexp things between () - parentheses are known as match groups. () are used to mark out what parts of a matched pattern you're interested in and the matched teck can be pulled out useing them. in the case above we are interested in everything flowing the tab character till the end of the string
the ".+" is what matches everything. the "." character in a regexp (unless escaped by a "\" -> "\.") matches any character at all including whitespace the "+" afterward is a modifier that matches one or more of the last pattern so ".+" means one or more of any character. "\d" matches any digit character (0-9).
the rest you can look up on your own.
OK now I'm going to describe everyplace you're going to need to modify to inject instance maps, I want you to try and identify every section on the list in the default scripts and RMX-OS including the server
- client side, when changing maps the client send a message to the server with the id they are changing to
- server side, where the client receives the change map message
- Cient side, when loading the map screen the client loads server data before displaying the map (here is where you're going to receive the real map id to replace instance ids)
- server side, where the server sends a client map data when they enter a new map
- client side, where the client physical loads the map data and creates a tilemap