Bot skill bug. -
12-12-2005
Small bug in HPB_bot which causes bot skill increase by one level on every mapchange until it's highest (skill 1).
In bot.cpp:BotCreate:
pBot->bot_skill = skill - 1; // 0 based for array indexes
Then in dll.cpp on mapchange:
char c_skill[2];
sprintf(c_skill, "%d", bots[index].bot_skill);
BotCreate(NULL, ... , ... , c_skill, ... , ...);
Ofcourse 'bots[index].bot_skill' should be 'bots[index].bot_skill + 1' instead. Quite well hidden bug, found it when were adding [lvl%d] tags.
|