public EventCommandChangeLevel(ChangeLevelCommand refCommand, FrmEvent editor)
        {
            InitializeComponent();
            mMyCommand   = refCommand;
            mEventEditor = editor;
            if (mMyCommand.Level <= 0 || mMyCommand.Level > Options.MaxLevel)
            {
                mMyCommand.Level = 1;
            }

            nudLevel.Maximum = Options.MaxLevel;
            nudLevel.Value   = mMyCommand.Level;
            InitLocalization();
        }
        public async Task <ActionResult> ChangeLevel(ChangeLevelCommand command)
        {
            await _commandDispatcher.SendAsync <ChangeLevelCommand>(command);

            return(Ok());
        }
Ejemplo n.º 3
0
 private static string GetCommandText(ChangeLevelCommand command, MapInstance map)
 {
     return(Strings.EventCommandList.setlevel.ToString(command.Level));
 }