Fixed drop out of flyers or ships.

This commit is contained in:
johns 2001-02-23 00:52:05 +00:00
parent e8888e2969
commit 330f770f0e

View file

@ -1199,6 +1199,11 @@ global void DropOutOnSide(Unit* unit,int heading,int addx,int addy)
for( ;; ) {
startw:
for( i=addy; i--; y++ ) {
#ifdef NEW_SHIPS
if( unit->Type->UnitType!=UnitTypeLand && ((x&1) || (y&1)) ) {
continue;
}
#endif
if( CheckedCanMoveToMask(x,y,mask) ) {
goto found;
}
@ -1206,6 +1211,11 @@ startw:
++addx;
starts:
for( i=addx; i--; x++ ) {
#ifdef NEW_SHIPS
if( unit->Type->UnitType!=UnitTypeLand && ((x&1) || (y&1)) ) {
continue;
}
#endif
if( CheckedCanMoveToMask(x,y,mask) ) {
goto found;
}
@ -1213,6 +1223,11 @@ starts:
++addy;
starte:
for( i=addy; i--; y-- ) {
#ifdef NEW_SHIPS
if( unit->Type->UnitType!=UnitTypeLand && ((x&1) || (y&1)) ) {
continue;
}
#endif
if( CheckedCanMoveToMask(x,y,mask) ) {
goto found;
}
@ -1220,6 +1235,11 @@ starte:
++addx;
startn:
for( i=addx; i--; x-- ) {
#ifdef NEW_SHIPS
if( unit->Type->UnitType!=UnitTypeLand && ((x&1) || (y&1)) ) {
continue;
}
#endif
if( CheckedCanMoveToMask(x,y,mask) ) {
goto found;
}