Yeah, I don't get MUD functions at all, and asking the wiki just gives me a bunch of old advertisements for Kingdoms. (THANKS! -_-)
Basically, that system NPC I inherited does
PHP Code:
if (clientr.equipped_id != NULL) unequipItem(temp.pl);
temp.item = temp.pl.getItem(temp.id);
if (temp.item[3] == "ammo") {
return;
}
temp.pl.equip(temp.id);
temp.pl.triggerclient("gui", this.name, "equip");
Then seems to expect the equip command to cause
PHP Code:
clientr.equipped[3] == "gun"
setshootparams(clientr.equipped[5]);
etc; it's easy enough to
PHP Code:
temp.tyid=clientr.equipped_id + 0;
temp.tokens = clientr.(@"item_"@tyid).tokenize();
instead, but I don't understand player.equip(float) enough to trust a workaround - should I just be saying, right after player.equip, to tokenize and assign
PHP Code:
clientr.equipped[5]=temp.tokens[5]
? (or even tidier),perhaps
PHP Code:
clientr.equipped=clientr.(@"item_"@tyid).tokenize();
?)