Course Template

Space Invaders with frameCraft – Arcade Game Step by Step

Basics of frameCraft Games with Space Invaders

Category: frameCraft Language: Python Components: 11 View Completed Game
Preview Image: Space Invaders with frameCraft – Arcade Game Step by Step

Didactic Objective

This template leads step-by-step into the construction of a simple Space-Invaders prototype using frameCraft. The focus is on the professional competences to structure a game in **Scene, Entities, Collider, Inputs, Rules, States and Presentation** and systematically transfer these elements into executable code. The construction combines **Modeling and Implementation**, where game objects are first described as named entities with properties and states, and then controlled using loops, rules, collisions, and scene variables. Professionally, the template is to be assigned in the field of game programming with a focus on **structured game logic, object-oriented thinking, and reusable patterns** such as pools, tags, and state variables.

Competence Focuses

The template bundles professional and methodological focuses of the frameCraft-based arcade prototype in sequentially building programming components.

  • Understand Game Structure: Window, Scene, Scene Layout, Entity, Collider, and graphical representation are introduced as basic components of a frameCraft game.
  • Input modeling: Keyboard actions and virtual touch buttons are bundled under common action names and evaluated in rules.
  • Movement control: Horizontal speed, boundary restriction, and time-controlled swarm movement clarify controlled state changes on the game field.
  • Object quantities structure: Shots and enemies are organized as recognizable groups with numbered names, loops, nested loops, and tags.
  • Game mechanics implementation: Shot pool, collisions, points, HUD display, and hit processing bring the central processes of the prototype together.
  • State management: Win, loss, restart, lock variables, and resetting changeable values show handling global scene states.
  • Display enhancement: Graphics from basic shapes and explosions as effect pool expand the prototype with visible feedback without additional game logic.

Structure of components

The components lead from static start image over control, shots, enemies, collisions, and states to restart and hit effects; each step extends the existing prototype with a clearly defined functional competence.

Preview: Funny spaceship with frameCraft

Funny spaceship with frameCraft

The entry clarifies the basic structure from GAME, SCENE, SCENE_BUILD, Entity, RECT and GFX and sets a visible spaceship as a starting point for the prototype.

Fifteen minutes 🧩 1 Aufgaben
Preview: Spaceship with buttons to control

Spaceship with buttons to control

This module adds keyboard actions, virtual buttons, a control rule, vx-movement and boundary as the first interactive game logic.

Twenty minutes 🧩 1 Aufgaben
Preview: Single shot to add

Single shot to add

The existing prototype is extended by a single prepared projectile, whose activation, position, vy-movement and deactivation show the basic flow of a shot.

Twenty minutes 🧩 1 Aufgaben
Preview: Multiple shots with pool

Multiple shots with pool

The single shot is expanded to a pool of numbered projectiles, introducing loops, free entities and a fire barrier as reusable arcade patterns.

⏱️ 20 min 🧩 1 Aufgaben
Preview: Enemy line with loop

Enemy line with loop

The template extends the game by multiple enemies, which are systematically generated with a for-loop, numbered names, calculated positions and common tags.

⏱️ 20 min 🧩 1 Aufgaben
Preview: Enemy swarm with loops

Enemy Swarm with Loops

A two-dimensional swarm of enemies is created through nested loops, resulting in rows, columns, calculated coordinates, and a regular naming scheme.

Time: 20 minutes 🧩 1 Task
Preview: Hits and Points

Hits and Points

Collisions between shots and enemies, deactivation by alive, point values in ctx.vars, and a HUD display connect object states with game feedback.

Time: 20 minutes 🧩 1 Task
Preview: Enemy Swarm Moving Together

Enemy Swarm Moving Together

The enemy group receives a time-controlled step movement, with swarm boundaries determined, directions stored, and living enemies moved together.

Time: 20 minutes 🧩 1 Task
Preview: Game Over in Space Invaders

Game Over in Space Invaders

This module combines game states, status messages, win and loss conditions, and hiding the game field as final logic of the prototype.

Time: 20 minutes 🧩 1 Task
Preview: Space Invaders: Clean Restart

Space Invaders: Clean Restart

The restart module shows how input actions, lock variables, RESTART, and explicit start values for variables and entities work together for a robust reset.

18 minutes 🧩 1 Task
Preview: Hit Explosion add

Hit Explosion add

Finally, a pool of effects adds short explosions with remaining time, ctx.dt and animated GFX without changing the existing hit and point logic.

20 minutes 🧩 1 Tasks
Use this template as a structured basis for your own frameCraft teaching projects. Test the template

Contents at a glance

The following overview summarizes the framework data and subject matter derived from the template.

AspectClassification
CategoryframeCraft
Programming languagePython 2 -> @@ITEM_0001@@Python 2 (no translation needed, as it's a programming language name)
Modules11
Total duration213 min -> @@ITEM_0001@@18 minutes and 33 seconds
Central contentsGame window, scene, entity, collider, graphics, control, shots, enemies, collisions, points, game states, restarts, and explosions
Teacher focusStep-by-step construction of a Space Invaders prototype with structured game logic
This template guides the construction of a Space Invaders prototype in a structured manner from scene to game states and effects.

The modules make learning objectives and intermediate steps transparent and can be easily connected to teaching series on frameCraft programming. The competency build-up ranges from the basic structure of a game to linking input, object groups, collisions, and states.

You can try out the template via demo access and select or adapt the individual building blocks according to your learning group.