Skip to content

Commit

Permalink
Update to 1.2.7: added "else" to movePlayerToDimension() and `execu…
Browse files Browse the repository at this point in the history
…te()` returns `int`
  • Loading branch information
Pedro270707 committed Jan 19, 2024
1 parent f213047 commit 80621a5
Show file tree
Hide file tree
Showing 9 changed files with 9 additions and 9 deletions.
2 changes: 1 addition & 1 deletion gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,6 @@ loader_version=0.14.19-babric.3-bta
halplibe_version=3.1.4

# Mod
mod_version=1.2.6
mod_version=1.2.7
mod_group=net.pedroricardo
mod_name=commander
6 changes: 3 additions & 3 deletions output/production/commander-bta.main/fabric.mod.json
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
{
"schemaVersion": 1,
"id": "commander",
"version": "1.2.3",
"version": "1.2.6",

"name": "Commander",
"description": "This mod overhauls the command system.",
"authors": [
"Pedro Ricardo"
],
"contact": {
"homepage": "",
"sources": ""
"homepage": "https://pedroricardo.net",
"sources": "https://github.com/Pedro270707/commander-bta"
},

"license": "CC0-1.0",
Expand Down
Binary file not shown.
Binary file not shown.
Binary file not shown.
Original file line number Diff line number Diff line change
Expand Up @@ -75,8 +75,8 @@ public void init() {
this.registerLegacyCommands();
}

public void execute(String s, CommanderCommandSource commandSource) throws CommandSyntaxException {
this.DISPATCHER.execute(s, commandSource);
public int execute(String s, CommanderCommandSource commandSource) throws CommandSyntaxException {
return this.DISPATCHER.execute(s, commandSource);
}

public CommandDispatcher<CommanderCommandSource> getDispatcher() {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ public World getWorld(int dimension) {
@Override
public void movePlayerToDimension(EntityPlayer player, int dimension) {
if (player instanceof EntityPlayerMP) this.server.playerList.sendPlayerToOtherDimension((EntityPlayerMP) player, dimension);
throw new IllegalStateException("Player is not an instance of EntityPlayerMP");
else throw new IllegalStateException("Player is not an instance of EntityPlayerMP");
}

@Override
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ public World getWorld(int dimension) {
@Override
public void movePlayerToDimension(EntityPlayer player, int dimension) {
if (player instanceof EntityPlayerMP) this.server.playerList.sendPlayerToOtherDimension((EntityPlayerMP) player, dimension);
throw new IllegalStateException("Player is not an instance of EntityPlayerMP");
else throw new IllegalStateException("Player is not an instance of EntityPlayerMP");
}

@Override
Expand Down
2 changes: 1 addition & 1 deletion src/main/resources/fabric.mod.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"schemaVersion": 1,
"id": "commander",
"version": "1.2.6",
"version": "1.2.7",

"name": "Commander",
"description": "This mod overhauls the command system.",
Expand Down

0 comments on commit 80621a5

Please sign in to comment.