Calibrate the soul layer: innocent harvests, sane gifts, healing path
Run 5 findings: justice arrived (selfish health 31-64 vs nature 100, all 108 refusals theirs) but two pathologies emerged: the whole village maxed others-regard debris because the commons penalty line (50%) sat above the nature harvest floor (45%) and debris had no clearing path; and warmth- weighted asking + near-total gift transfers produced a 2,501-gift winter food-swapping loop. Fixes: commons line lowered to 40% (respectful harvesting never grazes it; strip-harvesting lives deep inside it); gifts capped at 3 with a kept reserve of 5; asking gated on genuine hunger; and giving now heals the giver slightly (-0.003 others-regard vs +0.02 per refusal) — harm stays an order of magnitude easier than healing. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
@@ -305,6 +305,9 @@ public class Npc
|
||||
// Ask whoever might help — chosen by memory, not omniscience.
|
||||
// The warm are asked first; the remembered-cold aren't asked
|
||||
// at all. A stranger gets the benefit of the doubt once.
|
||||
// Asking is for the genuinely hungry, not for topping a reserve —
|
||||
// this keeps gifts meaningful instead of a food-swapping loop.
|
||||
if (Nourishment >= 0.55f) { Enter(NpcState.Socializing); return; }
|
||||
float bestScore = float.MinValue;
|
||||
foreach (var other in gm.Npcs)
|
||||
{
|
||||
|
||||
+11
-4
@@ -28,7 +28,7 @@ public static class TradeSystem
|
||||
public static void RequestGift(Npc giver, Npc asker)
|
||||
{
|
||||
giver.Inventory.TryGetValue(MaterialKind.Food, out float giverFood);
|
||||
bool hasFood = giverFood > 3f;
|
||||
bool hasFood = giverFood > 6f; // above their own reserve — enough to share
|
||||
bool willing = giver.Soul.Generosity >= 0.3f || giver.GetWarmth(asker.Name) > 0.5f;
|
||||
|
||||
if (hasFood && willing)
|
||||
@@ -78,9 +78,12 @@ public static class TradeSystem
|
||||
{
|
||||
TradesToday++;
|
||||
|
||||
// Generosity decides how much of the surplus is given.
|
||||
float surplus = giver.Inventory[material] - 2f;
|
||||
float given = surplus * giver.Soul.Generosity;
|
||||
// Generosity decides how much of the surplus is given — but a gift
|
||||
// is a portion, not a pantry: the giver keeps a real reserve (5)
|
||||
// and hands over at most 3, so giving doesn't create the next asker.
|
||||
float surplus = Godot.Mathf.Max(0f, giver.Inventory[material] - 5f);
|
||||
float given = Godot.Mathf.Min(3f, surplus * giver.Soul.Generosity);
|
||||
if (given <= 0f) return;
|
||||
|
||||
giver.Inventory[material] -= given;
|
||||
receiver.Inventory.TryGetValue(material, out float has);
|
||||
@@ -92,6 +95,10 @@ public static class TradeSystem
|
||||
receiver.RecordEcho(giver.Name, +0.15f);
|
||||
giver.RecordEcho(receiver.Name, +0.05f);
|
||||
|
||||
// Acts of regard mend regard-blindness — slowly. Harm stays easier
|
||||
// than healing by an order of magnitude (refusal +0.02, gift -0.003).
|
||||
giver.Imprint.OthersRegard = Godot.Mathf.Max(0f, giver.Imprint.OthersRegard - 0.003f);
|
||||
|
||||
// The kindness lands on both atmospheres — gently.
|
||||
giver.Imprint.ExternalPerception -= 0.002f;
|
||||
receiver.Imprint.ExternalPerception -= 0.002f;
|
||||
|
||||
+4
-1
@@ -88,7 +88,10 @@ public class World
|
||||
node.Amount -= taken;
|
||||
HarvestedToday += taken;
|
||||
|
||||
float commons = node.MaxAmount * 0.5f;
|
||||
// The moral line sits below any respectful harvest floor (nature souls
|
||||
// stop at 45%) — ordinary sustainable taking never grazes it, while
|
||||
// strip-harvesting (selfish floor ~10%) lives deep inside it.
|
||||
float commons = node.MaxAmount * 0.4f;
|
||||
if (node.Amount < commons)
|
||||
{
|
||||
float takenBelow = Math.Min(taken, commons - node.Amount);
|
||||
|
||||
Reference in New Issue
Block a user