JHN
01-11-2008, 10:49 AM
I'm having a problem with the cacheOps struct.
I have some spinners that sets the values of the pointcache in out and sample data.
I also have a button to cache out all objects with the new settings (on the same rollout).
Now when I use the cacheOps.recordCache it restores the values I had beforing starting the tool. So now I'm guessing... does cacheOps cache the pointcache settings in the scene on initializing or something. It's very weird. I see settings are good on the pointcaches but when I hit the record button it restores the old values from before the tool (dialog) started... When I hit the record button on the modifier itself.. it does keep the new setings... So the problem is in the for loop calling the cacheOps function.
I can't really post the code as I would need to post the whole tool, and it's hard to extract only the "bad code" as it's a rollout dialog and a lot of custom functions...
when i make a simple for loop with cacheOps the problem doesn't exist...
Baffled...
-Johan
I have some spinners that sets the values of the pointcache in out and sample data.
I also have a button to cache out all objects with the new settings (on the same rollout).
Now when I use the cacheOps.recordCache it restores the values I had beforing starting the tool. So now I'm guessing... does cacheOps cache the pointcache settings in the scene on initializing or something. It's very weird. I see settings are good on the pointcaches but when I hit the record button it restores the old values from before the tool (dialog) started... When I hit the record button on the modifier itself.. it does keep the new setings... So the problem is in the for loop calling the cacheOps function.
I can't really post the code as I would need to post the whole tool, and it's hard to extract only the "bad code" as it's a rollout dialog and a lot of custom functions...
when i make a simple for loop with cacheOps the problem doesn't exist...
Baffled...
-Johan
