Message 1 of 2
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
I am creating a script to set the value of Morpher.
If I write the following code, I can set all Morpher to 100.
mph=$.morpher
for i = 1 to 100 do (
mph[i].value = 100
)
However, I do not want to set all values to 100.
I want to set the value of mouthOpen to 30, and the value of mouthSmile to 60, and so on.
And if I create the following code, there will be 100 loops each time, even though I have only set up 2 Morpheres.
I want to reduce the number of loops in order to create a faster code.
Is there anything I can do?
mph=$.morpher
for i = 1 to 100 do (
if "mouthOpen" == WM3_MC_GetName mph i then
{
mph[i].value = 30
}
if "mouthSmile " == WM3_MC_GetName mph i then
{
mph[i].value = 60
}
)
Solved! Go to Solution.