weird and annoying error message
Moderators: Víctor Paredes, Belgarath, slowtiger
weird and annoying error message
OKay, so, while working on walk cycles (see my other threads), I started a new project, imported some of my characters (as AS objects) into it, and worked on the walk cycles in this new project.
I used Vern's save/load bone positions script to copy the walk cycle from one of my male characters to a female. I tweaked it a little bit, and decided it was good to go. The tweaking of the keyframes for the walk cycle for the lady was in the main timeline, not in an action timeline. So, I go to take the keys from the main timeline and put them in a walk action for the lady, and I keep getting this error message every time I select/make active the walk action:
"error: creating new objects in the middle of an action can lead to unexpected results. Stop all actions and restart the script."
This is a repeatable issue, and I should note that even when I open/make active a walk action that was already existent, in my male character's bone layer, I get this error. I don't get what I'm doing that's making ASP mad at me. Is this an actual issue? Or something I can ignore. It pops up whenever I make any of the actions in any of the bone layers in this new project active/open them.
I can't acutally SEE any problems, I just keep getting the box.
On a Mac, by the way, if that's relevant.
I used Vern's save/load bone positions script to copy the walk cycle from one of my male characters to a female. I tweaked it a little bit, and decided it was good to go. The tweaking of the keyframes for the walk cycle for the lady was in the main timeline, not in an action timeline. So, I go to take the keys from the main timeline and put them in a walk action for the lady, and I keep getting this error message every time I select/make active the walk action:
"error: creating new objects in the middle of an action can lead to unexpected results. Stop all actions and restart the script."
This is a repeatable issue, and I should note that even when I open/make active a walk action that was already existent, in my male character's bone layer, I get this error. I don't get what I'm doing that's making ASP mad at me. Is this an actual issue? Or something I can ignore. It pops up whenever I make any of the actions in any of the bone layers in this new project active/open them.
I can't acutally SEE any problems, I just keep getting the box.
On a Mac, by the way, if that's relevant.
Hey basshole...I get the same message and it sucks!!!
Vern seems to think it's to do with a recent script I may have installed. Check here for a more detailed explanation.
viewtopic.php?t=12764&highlight=error
Cheers
D.K
viewtopic.php?t=12764&highlight=error
Cheers
D.K
Okay, here's another weird thing. Somehow a bunch of my styles have magically been renamed.
Say I had one called "blonde hair". Now, it's "[name of bone layer] - blonde hair"
Let me guess. . .this is 'cause I imported objects/bone layers from the master project (with all my charactesr) into another to create those walk cycles, then imported them BACK into the master project from the walk cycle project and deleted the original bone layers/characters?
Oy.
Say I had one called "blonde hair". Now, it's "[name of bone layer] - blonde hair"
Let me guess. . .this is 'cause I imported objects/bone layers from the master project (with all my charactesr) into another to create those walk cycles, then imported them BACK into the master project from the walk cycle project and deleted the original bone layers/characters?
Oy.
Yes, the funky style names come from importing another AS file. It's annoying especially if you have the same styles. Now you have duplicates. I often "fix" this by using a text editor but it's a pain in the arse.
That error you get is due to a script that has an "onload" function that warns about doing stuff inside an action. It's a real pain. You have to find one of the scripts that has this code. You can delete or "comment it out" by putting:
Around that section of the code.
-vern
That error you get is due to a script that has an "onload" function that warns about doing stuff inside an action. It's a real pain. You have to find one of the scripts that has this code. You can delete or "comment it out" by putting:
Code: Select all
--[[
--]]-vern
Thanks. I see now that by expanding the window/dialogue box that has the styles/shapes buttons and the swatches that when you open the styles, you can see the full names. Much easier to navigate.
Regarding that script, do you know WHICH scripts have that code? I have only installed a few that weren't native to ASP upon its installation. Copy flip bones, save/load bone position. . .that may be it.
Also, I don't mean to be dense, but if I found that script, what exactly do I do with it? Will it simply open in a text editor if I double click? And then do I search for that word, "onload"? And where do I put those brackets, if I find this code, exactly? Literally at the beginning and ends of those code lines, like an HTML tag? I'm not a programming guy at all. Sorry.
Regarding that script, do you know WHICH scripts have that code? I have only installed a few that weren't native to ASP upon its installation. Copy flip bones, save/load bone position. . .that may be it.
Also, I don't mean to be dense, but if I found that script, what exactly do I do with it? Will it simply open in a text editor if I double click? And then do I search for that word, "onload"? And where do I put those brackets, if I find this code, exactly? Literally at the beginning and ends of those code lines, like an HTML tag? I'm not a programming guy at all. Sorry.
The scripts are just plain ascii text. They will open in any text editor.
Look for this code:
Comment out the print function or the whole thing:
-vern
Look for this code:
Code: Select all
function HV_SAVE_BONE_ANIMATION:IsEnabled(moho)
if (moho.layer:CurrentAction() ~= "") then
print ("Error: Creating new objects in the middle of an action can lead to unexpected results")
print ("Stop all actions and restart the script.")
return false
end
return true
end
Code: Select all
function HV_SAVE_BONE_ANIMATION:IsEnabled(moho)
--[[
if (moho.layer:CurrentAction() ~= "") then
--+print ("Error: Creating new objects in the middle of an action can lead to unexpected results")
--+print ("Stop all actions and restart the script.")
return false
end
--]]
return true
end
Last edited by heyvern on Fri Feb 20, 2009 3:15 pm, edited 1 time in total.
From what I can understand Vern says that te scripts contain this "Error" message. If you search through your suspected scripts, find the error message and put "Comments" around it so it does not pop up.
EDIT: Darn...I was one second too slow on the Submit button there Vern
Cheers
D.K
EDIT: Darn...I was one second too slow on the Submit button there Vern
Cheers
D.K
Last edited by DK on Fri Feb 20, 2009 3:17 pm, edited 1 time in total.
Keep in mind that some of the scripts that contain that code... uh... might do weird things if you use them inside an action. I've never seen this though. In the past a ton of the scripts had this code and caused all kinds of trouble. I have been trying to to comment them out.
I might have missed it on that save bone script or some others.
-vern
I might have missed it on that save bone script or some others.
-vern
But you don't really use the save bone script "inside an action," right?
It seems like (and I tried to load it into an action tlmeline) it will only load the script to the main timeline. Then you take those keys in the main timeline and "insert copy" back into the action. That's how I was doing it, anyway.
I mean, they're just keyframes, once they're in the timeline, right? No different from any other keys? It's only while you're doing the saving/loading that the script is actually "doing something?"
It seems like (and I tried to load it into an action tlmeline) it will only load the script to the main timeline. Then you take those keys in the main timeline and "insert copy" back into the action. That's how I was doing it, anyway.
I mean, they're just keyframes, once they're in the timeline, right? No different from any other keys? It's only while you're doing the saving/loading that the script is actually "doing something?"
Yes, you wouldn't use it "in" an action.
Basically the code that causes the error is a pain in the arse because tool and button scripts "run all the time". You don't have to use them in the action... they run as soon as you activate an action even if they aren't selected or used.
Here's what happened along the way...
Menu scripts DON'T run "all the time". Menu scripts may not work in an action which made that code a useful reminder. It wasn't a problem. Later on some of us discovered that a menu script can work as a BUTTON script... but now they are in the scripts tools directory and... well... then they "run all the time" causing those annoying error messages.
-vern
Basically the code that causes the error is a pain in the arse because tool and button scripts "run all the time". You don't have to use them in the action... they run as soon as you activate an action even if they aren't selected or used.
Here's what happened along the way...
Menu scripts DON'T run "all the time". Menu scripts may not work in an action which made that code a useful reminder. It wasn't a problem. Later on some of us discovered that a menu script can work as a BUTTON script... but now they are in the scripts tools directory and... well... then they "run all the time" causing those annoying error messages.
-vern