mirror of
https://github.com/Samsuik/Sakura.git
synced 2025-12-22 16:29:16 +00:00
Move messages into their own configuration part
This commit is contained in:
@@ -61,7 +61,7 @@ index 0000000000000000000000000000000000000000..65f7f7dee78e352bdc88ff42714d1058
|
||||
+}
|
||||
diff --git a/src/main/java/me/samsuik/sakura/command/subcommands/VisualCommand.java b/src/main/java/me/samsuik/sakura/command/subcommands/VisualCommand.java
|
||||
new file mode 100644
|
||||
index 0000000000000000000000000000000000000000..edb3733a15687fadbf25e6f69274fab6b91508c3
|
||||
index 0000000000000000000000000000000000000000..2931294d1063eb78b43f637269b27c257726b0ff
|
||||
--- /dev/null
|
||||
+++ b/src/main/java/me/samsuik/sakura/command/subcommands/VisualCommand.java
|
||||
@@ -0,0 +1,43 @@
|
||||
@@ -102,7 +102,7 @@ index 0000000000000000000000000000000000000000..edb3733a15687fadbf25e6f69274fab6
|
||||
+
|
||||
+ // Send message to player
|
||||
+ String state = visibility.isEnabled(this.type) ? "Enabled" : "Disabled";
|
||||
+ player.sendRichMessage(GlobalConfiguration.get().fps.message,
|
||||
+ player.sendRichMessage(GlobalConfiguration.get().messages.fpsSettingChange,
|
||||
+ Placeholder.unparsed("name", this.type.friendlyName()),
|
||||
+ Placeholder.unparsed("state", state)
|
||||
+ );
|
||||
@@ -110,7 +110,7 @@ index 0000000000000000000000000000000000000000..edb3733a15687fadbf25e6f69274fab6
|
||||
+}
|
||||
diff --git a/src/main/java/me/samsuik/sakura/player/visibility/VisibilityGUI.java b/src/main/java/me/samsuik/sakura/player/visibility/VisibilityGUI.java
|
||||
new file mode 100644
|
||||
index 0000000000000000000000000000000000000000..6f74429456e78f17fa3e4426d9d9b5f008d8df42
|
||||
index 0000000000000000000000000000000000000000..049befac3219413be44c0a56f7b930a2eb55cee9
|
||||
--- /dev/null
|
||||
+++ b/src/main/java/me/samsuik/sakura/player/visibility/VisibilityGUI.java
|
||||
@@ -0,0 +1,123 @@
|
||||
@@ -142,7 +142,7 @@ index 0000000000000000000000000000000000000000..6f74429456e78f17fa3e4426d9d9b5f0
|
||||
+ int row = (i + 1) / 9;
|
||||
+
|
||||
+ Material background = column > 0 && column < 8 ? (row > 0 && row < 4 || column > 1 && column < 7)
|
||||
+ ? Material.matchMaterial(GlobalConfiguration.get().fps.material)
|
||||
+ ? GlobalConfiguration.get().fps.material
|
||||
+ : Material.WHITE_STAINED_GLASS_PANE
|
||||
+ : Material.BLACK_STAINED_GLASS_PANE;
|
||||
+
|
||||
@@ -226,7 +226,7 @@ index 0000000000000000000000000000000000000000..6f74429456e78f17fa3e4426d9d9b5f0
|
||||
+ String state = visibility.isEnabled(setting) ? "Enabled" : "Disabled";
|
||||
+
|
||||
+ // Send message to player
|
||||
+ player.sendRichMessage(GlobalConfiguration.get().fps.message,
|
||||
+ player.sendRichMessage(GlobalConfiguration.get().messages.fpsSettingChange,
|
||||
+ Placeholder.unparsed("name", setting.friendlyName()),
|
||||
+ Placeholder.unparsed("state", state)
|
||||
+ );
|
||||
|
||||
Reference in New Issue
Block a user