<?xml version="1.0" encoding="UTF-8"?>
<templates><template name="MTASC_Single_MovieClip_inherit" description="Create a inter class for MTASC, Singleton and MovieClip extention" context="com.pf.fdt.ui.editor.template.actionscript" enabled="true" deleted="false" autoinsert="true">class ${enclosing_package_and_type} extends MovieClip
{
	private static var __scope__ : MovieClip;
	private static var __inst : ${enclosing_type};
	
	private function ${enclosing_type}()
	{
		super();
	}
	
	/**
	 * @return singleton instance of ${enclosing_type}
	 */
	public static function getInstance( Void ) : ${enclosing_type}
	{
		if( __inst == undefined)
		{
			__inst = ${enclosing_type}( __scope__ );
			__scope__.__proto__ = ${enclosing_type}.prototype;
			__scope__.constructor = ${enclosing_type};
			__scope__.constructor.call( __scope__ );
		}
		return __inst;
	}

	private static function main( scope:MovieClip ) : Void
	{
		__scope__ = scope;
		var app = ${enclosing_type}.getInstance();
	}
}</template></templates>