Пример #1
0
 public void AddVariableModPosition(int id, string position)
 {
     VariableMod mod;
     if (!_variableModMap.ContainsKey(id)){
         mod = new VariableMod(id);
         _variableModMap.Add(id, mod);
         mod.Position = position;
     }
     else{
         mod = _variableModMap[id];
         mod.Position = position;
     }
 }
Пример #2
0
 public void AddVariableModSite(int id, string site)
 {
     VariableMod mod;
     if (!_variableModMap.ContainsKey(id)){
         mod = new VariableMod(id);
         _variableModMap.Add(id, mod);
         mod.Site = site;
     }
     else{
         mod = _variableModMap[id];
         mod.Site = site;
     }
 }
Пример #3
0
        public bool AddVariableModParam(int id, Param param)
        {
            VariableMod mod;
            if (_variableModMap.ContainsKey(id)){
                mod = _variableModMap[id];
                if (mod.Param != null){
                    return false;
                }
                mod.Param = param;
                return true;
            }
            mod = new VariableMod(id);
            _variableModMap.Add(id, mod);

            mod.Param = param;
            return true;
        }