def setActive():
	leftKey = Keyboard("left");
	leftKey.on(moveLeft);
	rightKey = Keyboard("right");
	rightKey.on(moveRight);

	setControlsEnabled(True);

	Update.on(lambda: updatePosition());
def setActive():
    leftKey = Keyboard("left")
    leftKey.on(moveLeft)
    rightKey = Keyboard("right")
    rightKey.on(moveRight)

    setControlsEnabled(True)

    Update.on(lambda: updatePosition())
def setActive(value):
	global isActive;
	isActive = value;

	keyboardEvent = Keyboard("action");
	keyboardEvent.on(actionKeyboard);

	if isActive:
		Update.on(checkForAction);
示例#4
0
def setActive(value):
    global isActive
    isActive = value

    keyboardEvent = Keyboard("action")
    keyboardEvent.on(actionKeyboard)

    if isActive:
        Update.on(checkForAction)
示例#5
0
def setActive(value):
    global isActive
    isActive = value

    if value:
        keyboardEvent = Keyboard("action")
        keyboardEvent.on(keyboardInput)

        cancelEvent = Keyboard("escape")
        cancelEvent.on(cancelInput)
def setActive(value):
	global isActive;
	isActive = value;

	if value:
		keyboardEvent = Keyboard("action");
		keyboardEvent.on(keyboardInput);

		cancelEvent = Keyboard("escape");
		cancelEvent.on(cancelInput);
def setActive(value):
	global isActive;
	isActive = value;

	if value:
		keyboardInput = Keyboard("inventory");
		keyboardInput.on(keyboardOpenInventory);

		selectItem = Keyboard("action");
		selectItem.on(selectionItem);

		arrowUp = Keyboard("up");
		arrowUp.on(moveSelectionUp);
		arrowDown = Keyboard("down");
		arrowDown.on(moveSelectionDown);
示例#8
0
def setActive(value):
    global isActive
    global usedInterface
    isActive = value

    if value:
        keyboardInput = Keyboard("escape")
        keyboardInput.on(keyboardOpenPause)
        usedInterface = GlobalVars.getVar("pauseInterface")

        selectItem = Keyboard("action")
        selectItem.on(selectionItem)

        arrowUp = Keyboard("up")
        arrowUp.on(moveSelectionUp)
        arrowDown = Keyboard("down")
        arrowDown.on(moveSelectionDown)
def setActive(value):
	global isActive;
	global usedInterface;
	isActive = value;

	if value:
		keyboardInput = Keyboard("escape");
		keyboardInput.on(keyboardOpenPause);
		usedInterface = GlobalVars.getVar("pauseInterface");

		selectItem = Keyboard("action");
		selectItem.on(selectionItem);

		arrowUp = Keyboard("up");
		arrowUp.on(moveSelectionUp);
		arrowDown = Keyboard("down");
		arrowDown.on(moveSelectionDown);
示例#10
0
def setActive(value):
	global isActive;
	global isOpen;
	global usedInterface;

	isActive = value;

	usedInterface = GlobalVars.getVar("menuInterface");
	usedInterface.setOutside(outsider);

	if value:
		selectItem = Keyboard("action");
		selectItem.on(selectionItem);

		arrowUp = Keyboard("up");
		arrowUp.on(moveSelectionUp2);
		arrowDown = Keyboard("down");
		arrowDown.on(moveSelectionDown2);
		arrowLeft = Keyboard("left");
		arrowLeft.on(closeGameMenu);
def setActive(value):
	global isActive;
	isActive = value;

	keyboardAction = Keyboard("escape");
	keyboardAction.on(doClear);
示例#12
0
def setActive(value):
    global isActive
    isActive = value

    keyboardAction = Keyboard("escape")
    keyboardAction.on(doClear)