mirror of
https://github.com/jie65535/GrasscutterCommandGenerator.git
synced 2025-06-16 00:39:14 +08:00
Added a feature for give all characters
In fact, it is to fix the constellation function error...
This commit is contained in:
parent
daa883a96c
commit
608cd86981
@ -723,25 +723,27 @@ 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, (int)NUDAvatarConstellation.Value);
|
||||
GenAvatar(GameData.Avatars.Ids[CmbAvatar.SelectedIndex], (int)NUDAvatarLevel.Value);
|
||||
}
|
||||
|
||||
private void GenAvatar(int avatarId, int level, int constellation)
|
||||
private void GenAvatar(int avatarId, int level)
|
||||
{
|
||||
if (ChkNewCommand.Checked)
|
||||
SetCommand("/give", $"{avatarId} lv{level} c{constellation}");
|
||||
SetCommand("/give", $"{avatarId} lv{level}");
|
||||
else
|
||||
SetCommand("/givechar", $"{avatarId} {level}");
|
||||
}
|
||||
|
||||
private void BtnGiveAllChar_Click(object sender, EventArgs e)
|
||||
{
|
||||
var level = NUDAvatarLevel.Value;
|
||||
var constellation = NUDAvatarConstellation.Value;
|
||||
SetCommand("/give avatars", $"lv{level} c{constellation}");
|
||||
}
|
||||
|
||||
#endregion - 角色 -
|
||||
|
||||
#region - 生成 -
|
||||
|
Loading…
Reference in New Issue
Block a user