wavelength 1.0.0
Loading...
Searching...
No Matches
ForceFeedbackMgr::MotorEffect Class Reference

One vibration pattern of a controller, which runs both motors for a duration. More...

#include <forcefeedbackmgrmotoreffect.h>

Classes

class  OffCmd
 Command that ends a MotorEffect once its duration has passed. More...

Public Member Functions

 MotorEffect (int nController, int nSmallMotor, int nBigMotor, int nDuration)
 Construct an effect that is not running, with the command that ends it.
 ~MotorEffect ()
 Cancel the effect.
void Cancel ()
 Stop the motors and withdraw the command that ends the effect, when the effect runs.
void Start ()
 Start the effect again from its beginning.
void SetMotors (int nController, int nSmallMotor, int nBigMotor)
 Pass motor levels to the manager.
int GetController () const
int GetActive () const
void SetActive (int nActive)
 Set whether the effect runs.

Detailed Description

One vibration pattern of a controller, which runs both motors for a duration.

The class is not polymorphic. The RTTI of its nested OffCmd and of a pointer to it records the name. Every member except the constructor is inline.

Constructor & Destructor Documentation

◆ MotorEffect()

ForceFeedbackMgr::MotorEffect::MotorEffect ( int nController,
int nSmallMotor,
int nBigMotor,
int nDuration )

Construct an effect that is not running, with the command that ends it.

Inline in the program, which expands it into Controller's constructor.

Parameters
nControllerThe controller.
nSmallMotorThe small motor's state while the effect runs.
nBigMotorThe big motor's level while the effect runs.
nDurationThe ticks the effect runs for.

◆ ~MotorEffect()

ForceFeedbackMgr::MotorEffect::~MotorEffect ( )
inline

Cancel the effect.

Member Function Documentation

◆ Cancel()

void ForceFeedbackMgr::MotorEffect::Cancel ( )
inline

Stop the motors and withdraw the command that ends the effect, when the effect runs.

The name is inferred.

Ghidra address:
NTSC-U/C: 0x00335cb8
Ghidra address:
PAL: 0x003a3268

◆ Start()

void ForceFeedbackMgr::MotorEffect::Start ( )
inline

Start the effect again from its beginning.

The program expands it at every call. The name is inferred.

◆ SetMotors()

void ForceFeedbackMgr::MotorEffect::SetMotors ( int nController,
int nSmallMotor,
int nBigMotor )
inline

Pass motor levels to the manager.

The name is inferred.

Parameters
nControllerThe controller.
nSmallMotorThe small motor's state.
nBigMotorThe big motor's level.
Ghidra address:
NTSC-U/C: 0x00336110
Ghidra address:
PAL: 0x003a36c0

◆ GetController()

int ForceFeedbackMgr::MotorEffect::GetController ( ) const
inline
Returns
The controller.

◆ GetActive()

int ForceFeedbackMgr::MotorEffect::GetActive ( ) const
inline
Returns
Whether the effect runs.

◆ SetActive()

void ForceFeedbackMgr::MotorEffect::SetActive ( int nActive)
inline

Set whether the effect runs.

Parameters
nActiveWhether it runs.

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