s="highlightable default" tabindex=-1><div class=flex-block-wrapper><div id=head-tags></div><div class="corner-ribbon top-right sticky green"><a href=/godot_recipes/4.x/>3.x</a></div><article class=default><h1 id=adding-input-actions-in-code>Adding Input Actions in code</h1><h2 id=problem>Problem</h2><p>You need to add actions to the InputMap at runtime.</p><h2 id=solution>Solution</h2><p>Typically, you&rsquo;ll add actions to the InputMap via <em>Project Settings</em>, as shown in <a href=/godot_recipes/3.