Changes

m
Text replacement - "''e.g.''," to "''e.g.,''"
Line 18: Line 18:  
Each <samp>Character</samp>, <samp>GameLocation</samp>, <samp>Item</samp>, and <samp>TerrainFeature</samp> instance now has a <samp>modData</samp> dictionary field, which is persisted to the save file and synchronized in multiplayer. This can be used to store arbitrary mod data, including on the player itself via <samp>Game1.player.modData</samp>.
 
Each <samp>Character</samp>, <samp>GameLocation</samp>, <samp>Item</samp>, and <samp>TerrainFeature</samp> instance now has a <samp>modData</samp> dictionary field, which is persisted to the save file and synchronized in multiplayer. This can be used to store arbitrary mod data, including on the player itself via <samp>Game1.player.modData</samp>.
   −
When you split an item stack, the new stack copies the previous one's mod data; when merged into another stack, the merged items adopt the target stack's mod data. Otherwise mod data has no effect on item split/merge logic (''e.g.'', you can still merge items with different mod data), unless overridden by a Harmony patch.
+
When you split an item stack, the new stack copies the previous one's mod data; when merged into another stack, the merged items adopt the target stack's mod data. Otherwise mod data has no effect on item split/merge logic (''e.g.,'' you can still merge items with different mod data), unless overridden by a Harmony patch.
    
'''Note:''' to avoid mod conflicts, prefixing data fields with your mod ID is strongly recommended:
 
'''Note:''' to avoid mod conflicts, prefixing data fields with your mod ID is strongly recommended:
Line 55: Line 55:  
; How do I update affected code?
 
; How do I update affected code?
   −
:* Drawing something into the game world (''e.g.'', a tile overlay) in UI mode will make things much more difficult. Consider drawing outside UI mode instead, ''e.g.'',by switching from SMAPI's <samp>Rendered</samp> event to <samp>RenderedWorld</samp>.
+
:* Drawing something into the game world (''e.g.,'' a tile overlay) in UI mode will make things much more difficult. Consider drawing outside UI mode instead, ''e.g.,''by switching from SMAPI's <samp>Rendered</samp> event to <samp>RenderedWorld</samp>.
 
:* Be very careful about mixed coordinate systems. For example, a menu constructed outside the draw loop may initialize coordinates in non-UI mode, then handle clicks in UI mode. You may need to convert values to non-UI coordinates to check them in that case (see conversions below).
 
:* Be very careful about mixed coordinate systems. For example, a menu constructed outside the draw loop may initialize coordinates in non-UI mode, then handle clicks in UI mode. You may need to convert values to non-UI coordinates to check them in that case (see conversions below).
 
:* When drawing UI, in most cases you should replace <samp>Game1.viewport</samp> with <samp>Game1.uiViewport</samp>. These provide UI-adjusted pixel positions. '''Don't''' do this if you'll be adjusting the positions for UI scaling separately (see below), since double-conversion will give you incorrect results.
 
:* When drawing UI, in most cases you should replace <samp>Game1.viewport</samp> with <samp>Game1.uiViewport</samp>. These provide UI-adjusted pixel positions. '''Don't''' do this if you'll be adjusting the positions for UI scaling separately (see below), since double-conversion will give you incorrect results.
Line 89: Line 89:     
This is so that a single paint color will look generally the same when applied across multiple buildings, and is also used to ensure brightness values that are overbright or too dark aren't usable as they generally look bad. This is also used to prevent values that shade in weird ways.}}
 
This is so that a single paint color will look generally the same when applied across multiple buildings, and is also used to ensure brightness values that are overbright or too dark aren't usable as they generally look bad. This is also used to prevent values that shade in weird ways.}}
* Each paintable building also has a separate mask texture, like <samp>Buildings/Stable_PaintMask</samp> for the stable. The masks use three predefined colors: green (roof), blue (trim), and red (walls) matching the order in <samp>Data/PaintData</samp> (other colors are ignored). Groups don't need to be contiguous (''e.g.'', you can have separate red areas).  
+
* Each paintable building also has a separate mask texture, like <samp>Buildings/Stable_PaintMask</samp> for the stable. The masks use three predefined colors: green (roof), blue (trim), and red (walls) matching the order in <samp>Data/PaintData</samp> (other colors are ignored). Groups don't need to be contiguous (''e.g.,'' you can have separate red areas).  
    
===Other breaking changes===
 
===Other breaking changes===
Line 160: Line 160:  
** <samp>ordersboard</samp>: show the special orders board.
 
** <samp>ordersboard</samp>: show the special orders board.
 
** <samp>pathspousetome</samp> / <samp>pstm</samp>: warp or path the player's spouse spouse to the player.
 
** <samp>pathspousetome</samp> / <samp>pstm</samp>: warp or path the player's spouse spouse to the player.
** <samp>perfection</samp>: makes changes needed for 100% game completion (''e.g.'', max all friendships, mark all fish caught, etc).
+
** <samp>perfection</samp>: makes changes needed for 100% game completion (''e.g.,'' max all friendships, mark all fish caught, etc).
 
** <samp>pgb</samp>: prints the solution to the island gem bird shrine puzzle.
 
** <samp>pgb</samp>: prints the solution to the island gem bird shrine puzzle.
 
** <samp>phone</samp>: show the telephone menu.
 
** <samp>phone</samp>: show the telephone menu.
Line 264: Line 264:  
* For indoor locations:
 
* For indoor locations:
 
** <samp>ForceSpawnForageables</samp>: causes forage to spawn in the location.
 
** <samp>ForceSpawnForageables</samp>: causes forage to spawn in the location.
** <samp>indoorWater</samp>: enables water tiles in the location (''e.g.'', for fishing).
+
** <samp>indoorWater</samp>: enables water tiles in the location (''e.g.,'' for fishing).
 
* For all locations:
 
* For all locations:
 
** <samp>CanCaskHere</samp>: if set to any value, casks will work in this location regardless of whether it's a cellar.
 
** <samp>CanCaskHere</samp>: if set to any value, casks will work in this location regardless of whether it's a cellar.
Line 272: Line 272:  
** <samp>skipWeedGrowth</samp>: skip spawning/spreading weeds in this location.
 
** <samp>skipWeedGrowth</samp>: skip spawning/spreading weeds in this location.
   −
The various tiles/properties that accompany these features (''e.g.'', door tiles, mailbox tile action, etc) still need to be added to the map file. These aren't added/moved automatically by the map properties.
+
The various tiles/properties that accompany these features (''e.g.,'' door tiles, mailbox tile action, etc) still need to be added to the map file. These aren't added/moved automatically by the map properties.
    
===Greenhouse building===
 
===Greenhouse building===
Line 407: Line 407:  
** <samp>Back</samp> > <samp>NoPath</samp>: prevent NPCs from pathing through the tile;
 
** <samp>Back</samp> > <samp>NoPath</samp>: prevent NPCs from pathing through the tile;
 
** <samp>Buildings</samp> > <samp>NPCPassable</samp>: equivalent to <samp>Passable</samp>, but only for NPCs;
 
** <samp>Buildings</samp> > <samp>NPCPassable</samp>: equivalent to <samp>Passable</samp>, but only for NPCs;
** <samp>Buildings > ProjectilePassable</samp>: allows projectiles to cross tiles that would normally block them (''e.g.'', to allow shooting into lava pools).
+
** <samp>Buildings > ProjectilePassable</samp>: allows projectiles to cross tiles that would normally block them (''e.g.,'' to allow shooting into lava pools).
    
===Update impact===
 
===Update impact===
105,831

edits