Screen alignment issues on loading a .ged file

Questions, comments and discussion about the Game Editor development.

Screen alignment issues on loading a .ged file

Postby bamby1983 » Sun Dec 16, 2012 5:36 am

Background:
I have two .ged files in my game, which runs in full screen mode at 1360 X 760 resolution on my Windows 7 system. I have used the standard LoadGame function to load a new .ged file for the next game level.

Issue
Upon loading the new file, my screen first goes blank for a couple of seconds and then loads the correct file. However, when it does so, the new file, which is also loaded in full screen mode, is misaligned on my screen. I can see parts of my desktop/background folders on the extreme right of my screen and I can see the task bar and a part of the bottom of my desktop at the bottom of the screen. The top and left of the game seem to be out of my screen area. I'm not sure why the screen is misaligned when it is loaded like like, but I have tested this with two new files with no extra code or objects and it resulted in the same misaligned screen when each of the files loaded the other. The misalignment is not incremental - loading each file using the other multiple times does not increase this misalignment, which appears to be constant throughout.

Would anyone know why this misalignment occurs and how it can be avoided?
bamby1983
 
Posts: 112
Joined: Tue Jul 31, 2012 11:36 pm
Score: 8 Give a positive score

Re: Screen alignment issues on loading a .ged file

Postby skydereign » Sun Dec 16, 2012 7:00 am

Sounds like it is a bug (it doesn't happen on linux or mac.), and doesn't seem like one you can easily get around. Perhaps loading an in between windowed file will work?
User avatar
skydereign
 
Posts: 3510
Joined: Mon Jul 28, 2008 8:29 am
Score: 589 Give a positive score

Re: Screen alignment issues on loading a .ged file

Postby bamby1983 » Sun Dec 16, 2012 6:28 pm

skydereign wrote:Perhaps loading an in between windowed file will work?


You are awesome! Thanks! That did the trick. Would you know how I can switch from an in-between windowed file to a new full screen file without any user interaction? Here's what I had in mind:

1) Create an in-between windowed game file called "Loading.ged" to be used as a transition file for all levels
2) This file would import a variable containing the target file name using the loadVars function
3) As soon as the "Loading.ged" file launched, it would automatically execute a LoadGame function using the variable it imported from the original file. The new file would be opened in full screen mode.

I'm not sure how to implement point 3 above without a user input. Is there some way in which I can execute a function automatically when a new game file loads?
bamby1983
 
Posts: 112
Joined: Tue Jul 31, 2012 11:36 pm
Score: 8 Give a positive score

Re: Screen alignment issues on loading a .ged file

Postby skydereign » Sun Dec 16, 2012 8:50 pm

Well, the loading game acts like a normal game. Since all you want it to do is load the next game, you can use the view's create actor event to run the LoadGame.
User avatar
skydereign
 
Posts: 3510
Joined: Mon Jul 28, 2008 8:29 am
Score: 589 Give a positive score

Re: Screen alignment issues on loading a .ged file

Postby bamby1983 » Mon Dec 17, 2012 2:33 am

Thank you! It worked! :)
bamby1983
 
Posts: 112
Joined: Tue Jul 31, 2012 11:36 pm
Score: 8 Give a positive score


Return to General

Who is online

Users browsing this forum: No registered users and 1 guest

cron