Modding:Schedule data

From Stardew Valley Wiki
Revision as of 17:53, 1 October 2017 by Margotbean (talk | contribs) (→‎Data: each npc has schedule data on his/her talk page)
Jump to navigation Jump to search

Index

Axe.png
Article Stub

This article is a stub and is missing information. You can help Stardew Valley Wiki by expanding it!

This page is a collection of notes and hypotheses about how the game stores schedule data for NPCs. Schedule data determines the times and locations where the relevant NPC actor is, moves to, and the animations it displays meanwhile.

Data

The schedule data is stored under /Content/Characters/schedules/ and its subfolders in character-specific XNB files.

Schedule data (as of v1.2.33) is located on this wiki on each character's Talk page (e.g., Abigail's Talk page).

Format

Note
most of this section is unconfirmed and presumed to work similarly to the format of dialogue data.
"<preface>[heart level]_[date]_[year][suffix]": "String"

...where:

  • <preface> is an arbitrary key which identifies the occasion(s) the schedule is for.
  • [heart level] is the minimum heart level the player must have reached with the NPC for this schedule to be executed.
  • [date] is the numeric day of the month (like _28_), or the three-character weekday (like _Mon_).
  • [year] is _1_ for year one, or _2_ for any year after that.
  • [suffix] is any string further identifying the dialogue (like _inlaw_Abigail, for dialogue that only appears when you're married to Abigail).

If multiple dialogues are eligible, the game prioritises by the following:

  1. marriage status;
  2. preface;
  3. suffix;
  4. in-law status;
  5. day of month;
  6. year;
  7. heart level;
  8. day of week.
"<key>": "schedule event/schedule event/schedule event",

Format

Schedule events are separated by slashes (/) and written in the following format:

<time> <map> <coord x y> <?> <animation>
  • <time> is the time at which the schedule event begins, in military time (24 hour format, no colon)
  • [map] is the map on which the target location is
  • [coord x y] is the x and y coordinates of the target location, without a comma
  • [?] TODO; possibly the direction the NPC actor shall face once reaching the target location, or a spritesheet index ID.
  • [animation] (optional): is the animation the NPC actor will execute at reaching the target location.

At <time> the NPC begins to travel to the target location. Once there, [animation] is executed until the next schedule event begins. There is possibly no limit to how many schedule events one schedule entry may contain.