tubeshowcase●1,524,254 videos♡ My collection 0
← Learn to Code

Learn to Code14:06

Scripting Basics - Write C# scripts and attach them to nodes (Part 5 of 9)

dotnet ↗

From the creator

In Episode 5 of our Godot C# training series, we bring your player character to life with code! This lesson introduces the fundamentals of scripting in Godot using C#, including how to handle input, apply movement, and rotate the player smoothly using physics-based logic. You'll learn how to use Godot’s built-in lifecycle and input methods, configure the Input Map for flexible controls, and write clean, reusable code to drive gameplay. By the end of this episode, your player will be fully controllable and responsive to keyboard input — and ready to interact with the world. ✅ What You'll Learn How to configure the Input Map for keyboard controls Using lifecycle methods like _Ready, _Process, and _PhysicsProcess Handling input with _UnhandledInput and _UnhandledKeyInput Writing movement logic using CharacterBody3D Applying smooth rotation with LerpAngle Organizing script variables with Export and ExportGroup Debugging common issues in Godot C# scripts ✅ Resources GitHub repo with starter and final projects -https://github.com/microsoft/godot-csharp-essentials Godot Website - https://godotengine.org/ ✅ Challenge Create an interactive object in your scene that responds to a button press — like a spinning obstacle or a moving block triggered by the Y key. ✅ Chapters 00:04 - Intro: Making the Player Move 01:00 - Setting Up the Input Map 02:00 - Creating Movement Actions 03:00 - Adding a C# Script to the Player 04:30 - Understanding Built-In Methods 05:30 - Input Handling and

Published 2025-10-22 · Watch on YouTube ↗
Availability and playback restrictions are controlled by the original channel.

Keep exploring Learn to Code