Backport to 1.18.2
This commit is contained in:
parent
ed20b4f5fb
commit
8eb93ff176
32 changed files with 276 additions and 242 deletions
|
@ -33,7 +33,12 @@ public class HomeCommand {
|
|||
|
||||
private static int home(CommandSourceStack ctx, String homeName)
|
||||
{
|
||||
var exec = new CommandExecutionEvent(ctx.getPlayer(), "home");
|
||||
CommandExecutionEvent exec = null;
|
||||
try {
|
||||
exec = new CommandExecutionEvent(ctx.getPlayerOrException(), "home");
|
||||
} catch (CommandSyntaxException e) {
|
||||
throw new RuntimeException(e);
|
||||
}
|
||||
if(MinecraftForge.EVENT_BUS.post(exec))
|
||||
{
|
||||
return 0;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue