# HikeMap RPG System - Todo List ## Phase 1: Login on Load - COMPLETED - [x] Remove icon chooser from initial page load - [x] Show auth modal if no `accessToken` in localStorage - [x] Add "Continue as Guest" button to auth modal ## Phase 2: Character Creator - COMPLETED - [x] Add character creator modal HTML/CSS - [x] Implement race selection with stat preview - Human, Elf, Dwarf, Halfling - [x] Implement class selection (Trail Runner available, others grayed "Coming Soon") - Trail Runner (available) - Gym Bro (coming soon) - Yoga Master (coming soon) - CrossFit Crusader (coming soon) - [x] Add character name input - [x] Update database schema (character_name, race columns in rpg_stats) - [x] Create `/api/user/character` endpoint - [x] Wire up creation flow after login ## Phase 3: Character Sheet - COMPLETED - [x] Create character sheet modal UI - [x] Display all stats (HP, MP, ATK, DEF, etc.) - [x] Show XP progress bar with level milestones - [x] Show unlocked skills with descriptions (locked skills shown as grayed out) - [ ] Display equipped items (pending equipment system - Phase 5) - [ ] Add combat statistics (future enhancement) ## Phase 4: Skill Selection System - COMPLETED - [x] Create skill pools per class (SKILL_POOLS object with 2 options at levels 2, 3, 5) - [x] Add 3 new alternative skills (quick_step, second_wind, finish_line_sprint) - [x] Add level-up skill choice modal (2 options per milestone level) - [x] Update database to store unlocked_skills (JSON array column) - [x] Wire into level-up flow (checkLevelUp shows modal at milestone levels) - [x] Update combat UI to show only unlocked skills - [x] Update character sheet to show only unlocked skills ## Phase 5: Equipment System - [ ] Create items table in database - [ ] Create player_inventory table - [ ] Define equipment slots: Weapon, Armor, Accessory - [ ] Add class-specific accessories - [ ] Implement monster loot tables - [ ] Add equipment UI to character sheet - [ ] Calculate effective stats with equipment bonuses ## Phase 6: Admin Editor - MOSTLY COMPLETE - [x] Create admin.html (separate page) - [x] Add admin authentication middleware - [ ] User management (list, edit stats, grant admin) - [x] Monster types stored in database (monster_types table created) - [x] Monster management UI (CRUD for monster_types) - [x] Monster cloning - [x] Monster enable/disable toggle - [x] Auto-copy default images for new monsters - [ ] Spawn control (manual monster spawning) - [ ] Game balance settings ## Phase 8: Home Base / Death System - COMPLETE - [x] Add home_base_lat, home_base_lng, last_home_set, is_dead columns to rpg_stats - [x] Add "Set Home Base" mode - tap on map to select location - [x] Limit home base setting to once per day (check last_home_set timestamp) - [x] Show home base marker on map (uses default50.png) - [x] On death: - [x] Set player state to "dead" (can't initiate combat) - [x] All monsters despawn (clear entourage) - [x] Lose 10% of XP (but cannot drop below current level threshold) - [x] Show "You are dead! Return to home base to respawn" message - [x] Visual indicator when dead (grayed HUD with skull icon) - [x] Detect when dead player reaches home base (~20m radius) - [x] Respawn player with full HP and MP when they reach home - [x] If no home base set, old behavior (restore 50% HP on defeat) ## Phase 7: Skill Database System - COMPLETE - [x] Skills table in database - [x] Skills admin page (CRUD) - [x] Hit/miss mechanics (accuracy vs dodge) - [x] Monster skills with weighted random selection - [x] Custom skill names per monster - [x] Status effects (poison) with turn-based damage - [x] Buff skills (defend) working properly - [x] Status effect visual overlays (100x100px) - [x] Monster min/max level spawning - [ ] Class-specific skill names (getSkillForClass) - [ ] Class skill names admin editor --- ## Completed - [x] RPG combat system with turn-based battles - [x] Trail Runner class with skills - [x] Discarded GU monster with variants - [x] Multi-monster combat encounters - [x] XP bar in HUD - [x] Stat persistence fix (authToken → accessToken) - [x] Phase 1: Login on Load - [x] Phase 2: Character Creator - [x] Monster persistence (monsters saved to database, persist across login/logout) - [x] Phase 3: Character Sheet (click class name in HUD to view) - [x] Phase 4: Skill Selection System (choose 1 of 2 skills at levels 2, 3, 5) - [x] Monster types moved to database (future-proofing for admin editor)