reverted geo bone (#474)
This commit is contained in:
1 parent
d5019ffd78
commit
c09f178df0
6 files changed
+3
-131
No files matched your search
@@ -844,58 +844,6 @@ void geo_process_animated_part(struct GraphNodeAnimatedPart *node) {
|
||||
append_dl_and_return(((struct GraphNodeDisplayList *)node));
|
||||
}
|
||||
|
||||
/**
|
||||
* Render an animated part that has an initial rotation value
|
||||
*/
|
||||
void geo_process_bone(struct GraphNodeBone *node) {
|
||||
Vec3s rotation = { node->rotation[0], node->rotation[1], node->rotation[2] };
|
||||
Vec3f translation = { node->translation[0], node->translation[1], node->translation[2] };
|
||||
|
||||
if (gCurrAnimType == ANIM_TYPE_TRANSLATION) {
|
||||
translation[0] += gCurrAnimData[retrieve_animation_index(gCurrAnimFrame, &gCurrAnimAttribute)]
|
||||
* gCurrAnimTranslationMultiplier;
|
||||
translation[1] += gCurrAnimData[retrieve_animation_index(gCurrAnimFrame, &gCurrAnimAttribute)]
|
||||
* gCurrAnimTranslationMultiplier;
|
||||
translation[2] += gCurrAnimData[retrieve_animation_index(gCurrAnimFrame, &gCurrAnimAttribute)]
|
||||
* gCurrAnimTranslationMultiplier;
|
||||
gCurrAnimType = ANIM_TYPE_ROTATION;
|
||||
} else {
|
||||
if (gCurrAnimType == ANIM_TYPE_LATERAL_TRANSLATION) {
|
||||
translation[0] +=
|
||||
gCurrAnimData[retrieve_animation_index(gCurrAnimFrame, &gCurrAnimAttribute)]
|
||||
* gCurrAnimTranslationMultiplier;
|
||||
gCurrAnimAttribute += 2;
|
||||
translation[2] +=
|
||||
gCurrAnimData[retrieve_animation_index(gCurrAnimFrame, &gCurrAnimAttribute)]
|
||||
* gCurrAnimTranslationMultiplier;
|
||||
gCurrAnimType = ANIM_TYPE_ROTATION;
|
||||
} else {
|
||||
if (gCurrAnimType == ANIM_TYPE_VERTICAL_TRANSLATION) {
|
||||
gCurrAnimAttribute += 2;
|
||||
translation[1] +=
|
||||
gCurrAnimData[retrieve_animation_index(gCurrAnimFrame, &gCurrAnimAttribute)]
|
||||
* gCurrAnimTranslationMultiplier;
|
||||
gCurrAnimAttribute += 2;
|
||||
gCurrAnimType = ANIM_TYPE_ROTATION;
|
||||
} else if (gCurrAnimType == ANIM_TYPE_NO_TRANSLATION) {
|
||||
gCurrAnimAttribute += 6;
|
||||
gCurrAnimType = ANIM_TYPE_ROTATION;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (gCurrAnimType == ANIM_TYPE_ROTATION) {
|
||||
rotation[0] += gCurrAnimData[retrieve_animation_index(gCurrAnimFrame, &gCurrAnimAttribute)];
|
||||
rotation[1] += gCurrAnimData[retrieve_animation_index(gCurrAnimFrame, &gCurrAnimAttribute)];
|
||||
rotation[2] += gCurrAnimData[retrieve_animation_index(gCurrAnimFrame, &gCurrAnimAttribute)];
|
||||
}
|
||||
|
||||
mtxf_rotate_xyz_and_translate_and_mul(rotation, translation, gMatStack[gMatStackIndex + 1], gMatStack[gMatStackIndex]);
|
||||
|
||||
inc_mat_stack();
|
||||
append_dl_and_return((struct GraphNodeDisplayList *)node);
|
||||
}
|
||||
|
||||
/**
|
||||
* Initialize the animation-related global variables for the currently drawn
|
||||
* object's animation.
|
||||
@@ -1282,7 +1230,6 @@ void geo_process_node_and_siblings(struct GraphNode *firstNode) {
|
||||
case GRAPH_NODE_TYPE_GENERATED_LIST: geo_process_generated_list ((struct GraphNodeGenerated *) curGraphNode); break;
|
||||
case GRAPH_NODE_TYPE_BACKGROUND: geo_process_background ((struct GraphNodeBackground *) curGraphNode); break;
|
||||
case GRAPH_NODE_TYPE_HELD_OBJ: geo_process_held_object ((struct GraphNodeHeldObject *) curGraphNode); break;
|
||||
case GRAPH_NODE_TYPE_BONE: geo_process_bone ((struct GraphNodeBone *) curGraphNode); break;
|
||||
default: geo_try_process_children ((struct GraphNode *) curGraphNode); break;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user