I have been investigating throwing up a message if the current figure is not Dawn, but I'm not real sure about the syntax for that. Does python just use if/else statements?
if InternalName.currentFigure [does not =] {not sure how to express that} "Dawn":
print "Whoa there partner!"
Here's how I would write that if/else statement:
Code:
if "Dawn" in InternalName.currentFigure():
#do all the stuff
else:
#give an error message
There are also try/except statements in python that can also be handy for catching things the code can just not do (which might not be what you have in this case). Here's an example from a script I've made that connects up nodes in the material room.
Code:
try:
node2.ConnectToInput(rootNode.Input(j))
print "Connected", node
except:
print "Count not connect nodes"
Basically it try the first statement, but if it can't do it, like maybe there is no node or input, it goes and does the except statement.