Jump to content
  • Advertisement

Archived

This topic is now archived and is closed to further replies.

Bully

The perils of Cooperative level

This topic is 6924 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I recently put my Directx system into classes. And I don't know what I'm doing wrong. I can't seem to be able to set the cooperative level anymore. if(FAILED(lpDD4->SetCooperativeLevel(hwnd,DDSCL_FULLSCREEN/DDSCL_ALLOWMODEX/DDSCL_ALLOWREBOOT / DDSCL_EXCLUSIVE))) { ReportError("Can't set cooperative level"); exit(10); } The program compiles fine. but when I run it I get an error. here is also my window. if(!(hwnd = CreateWindowEx(NULL, "WINCLASS" "Window", WS_POPUP / WS_VISIBLE, 0,0, GetSystemMetrics(SM_CXSCREEN), GetSystemMetrics(SM_CYSCREEN), NULL, NULL, hinstance, NULL))) return(0); -Thank you for your help Edited by - Bully on 5/3/00 10:24:42 PM

Share this post


Link to post
Share on other sites
Advertisement
Are the "/" in your code actually there? Or are they just being used to denote one or the other? If they are actually in the code, remove them and replace them with "/". I dunno what the hell the button is called, but it''s the one above the "\", and it''s the one you want.

- IO Fission

Tearing 'em apart for no particular reason...

Share this post


Link to post
Share on other sites
This board turns the / (pipe) into /

As for Bully's question, it looks fine. Are you sure you have a valid pointer to the directdraw object? Since you recently moved it into classes, it seems that there might be some other problem beyond the window and this particular call. One thing that would help would be knowing what the error code is that you're getting from SetCooperativeLevel. It can tell you a lot.

Mark Fassett
Laughing Dragon Entertainment
http://www.laughing-dragon.com

Edited by - LaughingD on 5/4/00 2:02:55 AM

Share this post


Link to post
Share on other sites

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!