예제 #1
0
    def on_logic_frame(self):
        movement_speed = 1.0
        input = omnia.get_input()
        transform = omnia.get_component("Transform")

        if input.is_pressed(["s", "dpad_down"]):
            transform.globally_translate_z(movement_speed)
        elif input.is_pressed(["w", "dpad_up"]):
            transform.globally_translate_z(-movement_speed)

        if input.is_on_release("p"):
            omnia.get_component("Camera").toggle_wireframe_mode()
예제 #2
0
    def on_logic_frame(self):
        movement_speed = 1.0
        input = omnia.get_input()
        transform = omnia.get_component("Transform")

        if input.is_pressed(["s", "dpad_down"]):
            transform.globally_translate_y(-movement_speed)
        elif input.is_pressed(["w", "dpad_up"]):
            transform.globally_translate_y(movement_speed)
예제 #3
0
 def on_start(self):
     omnia.get_component("CountdownTimer").start(2.0)
예제 #4
0
 def on_logic_frame(self):
     countdown_timer =  omnia.get_component("CountdownTimer")
     if (countdown_timer.is_finished()):
         omnia.load_scene("selection_menu/scenes/entry.yml")
 def on_logic_frame(self):
     transform = omnia.get_component("Transform")
     transform.rotate_x(1.0)
     transform.rotate_y(2.0)
예제 #6
0
 def on_logic_frame(self):
     omnia.get_component("Transform").rotate_y(0.325)
예제 #7
0
    def on_logic_frame(self):

        if omnia.has_component("UITextLabel"):
            current_time_string = time.strftime("%H:%M:%S", time.localtime())
            ui_text_label = omnia.get_component("UITextLabel")
            ui_text_label.set_text("Time: " + current_time_string)
 def on_start(self):
     countdown_timer = omnia.get_component("CountdownTimer")
     countdown_value = 5.0
     countdown_timer.start(countdown_value)
 def on_logic_frame(self):
     if omnia.get_component("CountdownTimer").is_finished():
         omnia.load_scene("assets/scenes/debug.yml")