|
From: David M. <ci...@ya...> - 2003-07-24 19:16:56
|
Any suggestions on how I can optimized the following
function?
void pc_char::write_to_all_pc(string to_send, bool
add_eoln)
{
map<string, pc_char *>::iterator i =
current_players.begin();
while (i != current_players.end()) {
(*i).second->write_to_player(to_send, add_eoln);
}
}
I was hoping to use for_each but kept coming across the
problem of "How the hell am I going to pass the arguments
to write_to_player?"
Thanks in Advance
=====
Signed
David Mcken
Life Sucks
Live with it
__________________________________
Do you Yahoo!?
Yahoo! SiteBuilder - Free, easy-to-use web site design software
http://sitebuilder.yahoo.com
|