Skip to content

Commit

Permalink
add nonbinary gender
Browse files Browse the repository at this point in the history
  • Loading branch information
Connorppeach committed Nov 29, 2023
1 parent 803095d commit 471b586
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 3 deletions.
1 change: 1 addition & 0 deletions src/com/dogonfire/gods/commands/CommandHelp.java
Original file line number Diff line number Diff line change
Expand Up @@ -129,6 +129,7 @@ private void helpAltar(CommandSender sender)
sender.sendMessage(ChatColor.WHITE + " 1 - Place a block");
sender.sendMessage(ChatColor.WHITE + " 2a - Place a torch on top for a male god");
sender.sendMessage(ChatColor.WHITE + " 2b - Place a redstone torch on top for a female god");
sender.sendMessage(ChatColor.WHITE + " 2c - Place a soul torch on top for a nonbinary god");
sender.sendMessage(ChatColor.WHITE + " 3 - Place a sign on the side of the block");
sender.sendMessage(ChatColor.WHITE + " 4 - Write the name of your God on the sign");
sender.sendMessage("");
Expand Down
6 changes: 5 additions & 1 deletion src/com/dogonfire/gods/managers/AltarManager.java
Original file line number Diff line number Diff line change
Expand Up @@ -165,6 +165,10 @@ public GodManager.GodGender getGodGenderFromAltarBlock(Block block)
{
return GodManager.GodGender.Female;
}
if (block.getRelative(BlockFace.UP).getType().equals(Material.SOUL_TORCH))
{
return GodManager.GodGender.Nonbinary;
}
return GodManager.GodGender.Male;
}

Expand Down Expand Up @@ -580,4 +584,4 @@ public void setAltarBlockTypeForGodType(GodType godType, Material blockMaterial)

this.altarBlockTypes.put(blockMaterial, godTypes);
}
}
}
5 changes: 4 additions & 1 deletion src/com/dogonfire/gods/managers/GodManager.java
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@
public class GodManager
{
public static enum GodGender {
None, Male, Female;
None, Male, Female, Nonbinary;
}

public static enum GodMood {
Expand Down Expand Up @@ -1257,6 +1257,9 @@ public String getLanguageFileForGod(String godName)
case 1:
godGender = GodGender.Female;
break;
case 2:
godGender = GodGender.Nonbinary;
break;
}
}

Expand Down
2 changes: 1 addition & 1 deletion src/com/dogonfire/gods/managers/LanguageManager.java
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ private LanguageManager()

private void downloadLanguageFile(String fileName) throws IOException
{
BufferedInputStream in = new BufferedInputStream(new URL("https://raw.githubusercontent.com/DogOnFire/Gods/master/lang/" + fileName).openStream());
BufferedInputStream in = new BufferedInputStream(new URL("https://raw.githubusercontent.com/Connorppeach/Gods/master/lang/" + fileName).openStream());

FileOutputStream fos = new FileOutputStream(Gods.instance().getDataFolder() + "/lang/" + fileName);

Expand Down

0 comments on commit 471b586

Please sign in to comment.