Big changes to use the new lel-guecs setup but now almost everything works. Only thing missing is Issue #16 in quecs.
This commit is contained in:
parent
86ddfc460f
commit
d93bc1615c
14 changed files with 51 additions and 59 deletions
|
@ -14,17 +14,17 @@ namespace gui {
|
|||
$status.position(0, 0, BOSS_VIEW_X, SCREEN_HEIGHT);
|
||||
$status.layout(
|
||||
"[main_status]"
|
||||
"[(150)status_3|(150)status_4]"
|
||||
"[(150)status_5|(150)status_6]"
|
||||
"[(150)status_7|(150)status_8]");
|
||||
"[=status_3|=status_4]"
|
||||
"[=status_5|=status_6]"
|
||||
"[=status_7|=status_8]");
|
||||
|
||||
$overlay.position(BOSS_VIEW_X, BOSS_VIEW_Y,
|
||||
BOSS_VIEW_WIDTH, BOSS_VIEW_HEIGHT);
|
||||
|
||||
$overlay.layout("[overlay_1|overlay_2|overlay_4]"
|
||||
"[overlay_5|overlay_6|overlay_8]"
|
||||
"[overlay_9|overlay_10|overlay_12]"
|
||||
"[overlay_13|overlay_14|overlay_16]");
|
||||
$overlay.layout("[=overlay_1|=overlay_2|=overlay_4]"
|
||||
"[=overlay_5|=overlay_6|=overlay_8]"
|
||||
"[=overlay_9|=overlay_10|=overlay_12]"
|
||||
"[=overlay_13|=overlay_14|=overlay_16]");
|
||||
|
||||
$sounds = $world->get<components::Sound>($boss_id);
|
||||
$combat = $world->get<components::Combat>($boss_id);
|
||||
|
@ -73,9 +73,9 @@ namespace gui {
|
|||
}
|
||||
});
|
||||
if(name == "main_status") {
|
||||
$status.set<Textual>(button, {fmt::format(L"HP: {}", $combat.hp)});
|
||||
$status.set<Text>(button, {fmt::format(L"HP: {}", $combat.hp)});
|
||||
} else {
|
||||
$status.set<Label>(button, {L"Attack"});
|
||||
$status.set<Text>(button, {L"Attack"});
|
||||
}
|
||||
}
|
||||
$status.init();
|
||||
|
@ -131,8 +131,8 @@ namespace gui {
|
|||
}
|
||||
|
||||
if($combat.hp == 0) {
|
||||
$overlay.show_label("overlay_1", L"YOU WON!");
|
||||
$overlay.show_label("overlay_4", L"CLICK TO CONTINUE...");
|
||||
$overlay.show_text("overlay_1", L"YOU WON!");
|
||||
$overlay.show_text("overlay_4", L"CLICK TO CONTINUE...");
|
||||
}
|
||||
|
||||
$status.render(window);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue