- Add Revive (50% HP) and Max Revive (100% HP) items to config/items.json - Extend database schema with fainted_at timestamp for pets table - Add last_heal_time column to players table for heal command cooldown - Implement comprehensive pet healing database methods: - get_fainted_pets(): Retrieve all fainted pets for a player - revive_pet(): Restore fainted pet with specified HP - faint_pet(): Mark pet as fainted with timestamp - get_pets_for_auto_recovery(): Find pets eligible for 30-minute auto-recovery - auto_recover_pet(): Automatically restore pet to 1 HP - get_active_pets(): Get active pets excluding fainted ones - get_player_pets(): Enhanced to filter out fainted pets when active_only=True - Update inventory module to handle revive and max_revive effects - Add proper error handling for cases where no fainted pets exist - Maintain case-insensitive item usage compatibility 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
253 lines
No EOL
7.9 KiB
JSON
253 lines
No EOL
7.9 KiB
JSON
{
|
|
"_config": {
|
|
"global_spawn_multiplier": 1.0,
|
|
"description": "Global multiplier for all item spawn rates. Set to 0.5 for half spawns, 2.0 for double spawns, etc.",
|
|
"admin_note": "Edit this value to globally adjust all item spawn rates. Individual item spawn_rate values can still be fine-tuned."
|
|
},
|
|
"healing_items": [
|
|
{
|
|
"id": 1,
|
|
"name": "Small Potion",
|
|
"description": "Restores 20 HP to a pet",
|
|
"rarity": "common",
|
|
"category": "healing",
|
|
"effect": "heal",
|
|
"effect_value": 20,
|
|
"locations": ["all"],
|
|
"spawn_rate": 0.0375
|
|
},
|
|
{
|
|
"id": 2,
|
|
"name": "Large Potion",
|
|
"description": "Restores 50 HP to a pet",
|
|
"rarity": "uncommon",
|
|
"category": "healing",
|
|
"effect": "heal",
|
|
"effect_value": 50,
|
|
"locations": ["all"],
|
|
"spawn_rate": 0.02
|
|
},
|
|
{
|
|
"id": 3,
|
|
"name": "Super Potion",
|
|
"description": "Fully restores a pet's HP",
|
|
"rarity": "rare",
|
|
"category": "healing",
|
|
"effect": "full_heal",
|
|
"effect_value": 100,
|
|
"locations": ["all"],
|
|
"spawn_rate": 0.0075
|
|
},
|
|
{
|
|
"id": 4,
|
|
"name": "Energy Berry",
|
|
"description": "Restores 15 HP and cures status effects",
|
|
"rarity": "uncommon",
|
|
"category": "healing",
|
|
"effect": "heal_status",
|
|
"effect_value": 15,
|
|
"locations": ["mystic_forest", "enchanted_grove"],
|
|
"spawn_rate": 0.03
|
|
},
|
|
{
|
|
"id": 18,
|
|
"name": "Revive",
|
|
"description": "Revives a fainted pet and restores 50% of its HP",
|
|
"rarity": "rare",
|
|
"category": "healing",
|
|
"effect": "revive",
|
|
"effect_value": 50,
|
|
"locations": ["all"],
|
|
"spawn_rate": 0.005
|
|
},
|
|
{
|
|
"id": 19,
|
|
"name": "Max Revive",
|
|
"description": "Revives a fainted pet and fully restores its HP",
|
|
"rarity": "epic",
|
|
"category": "healing",
|
|
"effect": "max_revive",
|
|
"effect_value": 100,
|
|
"locations": ["all"],
|
|
"spawn_rate": 0.002
|
|
}
|
|
],
|
|
"battle_items": [
|
|
{
|
|
"id": 5,
|
|
"name": "Attack Booster",
|
|
"description": "Increases attack damage by 25% for one battle",
|
|
"rarity": "uncommon",
|
|
"category": "battle",
|
|
"effect": "attack_boost",
|
|
"effect_value": 25,
|
|
"locations": ["all"],
|
|
"spawn_rate": 0.025
|
|
},
|
|
{
|
|
"id": 6,
|
|
"name": "Defense Crystal",
|
|
"description": "Reduces incoming damage by 20% for one battle",
|
|
"rarity": "uncommon",
|
|
"category": "battle",
|
|
"effect": "defense_boost",
|
|
"effect_value": 20,
|
|
"locations": ["crystal_caves", "frozen_peaks"],
|
|
"spawn_rate": 0.02
|
|
},
|
|
{
|
|
"id": 7,
|
|
"name": "Speed Elixir",
|
|
"description": "Guarantees first move in battle",
|
|
"rarity": "rare",
|
|
"category": "battle",
|
|
"effect": "speed_boost",
|
|
"effect_value": 100,
|
|
"locations": ["all"],
|
|
"spawn_rate": 0.0125
|
|
}
|
|
],
|
|
"rare_items": [
|
|
{
|
|
"id": 8,
|
|
"name": "Fire Stone",
|
|
"description": "A mysterious stone that radiates heat (future evolution item)",
|
|
"rarity": "epic",
|
|
"category": "evolution",
|
|
"effect": "none",
|
|
"effect_value": 0,
|
|
"locations": ["volcanic_chamber"],
|
|
"spawn_rate": 0.005
|
|
},
|
|
{
|
|
"id": 9,
|
|
"name": "Water Stone",
|
|
"description": "A mysterious stone that flows like water (future evolution item)",
|
|
"rarity": "epic",
|
|
"category": "evolution",
|
|
"effect": "none",
|
|
"effect_value": 0,
|
|
"locations": ["crystal_caves"],
|
|
"spawn_rate": 0.005
|
|
},
|
|
{
|
|
"id": 10,
|
|
"name": "Lucky Charm",
|
|
"description": "Increases rare pet encounter rate by 50% for 1 hour",
|
|
"rarity": "legendary",
|
|
"category": "buff",
|
|
"effect": "lucky_boost",
|
|
"effect_value": 50,
|
|
"locations": ["all"],
|
|
"spawn_rate": 0.0025
|
|
},
|
|
{
|
|
"id": 11,
|
|
"name": "Ancient Fossil",
|
|
"description": "A mysterious fossil from prehistoric times",
|
|
"rarity": "legendary",
|
|
"category": "special",
|
|
"effect": "none",
|
|
"effect_value": 0,
|
|
"locations": ["forgotten_ruins"],
|
|
"spawn_rate": 0.0025
|
|
}
|
|
],
|
|
"location_items": [
|
|
{
|
|
"id": 12,
|
|
"name": "Pristine Shell",
|
|
"description": "A beautiful shell that shimmers with ocean magic",
|
|
"rarity": "uncommon",
|
|
"category": "treasure",
|
|
"effect": "sell_value",
|
|
"effect_value": 100,
|
|
"locations": ["crystal_caves"],
|
|
"spawn_rate": 0.03
|
|
},
|
|
{
|
|
"id": 13,
|
|
"name": "Glowing Mushroom",
|
|
"description": "A mushroom that glows with mystical energy",
|
|
"rarity": "rare",
|
|
"category": "treasure",
|
|
"effect": "sell_value",
|
|
"effect_value": 200,
|
|
"locations": ["mystic_forest", "enchanted_grove"],
|
|
"spawn_rate": 0.015
|
|
},
|
|
{
|
|
"id": 14,
|
|
"name": "Volcanic Glass",
|
|
"description": "Sharp obsidian formed by intense heat",
|
|
"rarity": "uncommon",
|
|
"category": "treasure",
|
|
"effect": "sell_value",
|
|
"effect_value": 150,
|
|
"locations": ["volcanic_chamber"],
|
|
"spawn_rate": 0.025
|
|
},
|
|
{
|
|
"id": 15,
|
|
"name": "Ice Crystal",
|
|
"description": "A crystal that never melts, cold to the touch",
|
|
"rarity": "rare",
|
|
"category": "treasure",
|
|
"effect": "sell_value",
|
|
"effect_value": 250,
|
|
"locations": ["frozen_peaks"],
|
|
"spawn_rate": 0.0125
|
|
},
|
|
{
|
|
"id": 16,
|
|
"name": "Ancient Rune",
|
|
"description": "A stone tablet with mysterious inscriptions",
|
|
"rarity": "epic",
|
|
"category": "treasure",
|
|
"effect": "sell_value",
|
|
"effect_value": 500,
|
|
"locations": ["forgotten_ruins"],
|
|
"spawn_rate": 0.0075
|
|
}
|
|
],
|
|
"treasure_items": [
|
|
{
|
|
"id": 17,
|
|
"name": "Coin Pouch",
|
|
"description": "A small leather pouch containing loose coins",
|
|
"rarity": "rare",
|
|
"category": "treasure",
|
|
"effect": "money",
|
|
"effect_value": "1-3",
|
|
"locations": ["all"],
|
|
"spawn_rate": 0.008
|
|
}
|
|
],
|
|
"rarity_info": {
|
|
"common": {
|
|
"color": "white",
|
|
"symbol": "○",
|
|
"description": "Common items found frequently"
|
|
},
|
|
"uncommon": {
|
|
"color": "green",
|
|
"symbol": "◇",
|
|
"description": "Uncommon items with moderate rarity"
|
|
},
|
|
"rare": {
|
|
"color": "blue",
|
|
"symbol": "◆",
|
|
"description": "Rare items with special properties"
|
|
},
|
|
"epic": {
|
|
"color": "purple",
|
|
"symbol": "★",
|
|
"description": "Epic items with powerful effects"
|
|
},
|
|
"legendary": {
|
|
"color": "gold",
|
|
"symbol": "✦",
|
|
"description": "Legendary items of immense value"
|
|
}
|
|
}
|
|
} |