PuzzleLightMirror
A class in Root.Township, the global namespace.
Light puzzle mirror: each beam that hits it spawns a reflected beam, with a limit on how often one beam chain can bounce off the same mirror.
- Listed in Global namespace: P
- Inherits or implements
PuzzleLightBeam,ILightDetector,ILightEmitter
Constructors
| Member | What it is |
|---|---|
PuzzleLightMirror() | Unity makes components itself; use AddComponent or spawn a prefab instead of new. |
Fields
2 private and internal fields
Methods
| Member | What it is |
|---|---|
void BeginHit(Beam incoming) | Creates a reflected beam for a new incoming beam if allowed, and enables the mirror. |
void EndHit(Beam incoming) | Stops the reflected beam for that incoming beam; disables the mirror when none are left. |
protected override void Awake() | Starts disabled until a beam hits it. |
protected virtual bool IsAllowed(Beam incoming) | False if the incoming beam's chain has already hit this mirror singleBeamHitCount times. |
protected override void Update() | Re-emits each reflected beam from its incoming beam's hit point, mirrored on the hit normal. |