public static void Do(Act act) { if (act.IsNoOp()) { return; } if (act.CanBatch() && (batch.Count == 0 || batch.Peek().GetType() == act.GetType())) { batch.Push(act); act.Do(); batchTime = Time.time + .5f; } else { if (batch.Count > 0) { DoBatch(); } act.Do(); if (act.CanUndo()) { undos.Push(act); redos.Clear(); } } width = use.tile.GetWidth(); height = use.tile.GetHeight(); depth = use.tile.GetDepth(); }