Loading...
Searching...
No Matches
PixelCrushers.GridController.Lever Class Reference

Interactable that also manages a lever handle GameObject that rotates when activated. More...

Inheritance diagram for PixelCrushers.GridController.Lever:
Collaboration diagram for PixelCrushers.GridController.Lever:

Public Member Functions

override void Interact (Vector3 playerPosition, CompassDirection playerCompassDirection)
 Rotate the lever.
 
void MoveAsPairedLever ()
 Flip this lever, usually called in conjunction with another lever (such as on opposite sides of a door) to keep them in sync.
 
virtual void FlipLeverImmediate ()
 Flips the lever immediately without animation.
 

Protected Member Functions

virtual IEnumerator PullLever (Vector3 playerPosition, CompassDirection playerCompassDirection)
 
virtual IEnumerator AnimateLever ()
 

Properties

bool IsFlipped [get]
 
Transform Handle [get, set]
 
float RotationAngle [get, set]
 
float RotationDuration [get, set]
 
Lever PairedLever [get, set]
 
- Properties inherited from PixelCrushers.GridController.Interactable
bool DisableAfterUse [get]
 

Additional Inherited Members

- Events inherited from PixelCrushers.GridController.Interactable
System.Action< Vector3 > Interacted = null
 

Detailed Description

Interactable that also manages a lever handle GameObject that rotates when activated.

Can be paired with another lever to keep their positions in sync.

Member Function Documentation

◆ AnimateLever()

virtual IEnumerator PixelCrushers.GridController.Lever.AnimateLever ( )
inlineprotectedvirtual

◆ FlipLeverImmediate()

virtual void PixelCrushers.GridController.Lever.FlipLeverImmediate ( )
inlinevirtual

Flips the lever immediately without animation.

◆ Interact()

override void PixelCrushers.GridController.Lever.Interact ( Vector3  playerPosition,
CompassDirection  playerCompassDirection 
)
inlinevirtual

Rotate the lever.

When finished, invoke the interaction.

Reimplemented from PixelCrushers.GridController.Interactable.

◆ MoveAsPairedLever()

void PixelCrushers.GridController.Lever.MoveAsPairedLever ( )
inline

Flip this lever, usually called in conjunction with another lever (such as on opposite sides of a door) to keep them in sync.

◆ PullLever()

virtual IEnumerator PixelCrushers.GridController.Lever.PullLever ( Vector3  playerPosition,
CompassDirection  playerCompassDirection 
)
inlineprotectedvirtual

Property Documentation

◆ Handle

Transform PixelCrushers.GridController.Lever.Handle
getset

◆ IsFlipped

bool PixelCrushers.GridController.Lever.IsFlipped
get

◆ PairedLever

Lever PixelCrushers.GridController.Lever.PairedLever
getset

◆ RotationAngle

float PixelCrushers.GridController.Lever.RotationAngle
getset

◆ RotationDuration

float PixelCrushers.GridController.Lever.RotationDuration
getset

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