summaryrefslogtreecommitdiff
path: root/soh/src/code/z_parameter.c
diff options
context:
space:
mode:
authorBaoulettes <perlouzerie@hotmail.fr>2022-05-29 23:02:19 +0200
committerGitHub <noreply@github.com>2022-05-29 23:02:19 +0200
commitea0ea0366be367fa6c8015772728489a22ebfdde (patch)
tree90d295b68a32dc8eb312778865be226e6ed31c8d /soh/src/code/z_parameter.c
parent72125bbd1e604369527e99056390bda2d37d9d9b (diff)
parentdaec428cb3844bdb5261f5ddf47b613cce514d05 (diff)
Merge branch 'develop' into 3DProjectiles
Diffstat (limited to 'soh/src/code/z_parameter.c')
-rw-r--r--soh/src/code/z_parameter.c21
1 files changed, 20 insertions, 1 deletions
diff --git a/soh/src/code/z_parameter.c b/soh/src/code/z_parameter.c
index dcfcdb05b..a9e9e4f9e 100644
--- a/soh/src/code/z_parameter.c
+++ b/soh/src/code/z_parameter.c
@@ -2884,7 +2884,26 @@ void Interface_DrawItemButtons(GlobalContext* globalCtx) {
gDPSetEnvColor(OVERLAY_DISP++, 0, 0, 0, 0);
gDPSetCombineLERP(OVERLAY_DISP++, PRIMITIVE, ENVIRONMENT, TEXEL0, ENVIRONMENT, TEXEL0, 0, PRIMITIVE, 0,
PRIMITIVE, ENVIRONMENT, TEXEL0, ENVIRONMENT, TEXEL0, 0, PRIMITIVE, 0);
-
+
+ //There is probably a more elegant way to do it.
+ char* doAction = actionsTbl[3];
+ char newName[512];
+ if (gSaveContext.language != LANGUAGE_ENG) {
+ size_t length = strlen(doAction);
+ strcpy(newName, doAction);
+ if (gSaveContext.language == LANGUAGE_FRA) {
+ newName[length - 6] = 'F';
+ newName[length - 5] = 'R';
+ newName[length - 4] = 'A';
+ } else if (gSaveContext.language == LANGUAGE_GER) {
+ newName[length - 6] = 'G';
+ newName[length - 5] = 'E';
+ newName[length - 4] = 'R';
+ }
+ doAction = newName;
+ }
+ memcpy(interfaceCtx->doActionSegment + DO_ACTION_TEX_SIZE * 2, ResourceMgr_LoadTexByName(doAction), DO_ACTION_TEX_SIZE);
+
gDPLoadTextureBlock_4b(OVERLAY_DISP++, interfaceCtx->doActionSegment + DO_ACTION_TEX_SIZE * 2, G_IM_FMT_IA,
DO_ACTION_TEX_WIDTH, DO_ACTION_TEX_HEIGHT, 0, G_TX_NOMIRROR | G_TX_WRAP,
G_TX_NOMIRROR | G_TX_WRAP, G_TX_NOMASK, G_TX_NOMASK, G_TX_NOLOD, G_TX_NOLOD);