How to use Opacity and Random method in pyleap?



Opacity: Changes the opacity of a sprite. The default value is 1(1 means opaque and 0 means transparent).

We can use the opacity value between 0 and 1.

Syntax to use opacity:

# Object will be partially transparent
object.opacity = 0.5

Check about the random methods here