summaryrefslogtreecommitdiffstats
path: root/MCServer
diff options
context:
space:
mode:
authorAlexander Harkness <bearbin@gmail.com>2014-01-31 08:41:21 +0100
committerAlexander Harkness <bearbin@gmail.com>2014-01-31 08:41:21 +0100
commit79ef653cb79a47f2b4bcec47e13aff16f8ca1b43 (patch)
tree2a47cf5b9392861296b7a788b80fd317075e59b0 /MCServer
parentFixed at least a little of the plugin guide. (diff)
downloadcuberite-79ef653cb79a47f2b4bcec47e13aff16f8ca1b43.tar
cuberite-79ef653cb79a47f2b4bcec47e13aff16f8ca1b43.tar.gz
cuberite-79ef653cb79a47f2b4bcec47e13aff16f8ca1b43.tar.bz2
cuberite-79ef653cb79a47f2b4bcec47e13aff16f8ca1b43.tar.lz
cuberite-79ef653cb79a47f2b4bcec47e13aff16f8ca1b43.tar.xz
cuberite-79ef653cb79a47f2b4bcec47e13aff16f8ca1b43.tar.zst
cuberite-79ef653cb79a47f2b4bcec47e13aff16f8ca1b43.zip
Diffstat (limited to 'MCServer')
-rw-r--r--MCServer/Plugins/APIDump/Writing-a-MCServer-plugin.html7
1 files changed, 3 insertions, 4 deletions
diff --git a/MCServer/Plugins/APIDump/Writing-a-MCServer-plugin.html b/MCServer/Plugins/APIDump/Writing-a-MCServer-plugin.html
index bdb80186f..1eec4842a 100644
--- a/MCServer/Plugins/APIDump/Writing-a-MCServer-plugin.html
+++ b/MCServer/Plugins/APIDump/Writing-a-MCServer-plugin.html
@@ -119,10 +119,10 @@ end
</p>
<pre class="prettyprint lang-lua">
-- ADD THIS IF COMMAND DOES NOT REQUIRE A PARAMETER (/explode)
-PluginManager.BindCommand("/commandname", "permissionnode", FunctionToCall, " - Description of command")
+cPluginManager.BindCommand("/commandname", "permissionnode", FunctionToCall, " - Description of command")
-- ADD THIS IF COMMAND DOES REQUIRE A PARAMETER (/explode Notch)
-PluginManager.BindCommand("/commandname", "permissionnode", FunctionToCall, " ~ Description of command and parameter(s)")
+cPluginManager.BindCommand("/commandname", "permissionnode", FunctionToCall, " ~ Description of command and parameter(s)")
</pre>
<p>
What does it do, and why are there two?
@@ -189,8 +189,7 @@ function Initialize(Plugin)
Plugin:SetName("DerpyPluginThatBlowsPeopleUp")
Plugin:SetVersion(9001)
- local PluginManager = cPluginManager:Get()
- PluginManager:BindCommand("/explode", "derpyplugin.explode", Explode, " ~ Explode a player");
+ cPluginManager.BindCommand("/explode", "derpyplugin.explode", Explode, " ~ Explode a player");
cPluginManager:AddHook(cPluginManager.HOOK_COLLECTING_PICKUP, OnCollectingPickup)