Changes

Jump to navigation Jump to search
1,515 bytes added ,  16:35, 15 September 2021
Line 75: Line 75:  
:::::Apart from "uniqueIDForThisGame", the game also saves "currentGemBirdIndex" in the save file and can loaded it from the file. The point is that the game executes the codes that I posted once in each rainy day. But the function Utility.Shuffle ouputs the same list when the seed "uniqueIDForThisGame" and imported list keep same. And the "currentGemBirdIndex" = ("currentGemBirdIndex" +1)%4 which means the index circulated in <nowiki>[0,1,2,3]</nowiki>.
 
:::::Apart from "uniqueIDForThisGame", the game also saves "currentGemBirdIndex" in the save file and can loaded it from the file. The point is that the game executes the codes that I posted once in each rainy day. But the function Utility.Shuffle ouputs the same list when the seed "uniqueIDForThisGame" and imported list keep same. And the "currentGemBirdIndex" = ("currentGemBirdIndex" +1)%4 which means the index circulated in <nowiki>[0,1,2,3]</nowiki>.
 
:::::Therefore, the location order doesn't change in the same save, and the gem's location is recurrent in each rainy day. Sorry for the wrong interpretation again. You can add extra information to the article if you want. Relating references: <code><nowiki>StardewValley.Game1::_newDayAfterFade</nowiki></code>, <code><nowiki>StardewValley.Utility::Shuffle</nowiki></code>. Thanks! --<small>[[User:Horizon98|Horizon98]] ([[User talk:Horizon98|Discussion]])</small> 07:46, 15 September 2021 (UTC)
 
:::::Therefore, the location order doesn't change in the same save, and the gem's location is recurrent in each rainy day. Sorry for the wrong interpretation again. You can add extra information to the article if you want. Relating references: <code><nowiki>StardewValley.Game1::_newDayAfterFade</nowiki></code>, <code><nowiki>StardewValley.Utility::Shuffle</nowiki></code>. Thanks! --<small>[[User:Horizon98|Horizon98]] ([[User talk:Horizon98|Discussion]])</small> 07:46, 15 September 2021 (UTC)
 +
 +
::::::Hey, thanks for the confirmation! "Order" is of course a local variable within the code you posted, but its results were placed in the index, whose scope I could not see. The utility shuffle was something of a mystery, and what you describe is a surprise to me, as its name would indicate some generic function, and its actual function is quite specialized. Not the first time I've encountered such things in code though. In fact, engineers are notorious for creating misleading names in code, and through decades of time that basic tendency has never diminished. So now I'm thoroughly comfortable with the fact (I would now declare it a true fact, not just a conclusion) that generation of the list and index is "once for all time" within any given created game, with appropriate pointers into it saved in the save file. And that makes moot (for us) the question of when it is actually generated. The program creates it early enough that the first time we meet its effects, it is already in place, and thereafter it is always the same. Unless we back up our play far enough (what is "enough"?) to a manually-saved earlier day/file, it must be the same. The file design doesn't go back farther than one day (for game restoration purposes in case of file loss), so anything like what I do is outside of Ape's direct intentions. And more than what I've done here seems to me to have no point anyway. We're on entirely firm ground. [[User:Giles|Giles]] ([[User talk:Giles|talk]]) 16:35, 15 September 2021 (UTC)
661

edits

Navigation menu