Unravel Engine C++ Reference
Loading...
Searching...
No Matches
input::gamepad_action_map Class Reference

#include <gamepad_action_map.hpp>

Classes

struct  gamepad_entry
 

Public Member Functions

auto get_analog_value (const action_id_t &action, const gamepad &device) const -> float
 
auto get_digital_value (const action_id_t &action, const gamepad &device) const -> bool
 
auto is_pressed (const action_id_t &action, const gamepad &device) const -> bool
 
auto is_released (const action_id_t &action, const gamepad &device) const -> bool
 
auto is_down (const action_id_t &action, const gamepad &device) const -> bool
 
void map (const action_id_t &action, gamepad_axis axis, axis_range range=axis_range::full, float min_analog_value=-1.0f, float max_analog_value=1.0f)
 
void map (const action_id_t &action, gamepad_button button)
 

Public Attributes

std::map< action_id_t, std::vector< gamepad_entry > > entries_by_action_id_
 

Friends

auto operator== (const gamepad_action_map &lhs, const gamepad_action_map &rhs) -> bool=default
 

Detailed Description

Definition at line 14 of file gamepad_action_map.hpp.

Member Function Documentation

◆ get_analog_value()

auto input::gamepad_action_map::get_analog_value ( const action_id_t & action,
const gamepad & device ) const -> float

Definition at line 38 of file gamepad_action_map.cpp.

◆ get_digital_value()

auto input::gamepad_action_map::get_digital_value ( const action_id_t & action,
const gamepad & device ) const -> bool

Definition at line 86 of file gamepad_action_map.cpp.

◆ is_down()

auto input::gamepad_action_map::is_down ( const action_id_t & action,
const gamepad & device ) const -> bool

Definition at line 204 of file gamepad_action_map.cpp.

◆ is_pressed()

auto input::gamepad_action_map::is_pressed ( const action_id_t & action,
const gamepad & device ) const -> bool

Definition at line 134 of file gamepad_action_map.cpp.

◆ is_released()

auto input::gamepad_action_map::is_released ( const action_id_t & action,
const gamepad & device ) const -> bool

Definition at line 169 of file gamepad_action_map.cpp.

◆ map() [1/2]

void input::gamepad_action_map::map ( const action_id_t & action,
gamepad_axis axis,
axis_range range = axis_range::full,
float min_analog_value = -1.0f,
float max_analog_value = 1.0f )

Definition at line 241 of file gamepad_action_map.cpp.

◆ map() [2/2]

void input::gamepad_action_map::map ( const action_id_t & action,
gamepad_button button )

Definition at line 258 of file gamepad_action_map.cpp.

Friends And Related Symbol Documentation

◆ operator==

auto operator== ( const gamepad_action_map & lhs,
const gamepad_action_map & rhs ) -> bool=default
friend

Member Data Documentation

◆ entries_by_action_id_

std::map<action_id_t, std::vector<gamepad_entry> > input::gamepad_action_map::entries_by_action_id_

Definition at line 28 of file gamepad_action_map.hpp.


The documentation for this class was generated from the following files: