Jump to content

Help increasing size for icepack


Recommended Posts

HI, i wanted to increase the size of insulated backpack (icepack), modifying more storage v2 fixed mod from workshop.

I tried some things but it's not working...

here is the script i used.

for modmain.lua, i added 

 

      elseif(tempPrefab == "icepack" and INCREASEBACKPACKSIZES_ICEPACK ~= 6) then
          container.widget.slotpos = {}
          if INCREASEBACKPACKSIZES_ICEPACK == 14 then 
        container.widget.animbank = "ui_krampusbag_2x8"
        container.widget.animbuild = "ui_krampusbag_2x8"
        container.widget.pos = Vector3(0,-75,0)
        for y = 0, 6 do
          table.insert(container.widget.slotpos, Vector3(-162, -y*75 + 240 ,0))
          table.insert(container.widget.slotpos, Vector3(-162 +75, -y*75 + 240 ,0))
        end
        updated = true
      elseif INCREASEBACKPACKSIZES_ICEPACK == 16 then 
        container.widget.animbank = "ui_krampusbag_2x8"
        container.widget.animbuild = "ui_krampusbag_2x8"
        container.widget.pos = Vector3(-5, -50, 0)
        for y = 0, 7 do
            table.insert(container.widget.slotpos, Vector3(-162, -65 * y + 245, 0))
            table.insert(container.widget.slotpos, Vector3(-162 + 75, -65 * y + 245, 0))
        end
      elseif INCREASEBACKPACKSIZES_ICEPACK == 18 then 
        container.widget.animbank = nil
        container.widget.animbuild = nil
        container.widget.bgatlas = "images/krampus_sack_bg.xml"
        container.widget.bgimage = "krampus_sack_bg.tex"
        container.widget.pos = Vector3(-76,-70,0)
        for y = 0, 8 do
          table.insert(container.widget.slotpos, Vector3(-37, -y*75 + 300 ,0))
          table.insert(container.widget.slotpos, Vector3(-37 +75, -y*75 + 300 ,0))
        end
      end

 

and for modinfo.lua,

 

     {
        name = "INCREASEBACKPACKSIZES_ICEPACK",
        label = "Icepack",
        options =    {
                        {description = "6(default)", data = 6},
                        {description = "14", data = 14},    
                        {description = "16", data = 16},
                        {description = "18", data = 18},
                    },
        default = 14,
      },

 

 

this makes the server not even start, saying something about failed spawing prefab..

 

I just changed the prefab name from piggyback to icepack. I assume this is no problem if i leave the storage size the way it is(except the default size, 6) since they're going to use same image files for stash outlines, etc.

 

any help please? thx in advance..

Edited by KimThought
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
  • Create New...