Fixed radial menu input

This commit is contained in:
2026-05-25 23:13:25 +03:00
parent 48951fa305
commit 38161ee4a2
8 changed files with 131 additions and 10 deletions
@@ -66,6 +66,13 @@ public:
UFUNCTION(BlueprintPure, Category = "Radial Menu")
int32 GetHoveredIndex() const { return HoveredIndex; }
// Update the hovered slice from a direction vector (X right, Y up), measured
// in the same frame as the menu. Used by both the mouse path (controller
// tick) and the gamepad path (widget forwards the right-stick vector here,
// since CommonUI consumes the stick before the controller can read it).
// Magnitude below the dead zone leaves the current hover unchanged.
void UpdateHoverFromDirection(float DirX, float DirY, float Magnitude);
// The data the menu draws. Populate from wherever you like (data table,
// inventory component, hardcoded list) before calling OpenMenu().
UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = "Radial Menu")