Skip to content

Commit

Permalink
Feedback for staffchat command
Browse files Browse the repository at this point in the history
  • Loading branch information
yitzy299 committed Apr 24, 2021
1 parent 2c4f757 commit f58b40a
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
4 changes: 2 additions & 2 deletions gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,9 @@ minecraft_version=1.16.5
yarn_mappings=1.16.5+build.5
loader_version=0.11.3
# Mod Properties
mod_version=1.0-SNAPSHOT
mod_version=1.0
maven_group=com.github.quiltservertools
archives_base_name=serverwires
archives_base_name=wires
# Dependencies
# check this on https://modmuss50.me/fabric.html
fabric_version=0.25.1+build.416-1.16
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
import com.mojang.brigadier.arguments.StringArgumentType;
import me.lucko.fabric.api.permissions.v0.Permissions;
import net.minecraft.server.command.ServerCommandSource;
import net.minecraft.text.LiteralText;

import static net.minecraft.server.command.CommandManager.argument;
import static net.minecraft.server.command.CommandManager.literal;
Expand All @@ -20,6 +21,7 @@ public static void register(CommandDispatcher<ServerCommandSource> dispatcher) {
.then(argument("message", StringArgumentType.greedyString()).executes(
ctx -> {
Wires.config.getStaffChat().sendMessage(ctx.getSource().getPlayer(), StringArgumentType.getString(ctx, "message"));
ctx.getSource().sendFeedback(new LiteralText(Wires.config.getStaffChat().isInStaffChat(ctx.getSource().getPlayer().getUuid()) ? "Joined" : "Left" + " staffchat"), false);
return 1;
}
)));
Expand Down

0 comments on commit f58b40a

Please sign in to comment.