ProxyCore Load a configuration file. Configuration name - for example "server". This should be your plugin name. Regex pattern used to load a line from config file. Groups[1]: Name of setting Groups[3]: Value of setting (including "" if string) Save a new configuration file with default values. If there is an existing config file, it will be replaced. This will be called to populate config data with default values and descriptions. Create a new setting for the file. If setting with this name already exists then skip. Setting name. Default value for setting. Make sure to use type casting if not integer. Description to write in the file for this setting. Read a 32 bit integer value from configuration file. Name of the option. Default value if config is missing this option or is invalid. Read a 32 bit unsigned integer value from configuration file. Name of the option. Default value if config is missing this option or is invalid. Read a 64 bit integer value from configuration file. Name of the option. Default value if config is missing this option or is invalid. Read a 64 bit unsigned integer value from configuration file. Name of the option. Default value if config is missing this option or is invalid. Read a float value from configuration file. Name of the option. Default value if config is missing this option or is invalid. Read a double value from configuration file. Name of the option. Default value if config is missing this option or is invalid. Read a string value from configuration file. Name of the option. Default value if config is missing this option or is invalid. Did we successfully load the config file? If not then it was probably missing. This is what we turn the @ into so we can replace colors and keep the symbol intact Check if a char code is ANSI color code. Char to check for. Convert normal colors to HTML colors. It converts inserting </font> in front of every color too so you need to have started with some font already. Message to convert colors in. Get last color code in the string (not including foreground colors). This will return with the @ sign. Removes duplicate colors from a string. For example "@r @Y bla@w" would become " @Ybla". Also XTERM color codes become padded with zero if they are present. String to fix colors in. This function will turn either ANSI color to our format or vice versa. String passed for color changing. False means we change our format (@x) to ANSI; true means we change ANSI to our format (we don't convert XTERM colors this way though). Allow replacing xterm colors? If disabled we will replace into closest ANSI. Remove dark grey color code from string and replace it with normal grey. String to remove dark grey from (replacing it with normal grey). This function will Remove all color from the string. String where the color is being removed. True means raw color (ansi); false means our format (@x). Get XTerm color code from text in index (index must be at @x or @z, before it). Text to get color code from. Index of @z or @x. Get full escape string from string in index. Text to search from. Index in text of @e Length of the thing behind @e. Get XTerm color code from text in index (index must be at the number not before @x or @z like the other function) Text to get color code from. Index of number. Length of the number. Replace XTerm color codes into real XTerm or ANSI values. Text to search in. Replace into XTerm codes or if false then convert to closest regular ANSI. Convert XTerm to ansi char (closest match). Code to convert. Name of your plugin. You must set this or your plugin will not be loaded. This is the keyword for your plugin. You must set this or your plugin will not be loaded. This must be unique. If two or more plugins with the same keyword are found then the plugin with the highest version number is loaded. Register a new trigger. Unique identifier for the trigger. Regex pattern for the trigger. Function that will be called if this trigger fires. Register a new trigger. Unique identifier for the trigger. Regex pattern for the trigger. Function that will be called if this trigger fires. Options for the trigger. Register a new trigger. Unique identifier for the trigger. Regex pattern for the trigger. Function that will be called if this trigger fires. Options for the trigger. Lower priority triggers get matched first. Register a new trigger. Unique identifier for the trigger. Regex pattern for the trigger. Function that will be called if this trigger fires. Options for the trigger. Lower priority triggers get matched first. Custom argument that will be passed to trigger data. Unregister a trigger by name. Name of the trigger you wish to unregister. Register a new command or overwrite a previous one. Command to register. Arguments to match (regex pattern). This can be set to null or empty string if you don't want to capture anything or plan to do so in the function yourself. Function of command. Register a new command or overwrite a previous one. Command to register. Arguments to match (regex pattern). This can be set to null or empty string if you don't want to capture anything or plan to do so in the function yourself. Function of command. Minimum length of command typed required to activate. For example if command is "plugins" and this is 6 then "plugin" and "plugins" both activate this command but "plugi" won't. Enter 0 to disable this behaviour. Register a new command or overwrite a previous one. Command to register. Arguments to match (regex pattern). This can be set to null or empty string if you don't want to capture anything or plan to do so in the function yourself. Function of command. Minimum length of command typed required to activate. For example if command is "plugins" and this is 6 then "plugin" and "plugins" both activate this command but "plugi" won't. Enter 0 to disable this behaviour. Options for command. Register a new command or overwrite a previous one. Command to register. Arguments to match (regex pattern). This can be set to null or empty string if you don't want to capture anything or plan to do so in the function yourself. Function of command. Minimum length of command typed required to activate. For example if command is "plugins" and this is 6 then "plugin" and "plugins" both activate this command but "plugi" won't. Enter 0 to disable this behaviour. Options for command. Parent command (if you want to create a subcommand). You can enter commands separated with space if it's nested. Register a new command or overwrite a previous one. Command to register. Arguments to match (regex pattern). This can be set to null or empty string if you don't want to capture anything or plan to do so in the function yourself. Function of command. Minimum length of command typed required to activate. For example if command is "plugins" and this is 6 then "plugin" and "plugins" both activate this command but "plugi" won't. Enter 0 to disable this behaviour. Options for command. Parent command (if you want to create a subcommand). You can enter commands separated with space if it's nested. Custom argument to pass to function handler. This way you can register multiple commands to a same function handler only differentiating them with this custom argument. Register a new command or overwrite a previous one. Command to register. Arguments to match (regex pattern). This can be set to null or empty string if you don't want to capture anything or plan to do so in the function yourself. Function of command. Options for command. Parent command (if you want to create a subcommand). You can enter commands separated with space if it's nested. Custom argument to pass to function handler. This way you can register multiple commands to a same function handler only differentiating them with this custom argument. Mask of allowed auth levels to access this command. Default ulong.MaxValue (meaning all auth levels are allowed). Enter 3 for example to allow only auth level 1 and 2 to access this command. Minimum length of command typed required to activate. For example if command is "plugins" and this is 6 then "plugin" and "plugins" both activate this command but "plugi" won't. Enter 0 to disable this behaviour. Unregister a command. Command to unregister. If you want to unregister a nested command separate commands with a space. This will be called when character enters the game. Either by log in or reconnect. This will be called when we disconnect from Aardwolf. This will be called when we connect to Aardwolf. This is called when program shuts down. Write any code you need to shut down your plugin. This is called on every loop of world update. You can use it as your main loop for the plugin if you need one. Current time since program startup. This is called when we receive a line from MUD. It is called AFTER triggers are done with it. If a trigger gagged the line this will not be called. This is called when we receive a line from MUD. It is called BEFORE triggers are done with it. This is called when user enters a command and inputhandler did not handle the command. So it is called AFTER we check for aliases and commands and we are about to send command to MUD. Command that was entered. You can change this in the function. If you set null then nothing will be sent to MUD. Client who entered the command. If this is 0 it was executed from a plugin. Auth level of who entered the command. This is called when user enters a command. It is called BEFORE we check for aliases and commands. Command that was entered. You can change this in the function. If you set null then nothing will be sent to MUD and nothing will be checked for aliases or commands. Client who entered the command. If this is 0 it was executed from a plugin. Auth level of who entered the command. Enter required player config options here. This will be displayed if user requests info about a plugin. For example you may enter here "echocommands ON" and "statmon ON" etc. Whatever your plugin requires. This doesn't actually change the settings in game it is only for plugin info command. This is the class name of script. For example moons has this set to "MoonScript.MoonScript". Only needed by developers who want to use another plugin in their plugin. Called when we load a configuration file. Did the loading succeed? If not then the config file wasn't present and we created a new one. Disable all triggers with this priority. Disabling triggers from a plugin will make them not work until you enable them from the same plugin again. If triggers have been disabled from multiple plugins then all plugins will have to enable them again until they start working. Disabling triggers will make all triggers with this priority to not work not only triggers in current plugin! Priority of triggers to disable. Disable all triggers with this priority. Disabling triggers from a plugin will make them not work until you enable them from the same plugin again. If triggers have been disabled from multiple plugins then all plugins will have to enable them again until they start working. Disabling triggers will make all triggers with this priority to not work not only triggers in current plugin! Minimum priority of triggers to disable. Maximum priority of triggers to disable. Enable all previously disabled triggers with this priority. Priority of triggers to enable. Enable all previously disabled triggers with this priority. Minimum priority of triggers to enable. Maximum priority of triggers to enable. Set this to be your configuration file if you want your plugin to have one. This is optional. Creator of the plugin, this is your name / character's name. This is optional. Version of your plugin. This is optional. Description about your plugin. You should explain here what it does and how to handle it. This will be displayed if user requests information about your plugin. This is optional. Enter a website for this plugin if you wish. Mostly used to see documentation and updates. Enter the URL for update checking txt file. For example "www.duckbat.com/plugins/update.moons.txt". In the text file enter the number of last version. For example whole contents of the txt file can be "3". Indicating that the last version for this plugin is 3. If version is greater than user's version and they have update checking on then they will be notified that there is a more up to date version out there. Does this plugin require a certain version of core? Set this if there was an update and your plugin requires it. Plugin is not loaded if an older version core than this is used and user will be notified. Version of Proxy. Handle text line as if we received it from Aardwolf. Handle GMCP data that we received from Aardwolf. GMCP data received. This is called from proxy when it shuts down. Do NOT call from a plugin. Enter input as if a client entered it. Meaning we parse it. Consider using the Execute command instead. Input entered. Which client is this from? Enter 0 to set not from a client. Authlevel of client who entered command (1...64) Send message to specified clients. Message to send. Clients to send it to. Enter null to send to all connected clients. Enter 0 as client to send it as a command to Aardwolf (we don't parse it though, if you want parsed input use the Execute command). Send a message to all connected authorized clients. Message to send to all authorized clients. Send a message to all connected authorized clients. Message to send to all authorized clients. Authorization levels required to see this message. This is a mask. Execute a command. Command to execute. Allow parsing it for aliases and such, or send it directly to Aardwolf? Execute a command. Command to execute. Allow parsing it for aliases and such, or send it directly to Aardwolf? Auth level that executes this command. (1...64) Send raw bytes to MUD. Bytes to send. Internal command for updating the world. DO NOT CALL FROM A PLUGIN! New mstime. This is messages for networking to handle. Don't touch unless you know what you are doing. Check for updates and report to all connected users if there are any. Check core update. Check plugin updates. Should we report if no updates were found? Game world instance. Milliseconds since program startup. Get plugin by keyword. Keyword of plugin. What we triggered on, you can change this value to replace the text. Custom argument if you registered a trigger to have one. Replace matched %0 value with new string. This only works in regex triggers. You can have {%1} - {%n} in the new string for matched data. Use {%%1} to escape. If you use % higher than what was captured then a NULL will be replaced there. For example using %3 when there are only 2 things captured with regex. Example: Line: "@mQuest Points @w: @Y19,361" Pattern: "^@mQuest Points @w: (\s*)@Y([\d,]+)$" Replace: "@mQuest Points @w: {%1}@G{%2}" This would make quest points green in the "worth" command output. Where {%1} inserts the right amount of spaces (what was captured) and {%2} inserts the quest points amount (19,361). New string to replace with. See function summary for help with this. Allow parsing {%n} in the New string or not. If not then string is replaced as is without parsing for arguments. Match data. This is the function template that will be called when a trigger fires. Return true to gag it - this will also prevent other triggers from triggering on this line. Triggered text data. Normal triggers stop after finding the first match in a line, with this flag the trigger repeats for each match in the same line. This only applies if you use regex pattern. Ignore lower and upper case. This only applies if you use regex pattern. Pattern is not regex but instead just raw string. For example if you want to trigger on "@w--> @WTICK @w<--" there's no need to create a regex pattern just insert this string and set this flag in options and the trigger will be MUCH faster. Use regex only where necessary. Trigger ignores color codes. If you set this flag you should NOT include any color codes in your trigger pattern. Matching will start from right and go to left. Register a new trigger. Unique identifier for the trigger. Regex pattern for the trigger. Function that will be called if this trigger fires. Register a new trigger. Unique identifier for the trigger. Regex pattern for the trigger. Function that will be called if this trigger fires. Options for the trigger. Register a new trigger. Unique identifier for the trigger. Regex pattern for the trigger. Function that will be called if this trigger fires. Options for the trigger. Lower priority triggers get matched first. Default: 1000 Register a new trigger. Unique identifier for the trigger. Regex pattern for the trigger. Function that will be called if this trigger fires. Options for the trigger. Lower priority triggers get matched first. Default: 1000 Custom argument to pass to trigger data. From which plugin was this registered. Unregister a trigger by name. Name of the trigger you wish to unregister. Function for handling input. Return true if we handled the command (no need to send to MUD) and false if we didn't and we must send it to MUD. Input data. Hidden from normal commands menu. Command is currently disabled and will be excluded in the list of valid commands. Dummy command, player can't type it but it will be redirected from elsewhere. Internal - this will be assigned automatically for commands that have subcommands. If this is set ignore message and send this byte data instead. Color codes will not be parsed by server and this is sent as is. This is message but without colors. Used for triggering non-ansi triggers. Which clients should receive the message. This is a mask for security levels. For example value "3" would only send this message to security level 1 and 2. Set ulong.MaxValue (default) to send to all clients or 0 to send to noone. This field is ignored when sending message to Aardwolf (as a command). This setting is used to send the message to specific clients (using client ID). Enter new uint[] { 0 } to send to Aardwolf and null to send to all clients (default). Is this message natural (client entered command or Aardwolf sent message) or is it generated by us, meaning Aardwolf did not send this and client did not enter it as a command. What kind of line ending do we send with this message (default \n\r). When was message generated (send time may vary by some milliseconds) Options for message. Contents of the message. This is a GMCP message the main module will be in Msg and the data will be in MsgData. Register a new command or overwrite a previous one. Command to register. Arguments to match (regex pattern). This can be set to null or empty string if you don't want to capture anything or plan to do so in the function yourself. Function of command. Register a new command or overwrite a previous one. Command to register. Arguments to match (regex pattern). This can be set to null or empty string if you don't want to capture anything or plan to do so in the function yourself. Function of command. Options for command. Register a new command or overwrite a previous one. Command to register. Arguments to match (regex pattern). This can be set to null or empty string if you don't want to capture anything or plan to do so in the function yourself. Function of command. Options for command. Parent command (if you want to create a subcommand). You can enter commands separated with space if it's nested. Register a new command or overwrite a previous one. Command to register. Arguments to match (regex pattern). This can be set to null or empty string if you don't want to capture anything or plan to do so in the function yourself. Function of command. Options for command. Parent command (if you want to create a subcommand). You can enter commands separated with space if it's nested. Custom argument to pass to function handler. This way you can register multiple commands to a same function handler only differentiating them with this custom argument. Register a new command or overwrite a previous one. Command to register. Arguments to match (regex pattern). This can be set to null or empty string if you don't want to capture anything or plan to do so in the function yourself. Function of command. Options for command. Parent command (if you want to create a subcommand). You can enter commands separated with space if it's nested. Custom argument to pass to function handler. This way you can register multiple commands to a same function handler only differentiating them with this custom argument. Mask of allowed auth levels to access this command. Default ulong.MaxValue (meaning all auth levels are allowed). Enter 3 for example to allow only auth level 1 and 2 to access this command. From which plugin did this come. Minimum length of command typed required to activate. For example if command is "plugins" and this is 6 then "plugin" and "plugins" both activate this command but "plugi" won't. Unregister a command. Command to unregister. If you want to unregister a nested command separate commands with a space. Whole command just as it was entered. You can change this to send something different to MUD. Just make sure you return false on the command handler otherwise nothing will get sent to MUD. Which function will we execute with this data. Who executed the command? This will be uint.MaxValue if we execute it from a plugin or other places - meaning it didn't originate from a client. Use this if you want to send message to whoever executed the command. If it was executed from a plugin send message to every client. Example: World.Instance.SendMessage("Test.", i.ClientMask); The auth level of client who entered command. (1...64) This is where we capture arguments if the arguments pattern was set. Check first if Arguments.Success, otherwise there will be no Groups set. Write this into console window. Message to write to console window. Write an error message to console window and error.log Write a stacktrace when program crashes. Trace to write.