Explorar el Código

Merge pull request #2469 from HeartoLazor/patch-1

Updated set_as_action code
Rémi Verschelde hace 6 años
padre
commit
8447a79e59
Se han modificado 1 ficheros con 2 adiciones y 1 borrados
  1. 2 1
      tutorials/inputs/inputevent.rst

+ 2 - 1
tutorials/inputs/inputevent.rst

@@ -185,7 +185,8 @@ The Input singleton has a method for this:
 
     var ev = InputEventAction.new()
     # set as move_left, pressed
-    ev.set_as_action("move_left", true)
+    ev.action = "move_left"
+    ev.pressed = true
     # feedback
     Input.parse_input_event(ev)