fix: add is_sheltered attribute to AgentSnapshot class

- Add is_sheltered parameter to AgentSnapshot in both locations
- Include is_sheltered in agent_data dictionary for idle chat

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
empty
2026-01-02 01:18:14 +08:00
parent 4f3bd5695c
commit ce0be0045d
7 changed files with 87 additions and 29 deletions

View File

@@ -63,6 +63,9 @@ class Agent(Base):
# Relationship 2.0 (Phase 17-B)
social_role = Column(String(20), default="neutral") # leader, follower, loner, neutral
# Shelter System (Phase 20-B)
is_sheltered = Column(Boolean, default=False)
def __repr__(self):
return f"<Agent {self.name} ({self.personality}) HP={self.hp} Energy={self.energy} Mood={self.mood}>"
@@ -88,7 +91,8 @@ class Agent(Base):
"location": self.location,
"is_sick": self.is_sick,
"immunity": self.immunity,
"social_role": self.social_role
"social_role": self.social_role,
"is_sheltered": self.is_sheltered
}