Fix team builder issues, Added startup import checks for consistency
🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
parent
08f7aa8ea8
commit
39ba55832d
5 changed files with 192 additions and 60 deletions
|
|
@ -90,7 +90,17 @@ class Exploration(BaseModule):
|
|||
self.send_message(channel, f"{nickname}: '{destination}' is not a valid location!")
|
||||
return
|
||||
|
||||
# Check if player can access this location
|
||||
# CRITICAL FIX: Check and award any outstanding achievements before checking travel requirements
|
||||
# This ensures players get credit for achievements they've earned but haven't been awarded yet
|
||||
print(f"🔄 Checking all achievements for {nickname} before travel...")
|
||||
|
||||
# Check ALL possible achievements comprehensively
|
||||
all_new_achievements = await self.game_engine.check_all_achievements(player["id"])
|
||||
if all_new_achievements:
|
||||
for achievement in all_new_achievements:
|
||||
self.send_message(channel, f"🏆 {nickname}: Achievement unlocked: {achievement['name']}! {achievement['description']}")
|
||||
|
||||
# Now check if player can access this location (after awarding achievements)
|
||||
missing_requirements = await self.database.get_missing_location_requirements(player["id"], location["id"])
|
||||
if missing_requirements:
|
||||
# Build specific message about required achievements
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue