public void Apply() { foreach (InteractionTuning tuning in InteractionTuning.sAllTunings.Values) { ITUNSettings setting = GetSettings(tuning, false); if (setting == null) { continue; } setting.Apply(Key, tuning); } for (int i = mTunables.Count - 1; i >= 0; i--) { TunableStore setting = mTunables[i]; if (!setting.Valid) { mTunables.RemoveAt(i); } else { setting.Apply(Key); } } List <string> remove = new List <string>(); foreach (ActionDataSetting setting in mActionData.Values) { ActionData data = ActionData.Get(setting.mName); if (data != null) { setting.Apply(Key, data); } else { remove.Add(setting.mName); } } foreach (string key in remove) { mActionData.Remove(key); } }
public void SetValue(SettingsKey key, object value) { TunableStore store = GetParentStore(new ValueStore(mField, value)); store.Apply(key); Retuner.SeasonSettings.AddTunable(store, true); }