PDA

View Full Version : Lightwave 10.0 to 10.1 LScript Bone Code Breaks



semory
09-12-2011, 04:01 PM
Hello, I have some LScript generated from a C++ program that traverses a bone hierarchy and writes out all the bone and weight map information to an LScript. It works fine in 10.0, but breaks in 10.1. I was wondering if I was doing something wrong? In 10.1 it skeleton flashes in the correct positions and then it just lies flat with all positions reset to (0, 0, 1).

LScript looks like this:


@warnings
@script generic
@name ShowHide
generic
{
AddBone("root");
BoneType(2);
Position(-0,0.942209,-0.00962308);
BoneActive();

SelectByName("root");
AddChildBone("spine_00");
BoneType(2);
Position(0,0,0);
BoneActive();

SelectByName("spine_00");
AddChildBone("spine_01");
BoneType(2);
Position(0,0.0799357,0.00744194);
BoneActive();

SelectByName("spine_01");
AddChildBone("spine_02");
BoneType(2);
Position(0,0.0799009,-0.00561367);
BoneActive();

SelectByName("spine_02");
AddChildBone("neck");
BoneType(2);
Position(0,0.177038,-0.0388088);
BoneActive();

SelectByName("neck");
AddChildBone("head");
BoneType(2);
Position(0,0.0397031,-0.00552592);
BoneActive();

// etc.
}


In LightWave 10.0:
http://www.calstatela.edu/faculty/semory/lw1.jpg

In LightWave 10.1:
http://www.calstatela.edu/faculty/semory/lw2.jpg

Castius
09-12-2011, 04:17 PM
Make sure autokey is on.

semory
09-12-2011, 04:19 PM
Thanks Scott! Oops :-)!

Matt
09-14-2011, 11:05 AM
That made me smile! :)