mirror of
https://github.com/coop-deluxe/sm64coopdx.git
synced 2026-04-22 10:01:46 +00:00
Fix dpad logic in menus (#825)
Some checks are pending
Build coop / build-linux (push) Waiting to run
Build coop / build-steamos (push) Waiting to run
Build coop / build-windows-opengl (push) Waiting to run
Build coop / build-windows-directx (push) Waiting to run
Build coop / build-macos-arm (push) Waiting to run
Build coop / build-macos-intel (push) Waiting to run
Some checks are pending
Build coop / build-linux (push) Waiting to run
Build coop / build-steamos (push) Waiting to run
Build coop / build-windows-opengl (push) Waiting to run
Build coop / build-windows-directx (push) Waiting to run
Build coop / build-macos-arm (push) Waiting to run
Build coop / build-macos-intel (push) Waiting to run
* Patches work when using git submodules (where .git is a file instead of a folder) * Patches: Use git's build in error throwing to detect if the git repository is valid * Fix dpad cursor logic in menus Without this change, there is no way to get the cursor onto the ">" button in the public lobbies pagination without using a mouse, because the dpad/arrowkey logic skips over it strangely. Another alternative solution could be that the rules button and the back/reset buttons swap places. * fixed brain fail in the djui cursor code I forgot how ternaries worked whoops
This commit is contained in:
parent
90af8dfb64
commit
61d0435311
2 changed files with 3 additions and 3 deletions
|
|
@ -85,8 +85,8 @@ static void djui_cursor_move_check(s8 xDir, s8 yDir, struct DjuiBase** pick, str
|
|||
if (*pick == NULL) {
|
||||
*pick = base;
|
||||
} else {
|
||||
f32 pickDist = djui_cursor_base_distance(*pick, xDir ? 1.0f : 2.0f, yDir ? 1.0f : 2.0f);
|
||||
f32 baseDist = djui_cursor_base_distance(base, xDir ? 1.0f : 2.0f, yDir ? 1.0f : 2.0f);
|
||||
f32 pickDist = djui_cursor_base_distance(*pick, xDir ? 1.0f : 1.2f, yDir ? 1.0f : 2.0f);
|
||||
f32 baseDist = djui_cursor_base_distance(base, xDir ? 1.0f : 1.2f, yDir ? 1.0f : 2.0f);
|
||||
if (baseDist < pickDist) { *pick = base; }
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -148,7 +148,7 @@ struct DjuiPaginated* djui_paginated_create(struct DjuiBase* parent, u32 showCou
|
|||
|
||||
djui_base_init(parent, base, djui_paginated_render, djui_paginated_destroy);
|
||||
djui_base_set_size_type(base, DJUI_SVT_RELATIVE, DJUI_SVT_ABSOLUTE);
|
||||
djui_base_set_size(base, 1.0, bodyHeight);
|
||||
djui_base_set_size(base, 1.0f, bodyHeight);
|
||||
djui_base_set_color(base, 0, 64, 0, 0);
|
||||
djui_base_set_alignment(base, DJUI_HALIGN_CENTER, DJUI_VALIGN_TOP);
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue