ModsJava
LoginCommand
Java mod listed for Minecraft 1.12. Download on the author's site.
⬇ Download on SpigotLoginCommand allows you to execute commands when players join your server.
Concept
The plugin uses command groups. Each group can have a number of commands. If a player has the corresponding permission node for a command group, those commands will be executed when he/she joins the server.
The commands are executed from the console. You can also execute player commands by adding the "sudo %name_of_player%" prefix to a command.
You can set a delay.
You can set a cooldown.
If you want some players to be ignored (regardless of other permissions), you can do that by giving them a permission node.
Setup instructions
1. Download the plugin.
2. Copy the plugin into your server's plugin folder.
3. Start the server.
4. Create a command group and add commands to it.
5. Give somebody the permission of the command group.
6. Further configuration:
You can find some more settings (command delay, cooldown, whether op's are exempt) in the configuration file. After making changes, issue the /logincommand reload command.
Troubleshooting
Commands
Placeholders
When you add a command and specify a placeholder, the placeholder will be replaced on every execution with its corresponding value.
Valid placeholders are:
The name of the player who joins the server:
Permissions
Example config
The effects:
Players who have the logincommand.group.group1 permission will be teleported to warp woods after 1 second of their joining, if their last login was more than 60 minutes ago.
Players with the logincommand.group.helper permission will be given 10 units of money (the same delay and cooldown applies).
Concept
The plugin uses command groups. Each group can have a number of commands. If a player has the corresponding permission node for a command group, those commands will be executed when he/she joins the server.
The commands are executed from the console. You can also execute player commands by adding the "sudo %name_of_player%" prefix to a command.
You can set a delay.
You can set a cooldown.
If you want some players to be ignored (regardless of other permissions), you can do that by giving them a permission node.
Setup instructions
1. Download the plugin.
2. Copy the plugin into your server's plugin folder.
3. Start the server.
4. Create a command group and add commands to it.
Let's say that we want to give Helpers a diamond pickaxe as an award when they join the server. We come up with a group name, "helpergifts" to store these commands.
The generalized command to add a command is:
In this case:
The generalized command to add a command is:
Code (Text):
/logincommand add <new group name> <command>
Code (Text):
/logincommand add helpergifts give %name_of_player% diamond_pickaxe
5. Give somebody the permission of the command group.
Now we have to give the permission group "Helpers" a certain permission node.
In case you use PermissionEx, the command might look like this:
In case you use PermissionEx, the command might look like this:
Code (Text):
/pex group Helper add logincommand.group.helpergifts
6. Further configuration:
You can find some more settings (command delay, cooldown, whether op's are exempt) in the configuration file. After making changes, issue the /logincommand reload command.
If the plugin doesn't work:
- Make sure that the player doesn't have the exempt permission node. See the
Permissions section.
- On default settings, operators are exempt. If you want the plugin to affect them, set the value of "ops exempt" to "false" in the configuration file, then issue the /logincommand reload command.
- On default settings, operators are exempt. If you want the plugin to affect them, set the value of "ops exempt" to "false" in the configuration file, then issue the /logincommand reload command.
Commands
Root command and aliases:
Reload the configuration file:
Code (Text):
/logincommand
Code (Text):
/lic
Code (Text):
/lc
Code (Text):
/logincommand reload
Add a command to a command group; (also auto-creates the group):
Code (Text):
/logincommand add <group> <command>
Remove a command from a command group:
Code (Text):
/logincommand remove <group> <command>
Placeholders
When you add a command and specify a placeholder, the placeholder will be replaced on every execution with its corresponding value.
Valid placeholders are:
The name of the player who joins the server:
Code (Text):
%name_of_player%
Code (Text):
logincommand.admin
description: Allows you to edit and reload the config.
default: operators
logincommand.exempt
description: The plugin will ignore your login.
default: Nobody, but if you have the * permission node (for example, your Admin group has it), Bukkit will report that you have this permission as well. Use negative permission nodes to counteract this.
logincommand.group.<group>
description: Group specific permission for command execution.
default: nobody
description: Allows you to edit and reload the config.
default: operators
logincommand.exempt
description: The plugin will ignore your login.
default: Nobody, but if you have the * permission node (for example, your Admin group has it), Bukkit will report that you have this permission as well. Use negative permission nodes to counteract this.
logincommand.group.<group>
description: Group specific permission for command execution.
default: nobody
Code (Text):
execution delay (sec): 1
login cooldown (min): 60
configversion (don't change): 2
ops exempt: true
# when the above is true, operators will be ignored
config:
group1:
- sudo <name> warp woods
helper:
- eco give <name> 10
timestamps (auto generated): []
login cooldown (min): 60
configversion (don't change): 2
ops exempt: true
# when the above is true, operators will be ignored
config:
group1:
- sudo <name> warp woods
helper:
- eco give <name> 10
timestamps (auto generated): []
Players who have the logincommand.group.group1 permission will be teleported to warp woods after 1 second of their joining, if their last login was more than 60 minutes ago.
Players with the logincommand.group.helper permission will be given 10 units of money (the same delay and cooldown applies).
Quick facts
- Edition: Minecraft Java
- File type: .jar
- Minecraft version listed: 1.12
- How to install: Install the matching mod loader (Forge, Fabric or NeoForge) for your Minecraft version. → Download the .jar. → Put it in the .minecraft/mods folder and launch that loader profile.
- Where to get it: Opens on Spigot — not every file is mirrored on our own servers.
Install steps are the general flow for this file type — How to install Minecraft Java mods & modpacks walks through it step by step.
LoginCommand is a free Minecraft Java mod. Compatible with Minecraft 1.12. Downloaded 268 times (via Spigot). Download it and open it directly in the game.