Attack/defense bug with merc limit

Locked
Nostradamus
Fledgling Forumer
Posts: 217
Joined: Sat Oct 22, 2005 4:05 am
Alliance: Dirty Dozen
Race: NanoTiMaster

Attack/defense bug with merc limit

You have 10k mercs with weapons and because you are over your limit 1% of them are deserting each turn. The function that desert them is placed after the function that calculates the stats, so you keep the same stats even when all of them have deserted.

I noticed this while on PPT and I belive that after 1 attack by you or on you the stats will be recalculated, still this can be exploited to hit someone big 1 time without losing troops at all.
Image
Mattwell
Forum Irregular
Posts: 320
Joined: Fri Apr 29, 2005 9:08 pm
Alliance: TSA
Race: Goauld
ID: 13702

They desert on the turn, so you could hit a bunch of times before losing any, as long as the turn hasn't gone yet.
Nostradamus
Fledgling Forumer
Posts: 217
Joined: Sat Oct 22, 2005 4:05 am
Alliance: Dirty Dozen
Race: NanoTiMaster

You don't get it.

Each attack after your losses are calculated your attack/defense is recalculated. This is a distinct php function.

Every turn how many mercs are deserting it's also calculated. This is another distinct php function.

The problem is that after you lose mercs the desertion function doesn't call the stats calculating function and you stay with the same stats and this can be exploited, but only 1 time because after an attack the stats calculating function is called and it will notice that some mercs are gone.
Image
Locked

Return to “Bugs Archive”