mirror of
https://github.com/kwsch/pkNX.git
synced 2026-10-02 14:16:55 -05:00
Sync missing changes
yay unsaved content
This commit is contained in:
@@ -542,6 +542,14 @@ private void B_Save_Click(object sender, EventArgs e)
|
||||
private void B_Randomize_Click(object sender, EventArgs e)
|
||||
{
|
||||
SaveEntry();
|
||||
var trand = GetRandomizer();
|
||||
trand.Execute();
|
||||
LoadEntry();
|
||||
System.Media.SystemSounds.Asterisk.Play();
|
||||
}
|
||||
|
||||
private TrainerRandomizer GetRandomizer()
|
||||
{
|
||||
var moves = Game.Data.MoveData.LoadAll();
|
||||
var rmove = new MoveRandomizer(Game.Info, moves, Personal);
|
||||
int[] banned = Legal.GetBannedMoves(Game.Info.Game, moves.Length);
|
||||
@@ -559,7 +567,24 @@ private void B_Randomize_Click(object sender, EventArgs e)
|
||||
GetBlank = () => new TrainerPoke7b(), // this should probably be less specific
|
||||
};
|
||||
trand.Initialize((TrainerRandSettings)PG_RTrainer.SelectedObject);
|
||||
trand.Execute();
|
||||
return trand;
|
||||
}
|
||||
|
||||
private void B_Boost_Click(object sender, EventArgs e)
|
||||
{
|
||||
SaveEntry();
|
||||
var trand = GetRandomizer();
|
||||
var settings = (TrainerRandSettings)PG_RTrainer.SelectedObject;
|
||||
trand.ModifyAllPokemon(pk => TrainerRandomizer.BoostLevel(pk, settings.LevelBoostRatio));
|
||||
LoadEntry();
|
||||
System.Media.SystemSounds.Asterisk.Play();
|
||||
}
|
||||
|
||||
private void B_MaxAI_Click(object sender, EventArgs e)
|
||||
{
|
||||
SaveEntry();
|
||||
var trand = GetRandomizer();
|
||||
trand.ModifyAllTrainers(TrainerRandomizer.MaximizeAIFlags);
|
||||
LoadEntry();
|
||||
System.Media.SystemSounds.Asterisk.Play();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user