public interface CommandCallback
Modifier and Type | Method and Description |
---|---|
void |
accountCreate(@NotNull java.lang.String login,
@NotNull java.lang.String password)
Creates an account.
|
void |
accountCreateCharacter(@NotNull java.lang.String login,
@NotNull java.util.Collection<java.lang.String> attributes)
Creates a character.
|
void |
accountLink(int force,
@NotNull java.lang.String login,
@NotNull java.lang.String password)
Links a character to the current account.
|
void |
accountLogin(@NotNull java.lang.String login,
@NotNull java.lang.String password)
Login to an account.
|
void |
accountPassword(@NotNull java.lang.String currentPassword,
@NotNull java.lang.String newPassword)
Change the account password.
|
void |
accountPlayCharacter(@NotNull java.lang.String name)
Plays a character from the current account.
|
void |
activateCommandInput(@NotNull java.lang.String newText)
Activates the command input text field.
|
void |
closeDialog(@NotNull java.lang.String dialog)
Closes a dialog.
|
boolean |
createKeyBinding(boolean perCharacter,
@NotNull CommandList commandList)
Adds a key binding.
|
@NotNull CommandList |
getCommandList(@NotNull java.lang.String args)
Returns a command list.
|
@NotNull java.util.Collection<java.lang.String> |
getCommandListNames()
Returns all command list names.
|
void |
openDialog(@NotNull java.lang.String dialog)
Opens a dialog.
|
void |
quitApplication()
Terminates the application.
|
boolean |
removeKeyBinding(boolean perCharacter)
Removes a key binding.
|
void |
toggleDialog(@NotNull java.lang.String dialog)
Toggles a dialog.
|
void |
updatePlayerName(@NotNull java.lang.String playerName)
Sets the current player name.
|
void quitApplication()
void openDialog(@NotNull @NotNull java.lang.String dialog)
dialog
- the dialog to openvoid toggleDialog(@NotNull @NotNull java.lang.String dialog)
dialog
- the dialog to togglevoid closeDialog(@NotNull @NotNull java.lang.String dialog)
dialog
- the dialog to close@NotNull @NotNull CommandList getCommandList(@NotNull @NotNull java.lang.String args) throws NoSuchCommandException
args
- the name of the command listNoSuchCommandException
- if the command list does not exist@NotNull @NotNull java.util.Collection<java.lang.String> getCommandListNames()
void updatePlayerName(@NotNull @NotNull java.lang.String playerName)
playerName
- the player namevoid activateCommandInput(@NotNull @NotNull java.lang.String newText)
If neither the main gui nor any visible dialog has an input text field, invisible GUIs are checked as well. If one is found, it is made visible.
newText
- the new command text if non-null
boolean createKeyBinding(boolean perCharacter, @NotNull @NotNull CommandList commandList)
perCharacter
- whether a per-character key binding should be addedcommandList
- the command list to execute on key pressboolean removeKeyBinding(boolean perCharacter)
perCharacter
- whether a per-character key binding should be
removedvoid accountLogin(@NotNull @NotNull java.lang.String login, @NotNull @NotNull java.lang.String password)
login
- loginpassword
- passwordvoid accountCreate(@NotNull @NotNull java.lang.String login, @NotNull @NotNull java.lang.String password)
login
- the account's namepassword
- the account's passwordvoid accountPlayCharacter(@NotNull @NotNull java.lang.String name)
name
- the character's namevoid accountLink(int force, @NotNull @NotNull java.lang.String login, @NotNull @NotNull java.lang.String password)
force
- 0 to allow failure, 1 to force in certain situationslogin
- the character's namepassword
- the character's passwordvoid accountCreateCharacter(@NotNull @NotNull java.lang.String login, @NotNull @NotNull java.util.Collection<java.lang.String> attributes)
accountLogin(java.lang.String, java.lang.String)
or accountCreate(java.lang.String, java.lang.String)
.login
- the character's nameattributes
- the character attributesvoid accountPassword(@NotNull @NotNull java.lang.String currentPassword, @NotNull @NotNull java.lang.String newPassword)
currentPassword
- the current account passwordnewPassword
- the new account password