NPCScheduleDataFormat.V2 defines the authored daily routine data consumed by
later schedule execution, pathfinding, interruption, persistence, and debug
systems. It is intentionally data-only: this layer validates what an NPC should
do and where each block binds, while behavior dispatch belongs to later schedule
runtime tasks.
Runtime Surface#
FV2NPCScheduleTimeOfDaystores hour/minute values and converts them to minutes from midnight.FV2NPCScheduleBlockstores a stable block id, activity type, concrete activity tag, location id, behavior tag, interaction tag, start/end times, priority, interruption policy, reservation policy, and authoring tags.FV2NPCScheduleDefinitionstores schedule id, NPC id, day pattern id, full-day coverage policy, and ordered schedule blocks.FV2NPCScheduleValidationIssuereports field-level authoring issues with blocking/non-blocking severity.FV2NPCScheduleValidationResultreports block count, covered minutes, gap minutes, and all validation issues.
Time Block Rules#
- Times are represented as local authored time of day from
00:00through23:59. - Blocks use half-open ranges: start minute is included and end minute is excluded.
- A block whose end time is earlier than its start time wraps midnight, such as
20:00to06:00for sleep. - Equal start and end times are invalid because full-day coverage should be explicit.
- Schedule definitions can require all
1440minutes to be covered. The example daily schedule covers breakfast at home from06:00to08:00, work at the shop from08:00to17:00, tavern visiting from17:00to20:00, and sleep at home from20:00to06:00.
Validation Rules#
- Schedules require
ScheduleId,NPCId, and at least one block. - Blocks require unique
BlockIdvalues. - Blocks require a non-
Invalidactivity type and a concreteActivityTag. - Blocks require a target
LocationId; later location binding resolves that id into owned homes, workplaces, tavern seats, or other authored anchors. - Block priority cannot be negative.
- Overlapping covered minutes are blocking validation issues.
- Missing full-day coverage is blocking when
bRequireFullDayCoverageis true and non-blocking when the schedule explicitly allows idle gaps.
Validation Commands#
Run these targeted checks when touching NPC schedule data:
bash
python3 V2/ue/Tools/check-v2-npc-schedule-data-format.py
python3 V2/ue/Tools/check-v2-ci-workflow.py
python3 -m json.tool V2/ue/Content/V2/Gameplay/NPC/NPCScheduleDataFormat_V2_Contract.json
python3 -m py_compile V2/ue/Tools/check-v2-npc-schedule-data-format.py