private void B_Save_Click(object sender, EventArgs e) { SaveEntry(entry); EL_Ground.SaveCurrent(); EL_Water.SaveCurrent(); EL_Old.SaveCurrent(); EL_Good.SaveCurrent(); EL_Super.SaveCurrent(); EL_Sky.SaveCurrent(); Close(); }
private void B_Save_Click(object sender, EventArgs e) { SaveEntry(entry); EL_Ground.SaveCurrent(); EL_Water.SaveCurrent(); EL_Old.SaveCurrent(); EL_Good.SaveCurrent(); EL_Super.SaveCurrent(); Result = Tables.WriteJson(); // Clipboard.SetText(Result); Close(); }
private void SaveEntry(int i) { if (i < 0) { return; } var arr = Tables.EncounterTables[i]; arr.TrainerRankMin = (int)NUD_RankMin.Value; arr.TrainerRankMax = (int)NUD_RankMax.Value; arr.GroundTableLevelMin = (int)EL_Ground.NUD_Min.Value; arr.GroundTableLevelMax = (int)EL_Ground.NUD_Max.Value; arr.GroundTableEncounterRate = (int)EL_Ground.NUD_SpawnRate.Value; arr.GroundSpawnCountMax = (int)EL_Ground.NUD_Count.Value; arr.GroundSpawnDuration = (int)EL_Ground.NUD_Duration.Value; arr.WaterTableLevelMin = (int)EL_Water.NUD_Min.Value; arr.WaterTableLevelMax = (int)EL_Water.NUD_Max.Value; arr.WaterTableEncounterRate = (int)EL_Water.NUD_SpawnRate.Value; arr.WaterSpawnCountMax = (int)EL_Water.NUD_Count.Value; arr.WaterSpawnDuration = (int)EL_Water.NUD_Duration.Value; arr.OldRodTableLevelMin = (int)EL_Old.NUD_Min.Value; arr.OldRodTableLevelMax = (int)EL_Old.NUD_Max.Value; arr.OldRodTableEncounterRate = (int)EL_Old.NUD_SpawnRate.Value; arr.GoodRodTableLevelMin = (int)EL_Good.NUD_Min.Value; arr.GoodRodTableLevelMax = (int)EL_Good.NUD_Max.Value; arr.GoodRodTableEncounterRate = (int)EL_Good.NUD_SpawnRate.Value; arr.SuperRodTableLevelMin = (int)EL_Super.NUD_Min.Value; arr.SuperRodTableLevelMax = (int)EL_Super.NUD_Max.Value; arr.SuperRodTableEncounterRate = (int)EL_Super.NUD_SpawnRate.Value; arr.SkyTableLevelMin = (int)EL_Sky.NUD_Min.Value; arr.SkyTableLevelMax = (int)EL_Sky.NUD_Max.Value; arr.SkyTableEncounterRate = (int)EL_Sky.NUD_SpawnRate.Value; arr.SkySpawnCountMax = (int)EL_Sky.NUD_Count.Value; arr.SkySpawnDuration = (int)EL_Sky.NUD_Duration.Value; EL_Ground.SaveCurrent(); EL_Water.SaveCurrent(); EL_Old.SaveCurrent(); EL_Good.SaveCurrent(); EL_Super.SaveCurrent(); EL_Sky.SaveCurrent(); }