tag_all.py

"""Most tag transformations.
   by stephan)
"""
from slut import *

class Atlantis(World):
    def onSetup(self):
        self.name = "Tag"

        TagText(self, 'tag1', 32, 'bitstream_sans')
        self.tags['tag1'].setText('CADRE')
        self.tags['tag1'].moveBy(100, 100)
        self.tags['tag1'].setColor(1.0, 0.0, 0.0, 0.7)


    def onMouseButtonDown(self, event):
        #self.tags['tag1'].moveBy(30, 50)
        #self.tags['tag1'].rotBy(10)
        #self.tags['tag1'].scaleBy(0.5)
        #self.tags['tag1'].orbitBy(23)

        #self.tags['tag1'].moveBy(Tween(30, 20, 1))
        #self.tags['tag1'].rotBy(Tween(0, 0, 23, 3))
        #self.tags['tag1'].scaleBy(Tween(0.5, 0.5, 2))
        #self.tags['tag1'].orbitBy(Tween(0, 0, 23, 2))

        #self.tags['tag1'].moveBy(Thrust(2, 2))
        #self.tags['tag1'].rotBy(Thrust(10, 0, 0, 2))
        #self.tags['tag1'].scaleBy(Thrust(0.01, 0.01))
        #self.tags['tag1'].orbitBy(Thrust(0.0, 180.0, 0.0))

        #self.tags['tag1'].moveTo(200, 200)
        #self.tags['tag1'].rotTo(23)
        #self.tags['tag1'].scaleTo(1.5, 1.5)
        #self.tags['tag1'].orbitTo(23)

        self.tags['tag1'].moveTo(Tween(50, 200))
        self.tags['tag1'].rotTo(Tween(10, 5, 12, 4))
        self.tags['tag1'].scaleTo(Tween(1.5, 1.5, 1.5, 2))
        self.tags['tag1'].orbitTo(Tween(0, 23, 0))


atlantis = Atlantis()
atlantis.run()
Initiated by Stephan Hechenberger
Thanks to CADRE's 103