mirror of
https://github.com/kwsch/NHSE.git
synced 2026-04-19 23:17:24 -05:00
Update MuseumEditor.cs
This commit is contained in:
parent
d22ac35f73
commit
199e57ec6d
|
|
@ -37,7 +37,7 @@ private void B_Save_Click(object sender, EventArgs e)
|
|||
|
||||
private void LB_Counts_SelectedIndexChanged(object sender, EventArgs e)
|
||||
{
|
||||
if (LB_Donations.SelectedIndex < 0)
|
||||
if (LB_Donations.SelectedIndex < 0 || Changing)
|
||||
return;
|
||||
|
||||
SaveIndex(Index);
|
||||
|
|
@ -73,7 +73,14 @@ private void SaveIndex(in int index)
|
|||
SetNameForIndex(index);
|
||||
}
|
||||
|
||||
private void SetNameForIndex(in int index) => LB_Donations.Items[index] = Editor.GetDonationText(GameInfo.Strings, index);
|
||||
private bool Changing;
|
||||
|
||||
private void SetNameForIndex(in int index)
|
||||
{
|
||||
Changing = true;
|
||||
LB_Donations.Items[index] = Editor.GetDonationText(GameInfo.Strings, index);
|
||||
Changing = false;
|
||||
}
|
||||
|
||||
private void B_Dump_Click(object sender, EventArgs e)
|
||||
{
|
||||
|
|
@ -94,7 +101,7 @@ private void B_Load_Click(object sender, EventArgs e)
|
|||
private void B_GiveAll_Click(object sender, EventArgs e)
|
||||
{
|
||||
SaveIndex(Index);
|
||||
Editor.GiveAll(GameInfo.GetStrings("en").itemlist);
|
||||
Editor.GiveAll(GameInfo.GetStrings("en").itemlist, 1000);
|
||||
Editor.Save();
|
||||
System.Media.SystemSounds.Asterisk.Play();
|
||||
DialogResult = DialogResult.OK;
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user