Posted By: bjarni
Panel - 09/19/10 22:49
I need fundamental understanding of panel
I need to set flag = SHOW later when panel already defined?.
and how to insert button in panel when created this way?.
function call_MainMenu()
{
PANEL* MainMenu = pan_create("flags=SHOW",999); //create a panel at 0,0 at runtime
BMAP* bmpMainMenu = "mainmenu.pcx"; //Set the bitmap
MainMenu.bmap = bmpMainMenu; // NOW add the bmap to the Panel
MainMenu.pos_x = (screen_size.x - bmap_width(bmpMainMenu)) / 2;
MainMenu.pos_y = 50;
// Need buttons here
}
I need to set flag = SHOW later when panel already defined?.
and how to insert button in panel when created this way?.
function call_MainMenu()
{
PANEL* MainMenu = pan_create("flags=SHOW",999); //create a panel at 0,0 at runtime
BMAP* bmpMainMenu = "mainmenu.pcx"; //Set the bitmap
MainMenu.bmap = bmpMainMenu; // NOW add the bmap to the Panel
MainMenu.pos_x = (screen_size.x - bmap_width(bmpMainMenu)) / 2;
MainMenu.pos_y = 50;
// Need buttons here
}