--- a/hedgewars/uGearsList.pas Tue Jun 12 17:20:27 2012 +0400
+++ b/hedgewars/uGearsList.pas Sun Jun 24 20:31:26 2012 +0400
@@ -100,15 +100,14 @@
gear^.Density:= _1;
// Define ammo association, if any.
gear^.AmmoType:= GearKindAmmoTypeMap[Kind];
+gear^.CollisionMask:= $FFFF;
+
+if CurrentHedgehog <> nil then gear^.Hedgehog:= CurrentHedgehog;
+
if Ammoz[Gear^.AmmoType].Ammo.Propz and ammoprop_NeedTarget <> 0 then
gear^.Z:= cHHZ+1
else gear^.Z:= cUsualZ;
-if CurrentHedgehog <> nil then
- begin
- gear^.Hedgehog:= CurrentHedgehog;
- gear^.IntersectGear:= CurrentHedgehog^.Gear
- end;
case Kind of
gtGrenade,
@@ -247,7 +246,7 @@
gear^.nImpactSounds:= 1;
gear^.Radius:= 16;
gear^.Elasticity:= _0_3;
- gear^.Timer:= 0
+ gear^.Timer:= 500
end;
gtExplosives: begin
gear^.ImpactSound:= sndGrenadeImpact;
@@ -483,9 +482,9 @@
// make sure that portals have their link removed before deletion
if (Gear^.Kind = gtPortal) then
begin
- if (Gear^.IntersectGear <> nil) then
- if (Gear^.IntersectGear^.IntersectGear = Gear) then
- Gear^.IntersectGear^.IntersectGear:= nil;
+ if (Gear^.LinkedGear <> nil) then
+ if (Gear^.LinkedGear^.LinkedGear = Gear) then
+ Gear^.LinkedGear^.LinkedGear:= nil;
end
else if Gear^.Kind = gtHedgehog then
(*