equal
deleted
inserted
replaced
205 // Define ammo association, if any. |
205 // Define ammo association, if any. |
206 gear^.AmmoType:= GearKindAmmoTypeMap[Kind]; |
206 gear^.AmmoType:= GearKindAmmoTypeMap[Kind]; |
207 gear^.CollisionMask:= lfAll; |
207 gear^.CollisionMask:= lfAll; |
208 gear^.Tint:= $FFFFFFFF; |
208 gear^.Tint:= $FFFFFFFF; |
209 gear^.Data:= nil; |
209 gear^.Data:= nil; |
|
210 gear^.Sticky:= false; |
210 |
211 |
211 if CurrentHedgehog <> nil then |
212 if CurrentHedgehog <> nil then |
212 begin |
213 begin |
213 gear^.Hedgehog:= CurrentHedgehog; |
214 gear^.Hedgehog:= CurrentHedgehog; |
214 if (CurrentHedgehog^.Gear <> nil) and (hwRound(CurrentHedgehog^.Gear^.X) = X) and (hwRound(CurrentHedgehog^.Gear^.Y) = Y) then |
215 if (CurrentHedgehog^.Gear <> nil) and (hwRound(CurrentHedgehog^.Gear^.X) = X) and (hwRound(CurrentHedgehog^.Gear^.Y) = Y) then |
351 with Gear^ do |
352 with Gear^ do |
352 begin |
353 begin |
353 Pos:= 0; |
354 Pos:= 0; |
354 Radius:= 1; |
355 Radius:= 1; |
355 DirAngle:= random(360); |
356 DirAngle:= random(360); |
|
357 Sticky:= true; |
356 if State and gstTmpFlag = 0 then |
358 if State and gstTmpFlag = 0 then |
357 begin |
359 begin |
358 dx.isNegative:= GetRandom(2) = 0; |
360 dx.isNegative:= GetRandom(2) = 0; |
359 dx.QWordValue:= QWord($40DA) * GetRandom(10000) * 8; |
361 dx.QWordValue:= QWord($40DA) * GetRandom(10000) * 8; |
360 dy.isNegative:= false; |
362 dy.isNegative:= false; |
461 gear^.Radius:= 2; |
463 gear^.Radius:= 2; |
462 gear^.Elasticity:= _0_55; |
464 gear^.Elasticity:= _0_55; |
463 gear^.Friction:= _0_995; |
465 gear^.Friction:= _0_995; |
464 gear^.Density:= _1_6; |
466 gear^.Density:= _1_6; |
465 gear^.AdvBounce:= 1; |
467 gear^.AdvBounce:= 1; |
|
468 gear^.Sticky:= true; |
466 if gear^.Timer = 0 then gear^.Timer:= 500; |
469 if gear^.Timer = 0 then gear^.Timer:= 500; |
467 end; |
470 end; |
468 gtKnife: begin |
471 gtKnife: begin |
469 gear^.ImpactSound:= sndKnifeImpact; |
472 gear^.ImpactSound:= sndKnifeImpact; |
470 gear^.AdvBounce:= 1; |
473 gear^.AdvBounce:= 1; |
471 gear^.Elasticity:= _0_8; |
474 gear^.Elasticity:= _0_8; |
472 gear^.Friction:= _0_8; |
475 gear^.Friction:= _0_8; |
473 gear^.Density:= _4; |
476 gear^.Density:= _4; |
474 gear^.Radius:= 7 |
477 gear^.Radius:= 7; |
|
478 gear^.Sticky:= true; |
475 end; |
479 end; |
476 gtCase: begin |
480 gtCase: begin |
477 gear^.ImpactSound:= sndGraveImpact; |
481 gear^.ImpactSound:= sndGraveImpact; |
478 gear^.nImpactSounds:= 1; |
482 gear^.nImpactSounds:= 1; |
479 gear^.Radius:= 16; |
483 gear^.Radius:= 16; |
669 // set color |
673 // set color |
670 gear^.Tag:= 2 * gear^.Timer; |
674 gear^.Tag:= 2 * gear^.Timer; |
671 gear^.Timer:= 15000; |
675 gear^.Timer:= 15000; |
672 gear^.RenderTimer:= false; |
676 gear^.RenderTimer:= false; |
673 gear^.Health:= 100; |
677 gear^.Health:= 100; |
|
678 gear^.Sticky:= true; |
674 end; |
679 end; |
675 gtPiano: begin |
680 gtPiano: begin |
676 gear^.Radius:= 32; |
681 gear^.Radius:= 32; |
677 gear^.Density:= _50; |
682 gear^.Density:= _50; |
678 end; |
683 end; |