View Single Post
Old 12-11-2003, 04:06 AM   #19
EricLongsten
A Treant
 
Join Date: Dec 2003
Posts: 27
Interface Author - Click to view interfaces
Default

Add some info for the next person trying to shrink a bag since I couldn't find it when I looked....

Sony has indeed padded the container window so that the size in the xml file does not match what shows up on the screen. After several hours of playing with it for my latest bag it looks like the pad on width is 11 pixels and height is 36 plus 4 each for the done and combine buttons. The catch is that the pad gets added to the "off" side of the inventory slots, if you are using the standard location/size tags to place the slots it references from the top left corner of the window, this will force the right side of the window to remain at least 11 pixels from the right most slot and the bottom of the window to be 36-44 pixels from the bottom slot. The trick to getting rid of this pad is to switch to the anchoroffset method of placing the slots and split your references. I will use width for an example, if you reference your left column from the left side then EQ pads to the right of it, if you reference your right column from the right side EQ will pad to the left of it. This places the pads between the columns, you can now change the cx on the window to hide the left pad behind the right column and the right pad behind the left column. The trick to making things line up the way you want is to do the math and find out how wide your window should be based on the offsets you used and subtract 11 from it for your cx. For example the bag that I worked all this out with used slots that were 40 x 40 and right and left borders of 3 pixels each, 2 slots + 2 borders gave me a bag width of 86, but putting 86 into the cx left the pad between the columns. Changing the cx to 75 hid the pad and gave me an on screen width of 86. The same technique works with height as well but you have to be careful about where you split your references and put your buttons or you come up with some very odd effects when you go to containers with less than 10 slots. Hope this helps save a few headaches for people....
EL
__________________
Eric Longsten
http://www.geocities.com/ericlongsten/
EricLongsten is offline   Reply With Quote