small tweak to restart and runas command
This commit is contained in:
parent
5f5c0f1cfb
commit
fb82cbe6f2
@ -54,11 +54,10 @@ namespace SharedLibraryCore.Commands
|
|||||||
RequiresTarget = false;
|
RequiresTarget = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
public override Task ExecuteAsync(GameEvent E)
|
public override async Task ExecuteAsync(GameEvent gameEvent)
|
||||||
{
|
{
|
||||||
E.Owner.Manager.Restart();
|
await gameEvent.Owner.Manager.Restart();
|
||||||
E.Origin.Tell(_translationLookup["COMMANDS_RESTART_SUCCESS"]);
|
gameEvent.Origin.Tell(_translationLookup["COMMANDS_RESTART_SUCCESS"]);
|
||||||
return Task.CompletedTask;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -63,9 +63,8 @@ namespace SharedLibraryCore.Commands
|
|||||||
.SelectMany(ev => ev.Value.Output)
|
.SelectMany(ev => ev.Value.Output)
|
||||||
.ToList();
|
.ToList();
|
||||||
|
|
||||||
foreach (var output in responses)
|
await gameEvent.Origin.TellAsync(responses.Select(output =>
|
||||||
await gameEvent.Origin.Tell(_translationLookup["COMMANDS_RUN_AS_SUCCESS"].FormatExt(output))
|
_translationLookup["COMMANDS_RUN_AS_SUCCESS"].FormatExt(output)));
|
||||||
.WaitAsync();
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
Loading…
Reference in New Issue
Block a user