This only happens rarely, but still annoying to see error in console :[
Here is the script:
- script ROTD -,{
end;
OnClock0000:
OnInit:
setarray .ROTD$[0], "Formless", "Undead", "Brute", "Plant", "Insect", "Fish", "Demon", "Demi-Human", "Angel", "Dragon";
set .Race, rand(9);
set .BonusEXP, rand(15,30);
set .ExpLvlRange, 10;
announce "Players will get " + .BonusEXP + "% bonus EXP from hunting " + .ROTD$[.Race] + " monsters today!",0;
end;
OnNPCKillEvent:
if (getmonsterinfo(killedrid,19) != .Race) end;
if (getcharid(1)) {
set .@Location$, strcharinfo(3);
set .BaseLvl, BaseLevel;
getpartymember getcharid(1),1;
getpartymember getcharid(1),2;
for (set .@a, 0; .@a < .partymembercount; set .@a, .@a + 1)
if (isloggedin(.partymemberaid[.@a]))
attachrid (.partymemberaid[.@a]);
if (strcharinfo(3) == .Location$ && ( .BaseLevel - BaseLevel) <= .ExpLvlRange)
getexp (getmonsterinfo(killedrid,3) * .BonusEXP / 100), (getmonsterinfo(killedrid,4) * .BonusEXP/100);
} else {
getexp (getmonsterinfo(killedrid,3) * .BonusEXP / 100), (getmonsterinfo(killedrid,4) * .BonusEXP/100);
}
end;
OnPCLoginEvent:
dispbottom "Players will get " + .BonusEXP + "% bonus EXP from hunting " + $mobrace$ + " monsters today!";
end;
}
Error output:
[Warning]: script:op_2num: overflow detected op=C_MUL i1=625000000 i2=26
[Debug]: Source (NPC): ROTD (invisible/not on a map)