Compose planet surfaces from profiles

This commit is contained in:
Loïc Wisniewski 2026-08-14 16:05:32 +02:00
commit 2f68515f33
19 changed files with 123 additions and 39 deletions

12
PlanetSurfaceProfiles.gd Normal file
View file

@ -0,0 +1,12 @@
class_name PlanetSurfaceProfiles
extends RefCounted
const DEFAULT_PROFILE_ID: String = "rocky"
const PROFILES: Dictionary = {
"rocky": preload("res://RockySurfaceProfile.tres"),
"gas": preload("res://GasSurfaceProfile.tres"),
}
static func get_profile(profile_id: String) -> Resource:
return PROFILES.get(profile_id, PROFILES[DEFAULT_PROFILE_ID])