OK, for any one who finds this thread and wonders ... I pulled it off, and here's how ...
Code:
function fn_Click();
function fn_Release();
function fn_Over();
PANEL Card1
{
bmap = card_frame;
Button = 0, 0, img_transparent, img_transparent, img_transparent, fn_Click, fn_Release, fn_Over;
flags = visible;
layer = 2;
}
PANEL Card1Image
{
bmap = card_1_normal;
layer = 1;
}
function fn_Click(btn, pnl)
{
if(pnl == Card1)
{
Card1Image.bmap = card_1_click;
}
}
function fn_Release(btn, pnl)
{
if(pnl == Card1 && event_type == event_release)
{
Card1Image.bmap = card_1_normal;
}
if(pnl == Card1 && event_type == event_mouseup)
{
Card1Image.bmap = card_1_over;
}
}
function fn_Over(btn, pnl)
{
if(pnl == Card1)
{
Card1Image.bmap = card_1_over;
}
}
So, basically ... if card_1_over, _normal and _click are BMAP*'s ... you could essentially create dynamically changing buttons ... say for example a memory card game where each time you lay the cards out the images behind them change ... you know there's 32 cards on the screen ... so you can define constant BMAP* references to card_1 -> card_32 ... and have _normal, _click and _over versions ... so the normal would be the back of the card (the same image for all cards in a memory deck most likely, heh) ... card_click would be the face of the card ... and card_over would maybe be the back of the card with a highlight ...
note, in the fn_Release ... I check the event type ... if the event_type==mouseup ... I go back to the 'over' (hover) state ... cause the mouse is still over the card ...
Hope this finds a use to someone, I know it helped me out ...
If anyone has a better way of doing this, please let me know.