예제 #1
0
        private IEnumerator SpillAtScrubber(Scrubber scrubber, ReagentContainer container)
        {
            yield return(WaitFor.Seconds(Random.Range(spawnDelayRange.x, spawnDelayRange.y)));

            // Check that the scrubber is still fine to reference after this delay.
            if (scrubber == null || scrubber.registerTile == null)
            {
                yield break;
            }

            var reagentMix = new ReagentMix();

            reagentMix.reagents.m_dict.Add(allReagents.PickRandom(), 75f);
            reagentMix.reagents.m_dict.Add(dispersionAgents.PickRandom(), 25f);

            container.Add(reagentMix);
            container.Spill(scrubber.registerTile.WorldPositionServer, 50f);

            // TODO: Play noise.
        }
예제 #2
0
 private void ExtinguishTile(Vector3Int worldPos)
 {
     reagentContainer.Spill(worldPos, reagentsPerUse);
 }
예제 #3
0
 void SprayTile(Vector3Int worldPos)
 {
     reagentContainer.Spill(worldPos, reagentsPerUse);
 }