The free camera steps through move, lock and off: locked, the view stays and Link walks where the left stick points on screen

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
lebomisandClaude Opus 5.5 committed 2026-11-19 14:28:13 +11:00
1 parent 58930c152c
commit 5fdacca237
6 files changed
+86 -65

No files matched your search

+6 -4
View File
@@ -99,12 +99,14 @@ int input_pad_read(uint64_t *buttons, int32_t *lx, int32_t *ly);
// The gamepad layout in effect (PAD_LAYOUT_*, input_map.h; TOTK_PAD_LAYOUT, live); -1 without a gamepad. Any thread.
int input_pad_layout(void);
// Free camera (freecam.c). input.c switches it with TOTK_FREECAM_PAD and, while it is on, hands it the gamepad and
// gives the game none: sticks -1..1 with up +y after the dead zone, triggers 0..1; each L or R press is one speed click.
// Free camera (freecam.c). input.c steps it with TOTK_FREECAM_PAD and, while it moves, hands it the gamepad and gives
// the game none: sticks -1..1 with up +y after the dead zone, triggers 0..1; each L or R press is one speed click.
// Locked, the view stays and the game gets the input.
typedef struct { float lx, ly, rx, ry, lt, rt; } FreecamPad;
enum { FREECAM_OFF, FREECAM_MOVE, FREECAM_LOCK };
int freecam_available(void); // game 1.4.3 with the freecam patch set on
int freecam_on(void);
void freecam_toggle(void); // logs; input thread
int freecam_state(void); // FREECAM_*
void freecam_cycle(void); // off, move, lock, off; logs; input thread
void freecam_pad(const FreecamPad *p);
void freecam_speed_click(int faster); // R (1) doubles the speed, L (0) halves it
void freecam_mouse(double right_deg, double down_deg); // a turn from the mouse, added at the next step