Skip to content

Commit

Permalink
MM用のTAGを追加
Browse files Browse the repository at this point in the history
  • Loading branch information
Arisa9006 committed Sep 3, 2024
1 parent e255d21 commit b5be46b
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 10 deletions.
4 changes: 4 additions & 0 deletions src/main/java/net/azisaba/lgw/core/MatchManager.java
Original file line number Diff line number Diff line change
Expand Up @@ -805,6 +805,10 @@ private void setUpPlayer(Player p, BattleTeam team) {
p.getActivePotionEffects().forEach(potionEffect -> p.removePotionEffect(potionEffect.getType()));
// 防具を装備
p.getInventory().setChestplate(chestplates.get(team));
// 別pl用のtagを付与。
p.removeScoreboardTag("red");
p.removeScoreboardTag("blue");
p.addScoreboardTag(team.getEngTeamName());
}

/**
Expand Down
18 changes: 8 additions & 10 deletions src/main/java/net/azisaba/lgw/core/util/BattleTeam.java
Original file line number Diff line number Diff line change
Expand Up @@ -16,33 +16,31 @@
*/
public enum BattleTeam {

RED("赤チーム", Color.fromRGB(0x930000), ChatColor.DARK_RED, NamedTextColor.DARK_RED),
BLUE("青チーム", Color.fromRGB(0x0000A0), ChatColor.BLUE, NamedTextColor.BLUE);
RED("赤チーム", Color.fromRGB(0x930000), ChatColor.DARK_RED, NamedTextColor.DARK_RED , "red"),
BLUE("青チーム", Color.fromRGB(0x0000A0), ChatColor.BLUE, NamedTextColor.BLUE, "blue");

private final String name;
@Getter
private final Color color;
@Getter
private final ChatColor chatColor;
private final NamedTextColor namedtextcolor;
@Getter
private final String engTeamName;


BattleTeam(String name, Color color, ChatColor chatColor, NamedTextColor namedtextcolor) {
BattleTeam(String name, Color color, ChatColor chatColor, NamedTextColor namedtextcolor, String engTeamName) {
this.name = name;
this.color = color;
this.chatColor = chatColor;
this.namedtextcolor = namedtextcolor;
this.engTeamName = engTeamName;
}

public String getTeamName() {
return chatColor + name;
}

public ChatColor getChatColor() {
return chatColor;
}

public Color getColor() {
return color;
}
public NamedTextColor getNamedTextColor() {
return namedtextcolor;
}
Expand Down

0 comments on commit b5be46b

Please sign in to comment.