public void ApplySavedData(ActiveBonusMassSaver.ViewData viewData) { if (viewData != null) { this.DecayProperties._decayDoneTime = viewData._floatValue1; this.SetDecayState((DecayingInventoryItemView.DecayStates)viewData._intValue1); } else { this.DecayProperties._decayDoneTime = 0f; this.DecayProperties._state = DecayingInventoryItemView.DecayStates.None; } }
public void InitDataToSave(ActiveBonusMassSaver.ViewData viewData) { viewData._intValue1 = (int)this.DecayProperties._state; viewData._floatValue1 = (float)((int)this.DecayProperties._decayDoneTime); }