def __init__(self): self.backgroundElement = None self.dynamicElements = [] screenSize = Global.getScreenSize() self.fade = { "direction": None, "interval": None, "running": False, "element": Image("assets/dot.png") } self.fade['element'].setSize(screenSize[0], screenSize[1]) self.fade['element'].setDepth(300) self.fade['element'].setAffectedByCamera(False) self.fade['element'].setOpacity(0)
def __init__(self): self.backgroundElement = None; self.dynamicElements = []; screenSize = Global.getScreenSize(); self.fade = { "direction" : None, "interval" : None, "running" : False, "element" : Image("assets/dot.png") }; self.fade['element'].setSize(screenSize[0], screenSize[1]); self.fade['element'].setDepth(300); self.fade['element'].setAffectedByCamera(False); self.fade['element'].setOpacity(0);
def __init__(self): super().__init__(); screenSize = Global.getScreenSize(); background = Image("assets/cinematics/test.png"); background.setSize(screenSize[0], screenSize[1]); background.setDepth(200); character = Image("assets/characterTest.png"); character.setPosition(100,100); character.setSize(100,100); character.setDepth(201); self.append(character, "character"); self.moveElementTo("character", 200,200, 2000); Global.setTimeout(self.whenArriveToEnd, 2000); self.setBackground(background);
def __init__(self): super().__init__() screenSize = Global.getScreenSize() background = Image("assets/cinematics/test.png") background.setSize(screenSize[0], screenSize[1]) background.setDepth(200) character = Image("assets/characterTest.png") character.setPosition(100, 100) character.setSize(100, 100) character.setDepth(201) self.append(character, "character") self.moveElementTo("character", 200, 200, 2000) Global.setTimeout(self.whenArriveToEnd, 2000) self.setBackground(background)