feat: Implement Minecraft-style execute command with relative positioning (#1864)

* Initial plan

* Implement Minecraft-style execute command

Co-authored-by: aronwk-aaron <26027722+aronwk-aaron@users.noreply.github.com>

* Add relative positioning support to execute command using ~ syntax

Co-authored-by: aronwk-aaron <26027722+aronwk-aaron@users.noreply.github.com>

* update the parsing and fix chat response

---------

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: aronwk-aaron <26027722+aronwk-aaron@users.noreply.github.com>
Co-authored-by: Aaron Kimbrell <aronwk.aaron@gmail.com>
This commit is contained in:
Copilot
2025-09-08 22:35:18 -07:00
committed by GitHub
parent 6d3bf2fdc3
commit 154112050f
4 changed files with 188 additions and 16 deletions

View File

@@ -808,6 +808,15 @@ void SlashCommandHandler::Startup() {
};
RegisterCommand(DeleteInvenCommand);
Command ExecuteCommand{
.help = "Execute commands with modified context (Minecraft-style)",
.info = "Execute commands as different entities or from different positions. Usage: /execute <subcommand> ... run <command>. Subcommands: as <entity>, at <entity>, positioned <x> <y> <z>",
.aliases = { "execute", "exec" },
.handle = DEVGMCommands::Execute,
.requiredLevel = eGameMasterLevel::DEVELOPER
};
RegisterCommand(ExecuteCommand);
// Register Greater Than Zero Commands
Command KickCommand{