equal
deleted
inserted
replaced
1364 State := (State or gstMoving) and not gstWinner; |
1364 State := (State or gstMoving) and not gstWinner; |
1365 end; |
1365 end; |
1366 DeleteGear(Gear) |
1366 DeleteGear(Gear) |
1367 end; |
1367 end; |
1368 |
1368 |
1369 (*procedure WaitCollision; |
1369 procedure WaitCollision; |
1370 begin |
1370 begin |
1371 with HHGear^ do |
1371 with HHGear^ do |
1372 begin |
1372 begin |
1373 Message := Message and not gmAttack; |
1373 Message := Message and not gmAttack; |
1374 State := State or gstMoving; |
1374 State := State or gstMoving; |
1375 end; |
1375 end; |
1376 RopePoints.Count := 0; |
1376 RopePoints.Count := 0; |
1377 Gear^.Elasticity := _0; |
1377 Gear^.Elasticity := _0; |
1378 Gear^.doStep := @doStepRopeAfterAttack |
1378 Gear^.doStep := @doStepRopeAfterAttack |
1379 end;*) |
1379 end; |
1380 |
1380 |
1381 begin |
1381 begin |
1382 HHGear := Gear^.Hedgehog^.Gear; |
1382 HHGear := Gear^.Hedgehog^.Gear; |
1383 |
1383 |
1384 if ((HHGear^.State and gstHHDriven) = 0) |
1384 if ((HHGear^.State and gstHHDriven) = 0) |
1580 begin |
1580 begin |
1581 if (Gear^.State and gsttmpFlag) <> 0 then |
1581 if (Gear^.State and gsttmpFlag) <> 0 then |
1582 with Gear^.Hedgehog^ do |
1582 with Gear^.Hedgehog^ do |
1583 begin |
1583 begin |
1584 PlaySound(sndRopeRelease); |
1584 PlaySound(sndRopeRelease); |
1585 //if CurAmmoType <> amParachute then |
1585 if CurAmmoType <> amParachute then |
1586 // WaitCollision |
1586 WaitCollision |
1587 //else |
1587 else |
1588 DeleteMe |
1588 DeleteMe |
1589 end |
1589 end |
1590 end |
1590 end |
1591 else |
1591 else |
1592 if (Gear^.State and gsttmpFlag) = 0 then |
1592 if (Gear^.State and gsttmpFlag) = 0 then |
2950 hogs := GearsNear(Gear^.X, Gear^.Y, gtHedgehog, Gear^.Radius); |
2950 hogs := GearsNear(Gear^.X, Gear^.Y, gtHedgehog, Gear^.Radius); |
2951 if Length(hogs) > 0 then |
2951 if Length(hogs) > 0 then |
2952 begin |
2952 begin |
2953 for i:= 0 to High(hogs) do |
2953 for i:= 0 to High(hogs) do |
2954 begin |
2954 begin |
2955 //d:= Distance(Gear^.X - hogs[i]^.X, Gear^.Y - hogs[i]^.Y); |
2955 if hogs[i] <> CurrentHedgehog^.Gear then |
2956 hogs[i]^.dX:= _0_25 * (Gear^.X - hogs[i]^.X) / _250; |
2956 begin |
2957 //if Gear^.X < hogs[i]^.X then hogs[i]^.dX.isNegative:= true; |
2957 //d:= Distance(Gear^.X - hogs[i]^.X, Gear^.Y - hogs[i]^.Y); |
2958 hogs[i]^.dY:= -_0_25; |
2958 hogs[i]^.dX:= _0_25 * (Gear^.X - hogs[i]^.X) / _250; |
2959 hogs[i]^.Active:= true; |
2959 //if Gear^.X < hogs[i]^.X then hogs[i]^.dX.isNegative:= true; |
|
2960 hogs[i]^.dY:= -_0_25; |
|
2961 hogs[i]^.Active:= true; |
|
2962 end |
2960 end; |
2963 end; |
2961 end ; |
2964 end ; |
2962 AfterAttack; |
2965 AfterAttack; |
2963 DeleteGear(Gear); |
2966 DeleteGear(Gear); |
2964 (* |
2967 (* |