hedgewars/GSHandlers.inc
changeset 6314 b4fc5b863f5f
parent 6305 5f7480c2a08d
child 6325 cdd3d8c723ec
equal deleted inserted replaced
6313:12567f6f6f02 6314:b4fc5b863f5f
  1283             begin
  1283             begin
  1284             DrawExplosion(i, y + 3, 3);
  1284             DrawExplosion(i, y + 3, 3);
  1285             inc(i, 1)
  1285             inc(i, 1)
  1286             end;
  1286             end;
  1287 
  1287 
  1288         if CheckLandValue(hwRound(Gear^.X + Gear^.dX + SignAs(_6,Gear^.dX)), hwRound(Gear^.Y + _1_9)
  1288         if CheckLandValue(hwRound(Gear^.X + Gear^.dX + SignAs(_6,Gear^.dX)), hwRound(Gear^.Y + _1_9), lfIndestructible) then
  1289            , lfIndestructible) then
       
  1290             begin
  1289             begin
  1291             Gear^.X := Gear^.X + Gear^.dX;
  1290             Gear^.X := Gear^.X + Gear^.dX;
  1292             Gear^.Y := Gear^.Y + _1_9;
  1291             Gear^.Y := Gear^.Y + _1_9;
  1293             end;
  1292             end;
  1294         SetAllHHToActive;
  1293         SetAllHHToActive;
  1299         SetLittle(HHGear^.dX);
  1298         SetLittle(HHGear^.dX);
  1300         HHGear^.dY := _0;
  1299         HHGear^.dY := _0;
  1301         end
  1300         end
  1302     else
  1301     else
  1303         begin
  1302         begin
  1304         Gear^.dY := Gear^.dY + cGravity;
  1303         if CheckLandValue(hwRound(Gear^.X), hwRound(Gear^.Y + Gear^.dY + cGravity), lfIndestructible) then
  1305         Gear^.Y := Gear^.Y + Gear^.dY;
  1304             begin
       
  1305             Gear^.dY := Gear^.dY + cGravity;
       
  1306             Gear^.Y := Gear^.Y + Gear^.dY
       
  1307             end;
  1306         if hwRound(Gear^.Y) > cWaterLine then Gear^.Timer := 1
  1308         if hwRound(Gear^.Y) > cWaterLine then Gear^.Timer := 1
  1307         end;
  1309         end;
  1308 
  1310 
  1309     Gear^.X := Gear^.X + HHGear^.dX;
  1311     Gear^.X := Gear^.X + HHGear^.dX;
  1310     HHGear^.X := Gear^.X;
  1312     if CheckLandValue(hwRound(Gear^.X), hwRound(Gear^.Y)-cHHRadius, lfIndestructible) then
  1311     HHGear^.Y := Gear^.Y - int2hwFloat(cHHRadius);
  1313         begin
       
  1314         HHGear^.X := Gear^.X;
       
  1315         HHGear^.Y := Gear^.Y - int2hwFloat(cHHRadius)
       
  1316         end;
  1312 
  1317 
  1313     if (Gear^.Message and gmAttack) <> 0 then
  1318     if (Gear^.Message and gmAttack) <> 0 then
  1314         if (Gear^.State and gsttmpFlag) <> 0 then Gear^.Timer := 1
  1319         if (Gear^.State and gsttmpFlag) <> 0 then Gear^.Timer := 1
  1315     else
  1320     else
  1316     else
  1321     else