hedgewars/CCHandlers.inc
changeset 4365 4f2b1a152979
parent 4241 835fd7a0e1bf
child 4389 d1c65b60cd68
equal deleted inserted replaced
4363:e944cc43f7a4 4365:4f2b1a152979
   158     val(id, CurrentHedgehog^.BotLevel);
   158     val(id, CurrentHedgehog^.BotLevel);
   159     Gear:= AddGear(0, 0, gtHedgehog, 0, _0, _0, 0);
   159     Gear:= AddGear(0, 0, gtHedgehog, 0, _0, _0, 0);
   160     SplitBySpace(s, id);
   160     SplitBySpace(s, id);
   161     val(s, Gear^.Health);
   161     val(s, Gear^.Health);
   162     TryDo(Gear^.Health > 0, 'Invalid hedgehog health', true);
   162     TryDo(Gear^.Health > 0, 'Invalid hedgehog health', true);
   163     PHedgehog(Gear^.Hedgehog)^.Team:= CurrentTeam;
   163     Gear^.Hedgehog^.Team:= CurrentTeam;
   164     if (GameFlags and gfSharedAmmo) <> 0 then CurrentHedgehog^.AmmoStore:= Clan^.ClanIndex
   164     if (GameFlags and gfSharedAmmo) <> 0 then CurrentHedgehog^.AmmoStore:= Clan^.ClanIndex
   165     else if (GameFlags and gfPerHogAmmo) <> 0 then
   165     else if (GameFlags and gfPerHogAmmo) <> 0 then
   166         begin
   166         begin
   167         AddAmmoStore;
   167         AddAmmoStore;
   168         CurrentHedgehog^.AmmoStore:= StoreCnt - 1
   168         CurrentHedgehog^.AmmoStore:= StoreCnt - 1