hedgewars/GSHandlers.inc
changeset 409 4f1841929ccc
parent 408 6c3da4907d00
child 415 d6d3a6a473a3
equal deleted inserted replaced
408:6c3da4907d00 409:4f1841929ccc
  1057    exit
  1057    exit
  1058    end;
  1058    end;
  1059 if (GameTicks and $3F) = 0 then
  1059 if (GameTicks and $3F) = 0 then
  1060    AddGear(hwRound(Gear^.X), hwRound(Gear^.Y), gtSmokeTrace, 0, 0, 0, 0)
  1060    AddGear(hwRound(Gear^.X), hwRound(Gear^.Y), gtSmokeTrace, 0, 0, 0, 0)
  1061 end;
  1061 end;
       
  1062 
       
  1063 ////////////////////////////////////////////////////////////////////////////////
       
  1064 
       
  1065 procedure doStepGirder(Gear: PGear);
       
  1066 begin
       
  1067 AllInactive:= false;
       
  1068 writelntoconsole(inttostr(TargetPoint.X));
       
  1069 if not TryPlaceOnLand(TargetPoint.X - SpritesData[sprAmGirder].Width div 2,
       
  1070                       TargetPoint.Y - SpritesData[sprAmGirder].Height div 2,
       
  1071                       sprAmGirder, Gear^.State) then
       
  1072    with PHedgehog(Gear^.Hedgehog)^.Gear^ do
       
  1073         begin
       
  1074         State:= State and not gstAttacking;
       
  1075         Message:= Message and not gm_Attack;
       
  1076         isCursorVisible:= true;
       
  1077         with PHedgehog(Gear^.Hedgehog)^ do
       
  1078              State:= State or gstHHChooseTarget
       
  1079         end
       
  1080    else AfterAttack;
       
  1081 TargetPoint.X:= NoPointX;
       
  1082 DeleteGear(Gear)
       
  1083 end;