Hey,
So I want to make a small InputComponent, and get inputs from there, so i can avoid putting them in the project settings.
I used delegates with BindKey to Bind my inputs with my methods, and they are working well. The problem comes when I want to get my joystick inputs.
I tried BindAxisKey, but returns me 1 as soon as i touch my joystick, when i would like to get a number between 0 and 1…
Anyone has an idea of how to get what i want?
//in header
void SetX(float axis);
//in cpp
Beginplay()
{
BindAxisKey(EKeys::Gamepad_LeftStick_Right, this, &URadioInput::SetX);
}
void URadioInput::SetX(float axis)
{
UE_LOG(LogTemp, Log, TEXT("%f"), axis);
}