Changes

→‎Type: wordsmithing
Line 22: Line 22:  
* First the game finds how many trees are in the 7×7 square around it, including immature trees. That number is multiplied by 3/4, rounded down, and that many mushrooms (at least one) are added to the list, randomly chosen between [[Purple Mushroom|Purple Mushrooms]] (5%), [[Red Mushroom|Red Mushrooms]] (14.25%), and [[Common Mushroom|Common Mushrooms]] (80.75%).   
 
* First the game finds how many trees are in the 7×7 square around it, including immature trees. That number is multiplied by 3/4, rounded down, and that many mushrooms (at least one) are added to the list, randomly chosen between [[Purple Mushroom|Purple Mushrooms]] (5%), [[Red Mushroom|Red Mushrooms]] (14.25%), and [[Common Mushroom|Common Mushrooms]] (80.75%).   
 
* Then, one more mushroom is added for each ''mature'' tree. If the tree is a [[Oak Tree]] then the mushroom added will always be a [[Morel]]. The same goes for [[Pine Tree]] with [[Chanterelle]], and for [[Mystic Tree]] with [[Purple Mushroom]]. [[Maple Tree|Maple Trees]] have a 10% chance to give a [[Purple Mushroom]] and a 90% chance to give a [[Red Mushroom]]. If the mature tree is none of these types, the same distribution as in step 1 is used.
 
* Then, one more mushroom is added for each ''mature'' tree. If the tree is a [[Oak Tree]] then the mushroom added will always be a [[Morel]]. The same goes for [[Pine Tree]] with [[Chanterelle]], and for [[Mystic Tree]] with [[Purple Mushroom]]. [[Maple Tree|Maple Trees]] have a 10% chance to give a [[Purple Mushroom]] and a 90% chance to give a [[Red Mushroom]]. If the mature tree is none of these types, the same distribution as in step 1 is used.
* Finally, a random mushroom is chosen from that list to generate.<ref name="code" />
+
* Finally, a random mushroom from the second list is generated.<ref name="code" />
 
This process makes it impossible to guarantee a single type of mushroom, as every tree added contributes not only to the chance of its own associated mushroom, but also the chance of [[Red Mushroom|red]], [[Common Mushroom|common]], and [[Purple Mushroom|purple]] mushrooms. Due to the rounding on the number of trees in step 1, adding more trees will not always increase the chance of the associated mushroom.
 
This process makes it impossible to guarantee a single type of mushroom, as every tree added contributes not only to the chance of its own associated mushroom, but also the chance of [[Red Mushroom|red]], [[Common Mushroom|common]], and [[Purple Mushroom|purple]] mushrooms. Due to the rounding on the number of trees in step 1, adding more trees will not always increase the chance of the associated mushroom.
  
661

edits