Skip to content
This repository was archived by the owner on Apr 27, 2019. It is now read-only.

Commit c0737b2

Browse files
AMorporkianMarv Cool
authored andcommitted
Added planet protection and planet tracking. A /who'ish command called /planet for players on your current planet.
1 parent be8da30 commit c0737b2

1 file changed

Lines changed: 4 additions & 4 deletions

File tree

plugins/admin_commands_plugin/admin_command_plugin.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
from base_plugin import SimpleCommandPlugin
22
from core_plugins.player_manager import permissions, UserLevels
3-
import packets
43
from utility_functions import give_item_to_player
54

65

@@ -10,7 +9,7 @@ class UserCommandPlugin(SimpleCommandPlugin):
109
"""
1110
name = "user_management_commands"
1211
depends = ['command_dispatcher', 'player_manager']
13-
commands = ["who", "whois", "promote", "kick", "ban", "kickban", "give_item"]
12+
commands = ["who", "whois", "promote", "kick", "ban", "kickban", "give_item", "planet"]
1413
auto_activate = True
1514

1615
def activate(self):
@@ -53,8 +52,9 @@ def whois(self, data):
5352
info = self.player_manager.whois(name)
5453
if info:
5554
self.protocol.send_chat_message(
56-
"Name: %s\nUserlevel: %s\nUUID: %s\nIP address: %s""" % (
57-
info.colored_name(self.config.colors), UserLevels(info.access_level), info.uuid, info.ip))
55+
"Name: %s\nUserlevel: %s\nUUID: %s\nIP address: %s\nCurrent planet: %s""" % (
56+
info.colored_name(self.config.colors), UserLevels(info.access_level), info.uuid, info.ip,
57+
info.planet))
5858
else:
5959
self.protocol.send_chat_message("Player not found!")
6060
return False

0 commit comments

Comments
 (0)