Public Member Functions | List of all members
Controller Class Referenceabstract

Object representing one Gamepad controller. More...

#include <jngl/Controller.hpp>

Public Member Functions

 Controller (const Controller &)=delete
Controlleroperator= (const Controller &)=delete
 Controller (Controller &&)=delete
Controlleroperator= (Controller &&)=delete
float state (controller::Button) const
 Returns a value between 0.0f (not pressed) and 1.0f (pressed)
virtual bool down (controller::Button) const =0
 Returns true when the button is down.
bool pressed (controller::Button)
 Returns true only once per frame (until jngl::updateInput is called) for every button press.
virtual void rumble (float, std::chrono::milliseconds)
 0 = no vibration, 1 = maximum
- Public Member Functions inherited from enable_shared_from_this< Controller >
enable_shared_from_this (T... args)
operator= (T... args)
shared_from_this (T... args)
weak_from_this (T... args)
~enable_shared_from_this (T... args)

Detailed Description

Object representing one Gamepad controller.

Definition at line 13 of file Controller.hpp.

Inheritance diagram for Controller:
Collaboration diagram for Controller:

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