public GrowSimulator BuildSim() { uint uid = UnitForm.GetUnitIDWhereSupportClass((uint)this.AddressList.SelectedIndex); GrowSimulator sim = new GrowSimulator(); UnitForm.GetSim(ref sim , uid //支援クラス ); sim.SetClassBase( (int)B11.Value //hp , (int)B12.Value //str , (int)B13.Value //skill , (int)B14.Value //spd , (int)B15.Value //def , (int)B16.Value //res , 0 //magic extends ); sim.SetClassGrow( (int)B27.Value //hp , (int)B28.Value //str , (int)B29.Value //skill , (int)B30.Value //spd , (int)B31.Value //def , (int)B32.Value //res , (int)B33.Value //luck , 0 //magic extends ); return(sim); }
public void SetParam(uint lv, uint grow, uint unitid, uint classid) { if (classid == 0) { classid = UnitForm.GetUnitIDWhereSupportClass(unitid); } GrowSimulator sim = new GrowSimulator(); UnitForm.SetSimUnit(ref sim, unitid); ClassForm.SetSimClass(ref sim, classid); if (UnitForm.isHighClass(unitid) || ClassForm.isHighClass(classid)) { lv += 10; } GrowSimulator.GrowOptionEnum growOption = GrowSimulator.GrowOptionEnum.None; if (grow == 1) { growOption = GrowSimulator.GrowOptionEnum.ClassGrow; sim.SetUnitLv1(); } sim.Grow((int)lv, growOption); U.SelectedIndexSafety(X_SIM_HP, sim.sim_hp); U.SelectedIndexSafety(X_SIM_STR, sim.sim_str); U.SelectedIndexSafety(X_SIM_SKILL, sim.sim_skill); U.SelectedIndexSafety(X_SIM_SPD, sim.sim_spd); U.SelectedIndexSafety(X_SIM_DEF, sim.sim_def); U.SelectedIndexSafety(X_SIM_RES, sim.sim_res); U.SelectedIndexSafety(X_SIM_LUCK, sim.sim_luck); U.SelectedIndexSafety(X_SIM_MAGICEX_Value, sim.sim_ext_magic); }