Weighted character selection

This commit is contained in:
2024-06-14 15:33:36 -04:00
parent ee6fa21177
commit 082b1353bc
36 changed files with 2914 additions and 160 deletions

View File

@@ -0,0 +1,14 @@
extends Resource
class_name Slot_Data
const MAX_STACK_SIZE: int = 99
@export var memberData: Member_Data
@export_range(1, MAX_STACK_SIZE) var quantity: int = 1: set = set_quantity
func set_quantity(value: int) -> void:
quantity = value
if quantity > 1 and not memberData.stackable:
quantity = 1
push_error("%s is not stackable, setting quantity to 1" % memberData.name)