Originally posted here:
http://forum.thegamecreators.com/?m=forum_view&t=179775&b=22
But no one seemed to be able to answer this on the DarkGDK forums so i translated the code and posted it here.
I might have gotten some things wrong at the translation but i hope it's readable

Soo i have problems applying the rotation properly after i glue an object to a limb, i made some code where i basically cut off a limb and then reapply it to the model. Using the ninja model from the DarkMatter.
NinjaLimbObject = GetNextObjectID();
Make Object From Limb NinjaLimbObject, ModelID, 11
Position Object NinjaLimbObject, 0, 0, 0
Scale Object NinjaLimbObject, 1000, 1000, 1000
GlueObjectToLimb NinjaLimbObject, ModelID, 11
I attached an image of the outcome. Clearly i have to rotate the object in some way. Maybe something like i do with the Position Object. As the rotation becomes relative to the limb. However i did this:
a = Object Angle X NinjaLimb
b = Object Angle Y NinjaLimb
c = Object Angle Z NinjaLimb
And they all returned 0.