View Single Post
Re: Storing an array of function calls, and their params.....
Old
  (#3)
Maleficus
Member
 
Maleficus's Avatar
 
Status: Offline
Posts: 1,054
Join Date: May 2004
Location: Planet Earth
Default Re: Storing an array of function calls, and their params..... - 16-05-2005

Quote:
Originally Posted by Lazy
fooFunc is a function pointer and you are assigning it an integer which is what MyCoolFunc is returning.
The easiest way to do what you want is simply add iParam1, iParam2, ect... to your struct then just do something like array[ slot ].fooFunc( array[slot ].iParam1, array[ slot ].iParam2 );

Unless I missed the point...
No, no - thats exactly what I'm looking for, I'll try it later when I get some time.

What I don't understand is, I've had no problem in the past doing essentially the same thing, but instead of being passed 2 ints, its passed 1 sturct.


Thanks!


Dum Spiro Spero


  
Reply With Quote