Changes
Jump to navigation
Jump to search
← Older edit
Newer edit →
Modding:Migrate to Stardew Valley 1.6
(view source)
Revision as of 06:30, 30 August 2023
489 bytes added
,
06:30, 30 August 2023
→Other API changes
:
+ NetField.AddFields -> AddField
Line 8,831:
Line 8,831:
| <samp>Name</samp>
| <samp>Name</samp>
| Removed; use its dictionary key in <samp>Game1.locationContextData</samp> instead.
| Removed; use its dictionary key in <samp>Game1.locationContextData</samp> instead.
+
|-
+
| <samp>NetField</samp>
+
| <samp>AddFields</samp>
+
| Removed; use <samp>AddField</samp> instead. For example:
+
<syntaxhighlight lang="c#">
+
// old code
+
NetFields.AddFields(textureName, spriteWidth, spriteHeight);
+
+
// new code
+
NetFields
+
.AddField(textureName)
+
.AddField(spriteWidth)
+
.AddField(spriteHeight);
+
</syntaxhighlight>
+
Note that the second argument (<samp>name</samp>) should usually be omitted, since it'll be auto-populated from the value passed to the first argument.
|-
|-
|rowspan="4"| <samp>NPC</samp>
|rowspan="4"| <samp>NPC</samp>
Pathoschild
translators
8,445
edits
Navigation menu
Personal tools
Create account
Log in
Namespaces
Modding
Discussion
Variants
Views
Read
View source
View history
More
Search
Navigation
Main page
Recent changes
Admin noticeboard
Help Editing
Random page
Official Links
Official Site
Official Forums
Official Merchandise
Discord
Reddit
Tools
Upload file
Special pages
Printable version