hedgewars/uGearsUtils.pas
changeset 11852 38e7206a5df4
parent 11827 4600dcb9db4f
child 11853 6a0d6b00dac8
equal deleted inserted replaced
11851:6bf91006d630 11852:38e7206a5df4
    55 function  GetAmmo(Hedgehog: PHedgehog): TAmmoType;
    55 function  GetAmmo(Hedgehog: PHedgehog): TAmmoType;
    56 function  GetUtility(Hedgehog: PHedgehog): TAmmoType;
    56 function  GetUtility(Hedgehog: PHedgehog): TAmmoType;
    57 
    57 
    58 function WorldWrap(var Gear: PGear): boolean;
    58 function WorldWrap(var Gear: PGear): boolean;
    59 
    59 
       
    60 function IsHogLocal(HH: PHedgehog): boolean;
    60 
    61 
    61 
    62 
    62 function MakeHedgehogsStep(Gear: PGear) : boolean;
    63 function MakeHedgehogsStep(Gear: PGear) : boolean;
    63 
    64 
    64 var doStepHandlers: array[TGearType] of TGearStepProcedure;
    65 var doStepHandlers: array[TGearType] of TGearStepProcedure;
  1587             State:= ord(sprBoing)
  1588             State:= ord(sprBoing)
  1588             end;
  1589             end;
  1589     PlaySound(sndMelonImpact, true)
  1590     PlaySound(sndMelonImpact, true)
  1590 end;
  1591 end;
  1591 
  1592 
       
  1593 function IsHogLocal(HH: PHedgehog): boolean;
       
  1594 begin
       
  1595     IsHogLocal:= (not (HH^.Team^.ExtDriven or (HH^.BotLevel > 0))) or (HH^.Team^.Clan^.ClanIndex = LocalClan);
       
  1596 end;
       
  1597 
  1592 end.
  1598 end.