Modding Help Unpacking xnb files on a Mac

Discussion in 'Mods' started by frozenfarmer, Jan 30, 2018.

  1. frozenfarmer

    frozenfarmer Space Hobo

    I'm definitely having trouble with unpacking xnb files on a Mac. I've downloaded Wine, XQuartz 2.7.7 and am using XNB extract but it doesn't seem to be working. Plus, XQuartz wants me to log in again for it to work? and when I click Wine it just comes up with a terminal page.

    Someone please pull me out of this misery. Thank you!
     
    • Pathoschild

      Pathoschild Cosmos Killer

      Hi @frozenfarmer. There's a new unpack tool called xnbcli which works natively on Mac (i.e. you don't need anything else installed). Here are the instructions if you want to try it.

      There's a bug in the current Mac version; just replace its pack.sh and unpack.sh files with these to fix it.
       

        Attached Files:

      • frozenfarmer

        frozenfarmer Space Hobo

        Thank you so much! I was pasting random code into Wine and it gave me such weird results I uninstalled both programs. Also if you're SMAPI Pathoschild then can I just say thank you so much! You'e very talented. And if you're not creator Pathoschild then thank you as Well, from saving me and my imminent modding death
         
        • frozenfarmer

          frozenfarmer Space Hobo

          So I've checked it over again and it seems that it's not working, returning only some script in terminal when I try to unpack a file. Is this common or is there any other fix I may be missing?
           
          • Joejoe2105

            Joejoe2105 Tentacle Wrangler

            First pick up Mac, walk over to garbage, put it in it. Drive to store buy a windows 10 OS computer. Enjoy... Lol. Sorry just being funny wish I could help good luck
             
            • frozenfarmer

              frozenfarmer Space Hobo

              Hey, no problem. I enjoy some comedy in these dark times.
               
              • Pathoschild

                Pathoschild Cosmos Killer

                @frozenfarmer Yep, I'm the SMAPI developer. Glad you enjoy it!

                Can you post a screenshot of what you see when you try to unpack a file?
                 
                • frozenfarmer

                  frozenfarmer Space Hobo

                  [​IMG]
                   
                  • Pathoschild

                    Pathoschild Cosmos Killer

                    @frozenfarmer I'm not very familiar with Mac. Can you try renaming pack.sh and unpack.sh to pack.command and unpack.command?
                     
                    • frozenfarmer

                      frozenfarmer Space Hobo

                      Tried that. It came up with this:
                      [​IMG]
                       
                      • Pathoschild

                        Pathoschild Cosmos Killer

                        Looks like the script ran fine, but didn't find any files to convert. Are you trying to pack files that were unpacked using XNB Node or XNB Extract? That won't work since it uses a different format; it'll only pack files that were unpacked using xnbcli. If you're unpacking files, can you post a screenshot of your packed folder?
                         
                        • frozenfarmer

                          frozenfarmer Space Hobo

                          Wait I was super stupid and forgot to put the xnb file I wanted to unpack into the folder. It worked!

                          So recap for any future Mac modders using xnbli and browsing through this thread:
                          1.) Get the updated pack.sh and unpack.sh files from here
                          2.) change the end to .cmd
                          3.) Unpack!

                          I'M SO HAPPY. THANK YOU SO MUCH YOU MARVELLOUS PIECE OF A HUMAN BEING. I WISH YOU ALL THE IRIDIUM QUALITY STARFRUIT WINE IN THE WORLD.
                           
                            mooshumi likes this.
                          • Pathoschild

                            Pathoschild Cosmos Killer

                            @frozenfarmer Glad you got it working! Just to confirm, did you use .cmd or .command? I'm documenting the changes you needed for the author to fix.
                             
                            • frozenfarmer

                              frozenfarmer Space Hobo

                              .cmd
                               
                              • Alliteri

                                Alliteri Space Hobo

                                Hi, in case anyone is still here: I also have a mac and this came up when I was googling how to extract xnb files. The fixed files only worked for me when I changed the extension to .command instead of .cmd . The original files in the xnbcli v1.0.1 as of 04/27 were .command but did not work.
                                 
                                  springacres likes this.
                                • SiderealSkies

                                  SiderealSkies Seal Broken

                                  I know this was posted/resolved a couple months ago, but I've been searching desperately for a way to unpack xnb files on my mac and this is the only thing that has worked. Thanks so much to everyone involved in figuring this out. ;u;
                                   
                                    springacres and Pathoschild like this.
                                  • springacres

                                    springacres Phantasmal Quasar

                                    I just tried this, after using the old XNBNode method for ages (which for me involved using Winetricks and its DOS prompt, manually switching to the right directory several levels down in the directory tree via the DOS prompt, then typing the commands) and this is so much easier!

                                    I ran into the same issue as alliteri when I tried to use the files in the original xnbcli v1.0.1 download - they didn't work, but the fixed files here did.
                                     
                                    • Nanogamer7

                                      Nanogamer7 Void-Bound Voyager

                                      If anyone still has trouble with extracting xnbs, I made my own little tool a while a go and it works at least on my mac without any problems.
                                       
                                      • Amu Tsukiyomi

                                        Amu Tsukiyomi Master Chief

                                        I don't know what's wrong with my mac, but apparently it REFUSES to actually unpack the xnb mod I got off of nexus. All I want is the PNG from the mod, but have no way to get at it.....because no matter how many times I open xnbcli in terminal, the file in the packed folder stays packed.

                                        EDIT:
                                        Double clicking unpack.command pops up the message that it could not be executed because I do not have the appropriate access privileges.....when I'm the only person who uses my mac and therefore have all permissions, etc as admin.
                                         
                                          Last edited: Nov 21, 2018
                                          Gina13279 likes this.
                                        • springacres

                                          springacres Phantasmal Quasar

                                          Did you download the fixed files from this thread?
                                           

                                          Share This Page