void ConfigElem::add_prop( const char* propname, unsigned long lval ) { OSTRINGSTREAM os; os << lval; properties.insert( make_pair(string(propname), OSTRINGSTREAM_STR(os)) ); }
void handle_ef_seed( Client *client, PKTIN_EF *msg ) { VersionDetailStruct detail; detail.major=cfBEu32(msg->ver_Major); detail.minor=cfBEu32(msg->ver_Minor); detail.rev=cfBEu32(msg->ver_Revision); detail.patch=cfBEu32(msg->ver_Patch); client->setversiondetail(detail); if (client->compareVersion(CLIENT_VER_7000)) client->setClientType(CLIENTTYPE_7000); else if (client->compareVersion(CLIENT_VER_60142)) client->setClientType(CLIENTTYPE_60142); else if (client->compareVersion(CLIENT_VER_6017)) //Grid-loc support client->setClientType(CLIENTTYPE_6017); else if (client->compareVersion(CLIENT_VER_5020)) client->setClientType(CLIENTTYPE_5020); else if (client->compareVersion(CLIENT_VER_5000)) client->setClientType(CLIENTTYPE_5000); else if (client->compareVersion(CLIENT_VER_4070)) client->setClientType(CLIENTTYPE_4070); else if (client->compareVersion(CLIENT_VER_4000)) client->setClientType(CLIENTTYPE_4000); // detail->patch is since 5.0.7 always numeric, so no need to make it complicated OSTRINGSTREAM os; os << detail.major << "." << detail.minor << "." << detail.rev << "." << detail.patch; client->setversion(OSTRINGSTREAM_STR(os)); }
void UObjectHelper::ShowProperties( Network::Client* client, PropertyList& proplist ) { for ( PropertyList::Properties::iterator itr = proplist.properties.begin(); itr != proplist.properties.end(); ++itr ) { OSTRINGSTREAM os; os << ( *itr ).first << ": " << ( *itr ).second; send_sysmessage( client, OSTRINGSTREAM_STR( os ) ); } }
void VectorConfigElem::add_prop( const char* propname, unsigned long lval ) { ConfigProperty* prop; OSTRINGSTREAM os; os << lval; prop = new ConfigProperty( propname, OSTRINGSTREAM_STR(os) ); properties.push_back( prop ); }
std::string decint( size_t v ) { OSTRINGSTREAM os; os << v; return OSTRINGSTREAM_STR( os ); }
std::string decint( unsigned long v ) { OSTRINGSTREAM os; os << v; return OSTRINGSTREAM_STR( os ); }
std::string hexint( size_t v ) { OSTRINGSTREAM os; os << "0x" << std::hex << v; return OSTRINGSTREAM_STR( os ); }
std::string hexint( unsigned long v ) { OSTRINGSTREAM os; os << "0x" << std::hex << v; return OSTRINGSTREAM_STR( os ); }
void Dice::die_string(std::string& str) const { OSTRINGSTREAM os; os << die_count << "d" << die_type << "+" << plus_damage; str = OSTRINGSTREAM_STR(os); }
string EScriptProgram::dbg_get_instruction( unsigned atPC ) const { OSTRINGSTREAM os; os << instr[ atPC ].token; return OSTRINGSTREAM_STR(os); }