Jump to content
  • Advertisement

Archived

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

test2

Callback-functions

This topic is 6152 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Advertisement
    

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

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!