Add fish selling, buyer profiles, and player wallet

This commit is contained in:
Alexander Sellite 2026-07-25 16:27:07 -04:00
parent fb04615600
commit d2fe367891
25 changed files with 738 additions and 5 deletions

View file

@ -1,11 +1,13 @@
extends Node3D
const FishingSpotType = preload("res://fishing/fishing_spot.gd")
const FishBuyerProfileType = preload("res://economy/fish_buyer_profile.gd")
const FishPoolType = preload("res://fish/fish_pool.gd")
const GameUIType = preload("res://ui/game_ui.gd")
const PlayerType = preload("res://player/player.gd")
@export var fish_catalog: FishPoolType
@export var pelican_buyer_profile: FishBuyerProfileType
@onready var _player: PlayerType = %Player
@onready var _fishing_spot: FishingSpotType = %FishingSpot
@ -13,6 +15,10 @@ const PlayerType = preload("res://player/player.gd")
func _ready() -> void:
_player.fish_sale_service.setup(
_player.inventory,
_player.wallet
)
_fishing_spot.setup(
_player,
_player.inventory,
@ -22,6 +28,9 @@ func _ready() -> void:
_player,
_player.inventory,
_player.collection_log,
_player.wallet,
_player.fish_sale_service,
pelican_buyer_profile,
fish_catalog,
_fishing_spot
)

View file

@ -1,4 +1,4 @@
[gd_scene load_steps=7 format=3]
[gd_scene load_steps=8 format=3]
[ext_resource type="PackedScene" path="res://world/test_world.tscn" id="1_world"]
[ext_resource type="PackedScene" path="res://player/player.tscn" id="2_player"]
@ -6,10 +6,12 @@
[ext_resource type="PackedScene" path="res://fishing/fishing_spot.tscn" id="4_spot"]
[ext_resource type="PackedScene" path="res://ui/game_ui.tscn" id="5_ui"]
[ext_resource type="Resource" path="res://fish/pools/test_water_pool.tres" id="6_pool"]
[ext_resource type="Resource" path="res://economy/buyers/pelicans.tres" id="7_pelicans"]
[node name="Main" type="Node3D"]
script = ExtResource("3_main")
fish_catalog = ExtResource("6_pool")
pelican_buyer_profile = ExtResource("7_pelicans")
[node name="TestWorld" parent="." instance=ExtResource("1_world")]