RynthSuite as of 2026-11-17 (internal d924ac04): release 2026.11.17.1
This commit is contained in:
parent
04add6c51b
commit
88f0aac49a
72 changed files with 7910 additions and 172 deletions
|
|
@ -23,6 +23,34 @@ eq(Character.BurdenUnits, 1500, "BurdenUnits")
|
|||
eq(Character.MaxBurdenUnits, 200 * 150, "MaxBurdenUnits")
|
||||
eq(Character.IsBusy(), false, "IsBusy()")
|
||||
|
||||
-- the server's yes/no prompts (AnswerNextPrompt / LastPrompt)
|
||||
eq(Character.LastPrompt, nil, "LastPrompt: none this session")
|
||||
eq(Character.AnswerNextPrompt(), true, "AnswerNextPrompt() arms")
|
||||
local arm = harness.promptArm()
|
||||
eq(arm.Type, 7, "default type YESNO")
|
||||
eq(arm.TimeoutMs, 5000, "default 5 s")
|
||||
eq(arm.MinPercent, 0, "default: Yes whatever the percent")
|
||||
eq(Character.AnswerNextPrompt(ClientConfirmationType.CRAFT_INTERACTION, 90000, 70), true, "a craft prompt")
|
||||
arm = harness.promptArm()
|
||||
eq(arm.Type, 5, "CRAFT_INTERACTION")
|
||||
eq(arm.TimeoutMs, 30000, "the timeout is capped at 30 s")
|
||||
eq(arm.MinPercent, 70, "Yes from 70%")
|
||||
eq(Character.AnswerNextPrompt(9), false, "an unknown type is refused")
|
||||
eq(harness.promptArm().Calls, 2, "and not armed")
|
||||
eq(Character.AnswerNextPrompt(7, 0), true, "0 ms disarms")
|
||||
eq(harness.promptArm().TimeoutMs, 0, "disarm sent")
|
||||
harness.setLastPrompt(4, 7, 0x1234, -1, 2, 150)
|
||||
local lp = Character.LastPrompt
|
||||
check(lp ~= nil, "LastPrompt after one")
|
||||
eq(lp.Seq, 4, "LastPrompt.Seq")
|
||||
eq(lp.Type, 7, "LastPrompt.Type")
|
||||
eq(lp.ContextId, 0x1234, "LastPrompt.ContextId")
|
||||
eq(lp.Percent, -1, "LastPrompt.Percent: none in its text")
|
||||
eq(lp.Outcome, "Accepted", "LastPrompt.Outcome")
|
||||
eq(lp.AgeMs, 150, "LastPrompt.AgeMs")
|
||||
harness.setLastPrompt(5, 7, 0, -1, 1, 10)
|
||||
eq(Character.LastPrompt.Outcome, "Shown", "not armed: the client's dialog")
|
||||
|
||||
-- stats the UB way (on the weenie) and with the vital numbering UB uses
|
||||
local vitals = Character.Weenie.Vitals
|
||||
eq(vitals[VitalId.Health].Current, 300, "Health.Current")
|
||||
|
|
|
|||
Loading…
Reference in a new issue