Game development

Stage 2 · Lesson 4 of 7

Small scripts and composition

Programming for games

Good gameplay code is built from small parts with one job each: a health , a mover, a damage dealer, a pickup. attaches components to . Godot builds scenes from child nodes.

Unreal adds to Actors. Building objects from parts like this is called composition. You can make a new enemy by combining existing pieces, instead of writing a new class or copying code.

It also makes bugs easier to find, because each part is small. (one class extending another) still has a place, such as a base enemy class, but keep those family trees shallow.

Common trapa single player script of thousands of lines that handles input, health, animation, sound and UI together.

A question to check yourself, an AI practice session and 1 cheat sheet entry come with the full roadmap. Unlock

Resources for this stage

Start with· follow one of these

  • CourseFree
    Unity Learn: Junior Programmer Pathway

    Unity Technologies · Beginner

    Unity's official free C# pathway, with small playable projects in every unit

  • GuideFree
    Learn C#

    Microsoft · Beginner

    Microsoft's free C# lessons, for the language itself when Unity code feels unfamiliar

Practise

  • Free mentored exercises in C# and C++ to strengthen the language outside the engine

Keep handy

Also worth your time

Mark this stage as not done?