EQ2Interface

EQ2Interface (https://www.eq2interface.com/forums/index.php)
-   XML Modification Help & Info (https://www.eq2interface.com/forums/forumdisplay.php?f=22)
-   -   Bags not staying put: PROBLEM SOLVED (https://www.eq2interface.com/forums/showthread.php?t=2178)

Deathbane27 03-26-2005 08:48 AM

Bags not staying put: PROBLEM SOLVED
 
PROBLEM SOLVED
:D :D :D :D :D :D :D :D :D

Issue:
When you move a window, the game saves its location as a relationship between whichever edge of the window is closest to an edge of the screen or letterbox, and that edge. When you exit and re-enter the game, it loads that relationship based on the window's size as defined in the xml file, unless the window is resizable, in which case it loads the window's size as saved in the character's ini file.

Because the bag window is not flagged as resizable, but gets resized, its location can become borked if the bottom of the window (at its full size) is closer to a screen edge than the top.


SOLUTION:

Step 1: Add these properties to the bag window's main page (Inventory.Bag):

UserResizable="true" OnHoverIn="UserResizable=false"

This causes the bag window to save its size in the character's ini file so it won't get borked, and make it so it's not actually user resizable. :D

Step 2: It's also necessary to set the first bag slot in each row to Visible="false" and OnShow="Parent.Size=(X,Y) Parent.MinimumSize=(X,Y)", where (X,Y) is the size that the bag should be when that slot's row is shown. If you don't do this, then the window will do it's resize-down-from-default size from that bag's saved size and you won't see your bag windows.

Step 3: (Nevermind, this problem can't actually affect the bags if they are set up properly.)


STEP 4:
If you're using somebody else's bag mod, they may have left code in there that hinders the proper saving of a bag's size. Such as, for example, Fetish Nightfall v3.3 bags containing a MaximumSize value in the XML that's smaller than the bag is going to be.

Remove any Minimumsize and Maximumsize parameters from the main bag page. This will be on the second line if opened in Notepad. Example, FetishNightfall v3.3 bag:

<Page Activated="true" eq2usescomwndcontrols="true" Location="3,58" MaximumSize="134,23" MinimumSize="134,23" Name="Bag"...

Replace with:

<Page Activated="true" eq2usescomwndcontrols="true" Location="3,58" Name="Bag"...

Itanius 03-26-2005 09:05 AM

Good work, Mook. :D

ger 03-26-2005 09:09 AM

I love you, man. And I'm not just saying that to get your Bud Light. ('Cause really, I don't drink anything that crappy ;) )

Deathbane27 03-26-2005 09:15 AM

Edit: Instructions added to initial post. It's not as easy as I thought (I was using a bag with this script to test with so didn't realize it was necessary), but we can fix the problem now.

ger 03-26-2005 09:21 AM

Quote:

Originally Posted by Deathbane27
Bah, there's to be something wrong. Window resizing down from previous size instead of default size. Using Talyns's 3/4 bag slot script to force a manual resize fixes it. Looking for a simpler solution. Don't go updating your bags just yet...

Heh, well, since I use Talyns' resizing scripts in both of my bag mods, I think I'll give it a go anyway. :)

(Actually, I was planning on mucking around with my bag mods today anyway, so this is really good timing for testing new ideas :D )

Kosmos 03-26-2005 09:35 AM

Good find.

I had noted that the only bags I had problems with before were the ones that were in the 'shared slots, or any bag I placed below a certain point on screen. Just about halfway.
If the bottom edge of the bag is placed on or below this mark, the bag posistion doesn't save.

If the bags are all placed above on the top half of the screen they seem to save the posistions fine. Due to your recent discover that all makes perfect sense now. I had though it was an issue with the shared bank slots, becuase those were the only ones I had issues with.

Once I got gers smaller bag size mod, the 3/4 size one, and all the bags fit on the top of the screen, I didn't have the issue.

So that is another work around for people that do not want to mess with the code.
I'm not sure if it would work the other way , if all the bags were on the bottom of the screen?
It's the attach point, as you discovered, good find!

Laffs 03-26-2005 09:39 AM

It was opposite way round for me since last patch the top ones wouldnt save but the bottom ones do.

/agree damn good find, I got sick of moving them and just left them all messed up lol

depechenode 03-26-2005 09:46 AM

With the 3/4 bag mod ger's or mine, it seems this problem was not an issue anymore as well.

Zonx 03-26-2005 12:00 PM

Oh man! This is awsome news. Gonna see if this solves shifting issues with my DynamicBags. If so, you'll get a credit line ;)

My DynamicBags mod reconfigures each bag based on total slots, so there's allot of resizing going on. Each bag can have different widths.

Weegie 03-26-2005 12:39 PM

Quote:

Originally Posted by Deathbane27
PROBLEM SOLVED
:D :D :D :D :D :D :D :D :D

:nana:
/kiss
:nana:

Azoz 03-26-2005 12:42 PM

wow.
 
go go mook!

/kowtow

acethewd 03-26-2005 11:59 PM

Ok forgive me if this was touched on in another thread. Did a search but didn't see any posts quite on what I am seeing. Also wasn't sure if I should have made this a new thread but figured this was a good spot since these changes are where I am seeing some of my issue.

I made a bag mod like what the OP originally stated (ended up adding Parent.MaximumSize=x,y to it to try to fix my issue). When I log in and open my bags, the bags show one row less then they are supposed to. So a 12 slot bag shows 8 slots, 14 slot shows 12, etxc. The last row is cut off in each bag (bags are 4 slots wide by X long). I found though if I exchange the positions of two physically different sized bags in my inventory window, the bags will then show the last row that was cut off. Except by the time I am done doing all the exchanges, my 12 slot bags are then trying to show a 4th row (there is nothing in the row - just blank space). So I could live with this if it would hold that way, but of course, that would make it to easy. Upon logging and coming back into the game, the bags are missing a row again.

Just curious if anyone else has seen this (probably not)?

If I take my custom file out and go with the default, the issue goes away (of course then I have the larger bulky box/bag windows again). If I put the mod back in place after that, then I have the same issue again. Will try one of your guy's bag mods and see if I get the same thing. It acts like the ui is stuck loading smaller bag settings from something.

Edit:
Ok nm. My modding skills just suck I guess. Tried Deathbane27 and Ger's 3/4th bag mods and they both worked fine. So I will have to go through my code and see what the heck is up with it (I like to know why it isn't working). Sorry for the wasted bandwidth.

Deathbane27 03-27-2005 01:14 AM

Acethewd: It sounds like you're scripting the bag to show too small. Make sure the OnShow script sizes the bag to include the bottom of the row, not be resized to the Y position of the row.

acethewd 03-27-2005 04:09 AM

Thanks for the reply Deathbane27 but I think I found my dumb mistake. Somehow I managed to change Parent.Size (on the icon settings) into Parent.MaximumSize. I think this is what was causing me all my grief (I managed to fix the dumb thing without remembering what I had changed and had to start over again).

So after several hours of logging in and out of the game, I, and my friends with my characters on their friends list, can't wait for /loadui to get fixed.

Thanks again for an awesome fix.

Zonx 03-31-2005 05:51 AM

Some related notes:

1) Windows set to UserResizable=false do not have their size saved to the server. I'd guess UserMovable=flase results in the location not being saved.

2) If no location or size info is saved on the server, UIBuilder settings will always be used.

3) If a window save does exist on the server, it uses that info regardless of the window's current Movable/resizable settings. What this means is a window that's resizable by default might be saved to the server prior to a mod being aplied that disables resizability. The saved state will still be used. It also means windows will pop back to a previously saved state if you're bugged and not saving new locations.

4) EQ2 likes to shove stuff fully on screen weather "allow windows off-screen" is checked or not. Not sure but I think it often uses the UIBuilder window size to decide what is or isn't offscreen. What this means is a bag window near the bottom edge of screen can be repositioned so their bottom at default size fits on screen before being shrunk down to their slot count. With nearly double the max slot count, this is a far more likely problem. Might be a good idea to set custom bags to a very small initial size to avoid this.

Drumstix42 04-06-2005 06:55 PM

Today I noticed SOE said that UI and chat settings should save better now... I wonder what this affected, and if the bags are affected. I personally don't have trouble with my bags/chat.

Sixes 04-09-2005 08:15 AM

Just tried making this change to the Tablets II skin.

No difference. Every time I log off my bags move to the right and /or down.

Sixes.

Deathbane27 04-09-2005 04:12 PM

Attach the modified bag window here and I'll take a look at it.

Zonx 04-10-2005 01:47 AM

FYI, I discovered an interesting issue that arrises from stay-putting custom bags with the usual resize scripting...

Reverting back to a more standard bag appears to have busted the auto-resizing.

Laffs 04-10-2005 08:20 AM

I found with handmade bags that can have X number of slots depending on the quality of the bag the first time you open one the frame will be the right size to take all the slots even though there is only say 6 , close it, reopen and the frame snaps to the correct size......

Also bags for me are not staying put again :mad: but on a vertical axis they always seem to be moved up as if they were snapping back to where the edge of the letterbox frame would be if I had it enabled..... Now with 26 bags ish on my artisan dude this is a royal pain in the butt... Seems like last patch broke them ?

depechenode 04-10-2005 08:59 AM

Quote:

Originally Posted by Drumstix42
Today I noticed SOE said that UI and chat settings should save better now... I wonder what this affected, and if the bags are affected. I personally don't have trouble with my bags/chat.

The effect was, now SOE has control over your .ini files. Even if you READONLY the files, upon campout, the files become readable and modified by the client!


I guess that was their fix? Seems it is not working? I have no problems with bags btw..I am stil lusing my mod which is really ger's bag mod changed to my liking with Stayput (tm) from Deathbane.

Zonx 04-10-2005 09:15 AM

Quote:

Originally Posted by depechenode
...Stayput (tm)...

LOL, why do you bother (tm)ing a term that:

1) We've all been using since befor Deathbane figured out a solution
2) Applies to Open Source code you can't profit from?

:p

ger 04-10-2005 09:17 AM

Quote:

Originally Posted by Zonx
LOL, why do you bother (tm)ing a term that:

1) We've all been using since befor Deathbane figured out a solution
2) Applies to Open Source code you can't profit from?

:p

It's a joke…at least, it is when I do it. Supposed to signify that StayPut is special. :D

Zonx 04-10-2005 09:25 AM

Aye, I occasionally use it jokingly. Only reason I asked is depechenode seams to use it constantly, which kinda looses the humor :p

Piltdown 04-11-2005 09:48 PM

It's very possible that I'm missing something, but this has not fixed the issue as far as I can tell. I installed the Fetish mod (excellent) and if I stack my bags or bankboxes down the side of the screen they still get shifted when I log. I poked at the xml files with a stick according to your instructions - no change.

Can one of you gurus check this out? My bags will stay if they're close to the top, but not stacked down the side.

* I should probably note that I installed the updated version of the mod.


All times are GMT -5. The time now is 11:53 AM.

vBulletin® - Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
© MMOUI