Jayme McColgan Posted January 12, 2022 Share Posted January 12, 2022 TLDR: i looking for a way to use vs.SetRField() on a selected PIO (in this case a stage deck) and have it refresh itself before continuing the script. i'm working on a plugin that takes objects, converts them to 3dpolys, and bounces out their points to a file. I'm trying to cut down on the amount of points by simplifying the objects as much as possible before converting... lets say i have a "Stage Deck" object and i want to change its "Structure" field from "Legs-Basic" to "Simple" which really cuts down on its poly count. but when i try to use vs.SetRField() to change that field it doesn't seem to refresh the geometry... after the script runs you can see that the field was changed but the geometry is still the same. i've tried the slu of resets and refresh commands and none of them seem to be helping. ive also tried changing the settings and then duplicating the object with vs.Duplicate() but vs.LNewObj() doesn't seem to be working with that. Quote Link to comment
Pat Stanford Posted January 12, 2022 Share Posted January 12, 2022 I don't think you can do that in Vectorscript or Python. Objects are only regenerated at the end of the script execution. It may be possible in the SDK. Hopefully @JBenghiat will set us both straight. Quote Link to comment
JBenghiat Posted January 12, 2022 Share Posted January 12, 2022 You can force an object to reset immediately by setting its object variable 1167 to true. However, I believe this only works if the object is SDK based, and I’m not sure about the stage decks. In this specific case, you could always reverse engineer what the stage deck is doing and calculate your 3D points based on the stage deck’s parameters and location. 1 Quote Link to comment
Sam Jones Posted January 12, 2022 Share Posted January 12, 2022 Damn! I've been wanting to know about this for 20 years. 1 Quote Link to comment
Jayme McColgan Posted January 16, 2022 Author Share Posted January 16, 2022 On 1/12/2022 at 2:55 PM, JBenghiat said: You can force an object to reset immediately by setting its object variable 1167 to true. However, I believe this only works if the object is SDK based, and I’m not sure about the stage decks. In this specific case, you could always reverse engineer what the stage deck is doing and calculate your 3D points based on the stage deck’s parameters and location. yeah ive been exploring this idea based on if its flipped or not but there are so many different variables to account for. ill post back if when i come up with a good way. Quote Link to comment
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.