View Full Version : Can't get a key to form

04 April 2009, 11:16 AM
I'm trying to have objects sit in place until it's time to move them and then start moving. This is what I tried but it's not working.

f = openfile "c:\\transforms.csv"
set animate on
if (f != undefined) then
skiptonextline f
while not eof f do
sliderTime = 0
TransformName = readdelimitedstring f ","
Xpos1 = readValue f
Ypos1 = readValue f
Zpos1 = readValue f
Start_Time = readValue f
End_Time = readValue f
DelXpos = readValue f
DelYpos = readValue f
DelZpos = readValue f
Point pos:[Xpos1,Ypos1,Zpos1] isSelected:on name:TransformName
addNewKey $.pos.controller.X_Position.controller Start_Time
addNewKey $.pos.controller.Y_Position.controller Start_Time
addNewKey $.pos.controller.Z_Position.controller Start_Time
sliderTime = End_Time
move $ [DelXpos,DelYpos,DelZpos]
messageBox "Open Failed" title:"Error!"

04 April 2009, 07:41 PM
1) You are missing a ")" to close the scope of your script (i.e. matching the opening "(" at the start of it). Running the code without it leaves the Maxscript parser waiting for another command.

2) Include some or all of the CSV file you are referencing. Can't help you until we can see what data you are actually trying to read into 3ds Max.

CGTalk Moderation
04 April 2009, 07:41 PM
This thread has been automatically closed as it remained inactive for 12 months. If you wish to continue the discussion, please create a new thread in the appropriate forum.