Skip to main content
gamedev.net
🔒 Locked

MsgProc Design Question

Started by GDMichael 0 replies 550+ views
Original Post
GDMichael
GDMichael
Dear All, I am the beginner. I have a question for window message design problem. May be my question is stupid, but please answer me. Thank You. As I want to use Object-Oriented Apporach to design my game. When the winmain is called on my program, I will call a class/object called "GameEngine", like that: gameengine = new GameEngine(hInstance); gameengine->Run(); On the gameengine object, I will create a window application, like this gameengine::CreateAppWindow() { ... } And the MsgProc is placed on the class of CWinApp that is a application window class. For my question, I want to know is it a good idea that I put every action or every message handling of the game on the MsgProc on the CWinApp. I don't know how to seperate the message on the other object because there has only one LRESULT WindowProc message. Do you understand what I mean? The main problem that I want to know how to handle the Message on the game? Which object to handle the message is a good skill? Thx

Topic Locked

This topic has been locked by a moderator. New replies are not allowed.

Sign in to reply to this topic.