I was pondering this earlier and wasn't sure if it was possible. Say, for example you had 2 objects; spam and eggs, and you wanted to create a function to change attributes - e.g. colour.
So spam.colour = 'Blue' and eggs.colour = 'Green'. How would you change that attribute using a nice elegant function? An example of my thinking is below (I know it won't work, but hopefully you get my drift).
def changeColour(objName, colour): [INDENT]objName.colour=colour[/INDENT]
I want to be able to change the attribute like this:
This is probably a daft question, and I apologise for my explaining skills. Thanks for your patience :P
Thanks in advance :)