Archived

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

test2

Callback-functions

Recommended Posts

    

bool MyFunc(LPVOID pvParam);

typedef bool (*MYFUNC)(LPVOID);

bool CallFunc(MYFUNC pFunc, LPVOID pvParam)
{
return pFunc(pvParam);
}

int main(int argc, char* argv[])
{
CallFunc(MyFunc, NULL);
return 0;
}


That is a trivial and pointless example, but you just need to look into and understand function pointers to do whatever it is you're trying.

Edited by - jonstelly on January 9, 2002 12:02:49 PM

Share this post


Link to post
Share on other sites
Guest Anonymous Poster
If you check out this thread:
http://www.gamedev.net/community/forums/topic.asp?topic_id=69844

You can see my linked list of functions example.. that''s should help you out a bit to :o).

Billy - BillyB@mrsnj.com

ps. It''s on page 2 of the discussion.

Share this post


Link to post
Share on other sites