@@ -473,28 +473,41 @@ namespace RTE {
473
473
if (!g_SceneMan.SceneWrapsX () && !g_SceneMan.SceneWrapsY ()) {
474
474
Vector drawStart = m_StartPos - targetPos;
475
475
476
- if (m_BlendMode > DrawBlendMode::NoBlend && m_RotAngle != 0 ) {
477
- rotate_sprite_trans (drawScreen, tempDrawBitmap, drawStart.GetFloorIntX (), drawStart.GetFloorIntY (), ftofix (rotation.GetAllegroAngle ()));
478
- } else if (m_RotAngle != 0 ) {
479
- rotate_sprite (drawScreen, tempDrawBitmap, drawStart.GetFloorIntX (), drawStart.GetFloorIntY (), ftofix (rotation.GetAllegroAngle ()));
476
+ if (m_BlendMode > DrawBlendMode::NoBlend) {
477
+ if (m_RotAngle != 0 ) {
478
+ rotate_sprite_trans (drawScreen, tempDrawBitmap, drawStart.GetFloorIntX (), drawStart.GetFloorIntY (), ftofix (rotation.GetAllegroAngle ()));
479
+ } else {
480
+ draw_trans_sprite (drawScreen, tempDrawBitmap, drawStart.GetFloorIntX (), drawStart.GetFloorIntY ());
481
+ }
480
482
} else {
481
- font->DrawAligned (&playerGUIBitmap, drawStart.GetFloorIntX (), drawStart.GetFloorIntY (), m_Text, m_Alignment);
483
+ if (m_RotAngle != 0 ) {
484
+ rotate_sprite (drawScreen, tempDrawBitmap, drawStart.GetFloorIntX (), drawStart.GetFloorIntY (), ftofix (rotation.GetAllegroAngle ()));
485
+ } else {
486
+ font->DrawAligned (&playerGUIBitmap, drawStart.GetFloorIntX (), drawStart.GetFloorIntY (), m_Text, m_Alignment);
487
+ }
482
488
}
483
489
} else {
484
490
Vector drawStartLeft;
485
491
Vector drawStartRight;
486
492
487
493
TranslateCoordinates (targetPos, m_StartPos, drawStartLeft, drawStartRight);
488
494
489
- if (m_BlendMode > DrawBlendMode::NoBlend && m_RotAngle != 0 ) {
490
- rotate_sprite_trans (drawScreen, tempDrawBitmap, drawStartLeft.GetFloorIntX (), drawStartLeft.GetFloorIntY (), ftofix (rotation.GetAllegroAngle ()));
491
- rotate_sprite_trans (drawScreen, tempDrawBitmap, drawStartRight.GetFloorIntX (), drawStartRight.GetFloorIntY (), ftofix (rotation.GetAllegroAngle ()));
492
- } else if (m_RotAngle != 0 ) {
493
- rotate_sprite (drawScreen, tempDrawBitmap, drawStartLeft.GetFloorIntX (), drawStartLeft.GetFloorIntY (), ftofix (rotation.GetAllegroAngle ()));
494
- rotate_sprite (drawScreen, tempDrawBitmap, drawStartRight.GetFloorIntX (), drawStartRight.GetFloorIntY (), ftofix (rotation.GetAllegroAngle ()));
495
+ if (m_BlendMode > DrawBlendMode::NoBlend) {
496
+ if (m_RotAngle != 0 ) {
497
+ rotate_sprite_trans (drawScreen, tempDrawBitmap, drawStartLeft.GetFloorIntX (), drawStartLeft.GetFloorIntY (), ftofix (rotation.GetAllegroAngle ()));
498
+ rotate_sprite_trans (drawScreen, tempDrawBitmap, drawStartRight.GetFloorIntX (), drawStartRight.GetFloorIntY (), ftofix (rotation.GetAllegroAngle ()));
499
+ } else {
500
+ draw_trans_sprite (drawScreen, tempDrawBitmap, drawStartLeft.GetFloorIntX (), drawStartLeft.GetFloorIntY ());
501
+ draw_trans_sprite (drawScreen, tempDrawBitmap, drawStartRight.GetFloorIntX (), drawStartRight.GetFloorIntY ());
502
+ }
495
503
} else {
496
- font->DrawAligned (&playerGUIBitmap, drawStartLeft.GetFloorIntX (), drawStartLeft.GetFloorIntY (), m_Text, m_Alignment);
497
- font->DrawAligned (&playerGUIBitmap, drawStartRight.GetFloorIntX (), drawStartRight.GetFloorIntY (), m_Text, m_Alignment);
504
+ if (m_RotAngle != 0 ) {
505
+ rotate_sprite (drawScreen, tempDrawBitmap, drawStartLeft.GetFloorIntX (), drawStartLeft.GetFloorIntY (), ftofix (rotation.GetAllegroAngle ()));
506
+ rotate_sprite (drawScreen, tempDrawBitmap, drawStartRight.GetFloorIntX (), drawStartRight.GetFloorIntY (), ftofix (rotation.GetAllegroAngle ()));
507
+ } else {
508
+ font->DrawAligned (&playerGUIBitmap, drawStartLeft.GetFloorIntX (), drawStartLeft.GetFloorIntY (), m_Text, m_Alignment);
509
+ font->DrawAligned (&playerGUIBitmap, drawStartRight.GetFloorIntX (), drawStartRight.GetFloorIntY (), m_Text, m_Alignment);
510
+ }
498
511
}
499
512
}
500
513
if (tempDrawBitmap) { destroy_bitmap (tempDrawBitmap); }
0 commit comments