A class in Root.Township, the global namespace.
When its target chunk finishes loading, turns on trigger colliders for one frame and pushes any loose, unheld pickup they touch by a fixed offset. Probably clears items stuck in a spot.
Constructors
| Member | What it is |
|---|
CleaningHelper() | Unity makes components itself; use AddComponent or spawn a prefab instead of new. |
Fields
3 private and internal fields
| Member | What it is |
|---|
private Collider[] colliders | Trigger colliders used for the check. |
private Vector3 moveOnFound | World offset added to a pickup found in the triggers. |
private LocationChunk targetChunk | Location chunk whose full load starts the check. |
Properties
1 private and internal property
| Member | What it is |
|---|
private int IBuildRendererBakeable.SortingOrder { get; } | Bake order, always 0. |
Methods
5 private and internal methods
| Member | What it is |
|---|
private void Awake() | Disables the colliders and waits for the target chunk to fully load. |
private void IBuildRendererBakeable.Bake(bool isSaving) | Empty build bake step. |
private void IBuildRendererBakeable.Clean() | Empty build clean step. |
private void EnableCheck(Chunk obj) | Turns the colliders on, then off again next frame. |
private void OnTriggerEnter(Collider other) | Moves a touched non-kinematic pickup that nobody holds by moveOnFound. |