src/squirrel.hpp
branchnoai
changeset 9674 15f7b310b6cf
parent 9673 ee4f133c84ec
child 9782 e8d8d8894f23
equal deleted inserted replaced
9673:ee4f133c84ec 9674:15f7b310b6cf
    92 	/**
    92 	/**
    93 	 * Creates a class instance.
    93 	 * Creates a class instance.
    94 	 * @param class_name The name of the class of which we create an instance.
    94 	 * @param class_name The name of the class of which we create an instance.
    95 	 * @param real_instance The instance to the real class, if it represents a real class.
    95 	 * @param real_instance The instance to the real class, if it represents a real class.
    96 	 * @param instance Returning value with the pointer to the instance.
    96 	 * @param instance Returning value with the pointer to the instance.
       
    97 	 * @param release_hook Optional param to give a release hook.
    97 	 * @return False if creating failed.
    98 	 * @return False if creating failed.
    98 	 */
    99 	 */
    99 	static bool CreateClassInstanceVM(HSQUIRRELVM vm, const char *class_name, void *real_instance, HSQOBJECT *instance);
   100 	static bool CreateClassInstanceVM(HSQUIRRELVM vm, const char *class_name, void *real_instance, HSQOBJECT *instance, SQRELEASEHOOK release_hook);
   100 
   101 
   101 	/**
   102 	/**
   102 	 * Exactly the same as CreateClassInstanceVM, only callable without instance of Squirrel.
   103 	 * Exactly the same as CreateClassInstanceVM, only callable without instance of Squirrel.
   103 	 */
   104 	 */
   104 	bool CreateClassInstance(const char *class_name, void *real_instance, HSQOBJECT *instance);
   105 	bool CreateClassInstance(const char *class_name, void *real_instance, HSQOBJECT *instance);