]> Git Server - utils.git/commitdiff
1.3.1
authorRobin Cheney <cheneyr@eternal.ddnss.de>
Tue, 25 Nov 2025 08:48:14 +0000 (09:48 +0100)
committerRobin Cheney <cheneyr@eternal.ddnss.de>
Tue, 25 Nov 2025 08:48:14 +0000 (09:48 +0100)
pom.xml
src/main/java/de/ddnss/eternal/utils/io/input/Command.java
src/main/java/de/ddnss/eternal/utils/io/input/GenericCommand.java
src/main/java/de/ddnss/eternal/utils/io/input/user/CMDCommands.java

diff --git a/pom.xml b/pom.xml
index 05f6ab6f03fa144736e9295992e1c456d96d8f6a..d4942793791b7af397b30069e78244f08c062224 100644 (file)
--- a/pom.xml
+++ b/pom.xml
@@ -6,7 +6,7 @@
 
     <groupId>de.ddnss.eternal.utils</groupId>
     <artifactId>utils</artifactId>
-    <version>1.3</version>
+    <version>1.3.1</version>
 
     <properties>
         <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
index 7eef2c5ae07c93f25a6d85f9ddb0cc3c93af9f9f..2164f0c162d5f087134416eb19376d8a629fb554 100644 (file)
@@ -75,6 +75,19 @@ public class Command {
         return this;
     };
 
+    /**
+     * Binds arguments to the command
+     * 
+     * @param key   HashMap key
+     * @param value HashMap value
+     * @return the {@link Command} object itself
+     * @since 1.3.1
+     */
+    public Command bindArguments(String key, String value) {
+        this.arguments.put(key, value);
+        return this;
+    };
+
     /**
      * Executes a command with a {@link GenericCommandOption}
      * 
index e6ebe379a2af2c3444d2059c114592b894aa137e..b2e056da3011302a415348254aae53b9cf2f0da4 100644 (file)
@@ -75,6 +75,19 @@ public class GenericCommand<E> {
         return this;
     };
 
+    /**
+     * Binds arguments to the command
+     * 
+     * @param key   HashMap key
+     * @param value HashMap value
+     * @return the {@link Command} object itself
+     * @since 1.3.1
+     */
+    public GenericCommand<E> bindArguments(String key, E value) {
+        this.arguments.put(key, value);
+        return this;
+    };
+
     /**
      * Executes a command with a {@link GenericCommandOption}
      * 
index eda694e475fd3b5e39de59c32a9f142cca7246e4..bf6e9beb46c8e2307261002c72c3f3509b6538d3 100644 (file)
@@ -45,7 +45,7 @@ public class CMDCommands {
                 break;
             }
 
-            command.getCommand().bindArguments(new CommandOption("SAY", parts[0])).exec();
+            command.getCommand().bindArguments(new CommandOption()).exec();
         }
     }
 }