Yesterday I accidentally changed the resolution of the game in General Settings (from 320x200 to 1980x1080), while agreeing to reformat the GUI.
I tried to change everything back, but now my GUI "shrank" like this:
(https://sun9-43.userapi.com/impg/BHft9-7oJvr2Y254_JP69K_7AGeG4nxaObxw5Q/NFtKJaLbrbA.jpg?size=320x277&quality=96&proxy=1&sign=5f2a5605495628b9b99bffaac5a5516aype=album)
I tried to create a second project to look at the width-height parameters of each element and manually rewrite them into the main project, but still many settings are knocked down (the buttons are clickable in the corners, the text is shifted, and so on)
(https://sun9-32.userapi.com/impg/EVqC-vZY9miV-wzYoMY9ntI0gLFq4tvUIm0Mfg/DiRuGOrb3RA.jpg?size=449x93&quality=96&proxy=1&sign=423f4d592e90bfedee66e991ad711d15ype=album)
Can you tell me how to fix this?
If you have a project backup then you may try doing export/import GUI (or return to backup version). Same export/import may be used if your project just uses GUI from template without much changes.
Otherwise, only by hand.
I am not fully certain what do you mean "buttons clickable in the corners", if you mean only small part of button is clickable - that usually means their real Width/Height is still smaller than the graphic.
Didn't know that GUI could be imported. Thanks!
But when I trying to import and run the build - this error shows:
(https://sun9-39.userapi.com/impg/w_Axb_h5uuDwl57OocqFmFin6ib9Q79f3ruOag/QA7Wn6SgcNU.jpg?size=871x391&quality=96&proxy=1&sign=5c2e096bc3e2776208efdd7662aa272aype=album)
I don't know what exactly did you do, have you deleted previous GUI? where did you export new GUI from?
The error means simply that lblOverHotspot no longer exists.
I created a project with the Sierra preset, exported the GUI from there, went to my main project, deleted the old GUIs (which were broken due to a change in resolution), imported the GUIs saved from the new project and assigned them the same ID that the deleted ones had.
Quote from: Licht61 on Tue 23/02/2021 11:28:23
I created a project with the Sierra preset, exported the GUI from there, went to my main project, deleted the old GUIs (which were broken due to a change in resolution), imported the GUIs saved from the new project and assigned them the same ID that the deleted ones had.
Well, if your project had something different (more GUIs, more controls on them) than in Sierra template, then there will be mismatches, that you'd have to fix yourself.
Unless you saved more times after that you could try restore old guis by renaming Game.agf.bak file to Game.agf in your project folder, then try different approach (you'd have to close Editor without saving for that).
If you saved more than 1 time then Game.agf.bak already contains new changes probably.
Don't you have any backup of your project to which you could revert, or import guis from?
Found source of problem.
Some GUIs have buttons inside: for example gIconbar has btnIconWalk. This button has own setting\properties and script name (btnIconWalk).
When importing, which I described above (with deleting of "compressed" old GUIs), for some reason, I have these names with "2" in the end (btnIconWalk2). So game was crashing on launch, because I didn't see that new "2" in names.
I just deleted this number, saved project and everything work fine now.