mirror of
https://github.com/prosolis/gogobee.git
synced 2026-07-15 08:32:41 +00:00
Add Misty & Arina NPCs, fix tier gating, babysit actions, Robbie filter, streak/scheduler bugs
Misty & Arina: random encounter NPCs triggered by chat message counting (5-10 msg threshold, 7-day cooldown, 7.5% roll). Misty asks for €100 — accept gives 7-day arena buff (20% gourmet food heals gear + 5 enemy dmg), decline gives 7-day debuff (20% crowd revenge damage). Arina asks for €5000 — accept gives 7-day sniper buff (8% instant kill in arena). Effects integrate into arena round resolution after combat roll; sniper overrides death. Other fixes: - Tier gating now uses base skill only — buffs improve success, not access - Babysitter uses all harvest actions (3/day, 4 on holidays) instead of 1 - Robbie collects all non-equipped items, not just slotted gear - Robbie timing: fire on first tick >= target hour, not exact minute match - Streak: dead players who acted still get streak credit - Streak: dead players skip shame DM (use LastDeathDate, not Alive flag) - Midnight ticker: in-memory date cache prevents 1439 wasted DB checks/day - T1 loot values ~3x across all activities to close T1/T2 gap Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -127,6 +127,35 @@ func TestAdvIsEligible_NoPenalty(t *testing.T) {
|
||||
}
|
||||
}
|
||||
|
||||
func TestAdvIsEligible_BonusesDontUnlockTiers(t *testing.T) {
|
||||
char := &AdventureCharacter{MiningSkill: 1}
|
||||
equip := map[EquipmentSlot]*AdvEquipment{}
|
||||
loc := &AdvLocation{Activity: AdvActivityMining, MinLevel: 8, MinEquipTier: 0}
|
||||
bonuses := &AdvBonusSummary{MiningBonus: 10} // +10 would make effective 11, but base is 1
|
||||
|
||||
eligible, _ := advIsEligible(char, equip, loc, bonuses)
|
||||
if eligible {
|
||||
t.Error("bonuses should not unlock tiers — base mining 1 should not access min level 8")
|
||||
}
|
||||
}
|
||||
|
||||
func TestAdvIsEligible_BonusesDontAffectPenaltyZone(t *testing.T) {
|
||||
char := &AdventureCharacter{CombatLevel: 21} // base 21, min 20 → penalty (21-20=1 < 3)
|
||||
equip := map[EquipmentSlot]*AdvEquipment{
|
||||
SlotWeapon: {Tier: 2, Condition: 100},
|
||||
}
|
||||
loc := &AdvLocation{Activity: AdvActivityDungeon, MinLevel: 20, MinEquipTier: 0}
|
||||
bonuses := &AdvBonusSummary{CombatBonus: 10} // +10 would make effective 31, but penalty uses base
|
||||
|
||||
eligible, penalty := advIsEligible(char, equip, loc, bonuses)
|
||||
if !eligible {
|
||||
t.Error("should be eligible at base combat 21 for min 20")
|
||||
}
|
||||
if !penalty {
|
||||
t.Error("should still be in penalty zone — bonuses don't affect penalty calculation")
|
||||
}
|
||||
}
|
||||
|
||||
func TestCalculateAdvProbabilities_SumsTo100(t *testing.T) {
|
||||
char := &AdventureCharacter{CombatLevel: 10}
|
||||
equip := map[EquipmentSlot]*AdvEquipment{
|
||||
|
||||
Reference in New Issue
Block a user