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

Commit b8ec182

Browse files
committed
Documented all plugins in README.md, and updated a few other portions where appropriate. Nearly ready for release of v0.1.0, Happy Kangaroo.
1 parent 5a0f88c commit b8ec182

1 file changed

Lines changed: 94 additions & 2 deletions

File tree

README.md

Lines changed: 94 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,16 +16,108 @@ With the built-in plugins (which are removable):
1616

1717
# Installation
1818

19-
StarryPy runs on Python 2.7. It has been tested with Python 2.7.6 and 2.7.5.
19+
StarryPy runs on Python 2.7. It has been tested with Python 2.7.6, 2.7.5, 2.7.2, and PyPy.
2020

2121
After installing Python and pip, simply run `pip install -r requirements.txt` in the root directory of StarryPy. This will install all of the components needed for use. I recommend running it in a virtualenv.
2222

23-
Create a configuration file using the config.json.example. The most important things to note are owner_uuid, which should be set to a character's UUID that you posses and have never shared; server_address and server_port, which should be set to the proxied server. StarryPy will default to port 21025 for normal clients to connect to. Select a good random port, or set it to 21024 and firewall it off from the outside.
23+
Create a configuration file using the config.json.example. The most important things to note are owner\_uuid, which should be set to a character's UUID that you possess and have never shared; server\_address and server\_port, which should be set to the proxied server. StarryPy will default to port 21025 for normal clients to connect to. Select a good random port, or set it to 21024 and firewall it off from the outside.
24+
25+
# Built-in plugins
26+
StarryPy is nearly entirely plugin driven (our plugin manager is a plugin!), so there are quite a few built-in plugins. The truly important plugins are in the core\_plugins folder. If you remove any of those, it's likely that most other plugins will break. We'll break them down by core plugin and normal plugin classes. If you are looking for the commands, feel free to skip the core plugins section.
27+
28+
## Core Plugins
29+
30+
Core plugins are plugins that have no dependencies and are intended to be accessed by other plugins. If your plugin doesn't meet those criteria, it is recommended to put it in the normal plugins folder.
31+
32+
### Player Manager
33+
34+
The player manager is perhaps the most essential plugin of them all. It keeps track of each player that logs in, tracks their position, and manages kicks/bans. It is composed of the actual database manager, using SQLAlchemy on an SQLite3 backend by default.
35+
36+
### Command Plugin
37+
38+
This is a core plugin that works in conjunction with the plugin class SimpleCommandPlugin. SimpleCommandPlugins automatically register their commands with the instantiated command plugin and when a chat packet is sent it is automatically parsed. If it matches one of these commands, it sends it off to that function for processing. If it doesn't match any of the commands, it sends it on its merry way to the actual starbound server for processing.
39+
40+
## Plugins
41+
42+
### Admin Commands
43+
The admin commands plugin implements player management from in game. It is a SimpleCommandPlugin that provides the following commands:
44+
45+
* **/who**: Displays all users currently logged into the server. `Access: Everyone`
46+
* **/planet**: Displays all users on your current planet. `Access: Everyone`
47+
* **/whois**: Displays user information. Includes player UUID, IP address, username, access level, and current planet. `Access: Admin`
48+
* **/promote**: Promotes/demotes a user to a given access level. You can only promote if you are a moderator or above, and then only to a user of lesser rank than yourself. `Access: Moderator`
49+
* **/kick**: Kicks a user by username. If the name has spaces, enclose it in quotes. `Access: Moderator`
50+
* **/ban**: Bans an IP address. Best fetched with /whois. It does not support usernames. `Access: Admin`
51+
* **/bans**: Lists all active IP bans. `Access: Admin`
52+
* **/unban**: Unbans an IP address. `Access: Admin`
53+
* **/give\_item**: Gives an item to a player. Syntax is /give\_item player (enclosed in quotes if it has spaces) itemname count. The default limit for number of items to give to a player is 1000. `Access: Admin`
54+
55+
### Announcer
56+
This plugin simply announces whenever a player joins or quits the server.
57+
58+
### Bouncer
59+
This plugin prevents non-registered users from building or destroying anything. It is disabled by default.
60+
61+
### Colored names
62+
This plugin displays color codes for each username depending on rank. The colors are set in config.json.
63+
64+
### MOTD
65+
This plugin sends a Message of the Day on login. The MOTD is located in motd.txt in the plugin folder. It provides the following command:
66+
67+
* **/set\_motd**: Sets the MOTD to the following text. `Access: Moderator`
68+
69+
### New Player Greeter
70+
71+
Greets first-time players on the server. Gives them a greeting (located in new\_player\_message.txt) and gives them a pack of starter items (located in starter\_items.txt). Default items are 200 `coalore` and 5 `alienburger`s.
72+
73+
### Planet Protection
74+
This plugin protects specified planets against modification in any way. Currently if a planet is protected only Admins may modify it. This plugin provides the following commands:
75+
76+
* **/protect**: Protects the planet you are currently on. `Access: Admin`
77+
* **/unprotect**: Unprotects the planet you are currently on. `Access: Admin`
78+
79+
### Plugin Manager
80+
This plugin provides a method of enabling/disabling plugins. I know it's silly that it's a plugin, you don't have to tell me. It provides the following commands:
81+
82+
* **/list\_plugins**: Sends you a list of all loaded plugins. `Access: Admin`
83+
* **/disable\_plugin**: Disables a plugin by name. `Access: Admin`
84+
* **/enable\_plugin**: Enables a plugin by name. `Access: Admin`
85+
* **/help**: This command provides a list of commands if called by itself, and the help string for a command if given a name. Example syntax: /help enable\_plugin.
86+
87+
### Warpy
88+
This plugin provides various methods for warping players and ships around.
89+
90+
* **/warp**: Warps you to another player's ship. `Access: Admin`
91+
* **/move\_ship**: Moves your ship to the location of another player, or coordinates in the form of `alpha 514180 -82519336 -23964461 4` `Access: Admin`
92+
* **/move\_other\_ship**: Same as above, but another player's ship.
2493

2594
# Plugin development
2695

2796
There are several built-in plugins that you can derive inspiration from. The plugin API is decidedly simple, and simply responds to packet events. There is a convenience plugin class called SimpleCommandPlugin which responds to user commands in chat. Currently there is no easy way to *modify* packets, however they can be dropped or allowed to send by any plugin intercepting that packet type.
2897

2998
All plugins must ultimately derive from `BasePlugin`. Do not override the `__init__` method unless you absolutely know that you need to. All setup functions should be done in `activate()`
3099

100+
There will be more to come in the near future, for now please examine the base plugin classes.
101+
102+
# Planned features
103+
We haven't been able to pack in everything we've wanted to in this version. We love contributions, so please feel free to write whatever plugins/improve the core however you can.
104+
105+
We have quite a roadmap, here are some of the highlights you can expect in the next major version, and in the development branch before that if you're feeling brave:
106+
107+
* Spawn networks. Free transportation between admin-designated planets, so your new players can get a leg up in the world.
108+
* Loot rolling. So a rare item dropped and you don't think it's fair your friend got it? Soon you'll be able to get good items without ending friendships and going to prison on the inevitable murder charge.
109+
* Lotteries. Because what is like without a little risk?
110+
* Creature spawning. Want to spawn a couple dozen bone dragons? So do we!
111+
* Projectile blacklist. This should be coming very soon.
112+
* Internationalization. Translate plugins and core messages with ease to your preferred language.
113+
* Role based access control Thought the mod/admin/owner distinction is useful, having individual roles is our plan for the future.
114+
* Client filtering based on modded items. Though asset digests aren't supported right now, we want to do some minor filtering to keep out the riff-raff (if you as an admin want to.)
115+
* Plugin dependency overhaul. Really only interesting to developers, but it will allow for complex dependency resolution.
116+
117+
118+
There are many more planned features, minor and major. If you have a feature you'd just love to have that we haven't covered here, put in a feature request on the issues page.
119+
120+
# Contributing
121+
We're absolutely happy to accept pull requests. There is a freenode channel called ##starbound-dev that we discuss our development on primarily.
31122

123+
Other than that, please report any bugs you find with the appropriate section of the debug.log file that is generated.

0 commit comments

Comments
 (0)