45 procedure AddFlakes; |
45 procedure AddFlakes; |
46 procedure ChangeToSDFlakes; |
46 procedure ChangeToSDFlakes; |
47 procedure AddDamageTag(X, Y, Damage, Color: LongWord); |
47 procedure AddDamageTag(X, Y, Damage, Color: LongWord); |
48 |
48 |
49 implementation |
49 implementation |
50 uses uSound, uMobile, uVariables, uTextures, uRender, Math, uRenderUtils; |
50 uses uSound, uMobile, uVariables, uTextures, uRender, Math, uRenderUtils, uStore; |
51 |
51 |
52 const cExplFrameTicks = 110; |
52 const cExplFrameTicks = 110; |
53 |
53 |
54 // For better maintainability the step handlers of visual gears are stored |
54 // For better maintainability the step handlers of visual gears are stored |
55 // in a separate file. |
55 // in a separate file. |
479 vgtSmallDamageTag: DrawCentered(round(Gear^.X) + WorldDx, round(Gear^.Y) + WorldDy, Gear^.Tex); |
479 vgtSmallDamageTag: DrawCentered(round(Gear^.X) + WorldDx, round(Gear^.Y) + WorldDy, Gear^.Tex); |
480 vgtHealthTag: if Gear^.Tex <> nil then |
480 vgtHealthTag: if Gear^.Tex <> nil then |
481 begin |
481 begin |
482 if Gear^.State = 0 then |
482 if Gear^.State = 0 then |
483 DrawCentered(round(Gear^.X) + WorldDx, round(Gear^.Y) + WorldDy, Gear^.Tex) |
483 DrawCentered(round(Gear^.X) + WorldDx, round(Gear^.Y) + WorldDy, Gear^.Tex) |
484 else DrawTexture(round(Gear^.X), round(Gear^.Y), Gear^.Tex); |
484 else |
|
485 begin |
|
486 SetScale(cDefaultZoomLevel); |
|
487 DrawTexture(round(Gear^.X), round(Gear^.Y), Gear^.Tex); |
|
488 SetScale(zoom) |
|
489 end |
485 end; |
490 end; |
486 //if Gear^.Tex <> nil then DrawCentered(round(Gear^.X) + WorldDx, round(Gear^.Y) + WorldDy, Gear^.Tex); |
491 //if Gear^.Tex <> nil then DrawCentered(round(Gear^.X) + WorldDx, round(Gear^.Y) + WorldDy, Gear^.Tex); |
487 vgtStraightShot: DrawRotatedF(TSprite(Gear^.State), round(Gear^.X) + WorldDx, round(Gear^.Y) + WorldDy, Gear^.Frame, 1, Gear^.Angle); |
492 vgtStraightShot: DrawRotatedF(TSprite(Gear^.State), round(Gear^.X) + WorldDx, round(Gear^.Y) + WorldDy, Gear^.Frame, 1, Gear^.Angle); |
488 end; |
493 end; |
489 if (cReducedQuality and rqAntiBoom) = 0 then |
494 if (cReducedQuality and rqAntiBoom) = 0 then |