static internal TBAGW.KeyValuePair <Type, int> getStat(String statName) { LuaStat temp = new LuaStat(statName, 5); LuaStatEdit coll = new LuaStatEdit(); coll.modifyStats.Add(temp); STATChart sc = coll.ExtractStatChart(); for (int i = 0; i < sc.currentActiveStats.Count; i++) { if (sc.currentActiveStats[i] != 0) { return(new TBAGW.KeyValuePair <Type, int>(typeof(STATChart.ACTIVESTATS), i)); } } for (int i = 0; i < sc.currentPassiveStats.Count; i++) { if (sc.currentPassiveStats[i] != 0) { return(new TBAGW.KeyValuePair <Type, int>(typeof(STATChart.PASSIVESTATS), i)); } } for (int i = 0; i < sc.currentSpecialStats.Count; i++) { if (sc.currentSpecialStats[i] != 0) { return(new TBAGW.KeyValuePair <Type, int>(typeof(STATChart.SPECIALSTATS), i)); } } return(new TBAGW.KeyValuePair <Type, int>(null, 0)); }
public TBAGW.STATChart ExtractStatChart(LuaStatEdit lse) { TBAGW.STATChart temp = new TBAGW.STATChart(true); foreach (var item in lse.modifyStats) { TryExtractActiveStats(ref temp, item); TryExtractPassiveStats(ref temp, item); TryExtractSpecialStats(ref temp, item); } // ActivePassiveStatsEqual(ref temp); return(temp); }