Skip to content

Instantly share code, notes, and snippets.

@gamebuilderstudio
Last active December 15, 2015 09:58
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save gamebuilderstudio/5241901 to your computer and use it in GitHub Desktop.
Save gamebuilderstudio/5241901 to your computer and use it in GitHub Desktop.
package com.gbs.plugins
{
import com.gbs.plugins.components.CustomGameEngineComponent;
import com.gbs.utils.ClassRegistrar;
import com.gbs.utils.ClassRegistrarTypes;
public class CustomComponentClassList
{
public function CustomComponentClassList(pluginUID : String = "_*_")
{
//Define the custom game engine component
ClassRegistrar.instance.registerClass(CustomGameEngineComponent, ClassRegistrarTypes.COMPONENTS);
//If you create custom game actions or states in your plugin you can
//register them here by setting the class type to ClassRegistrarTypes.ACTIONS and you can give it
//Custom Name by passing a string.
ClassRegistrar.instance.registerClass(MethodInvoker, pluginUID, ClassRegistrarTypes.ACTIONS, "Call Method");
//You can also define states to be included in the State Machine state type dropdown
ClassRegistrar.instance.registerClass(BasicState, pluginUID, ClassRegistrarTypes.STATES,"GenericState");
//Every class in your plugin needs to be listed here so that it can be included in the final build
//and so that dependencies can be assesed.
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment