PANEL* menu_pan =
{
pos_x = 10;
pos_y = 340;
button(0,0,"button_new.bmp","button_new.bmp","button_new.bmp",DoReset,NULL,NULL);
layer=900; //to be sure nothing is above the panel
flags = VISIBLE;}
function DoReset() { ... } //You can write this function under the panel-definition also
//...
function main() {
mouse_mode=2;
mouse_map=bmap_create("button_new.bmp");
while(1)
{
vec_set(mouse_pos.x,mouse_cursor.x);
wait(1);}
//...