How to reference Sprite object property in one class from another?
I dont know how to reference the 'top' property of the Sprite object in Livewires in one class, from another cla开发者_如何转开发ss??
Assuming that Sprite
is the class you dealing with...
This is how you access an object attribute:
>>> a = Sprite()
>>> a.top
This is how you access a class attribute:
>>> Sprite.top
Is this what you're looking for?
精彩评论