diff --git a/data/font/04b_25_2x.png b/data/font/04b_25_2x.png new file mode 100644 index 0000000..d6297f7 Binary files /dev/null and b/data/font/04b_25_2x.png differ diff --git a/data/font/04b_25_2x.txt b/data/font/04b_25_2x.txt new file mode 100644 index 0000000..ea52a2b --- /dev/null +++ b/data/font/04b_25_2x.txt @@ -0,0 +1,194 @@ +# box width +28 +# box height +28 +# 32 espacio ( ) +16 +# 33 ! +10 +# 34 " +16 +# 35 +20 +# 36 $ +20 +# 37 % +18 +# 38 & +22 +# 39 ' +10 +# 40 ( +14 +# 41 ) +14 +# 42 * +14 +# 43 + +18 +# 44 , +10 +# 45 - +18 +# 46 . +10 +# 47 / +24 +# 48 0 +16 +# 49 1 +12 +# 50 2 +16 +# 51 3 +16 +# 52 4 +16 +# 53 5 +16 +# 54 6 +16 +# 55 7 +16 +# 56 8 +16 +# 57 9 +16 +# 58 : +10 +# 59 ; +10 +# 60 < +16 +# 61 = +16 +# 62 > +16 +# 63 ? +16 +# 64 @ +22 +# 65 A +16 +# 66 B +16 +# 67 C +16 +# 68 D +16 +# 69 E +16 +# 70 F +16 +# 71 G +16 +# 72 H +16 +# 73 I +10 +# 74 J +16 +# 75 K +16 +# 76 L +16 +# 77 M +22 +# 78 N +16 +# 79 O +16 +# 80 P +16 +# 81 Q +16 +# 82 R +16 +# 83 S +16 +# 84 T +18 +# 85 U +16 +# 86 V +16 +# 87 W +22 +# 88 X +16 +# 89 Y +16 +# 90 Z +16 +# 91 [ +14 +# 92 \ +22 +# 93 ] +14 +# 94 ^ +12 +# 95 _ +14 +# 96 ` +12 +# 97 a +16 +# 98 b +16 +# 99 c +16 +# 100 d +16 +# 101 e +16 +# 102 f +16 +# 103 g +16 +# 104 h +16 +# 105 i +10 +# 106 j +16 +# 107 k +16 +# 108 l +16 +# 109 m +22 +# 110 n +16 +# 111 o +16 +# 112 p +16 +# 113 q +16 +# 114 r +16 +# 115 s +16 +# 116 t +18 +# 117 u +16 +# 118 v +16 +# 119 w +22 +# 120 x +16 +# 121 y +16 +# 122 z +16 +# 123 { +2 +# 124 | +2 +# 125 } +2 +# 126 ~ +2 \ No newline at end of file diff --git a/source/director.cpp b/source/director.cpp index 70a4d8c..f4a7892 100644 --- a/source/director.cpp +++ b/source/director.cpp @@ -495,6 +495,8 @@ void Director::setFileList() Asset::get()->add(prefix + "/data/font/smb2.txt", AssetType::FONT); Asset::get()->add(prefix + "/data/font/04b_25.png", AssetType::BITMAP); Asset::get()->add(prefix + "/data/font/04b_25.txt", AssetType::FONT); + Asset::get()->add(prefix + "/data/font/04b_25_2x.png", AssetType::BITMAP); + Asset::get()->add(prefix + "/data/font/04b_25_2x.txt", AssetType::FONT); // Textos Asset::get()->add(prefix + "/data/lang/es_ES.txt", AssetType::LANG); @@ -614,7 +616,7 @@ void Director::runGame() { const auto player_id = section::options == section::Options::GAME_PLAY_1P ? 1 : 2; #ifdef DEBUG - constexpr auto current_stage = 9; + constexpr auto current_stage = 0; #else constexpr auto current_stage = 0; #endif diff --git a/source/game.cpp b/source/game.cpp index fc75e77..76dcdd3 100644 --- a/source/game.cpp +++ b/source/game.cpp @@ -351,9 +351,9 @@ void Game::updateStage() createMessage(paths, Resource::get()->getTexture("last_stage")); else { - auto text = Resource::get()->getText("04b_25"); + auto text = Resource::get()->getText("04b_25_2x"); const std::string caption = std::to_string(10 - current_stage_) + lang::getText(38); - createMessage(paths, text->writeToTexture(caption, 2, -2)); + createMessage(paths, text->writeToTexture(caption, 1, -4)); } } } diff --git a/source/resource.cpp b/source/resource.cpp index 1c0b1aa..edd33e4 100644 --- a/source/resource.cpp +++ b/source/resource.cpp @@ -255,7 +255,6 @@ void Resource::createTextures() }; std::cout << "\n>> CREATING TEXTURES" << std::endl; - auto text = getText("04b_25"); // TamaƱo normal std::vector strings = { @@ -267,6 +266,7 @@ void Resource::createTextures() NameAndText("game_text_stop", lang::getText(119)), NameAndText("1000000_points", lang::getText(76))}; + auto text = getText("04b_25"); for (const auto &s : strings) { textures_.emplace_back(ResourceTexture(s.name, text->writeToTexture(s.text, 1, -2))); @@ -280,9 +280,10 @@ void Resource::createTextures() NameAndText("congratulations", lang::getText(50)), NameAndText("game_over", "Game Over")}; + auto text2 = getText("04b_25_2x"); for (const auto &s : strings2X) { - textures_.emplace_back(ResourceTexture(s.name, text->writeToTexture(s.text, 2, -2))); + textures_.emplace_back(ResourceTexture(s.name, text2->writeToTexture(s.text, 1, -4))); printWithDots("Texture : ", s.name, "[ DONE ]"); } } @@ -294,6 +295,7 @@ void Resource::createText() std::vector> resources = { {"04b_25", "04b_25.png"}, + {"04b_25_2x", "04b_25_2x.png"}, {"8bithud", "8bithud.png"}, {"nokia", "nokia.png"}, {"smb2", "smb2.gif"}};