Well my basic question is this: is the 2.<whatever> handled by something in the rom code or something in a library? I can't find the function that specifically deals with this….the reason I ask is I'd like to set it so just plain kill 2. will attack the second thing in the room, get 2. would get the second thing in the room, etc.
I realize there are other ways to go about it but if there's an existing function I can just modify, seems it'd be a lot easier.
int number_argument( char *argument, char *arg ) is probably the function you are looking for. It is called from things like CHAR_DATA *get_char_room( CHAR_DATA * ch, char *argument ), which would explain your example using kill 2..
creepy, the ghosts are after me. After posting this I went and just looked at the function, I didn't change anything on it and went into my mud and did kill 2.murph (name of a mob) and it laglocked the mud, taking up 25% of the cpu% (and since I'm using a host, probably not the greatest thing) so I had to kill it. Tried again with a clean make, did the same….the only two files i've edited today are fight.c and merc.h so I uploaded about a week agos backup copies of fight.c, merc.h and interp.c (just in case) and it did the same thing again…uploaded the whole backup and it works fine…so the ghosts took my thoughts and bugged my mud…IT'S TRUE.