Jump to content

Talk:Trinkets

From Stardew Valley Wiki
Revision as of 14:35, 30 September 2024 by imported>第二个熺 (→Probability obtained from Crates and Barrels: new section)

Trinket Source

I added a "source" column and included information on trinkets I've obtained. --Darkstreamfarm (talk) 05:06, 27 March 2024 (UTC)

Probability obtained from Crates and Barrels

In the game code BreakableContainer::releaseContents, the code for determining whether to generate four types of seeds is at the very beginning, as follows:

if (r.NextDouble() < 0.2)
{
	if (r.NextDouble() < 0.1)
	{
	Game1.createMultipleItemDebris(Utility.getRaccoonSeedForCurrentTimeOfYear(who, r), new Vector2(x, y) * 64f + new Vector2(32f), -1, location);
	}
	return;
}

When the random number is less than 0.2, this section of code executes and directly returns, so the subsequent code does not execute. Therefore, the probability of all other items appearing after this code segment should be multiplied by 0.8. This affects the probability of all items available from the container, including trinkets. 第二个熺 (talk) 14:35, 30 September 2024 (UTC)