Skip to content

Commit

Permalink
Clear player's team if they are moving in unknown dimension
Browse files Browse the repository at this point in the history
  • Loading branch information
NikitaCartes committed Jan 28, 2024
1 parent 7fc9abd commit fe726ac
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 1 addition & 1 deletion gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ yarn_mappings=1.20.2+build.1
loader_version=0.14.22

# Mod Properties
mod_version=1.2.0
mod_version=1.3.0
maven_group=xyz.nikitacartes
archives_base_name=dimensionalTracker

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,8 @@ private void onServerTick(MinecraftServer server) {
Team team = server.getScoreboard().getTeam("dimTracker." + player.getServerWorld().getRegistryKey().getValue().getPath());
if (team != null) {
scoreboard.addPlayerToTeam(playerName, team);
} else if (playerTeam != null) {
scoreboard.removePlayerFromTeam(playerName, scoreboard.getPlayerTeam(playerName));
}
}
}
Expand Down

0 comments on commit fe726ac

Please sign in to comment.