Here's the code for $zone (with my modification in bold). Doing $zone(bonus) just makes MQ print @zone(bonus), through the else branch.
Code: Select all
// $zone(xxx)
} else if (!strncmp("zone(",szVar,5)) {
// $zone()
if (!strncmp("zone()",szVar,6)) {
i+=5;
strcat(szOutput,GetFullZone(pChar->Zone));
j+=strlen(GetFullZone(pChar->Zone));
// $zone(bound)
} else if (!strncmp("zone(bound)",szVar,13)) {
i+=12;
strcat(szOutput,GetFullZone(pCharInfo->ZoneBoundId));
j+=strlen(GetFullZone(pCharInfo->ZoneBoundId));
// $zone(birth)
} else if (!strncmp("zone(birth)",szVar,13)) {
i+=12;
strcat(szOutput,GetFullZone(pCharInfo->ZoneBirthId));
j+=strlen(GetFullZone(pCharInfo->ZoneBirthId));
[b]// $zone(bonus)
} else if (!strncmp("zone(bonus)",szVar,13)) {
i+=12;
strcat(szOutput,"TestOK");
j+=strlen("TestOK");[/b]
// $zone(Unknown)
} else {
DebugSpew("PMP - Bad $zone() '%s'",szVar);
i--;
szOutput[j] = '@';
j++;
}
// $zone
} else if (!strncmp("zone",szVar,4)) {
i+=3;
strcat(szOutput,GetFullZone(pChar->Zone));
j+=strlen(GetFullZone(pChar->Zone));
Code: Select all
PMP - Bad $zone() 'zone(bonus)'
Echo - [MacroQuest] @zone(bonus)
CChatHook::Detour([MacroQuest] @zone(bonus))