Class PluginEditor<G extends GameObject<G,​A,​R>,​A extends MapArchObject<A>,​R extends Archetype<G,​A,​R>>

    • Constructor Detail

      • PluginEditor

        public PluginEditor​(@NotNull
                            @NotNull Plugin<G,​A,​R> plugin,
                            @NotNull
                            @NotNull PluginController<G,​A,​R> pluginController,
                            @NotNull
                            @NotNull PluginModel<G,​A,​R> pluginModel,
                            @NotNull
                            @NotNull PluginParameterViewFactory<G,​A,​R> pluginParameterViewFactory,
                            @NotNull
                            @NotNull ResourceIcons resourceIcons)
        Creates a visual JComponent used to edit the given script.
        Parameters:
        plugin - the script object to edit
        pluginController - the associated script control instance
        resourceIcons - the resource icons for creating icons
    • Method Detail

      • getComponent

        @NotNull
        public @NotNull java.awt.Component getComponent()
        Returns the Component for this plugin editor.
        Returns:
        the component
      • isPluginEditorIsAutoRun

        @ActionMethod
        public boolean isPluginEditorIsAutoRun()
        Action method for option to run the editor script automatically.
        Returns:
        whether auto-run is enabled
      • setPluginEditorIsAutoRun

        @ActionMethod
        public void setPluginEditorIsAutoRun​(boolean autoRun)
        Action method for option to run the editor script automatically.
        Parameters:
        autoRun - whether auto-run is enabled
      • isPluginIsEditorFilter

        @ActionMethod
        public boolean isPluginIsEditorFilter()
        Action method for option to make an editor script a map filter.
        Returns:
        whether the editor script is a map filter
      • setPluginIsEditorFilter

        @ActionMethod
        public void setPluginIsEditorFilter​(boolean filter)
        Action method for option to run the editor script automatically.
        Parameters:
        filter - whether the editor script is a filter
      • isPluginIsScript

        @ActionMethod
        public boolean isPluginIsScript()
        Action method for option to add an editor script to the plugins menu.
        Returns:
        whether the editor script should be added to the plugins menu
      • setPluginIsScript

        @ActionMethod
        public void setPluginIsScript​(boolean script)
        Action method for option to add the script to the plugins menu.
        Parameters:
        script - whether the editor script should be added to the plugins menu
      • pluginEditorReRegister

        @ActionMethod
        public void pluginEditorReRegister()
        Action method to re-register the current plugin.
      • pluginEditorExport

        @ActionMethod
        public void pluginEditorExport()
        Action method to export the current plugin as an XML file.
      • pluginEditorAddParameter

        @ActionMethod
        public void pluginEditorAddParameter()
        Action method to add a parameter to the current plugin script.
      • pluginEditorRemoveParameter

        @ActionMethod
        public void pluginEditorRemoveParameter()
        Action method to remove the selected parameter from the current plugin script.
      • pluginEditorRunScript

        @ActionMethod
        public void pluginEditorRunScript()
        Action method to execute the selected plugin script.