Modding Discussion [Request] Unlocking greenhouse allows player to buy all seeds in all seasons

Discussion in 'Mods' started by irrimn, Mar 13, 2016.

Tags:
  1. irrimn

    irrimn Pangalactic Porcupine

    Since I doubt this is ever going to get added to the main game, I figured I'd make a request.

    This can either be a mod that changes Pierre's shop, Joja Mart, or hell, even an player-made mod menu that will simply take your gold and give you the seeds as though it was a legit shop (either available everywhere, only while inside Pierre's / Joja Mart, or while inside the greenhouse, maybe?)

    Anyways, from what I've seen the last option shouldn't be too terribly hard since it'd just be a matter of checking that the player has the required amount of money, checking to make sure there is inventory room, removing the money, and adding the item to the inventory.
     
    • bloc97

      bloc97 Void-Bound Voyager

      If someone could find out which .xnb file controls the shops, it would be very easy to make this mod.
       
      • Axelius

        Axelius Tentacle Wrangler

        No xnb does that, it is hardcoded into the .exe. Having looked at the code for the shop easiest would probably be to inject a check if the player has unlocked the greenhouse into the checks for which season it is when the game constructs the list of buyable items at Pierre's
         
        • irrimn

          irrimn Pangalactic Porcupine

          So I've been looking into the game's code using dotPeek and found the part where it specifies the items listed in Pierre's shop. Took a screenshot for future reference: http://i.imgur.com/Q5FPIKe.png

          So it seems like, all that would need to be done is append an OR statement (||) to that that checks the variable (variables?) that store if the greenhouse is unlocked or not. Although, I haven't been able to find what variable that is yet -- maybe someone else already knows? I'm assuming BOTH the community center and Joja branches store that in a different variable so it'd need an OR for both (or hell, make it so that if you go the CC route that Pierre starts selling all seeds in all seasons, and if you go Joja route make Joja Mart sell all seeds in all seasons).

          Still, hopefully this will catch the attention of a more experienced modder who could probably work this out in about 5 minutes.
           
          • Umeneko

            Umeneko Void-Bound Voyager

            I'm unable to get an achievement for another half year because i forgot to keep some kale to make seeds. This would be a great mod.
             
            • irrimn

              irrimn Pangalactic Porcupine

              So I think I found the trigger that this would need:
              All we have to do is change:

              if (Game1.currentSeason.Equals("spring"))
              to
              if (Game1.currentSeason.Equals("spring") || (Game1.player.mailReceived.Contains("ccPantry") && !Game1.player.mailReceived.Contains("JojaMember")))

              Basically, instead of checking just the season, it checks the season first and if that evaluates to false it checks if the Panty is complete (which unlocks the greenhouse) and if the player IS NOT a Joja Member --

              and then do that for each season, basically. Although, I have no idea how to mod this into the game or even if this is possible with SMAPI or STORM currently.

              Hopefully someone more skilled with modding will know...
               

              Share This Page