Modding Help How do I convert to xnb file

Discussion in 'Mods' started by Candel0ro, Mar 17, 2016.

Tags:
  1. Candel0ro

    Candel0ro Poptop Tamer

    PROBLEM SOLVED: Had to name the png 'Alex..png' for some reason it needed two periods.

    Hey guys, I would love to start modding and all, but I havent the slightest clue to how to convert a png into a xnb. I've scrolled through dozens of forums and pages saying that you have to use this app or these app and nothing is working for me- If anyone could give me a clear tldr list of things I have to do that would be awesome!
     
      Last edited: Mar 19, 2016
    • GreaterPorpoise

      GreaterPorpoise Void-Bound Voyager

      I don't know if you've seen it already but I found this guide pretty thorough.
       
        Lunumi likes this.
      • Candel0ro

        Candel0ro Poptop Tamer

        Hi thanks for the link! I've followed all the instructions and I seem to keep getting this show up on my cmd.exe

        [​IMG]

        Am I doing something wrong?
         
        • GreaterPorpoise

          GreaterPorpoise Void-Bound Voyager

          Whoa. I've never had that happen before, not sure how much help I can be. Is the program (xnb_node.cmd and its 'app' folder) in the same folder as your Stardew Valley.exe?

          Only other thing I can think of is the command format after you've done the "cd: [path to Stardew Valley folder containing the app]":
          1. [xnb_node.cmd] [instruction e.g extract or pack] [input folder\file] [output folder\file] so for an example:

          3. unpacking: 'extract' is the instruction, 'Content\Characters\' is what I want to extract, 'ContentUnpacked\Characters' is where I want to put what I extract:
          Afterwards, ContentUnpacked\Characters will have the editable .png and .yaml/.json versions of the .xnb files that were in Content\Characters.

          4. packing Alex.xnb: 'pack' is the instruction, 'UnpackedMods' is where I put my modded Alex.png and Alex.yaml, 'PackedMods' is where I want the final .xnb.
          EDIT: Guh, I messed up on the command. Way to be helpful, me. Also, I discovered I'm using the outdated version of the app. :p
           
            Last edited: Mar 17, 2016
          • Candel0ro

            Candel0ro Poptop Tamer

            So I've been fiddling with it but I get this error [​IMG]
             
            • GreaterPorpoise

              GreaterPorpoise Void-Bound Voyager

              Well, the 'no such file' thing seems to be because of the repeated fullstop, 'Alex..png'. But also, you have to pack the .yaml, not the .png, to get a .xnb. The .yaml will automatically group up with the png if they have the same name. :)
               
              • Candel0ro

                Candel0ro Poptop Tamer

                I'm using the code xnb_node.cmd pack alex.yaml alex.xnb
                I dont know why its saying png??
                 
                • GreaterPorpoise

                  GreaterPorpoise Void-Bound Voyager

                  Hmm, maybe it's because your file extensions are hidden so it fills it in? You could try turning that setting off but beyond that, it's puzzling. Now that I understand the problem better, I'm really sorry that I can't be more helpful. :oops:
                   
                  • Candel0ro

                    Candel0ro Poptop Tamer

                    Thanks for all your help regardless!
                     
                    • Morichinatsu

                      Morichinatsu Space Spelunker

                      I followed [ this ] youtube guide and it works flawlessly for me. Hope it helps!
                       
                      • Ceylon

                        Ceylon Void-Bound Voyager

                        I've tried inputting the parameter you've mentioned and I received an error. Try using one of these and see if they work?
                        • xnb_node.cmd pack UnpackedMods PackedMods
                        • xnb_node.cmd pack UnpackedMods\Alex.yaml PackedMods\Alex.xnb
                        I've also used the guide GreaterPorpoise linked and it worked fine for me.
                         
                        • blargsnarf

                          blargsnarf Pangalactic Porcupine

                          You have two folders, which is right. Packed and unpacked.
                          Put Alex.xnb in Packed.
                          Then cmd xnb_node extract packed unpacked (this'll unpack the "packed" folder into the "unpacked" folder
                          Then do your edits
                          Then cmd xnb_node pack unpacked packed (this one will pack the unpacked folder back into the packed folder)
                          Now the alex.xnb in the packed folder will contain your edited png.

                          That's it!
                           
                          • zomgzomg

                            zomgzomg Scruffy Nerf-Herder

                            Anyone who finds this via Google, like me...
                            Follow the imgur guide linked in the second post and make sure all your cmd prompts are correct.
                            Like, really correct. No really, retype all of it, there's a dumb mistake somewhere you aren't seeing.

                            I had it working fine until the very last step and it started just running infinitely with no errors or activity being shown.
                            Went back and rechecked the folders/files, cursed a bit, ripped out some hair, finally just retyped it a 3rd time and it worked. e__e
                            No idea what the problem was, but it ran correctly in like 1/4 second. Supa fast and flawless.

                            cmd prompts are dumb and outdated (just make a "full" program, sheesh) but they're also primitive as hell.
                            If they work at all for most people, it's 1000% user error. Quadruple check and try it again.
                             
                            • yuukiw

                              yuukiw Scruffy Nerf-Herder

                              Are you sure you use the newest version of the unpacker? I know that an older version required that you remove the extension. In the regards change your folder se tri so that it show known extension.
                               
                              • leomonpunk0

                                leomonpunk0 Space Hobo

                                I tried to follow the instructions for obtaining the XNB Node, yet I am unable to extract the files from the download. It's a .rar file, so I tried to use a specific software that would extract the files, but it keeps giving me an error. I've successfully used that software to extract .rar files before, so I don't believe there's a problem with the extracting software. I'm not sure where the problem is nor how to fix it.
                                 

                                Share This Page