diff --git a/scripts/Statemachine/ColorBar.gd b/scripts/Statemachine/ColorBar.gd index d538395..3c51ac6 100644 --- a/scripts/Statemachine/ColorBar.gd +++ b/scripts/Statemachine/ColorBar.gd @@ -22,7 +22,7 @@ func setCurrent(value: float): if value == currentValue: return forwardDirection = sign(value - currentValue) - currentValue = value + currentValue = clamp(value, minValue, maxValue) func _ready(): middleValue = currentValue diff --git a/scripts/Statemachine/EntityBase.gd b/scripts/Statemachine/EntityBase.gd index 0238148..8a688b2 100644 --- a/scripts/Statemachine/EntityBase.gd +++ b/scripts/Statemachine/EntityBase.gd @@ -28,7 +28,7 @@ var fields = { var inventory = { ItemStore.ItemType.BASEBALL: 100, ItemStore.ItemType.BASKETBALL: 100, - ItemStore.ItemType.APPLE: 3, + ItemStore.ItemType.APPLE: 10, } var inventoryMax = { ItemStore.ItemType.BASEBALL: INF, # 无限