mirror of
https://github.com/jie65535/GrasscutterCommandGenerator.git
synced 2025-06-11 23:49:14 +08:00
Update FormMain.cs
This commit is contained in:
parent
bb13d47ea9
commit
ac022b377e
@ -720,16 +720,21 @@ namespace GrasscutterTools.Forms
|
||||
AvatarInputChanged();
|
||||
}
|
||||
|
||||
private void NUDAvatarConstellation_ValueChanged(object sender, EventArgs e)
|
||||
{
|
||||
AvatarInputChanged();
|
||||
}
|
||||
|
||||
private void AvatarInputChanged()
|
||||
{
|
||||
if (CmbAvatar.SelectedIndex >= 0)
|
||||
GenAvatar(GameData.Avatars.Ids[CmbAvatar.SelectedIndex], (int)NUDAvatarLevel.Value);
|
||||
GenAvatar(GameData.Avatars.Ids[CmbAvatar.SelectedIndex], (int)NUDAvatarLevel.Value, (int)NUDAvatarConstellation.Value);
|
||||
}
|
||||
|
||||
private void GenAvatar(int avatarId, int level)
|
||||
private void GenAvatar(int avatarId, int level, int constellation)
|
||||
{
|
||||
if (ChkNewCommand.Checked)
|
||||
SetCommand("/give", $"{avatarId} lv{level}");
|
||||
SetCommand("/give", $"{avatarId} lv{level} c{constellation}");
|
||||
else
|
||||
SetCommand("/givechar", $"{avatarId} {level}");
|
||||
}
|
||||
@ -942,24 +947,6 @@ namespace GrasscutterTools.Forms
|
||||
LblStatPercent.Visible = stat.Percent;
|
||||
LblStatTip.Text = stat.Tip;
|
||||
|
||||
if (CmbStat.SelectedIndex == 3 && CmbLanguage.SelectedIndex != 0)
|
||||
{
|
||||
GrpSetStats.Left = 19;
|
||||
GrpSetStats.Width = 560;
|
||||
CmbStat.Left = 160;
|
||||
NUDStat.Left = 324;
|
||||
LblStatTip.Left = 0;
|
||||
|
||||
}
|
||||
else
|
||||
{
|
||||
GrpSetStats.Left = 135;
|
||||
GrpSetStats.Width = 332;
|
||||
CmbStat.Left = 43;
|
||||
NUDStat.Left = 207;
|
||||
LblStatTip.Left = 40;
|
||||
}
|
||||
|
||||
SetCommand("/setstats", $"{stat.ArgName} {NUDStat.Value}{(stat.Percent ? "%" : "")}");
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user