Repository navigation
From v2.3.1 to v2.4
This is what you need to change for your commands to work in v2.4.
Before, arguments used the then prefix to indicate that they were an argument.
There was also a type field that specified whether this argument is a literal or argument.
Argument arguments specified their argument type in argument.type.
Now, arguments use either a literal or argument prefix to specify they are a literal/argument.
Argument arguments specify their argument type in type.
The argument section is only used for passing additional information to the argument types.
# v2.3.1
send-updater-message:
executes: #...
then:broadcast:
type: LITERAL
executes: #...
send-updater-message-2:
then:broadcast:
type: ARGUMENT
argument:
type: boolean
executes: #...
# v2.4
send-updater-message:
executes: #...
literal:broadcast:
executes: #...
send-updater-message-2:
argument:broadcast:
type: boolean
executes: #...The COMMANDS execution type has been renamed to command
Execution types have changed because of preparation for multi-typing.
(Almost) every execution is now wrapped in a section which is called like the type (underscores replaced with dashes)
javascript and javascript_reference remain untouched by this.
# v2.3.1
command:
executes:
type: MESSAGE
message: 'hello, World!'
command-2:
executes:
type: BOSS_BAR
name: 'My boss bar'
color: GREEN
progress: 0.5
# v2.4
command:
executes:
type: MESSAGE
message: # I will make the old way possible again in the near future
message: 'hello, World!'
#broadcast: true
command-2:
executes:
type: BOSS_BAR
boss-bar:
name: 'My boss bar'
color: GREEN
progress: 0.5The conventions have changed. You should now use lower case for execution, suggestion, argument and requirement types.
# v2.3.1
command:
executes:
type: MESSAGE
#...
# v2.4
command:
executes:
type: message
#...There is quite a difference between v2.3.1 and v2.4. I hope to not have to make such big changes between minor updates in the future.
I didn't like the boilerplate in the YAML command declarations, so I changed it. Also, the whole API was changed, so it fit right in.
# v2.3.1
command:
then:my-argument:
type: LITERAL
then:my-argument-2:
type: ARGUMENT
argument:
type: STRING
# v2.4
command:
literal:my-argument:
argument:my-argument-2:
type: stringThat's about 40% less characters, and personally, I also think the new one is easier to understand.
The new way is how I intend this plugin to be used. The old way was more like a bridge and I wanted to get rid of it early.