diff --git a/project.godot b/project.godot index 173ee6f..b95920e 100644 --- a/project.godot +++ b/project.godot @@ -30,10 +30,6 @@ window/size/viewport_width=1280 window/size/viewport_height=720 window/stretch/mode="viewport" -[physics] - -3d/physics_engine="Jolt Physics" - [input] move_left={ @@ -61,6 +57,10 @@ move_down={ ] } +[physics] + +3d/physics_engine="Jolt Physics" + [rendering] rendering_device/driver.windows="d3d12" diff --git a/scripts/perk_card.gd b/scripts/perk_card.gd index d331031..edc166d 100644 --- a/scripts/perk_card.gd +++ b/scripts/perk_card.gd @@ -93,7 +93,10 @@ func _build_recipe_panel(perk: Perk) -> void: fruit.mouse_filter = Control.MOUSE_FILTER_IGNORE var atlas := AtlasTexture.new() atlas.atlas = _FRUIT_ATLAS - atlas.region = Rect2(1, 2, 16, 15) if recipe[i] == SpellLibrary.APPLE else Rect2(55, 19, 15, 16) + match recipe[i]: + SpellLibrary.APPLE: atlas.region = Rect2(1, 2, 16, 15) + SpellLibrary.GRAPE: atlas.region = Rect2(55, 19, 15, 16) + SpellLibrary.CHILI: atlas.region = Rect2(19, 37, 16, 16) fruit.texture = atlas fruit.custom_minimum_size = Vector2(32, 32) fruit.stretch_mode = TextureRect.STRETCH_KEEP_ASPECT_CENTERED