void LabourResult() { int x = (int)workflow; float production = x; if (dig) { production = workObject.Dig(x, true); GameMaster.geologyModule.CalculateOutput(production, workObject, GameMaster.colonyController.storage); } else { production = GameMaster.colonyController.storage.GetResources(mainResource, production); if (production != 0) { production = workObject.PourIn((int)production); if (production == 0) { StopWork(); return; } } } workflow -= production; if (dig) { actionLabel = Localization.GetActionLabel(LocalizationActionLabels.DigInProgress) + " (" + ((int)((1 - (float)workObject.volume / (float)CubeBlock.MAX_VOLUME) * 100)).ToString() + "%)"; } else { actionLabel = Localization.GetActionLabel(LocalizationActionLabels.PouringInProgress) + " (" + ((int)(((float)workObject.volume / (float)CubeBlock.MAX_VOLUME) * 100)).ToString() + "%)"; } }
override protected void LabourResult() { int x = (int)workflow; float production = x; production = workObject.Dig(x, false); GameMaster.geologyModule.CalculateOutput(production, workObject, GameMaster.colonyController.storage); if (workObject != null & workObject.volume != 0) { float percent = workObject.volume / (float)CubeBlock.MAX_VOLUME; if (showOnGUI) { workbuildingObserver.SetActionLabel(string.Format("{0:0.##}", (1 - percent) * 100) + "% " + Localization.GetActionLabel(LocalizationActionLabels.Extracted)); } workflow -= production; } else { workFinished = true; if (showOnGUI) { workbuildingObserver.SetActionLabel(Localization.GetActionLabel(LocalizationActionLabels.WorkStopped)); } awaitingElevatorBuilding = true; } }
void LabourResult() { int x = (int)workflow; float production = x; production = workObject.Dig(x, false); if (workObject == null) { StopWork(); return; } GameMaster.geologyModule.CalculateOutput(production, workObject, GameMaster.colonyController.storage); workflow -= production; actionLabel = Localization.GetActionLabel(LocalizationActionLabels.DigInProgress) + " (" + ((int)(((float)workObject.volume / (float)CubeBlock.MAX_VOLUME) * 100)).ToString() + "%)"; }