systems rework: buffs, prestige graph, research, modular architecture
Decouples core systems from centralized globals in favor of catalogue-based architecture and data-driven content. Key changes: - Prestige: node-based buff tech tree, graph panel, progress bar - Research: multi-worker system, per-generator research, xp generation - Ascension: meta-currency layer via multi-currency prestige resets - Buffs: refactored as generator-independent via catalogues - UI: currency panel, edge-scrolling camera + zoom, current-goal panel - Alchemy Tower: crafting building with recipe/cost system - Testing: 7 test suites (ascension, prestige, research, goals) - Content: migrated from hardcoded idles/ to gym format (tiny_sword)
This commit was merged in pull request #1.
This commit is contained in:
@@ -0,0 +1,18 @@
|
||||
class_name AlchemyCraftCatalogue
|
||||
extends Resource
|
||||
|
||||
## Catalogue of alchemy craft recipes
|
||||
@export var recipes: Array[AlchemyCraftRecipe] = []
|
||||
|
||||
func get_recipe_by_id(id: StringName) -> Variant:
|
||||
for recipe in recipes:
|
||||
if recipe != null and recipe.id == id:
|
||||
return recipe
|
||||
return null
|
||||
|
||||
func get_all_ids() -> Array[StringName]:
|
||||
var ids: Array[StringName] = []
|
||||
for recipe in recipes:
|
||||
if recipe != null and recipe.id != &"":
|
||||
ids.append(recipe.id)
|
||||
return ids
|
||||
@@ -0,0 +1 @@
|
||||
uid://biljlhsxr3rsc
|
||||
@@ -0,0 +1,10 @@
|
||||
[gd_resource type="Resource" script_class="AlchemyCraftCatalogue" format=3 uid="uid://diboykfbbxpfs"]
|
||||
|
||||
[ext_resource type="Script" uid="uid://biljlhsxr3rsc" path="res://docs/gyms/tiny_sword/buildings/alchemy_tower/recipes/alchemy_craft_catalogue.gd" id="1_cat"]
|
||||
[ext_resource type="Resource" uid="uid://by8qmuhvo38nn" path="res://docs/gyms/tiny_sword/buildings/alchemy_tower/recipes/mana_stone_recipe.tres" id="2_mana_recipe"]
|
||||
[ext_resource type="Resource" uid="uid://dliibkgb2mom0" path="res://docs/gyms/tiny_sword/buildings/alchemy_tower/recipes/cognite_recipe.tres" id="3_cognite_recipe"]
|
||||
[ext_resource type="Resource" uid="uid://nfpkv6a2u0wf" path="res://docs/gyms/tiny_sword/buildings/alchemy_tower/recipes/philosoper_stone_recipe.tres" id="3_pbygp"]
|
||||
|
||||
[resource]
|
||||
script = ExtResource("1_cat")
|
||||
recipes = [ExtResource("2_mana_recipe"), ExtResource("3_cognite_recipe"), ExtResource("3_pbygp")]
|
||||
@@ -0,0 +1,10 @@
|
||||
class_name AlchemyCraftRecipe
|
||||
extends Resource
|
||||
|
||||
## Recipe for crafting currencies at the Alchemy Tower
|
||||
@export var id: StringName = &""
|
||||
@export var output_currency: Currency
|
||||
@export var output_amount: int = 1
|
||||
|
||||
## Multi-currency cost to perform this craft
|
||||
@export var cost_entries: Array[CurrencyCostEntry] = []
|
||||
@@ -0,0 +1 @@
|
||||
uid://ddlnlpb0p750q
|
||||
@@ -0,0 +1,10 @@
|
||||
[gd_resource type="Resource" script_class="CurrencyCostEntry" format=3]
|
||||
|
||||
[ext_resource type="Script" uid="uid://ba8e403mb7hp0" path="res://docs/gyms/tiny_sword/buildings/alchemy_tower/recipes/currency_cost_entry.gd" id="1_cost"]
|
||||
[ext_resource type="Resource" uid="uid://dpbndqxvsffa0" path="res://docs/gyms/tiny_sword/currencies/magic_gold.tres" id="2_magic_gold"]
|
||||
|
||||
[resource]
|
||||
script = ExtResource("1_cost")
|
||||
currency = ExtResource("2_magic_gold")
|
||||
amount = 25
|
||||
metadata/_custom_type_script = "res://docs/gyms/tiny_sword/buildings/alchemy_tower/currency_cost_entry.gd"
|
||||
@@ -0,0 +1,11 @@
|
||||
[gd_resource type="Resource" script_class="AlchemyCraftRecipe" format=3 uid="uid://dliibkgb2mom0"]
|
||||
|
||||
[ext_resource type="Script" uid="uid://ddlnlpb0p750q" path="res://docs/gyms/tiny_sword/buildings/alchemy_tower/recipes/alchemy_craft_recipe.gd" id="1_recipe"]
|
||||
[ext_resource type="Resource" uid="uid://t6du7gm2ywbi" path="res://docs/gyms/tiny_sword/currencies/cognite.tres" id="2_xltlj"]
|
||||
[ext_resource type="Resource" path="res://docs/gyms/tiny_sword/buildings/alchemy_tower/recipes/cognite_cost_entry.tres" id="3_cost"]
|
||||
|
||||
[resource]
|
||||
script = ExtResource("1_recipe")
|
||||
id = &"cognite_recipe"
|
||||
output_currency = ExtResource("2_xltlj")
|
||||
cost_entries = [ExtResource("3_cost")]
|
||||
@@ -0,0 +1,6 @@
|
||||
class_name CurrencyCostEntry
|
||||
extends Resource
|
||||
|
||||
## Entry for multi-currency cost in alchemy recipes
|
||||
@export var currency: Currency
|
||||
@export var amount: int = 1
|
||||
@@ -0,0 +1 @@
|
||||
uid://ba8e403mb7hp0
|
||||
@@ -0,0 +1,10 @@
|
||||
[gd_resource type="Resource" script_class="CurrencyCostEntry" format=3]
|
||||
|
||||
[ext_resource type="Script" uid="uid://ba8e403mb7hp0" path="res://docs/gyms/tiny_sword/buildings/alchemy_tower/recipes/currency_cost_entry.gd" id="1_cost"]
|
||||
[ext_resource type="Resource" uid="uid://dpbndqxvsffa0" path="res://docs/gyms/tiny_sword/currencies/magic_gold.tres" id="2_magic_gold"]
|
||||
|
||||
[resource]
|
||||
script = ExtResource("1_cost")
|
||||
currency = ExtResource("2_magic_gold")
|
||||
amount = 10
|
||||
metadata/_custom_type_script = "res://docs/gyms/tiny_sword/buildings/alchemy_tower/currency_cost_entry.gd"
|
||||
@@ -0,0 +1,11 @@
|
||||
[gd_resource type="Resource" script_class="AlchemyCraftRecipe" format=3 uid="uid://by8qmuhvo38nn"]
|
||||
|
||||
[ext_resource type="Script" uid="uid://ddlnlpb0p750q" path="res://docs/gyms/tiny_sword/buildings/alchemy_tower/recipes/alchemy_craft_recipe.gd" id="1_recipe"]
|
||||
[ext_resource type="Resource" uid="uid://brctmnpmhjas6" path="res://docs/gyms/tiny_sword/currencies/mana_stone.tres" id="2_mana_stone"]
|
||||
[ext_resource type="Resource" path="res://docs/gyms/tiny_sword/buildings/alchemy_tower/recipes/mana_stone_cost_entry.tres" id="3_cost"]
|
||||
|
||||
[resource]
|
||||
script = ExtResource("1_recipe")
|
||||
id = &"mana_stone_recipe"
|
||||
output_currency = ExtResource("2_mana_stone")
|
||||
cost_entries = [ExtResource("3_cost")]
|
||||
@@ -0,0 +1,9 @@
|
||||
[gd_resource type="Resource" script_class="CurrencyCostEntry" format=3 uid="uid://cheww15gwet47"]
|
||||
|
||||
[ext_resource type="Resource" uid="uid://brctmnpmhjas6" path="res://docs/gyms/tiny_sword/currencies/mana_stone.tres" id="1_8mjcf"]
|
||||
[ext_resource type="Script" uid="uid://ba8e403mb7hp0" path="res://docs/gyms/tiny_sword/buildings/alchemy_tower/recipes/currency_cost_entry.gd" id="1_cost"]
|
||||
|
||||
[resource]
|
||||
script = ExtResource("1_cost")
|
||||
currency = ExtResource("1_8mjcf")
|
||||
amount = 10
|
||||
@@ -0,0 +1,9 @@
|
||||
[gd_resource type="Resource" script_class="CurrencyCostEntry" format=3 uid="uid://bprij85vf66at"]
|
||||
|
||||
[ext_resource type="Resource" uid="uid://t6du7gm2ywbi" path="res://docs/gyms/tiny_sword/currencies/cognite.tres" id="1_3oqnk"]
|
||||
[ext_resource type="Script" uid="uid://ba8e403mb7hp0" path="res://docs/gyms/tiny_sword/buildings/alchemy_tower/recipes/currency_cost_entry.gd" id="2_q6dwm"]
|
||||
|
||||
[resource]
|
||||
script = ExtResource("2_q6dwm")
|
||||
currency = ExtResource("1_3oqnk")
|
||||
amount = 10
|
||||
@@ -0,0 +1,12 @@
|
||||
[gd_resource type="Resource" script_class="AlchemyCraftRecipe" format=3 uid="uid://nfpkv6a2u0wf"]
|
||||
|
||||
[ext_resource type="Resource" uid="uid://cheww15gwet47" path="res://docs/gyms/tiny_sword/buildings/alchemy_tower/recipes/philosoper_stone_cost_entry_0.tres" id="1_jbac4"]
|
||||
[ext_resource type="Resource" uid="uid://co4fiqgluwit0" path="res://docs/gyms/tiny_sword/currencies/philosoper_stone.tres" id="1_o0mnq"]
|
||||
[ext_resource type="Script" uid="uid://ddlnlpb0p750q" path="res://docs/gyms/tiny_sword/buildings/alchemy_tower/recipes/alchemy_craft_recipe.gd" id="1_pxgqn"]
|
||||
|
||||
[resource]
|
||||
script = ExtResource("1_pxgqn")
|
||||
id = &"philosoper_stone_recipe"
|
||||
output_currency = ExtResource("1_o0mnq")
|
||||
cost_entries = [ExtResource("1_jbac4")]
|
||||
metadata/_custom_type_script = "uid://ddlnlpb0p750q"
|
||||
Reference in New Issue
Block a user