Files
SVSimServer/SVSim.Database/Models/Config/ArenaTwoPickConfig.cs
gamer147 dc19289818 fix(tk2): honor consume_item_type (ticket/crystal/rupy/free) + correct entry ticket id
- ArenaTwoPickConfig: add TicketItemId=1, TicketCost=1, CrystalCost=150, RupyCost=150 scalars
- ArenaTwoPickService.EntryAsync: switch on eARENA_PAY (1/3/4/5); crystal/rupy go through
  ICurrencySpendService.TrySpendAsync; ticket uses item id 1 (challenge ticket, not 80001);
  free entry returns empty reward_list; invalid type throws
- Tests: fix ticket id 80001→1 in entry/e2e; add 4 new path tests; update ctor (10th arg)
  across all 4 service test files; fix e2e retire assertion (reward ticket 80001 post-state=1)

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-31 12:26:57 -04:00

39 lines
1.4 KiB
C#

namespace SVSim.Database.Models.Config;
/// <summary>
/// Take Two run mechanics: rarity weights, class/neutral mix, per-battle XP, season ids,
/// allowed-class allow-list. The pool's set scoping lives on <see cref="ChallengeConfig"/>;
/// this section is purely mechanics + the reward-schedule/challenge ids stamped on each run.
/// </summary>
[ConfigSection("ArenaTwoPick")]
public class ArenaTwoPickConfig
{
public int RewardScheduleId { get; set; } = 1;
public int ChallengeId { get; set; } = 1;
public int MaxLosses { get; set; } = 2;
public int ClassXpPerBattle { get; set; } = 100;
public int SpotPointsPerBattle { get; set; } = 10;
public double LegendaryRate { get; set; } = 0.06;
public double GoldRate { get; set; } = 0.17;
public double SilverRate { get; set; } = 0.33;
public double BronzeRate { get; set; } = 0.44;
public double NeutralMixRate { get; set; } = 0.25;
/// <summary>TK2 entry ticket — item id 1 (challenge ticket). Distinct from the run-end
/// REWARD ticket id (80001, throwback pack ticket).</summary>
public int TicketItemId { get; set; } = 1;
public int TicketCost { get; set; } = 1;
public int CrystalCost { get; set; } = 150;
public int RupyCost { get; set; } = 150;
public List<int> AllowedClassIds { get; set; } = new();
public static ArenaTwoPickConfig ShippedDefaults() => new()
{
AllowedClassIds = new List<int> { 1, 2, 3, 4, 5, 6, 7, 8 },
};
}