# HG changeset patch # User unc0rr # Date 1155764127 0 # Node ID ca5f06017e993de06a2842423328de37d48dab37 # Parent 30ca06092a6418f8374cd80081620520c105ce27 Fix use of slot 8 and avoid such bug in future diff -r 30ca06092a64 -r ca5f06017e99 hedgewars/uConsts.pas --- a/hedgewars/uConsts.pas Wed Aug 16 11:41:00 2006 +0000 +++ b/hedgewars/uConsts.pas Wed Aug 16 21:35:27 2006 +0000 @@ -270,7 +270,7 @@ Ammoz: array [TAmmoType] of record NameId: TAmmoStrId; Ammo: TAmmo; - Slot: Longword; + Slot: 0..cMaxSlotIndex; TimeAfterTurn: Longword; end = ( (NameId: sidGrenade; diff -r 30ca06092a64 -r ca5f06017e99 hedgewars/uIO.pas --- a/hedgewars/uIO.pas Wed Aug 16 11:41:00 2006 +0000 +++ b/hedgewars/uIO.pas Wed Aug 16 21:35:27 2006 +0000 @@ -204,7 +204,7 @@ CursorPoint.Y:= extcmd[cmdcurpos].Y + WorldDy; end; '1'..'5': ParseCommand('timer ' + extcmd[cmdcurpos].cmd); - #128..#134: ParseCommand('slot ' + char(byte(extcmd[cmdcurpos].cmd) - 79)) + #128..char(128 + cMaxSlotIndex): ParseCommand('slot ' + char(byte(extcmd[cmdcurpos].cmd) - 79)) end; inc(cmdcurpos) end;