diff -r 2378ada8a6ee -r a44406f4369b hedgewars/PascalExports.pas --- a/hedgewars/PascalExports.pas Tue Jul 20 23:30:54 2010 +0200 +++ b/hedgewars/PascalExports.pas Thu Jul 22 03:08:17 2010 +0200 @@ -191,7 +191,10 @@ function HW_isWeaponRequiringClick: boolean; cdecl; export; begin - exit( (CurrentHedgehog^.Gear^.State and gstHHChooseTarget) <> 0 ) + if (CurrentHedgehog <> nil) and (CurrentHedgehog^.Gear <> nil) then + exit( (CurrentHedgehog^.Gear^.State and gstHHChooseTarget) <> 0 ) + else + exit(false); end; function HW_isWeaponTimerable: boolean; cdecl; export;