Screenresolution not correct ?

This forum is meant for requesting technical support or reporting bugs.

Moderators: time-killer-games, Vengeance66, Candle, reneuend, GM-Support

Screenresolution not correct ?

Postby ShadowHunter » Thu Dec 29, 2005 6:59 pm

Hi GM,

I'm wondering wheter or not there is a problem with the retrieving the resolution from AM.

When I set the resolution to 1280x1024 or 800x600 AM retrieves the width like the height being 1024 or 600 instead of 1280 or 800. There is also no difference between the height and the width so one of them must be coded wrong. Height and width are both 1024 or 600...

When the resolution is changed by AM from 1280 x 1024 to 640 x 480 the width is retrieved as 480 and the height as 1024 ?

I'm using these commands:

MsgBox "Height: " & ScreenObject.Height/15
MsgBox "Height: " & ScreenObject.Width/15

Could you verify this please, I'm not getting my new plugin to work because of this little issue :wink:

Tried it with version 3.5.2 and 4.0.3...

Thanks GM and happy New Year

ShAdOwHuNtEr
User avatar
ShadowHunter
Forum Admin and Games Page admin
 
Posts: 1304
Joined: Fri Jun 06, 2003 10:37 pm
Location: Belgium

Postby GM-Support » Thu Dec 29, 2005 7:30 pm

Hi ShadowHunter,

This is a bug of VB6, that happens only on some computers. I have just tested it here and it works fine. If you open VB6 and type MsgBox Screen.Width/15 you will probably get the same problem.


To solve the probem, please use the commands Action.GetDisplayResolutionX and Action.GetDisplayResolutionY, like in the following example:
Code: Select all
MsgBox Action.GetDisplayResolutionX
MsgBox Action.GetDisplayResolutionY


You don't even need to divide by 15, as you get the result directly in pixels (it makes API calls instead of native VB6 calls).


BTW, good news about the plugins! v4.2 build4 (to be released very soon) allows the FREE Edition users to evaluate the plugins as if they were using the Full Edition. They can evaluate them only with projects that have fewer than 20 frames.

So, in the future you will probably have more users using your nice plugins!

Best regards,
GM-Support
GM-Support
Forum Admin and Games Page admin
 
Posts: 2221
Joined: Thu Jun 05, 2003 7:52 pm

Postby ShadowHunter » Thu Dec 29, 2005 8:36 pm

Hi GM,

Thanks for the great feedback, I was already afraid it was a bug with Visual Basic since my stand alone exectuable had the same problem.

I have another question too, you may also PM it to me. I need to get the Hwnd from a running AM-game so I can hook my plugin to it.

Problem is I can only hook in if I know the window caption. There are other ways but I'm not familiar to them. Could you please help me out how to get the needed handle ? Doens't matter how...

I want to retrieve the X-Y coordinates related to the AM area by means of a plugin. It would be even better to retrieve the hotspot number of a frame but I think that is not feasable :wink:

BTW: That is indeed great news for all of us. I hope more people will use plugins because the sky is the limit. Great job GM :D

Thank you very much !

Kind regards,

ShAdOwHuNtEr
User avatar
ShadowHunter
Forum Admin and Games Page admin
 
Posts: 1304
Joined: Fri Jun 06, 2003 10:37 pm
Location: Belgium

Postby GM-Support » Thu Dec 29, 2005 8:54 pm

Hi ShadowHunter,

I am going to think about that. I will let you know if I come up with an idea.

Thanks,
Best regards,
GM-Support
GM-Support
Forum Admin and Games Page admin
 
Posts: 2221
Joined: Thu Jun 05, 2003 7:52 pm

Postby ShadowHunter » Thu Dec 29, 2005 9:03 pm

Thanks GM :D
User avatar
ShadowHunter
Forum Admin and Games Page admin
 
Posts: 1304
Joined: Fri Jun 06, 2003 10:37 pm
Location: Belgium


Return to Adventure Maker Technical Support and Bug Reports

Who is online

Users browsing this forum: No registered users and 1 guest

cron