GetSystemMetrics

Posts 1–14 of 14 · Page 1 of 1
GetSystemMetrics
Hey i was experimenting in mo3ad001 new menu base and i thought id release this if any of the noobs out there didn't know this. Its a function i found and used to my advantage.

You know how people have different monitor sizes and if you put a certain d3d item at the end of your users monitor that will appear at a different spot on someone elses monitor because their monitor could be bigger or smaller. You can fix that by using this simple function.

First....Put were your functions go.
Code:
void GetPrimaryScreenSizeInPixels( SIZE& s)
{
// Start With Nothing
ZeroMemory( &s, sizeof(SIZE) );

// Get Width/Height
s.cx = (LONG)::GetSystemMetrics( SM_CXFULLSCREEN );
s.cy = (LONG)::GetSystemMetrics( SM_CYFULLSCREEN );

}
Second put above your render menu.(Or were ever you draw it)
Code:
int XRes = GetSystemMetrics(SM_CXFULLSCREEN);
int YRes = GetSystemMetrics(SM_CYFULLSCREEN);
Third... This is were you are doing your menu or whatever.
Code:
Menu.DrawBox(0,0,XRes,25,5,0x960000FF,0xFF000000,0xFF000000,pDevice);
This is using mo3ad001 functions.

This will create a bar that goes across your screen thats blue with a black border. Hope this helped if not w/e.

- Zane
nice ive had something like this befour its the same concept(kinda but thanks)
Idk what to say i didnt know what ur saying in that whole paragrah
*cough* GetViewport()
The problem with this is that, Your using the General windows stuff. So if game in Windows Mode... It will Draw a crosshair at the center of your screen, not the center of the games ViewPort.
Whit is right pDevice->GetViewPort(&vp);
Thanks but i did this myself. Gotta gain some self confidence

- Zane
someone gunna copy my title bar for black cipher
Quote Originally Posted by NOOB View Post
someone gunna copy my title bar for black cipher
I call it a taskbar? you know the thing microsft invented probably before you were born. LOL
Its alright i aint gunna release it, Just to see my skillz in D3D. I got a better one comin.

-Zane

Quote Originally Posted by NOOBJr View Post

>>I call it a taskbar? you know the thing microsft invented probably before you
>>thing microsft invented
>>invented...
No offense dude, but that is just plain not nice. And for your information: Microsoft doesn't invent shit. Task managing and context switching happens down at the hardware level. The 'taskbar' as you call it, is simply a display and for as far as I know you can't 'invent' a display.
Quote Originally Posted by .::SCHiM::. View Post
No offense dude, but that is just plain not nice. And for your information: Microsoft doesn't invent shit. Task managing and context switching happens down at the hardware level. The 'taskbar' as you call it, is simply a display and for as far as I know you can't 'invent' a display.
the taskbar is the thing at the bottom of your screen.. not the display, lol

It first came out in windows 95 also the start menu..

bfore that windows 3 had only the progrma manager and it was fuckin shitty
Quote Originally Posted by AVGN View Post


the taskbar is the thing at the bottom of your screen.. not the display, lol

It first came out in windows 95 also the start menu..

bfore that windows 3 had only the progrma manager and it was fuckin shitty
avgn would know
Thanks, Whits method is 10 times better though :/

And SCHiM is right not nice at all...
Dont gotta be a dick bro
hes 30 years old he should
Posts 1–14 of 14 · Page 1 of 1
This thread is closed for replies.

Tags for this Thread

None

Talk with us