1
0
mirror of https://foundry.openuru.org/gitblit/r/CWE-ou-minkata.git synced 2025-07-20 20:29:10 +00:00

Convert plUoid's object name to a plString

This commit is contained in:
2012-01-28 16:24:20 -08:00
parent 442a733fbb
commit e34414889f
122 changed files with 810 additions and 842 deletions

View File

@ -111,22 +111,14 @@ plCoopCoordinator::plCoopCoordinator(plKey host, plKey guest,
fGuestAccepted(false),
fGuestLinked(false)
{
const char * hostName = host->GetName();
const char * guestName = guest->GetName();
static int serial = 0;
int len = strlen(hostName) + strlen(guestName) + 3 /* serial num */ + 1;
char *newName = TRACKED_NEW char[len];
serial = serial % 999;
sprintf(newName, "%s%s%3i\x000", hostName, guestName, serial++);
plString newName = plString::Format("%s%s%3i\x000", host->GetName().c_str(), guest->GetName().c_str(), serial++);
plKey newKey = hsgResMgr::ResMgr()->NewKey(newName, this, host->GetUoid().GetLocation());
delete[] newName;
fSynchBone = hsStrcpy(synchBone);
plKey avMgrKey = plAvatarMgr::GetInstance()->GetKey();