private void Panel_WellChange(RuneType rune, RunePower power, bool wellIncrease) { double value = rune.GetWeigth(power) * (wellIncrease ? 1 : -1); ppWellValue += value; oOnWellChange(); }
public static RuneType IdentifyRune(String msg) { List <RuneType> runes = RunesTypes.GetRuneTypes(); RuneType ret = runes.Find(r => msg.ToUpper().Contains(r.Stat.GetNiceName().ToUpper())); return(ret); }
public void ShowRune(RuneType rune) { ppRune = rune; picImage.Image = ppRune.Image; lblName.Text = ppRune.Name; lblNormalValue.Text = ppRune.GetWeigth(RunePower.Normal).ToString(); lblPaValue.Text = ppRune.GetWeigth(RunePower.Pa).ToString(); lblPaValue.Visible = ppRune.HasPa; btnPa.Visible = ppRune.HasPa; lblRaValue.Text = ppRune.GetWeigth(RunePower.Ra).ToString(); lblRaValue.Visible = ppRune.HasRa; btnRa.Visible = ppRune.HasRa; }
public static double ParseReliquat(String message) { List <String> split = message.Split(',').ToList(); double wellValue = 0; foreach (String s in split) { String stat = s.Trim(); RuneType rune = IdentifyRune(stat); Int32 val = ExtractNumber(stat); if (rune != null) { wellValue -= rune.UnitWeight * val; } } return(wellValue); }
protected void oOnWellChange(RuneType rune, RunePower power, Boolean wellIncrease) { WellChange(rune, power, wellIncrease); }