idlegame/CLAUDE.md

1.7 KiB

CLAUDE.md

This file provides guidance to Claude Code (claude.ai/code) when working with code in this repository.

Project Overview

This is a Godot 4.3 idle game project. The game uses Godot's Forward Plus rendering method and is configured for 1280x720 resolution.

Commands

Running the Game

  • Open the project in Godot 4.3 Editor
  • Press F5 or click the Play button to run the main scene
  • Press F6 to run the current scene

Development Workflow

Since this is a Godot project, most development happens through:

  1. The Godot Editor for scene editing and visual work
  2. External text editor/IDE for GDScript files in scripts/
  3. Asset pipeline through assets/ subdirectories

Architecture

Scene Structure

  • Main.tscn: Root scene that instantiates all game elements
  • Player.tscn: CharacterBody2D-based player with movement controls
  • Scenes reference scripts via res://scripts/ paths
  • Scene UIDs are auto-generated by Godot (e.g., uid://b4ncr5x8y7kmt)

Script Organization

  • All GDScript files go in scripts/
  • Scripts extend appropriate Godot node types (Node2D, CharacterBody2D, etc.)
  • Player movement uses built-in input actions (ui_left, ui_right, ui_up, ui_down)

Asset Organization

assets/
├── sprites/  # 2D graphics and textures
├── sounds/   # Audio files (music, SFX)
└── fonts/    # Font files

Important Notes

  • The project uses placeholder graphics (PlaceholderTexture2D) for prototyping
  • Movement speed is defined as a constant in Player.gd (SPEED = 300.0)
  • The .godot/ directory is auto-generated and should never be edited manually
  • Scene files (.tscn) use Godot's text format and can be edited manually if needed, but prefer using the Godot Editor