CommandSigns - WIP
#1
This is a Plugin that I had scripted; due to the lack of functionality/implementation of Command Blocks in Cuberite, I needed a plugin that would provide a temporary alternative to command blocks.... I searched and searched and found nothing.


CommandSigns, allows the user (with the proper perms) to create and use a sign that will activate a in-game command without the user having to physically enter the command on their part. This can also provide a way for users to use a command that they lack the needed permissions for in a controlled manner [IN THEORY].

My LUA isn't my greatest aspect, I'm a C++ Programmer not a LUA Coder.... But, anyways...

Sign Creation:
    -Permission Node: 'CommandSigns.Create'
    -How-To: Place Sign and set Line1 to '[CS]' without quotes.... Then set Line2 with the command starting with '/'; plain text can be entered in Line2 but that is pointless, however any additional plain text can be entered in the 3rd and 4th lines.

Sign Usage:
    -Permission Node: 'CommandSigns.Read'
    -How-To: Rightclicking on a Command Sign will output a message to the player with Green Underlined Text that can be clicked; When the text is clicked the command is ran.

I HEREBY provide full permission to edit/modify/rework, and redistribute this plugin under any name or function; in any location without regard for my original authoring of said plugin.


Attached Files
.zip   CommandSigns.zip (Size: 1.45 KB / Downloads: 220)
"Full Canvas!! Let's set sail on the cyber sea of coding adventure!! Ya'harg!" ~ Cpt_Redbeard

-Arctic Blue 32 (Official Website)
http://aeo.x10host.com/


Reply
Thanks given by:
#2
Hello and welcome to the forum Smile

Congrats with your first plugin.

I'd like to point out that we do support command blocks though. You have to enable it in the world.ini file. The commands you can use are the same as the console commands, so if you want to register a command you have to use cPluginManager:BindConsoleCommand. We are planning on making the commandblock commands separate though.
Reply
Thanks given by:
#3
(02-14-2016, 03:25 AM)NiLSPACE Wrote: Hello and welcome to the forum Smile

Congrats with your first plugin.

I'd like to point out that we do support command blocks though. You have to enable it in the world.ini file. The commands you can use are the same as the console commands, so if you want to register a command you have to use cPluginManager:BindConsoleCommand. We are planning on making the commandblock commands separate though.

Huh, I've tried that 3 day ago and it didn't work, now it did..... I dnt eve *facedesk* lol....
I see what you mean by the commandblock commands are limited to console commands.... well at least my signs handle usage of in-game commands.

So I could, however, Bind a In-Game Command to be a Console Command; PLUGIN IDEAS!!! Thanks, dude.... Your input is appreciated.
"Full Canvas!! Let's set sail on the cyber sea of coding adventure!! Ya'harg!" ~ Cpt_Redbeard

-Arctic Blue 32 (Official Website)
http://aeo.x10host.com/


Reply
Thanks given by:
#4
The API Documentation only succeeds in confusing the crud out of me....  Huh Huh Huh

A Basic descriptions on what it does, some general examples of how it may be used, and also some examples of how it HAS been used? I really like the Multi Theft Auto API Documentation.

Just my own personal problems. xD
"Full Canvas!! Let's set sail on the cyber sea of coding adventure!! Ya'harg!" ~ Cpt_Redbeard

-Arctic Blue 32 (Official Website)
http://aeo.x10host.com/


Reply
Thanks given by:
#5
After a quick search for the Multi Theft Auto API documentation it looks pretty similar to how we do it. Or at least the way you bind an event. Here is an example on how you bind a console command:
function HandleHelpCommand(SplitArguments)
return "This command has not been implemented yet"
end

cPluginManager:BindConsoleCommand("help", HandleHelpCommand, "Shows all the commands")

The string you return is what the console/command block will output.

Currently we use the Info.lua file more often though. It allows you to easily generate documentation for your plugin.
Reply
Thanks given by:
#6
Actually I added [Command] signs to essentials and proposed them as pr.
Reply
Thanks given by:




Users browsing this thread: 1 Guest(s)