RPG Maker MV
CXJ Core

This script powers most of the scripts I've written. In most cases, the use of this script is optional, as I'll always try to find a fallback, but it does make things a bit less complicated.

Download (10.07 kB, 5 times downloaded)

Just put this script as high as possible. You can also use this library for your own projects.

All functions are accessible through the CXJScripts.CXJCore namespace by default. You can always change this, either by altering the settings, or by essentially set it as the value of a variable in case you're writing your own plugin that's using this as a basis.

Plugin parameters


This allows you to set a custom namespace for the plugin to load from. This can be especially useful when running certain commands from event scripts and the likes, although they're a lot less useful for custom scripts.

Basic functions

CXJScripts.CXJCore.getParameters(pluginName, defaultParameters)

This retrieves the parameters for the current plugin. It essentially is an extension to the existing PluginManager function. First, it calls PluginManager.parameters to retrieve the parameters in the old-fashioned way. If it can't find the parameters, it falls back to document.currentScript, which essentially gets the current script file name. This does not work on Internet Explorer, so as a final resort it checks all settings for each plugin and compares it to the object given in defaultParameters. If it finds a complete match, it'll return these parameters. Finally, if it still fails to find the plugin settings, it will use the defaultParameters object as the parameters.


pluginNameThe name of the plugin
defaultParametersThe default parameters

Returns: An object containing every parameter, or defaultParameters if it can't find it.

Creator: GaryCXJk

Release date: 2017-07-15

Downloads: 5

License: ISC License

Optional compatibility: