public SimAction(SimActionType type, TimeSpan actTime, ItemData compModData) { actType = type; simInfo = null; itemData = compModData; time = actTime; }
public SimAction(SimActionType type, TimeSpan?actTime = null) { actType = type; time = actTime; if ((type == SimActionType.atTimer || type == SimActionType.atRestartAtTime) && (actTime == null)) { throw new Exception("Timer or restartAtTime actions require a time."); } simInfo = null; itemData = null; }