Working on UI, navigation, minor fixing

This commit is contained in:
Vladislav Khorev committed 2026-05-31 18:33:39 +03:00
1 parent a0550daf4b
commit 03681bedaf
38 files changed
+8303 -772

No files matched your search

+8 -7
View File
@@ -234,7 +234,6 @@ namespace ZL
};
*/
uniInteriorParams.navigationJsonPaths = {
"resources/navigation/uni_interior3_all_locked.json",
"resources/navigation/uni_interior3_hall.json",
@@ -294,12 +293,12 @@ namespace ZL
params_dorm.dialoguesJsonPath = "resources/dialogue/dorm_dialogues.json";
params_dorm.navigationJsonPaths = {
"resources/navigation/dorm3_free.json",
"resources/navigation/dorm3_free.json",
"resources/navigation/dorm3_free.json",
"resources/navigation/dorm3_free.json",
"resources/navigation/dorm3_free.json",
"resources/navigation/dorm3_free.json",
"resources/navigation/dorm3_bca.json",
"resources/navigation/dorm3_ca.json",
"resources/navigation/dorm3_ba.json",
"resources/navigation/dorm3_a.json",
"resources/navigation/dorm3_b.json",
"resources/navigation/dorm3_all_open.json",
};
/*
params_dorm.navigationJsonPaths = {
@@ -311,6 +310,7 @@ namespace ZL
"resources/navigation/dorm2_all_open.json",
};*/
/*
params_dorm.navigationJsonPaths = {
"resources/navigation/dorm2_bca2.txt",
@@ -330,6 +330,7 @@ namespace ZL
"resources/navigation/dorm0_large.json",
};*/
params_dorm.teleportsJsonPath = "resources/config2/teleports_dorm.json";
params_dorm.triggerZonesJsonPath = "resources/config2/trigger_zones_dorm.json";
params_dorm.scriptPath = "resources/start_dorm.lua";
+5 -3
View File
@@ -84,6 +84,8 @@ namespace ZL {
phoneChatListRoot = loadUiFromFile("resources/w/ui/screen_phone_chat_list.json", renderer, zipFile);
phoneChat1Root = loadUiFromFile("resources/w/ui/screen_phone_chat1.json", renderer, zipFile);
phoneChat2Root = loadUiFromFile("resources/w/ui/screen_phone_chat2.json", renderer, zipFile);
phoneChat3Root = loadUiFromFile("resources/w/ui/screen_phone_chat3.json", renderer, zipFile);
newInventoryRoot = loadUiFromFile("resources/w/ui/screen_inventory.json", renderer, zipFile);
questJournalRoot = loadUiFromFile("resources/w/ui/screen_journal.json", renderer, zipFile);
@@ -205,13 +207,13 @@ namespace ZL {
});
uiManager.setButtonCallback("phoneMain", [this](const std::string&) {});
uiManager.setTextButtonCallback("chat1button", [this](const std::string&) {
openPhoneChatFromList(phoneChat1Root, "dialog_chat_parents001");
openPhoneChatFromList(phoneChat1Root, "dialog_chat_aiperi001");
});
uiManager.setTextButtonCallback("chat2button", [this](const std::string&) {
openPhoneChatFromList(phoneChat2Root, "dialog_chat_aiperi001");
openPhoneChatFromList(phoneChat2Root, "dialog_chat_parents001");
});
uiManager.setTextButtonCallback("chat3button", [this](const std::string&) {
// not yet implemented
openPhoneChatFromList(phoneChat3Root, "dialog_chat_news001");
});
}
+2 -1
View File
@@ -68,7 +68,6 @@ namespace ZL {
void enterGameplay();
void refreshQuestJournalUi();
void selectQuestByIndex(int index);
void selectInventoryItem(int index);
void refreshItemPickupHud();
void setupStep5Callbacks();
void resetPhoneChatNodes();
@@ -98,6 +97,8 @@ namespace ZL {
std::shared_ptr<UiNode> phoneChatListRoot;
std::shared_ptr<UiNode> phoneChat1Root;
std::shared_ptr<UiNode> phoneChat2Root;
std::shared_ptr<UiNode> phoneChat3Root;
std::shared_ptr<UiNode> newInventoryRoot;
std::shared_ptr<UiNode> questJournalRoot;
+1 -1
View File
@@ -216,7 +216,7 @@ void DialogueOverlay::drawDialogue(Renderer& renderer, const PresentationModel&
}
const float bodyTextScale = 1.0f;
const float bodyMaxWidthPx = W - nameX - 48.f-x;
const float bodyMaxWidthPx = W - nameX - 48.f-x-60.f;
const std::string wrappedBody = wrapTextToWidth(model.visibleText, *bodyRenderer, bodyMaxWidthPx, bodyTextScale);
bodyRenderer->drawText(wrappedBody, bodyX, bodyY, bodyTextScale, false, { 1.0f, 1.0f, 1.0f, 1.0f });