Created
May 19, 2011 15:08
-
-
Save bamboo/980973 to your computer and use it in GitHub Desktop.
alchemy - struct instantiation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
static AS3_Val Vector3f_DefaultValue() { | |
static AS3_Val (*DefaultValueShim)() = NULL; | |
if (DefaultValueShim == NULL) { | |
AS3_Val UnityEngine = AS3_String("UnityEngine"); | |
AS3_Val Vector3_class = AS3_NSGetS(UnityEngine, "Vector3"); | |
AS3_Val DefaultValue = AS3_GetS(Vector3_class, "DefaultValue"); | |
DefaultValueShim = AS3_Shim(DefaultValue, null, "AS3ValType", false); | |
AS3_Release(DefaultValue); | |
AS3_Release(Vector3_class); | |
AS3_Release(UnityEngine); | |
} | |
return DefaultValueShim(); | |
} | |
static AS3_Val Vector3f_To_AS3(const Vector3f& cppValue) { | |
AS3_Val returnValue = Vector3f_DefaultValue(); | |
Vector3f_To_AS3(cppValue, returnValue); | |
return returnValue; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment