Code: Select all
public int unitFinished(Unit unit)
{
if(unit.getDef().isBuilder()&&unit.getDef().getBuildDistance()>128){
AIFloat3 location = unit.getPos();
location.x+=50;
unit.fight(location,(short)1, INTEGER.MAX_VALUE);//I've tried 0, -1 and MAX_VALUE, both of which didn't work
}
return 0;
}