From: Enar <eva...@us...> - 2007-01-04 09:31:23
|
Update of /cvsroot/planeshift/planeshift/src/server In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv31963 Modified Files: gmeventmanager.cpp chatmanager.cpp Log Message: MSVS warning fixes Index: gmeventmanager.cpp =================================================================== RCS file: /cvsroot/planeshift/planeshift/src/server/gmeventmanager.cpp,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** gmeventmanager.cpp 27 Dec 2006 21:17:54 -0000 1.2 --- gmeventmanager.cpp 4 Jan 2007 09:31:16 -0000 1.3 *************** *** 41,45 **** psserver->GetEventManager()->Unsubscribe(this,MSGTYPE_GMEVENT_INFO); ! for (int e = 0; e < gmEvents.Length(); e++) { gmEvents[e]->playerID.DeleteAll(); --- 41,45 ---- psserver->GetEventManager()->Unsubscribe(this,MSGTYPE_GMEVENT_INFO); ! for (size_t e = 0; e < gmEvents.Length(); e++) { gmEvents[e]->playerID.DeleteAll(); *************** *** 57,61 **** if (events.IsValid()) { ! for (int e=0; e<events.Count(); e++) { ongoingGMEvent = new GMEvent; --- 57,61 ---- if (events.IsValid()) { ! for (unsigned long e=0; e<events.Count(); e++) { ongoingGMEvent = new GMEvent; *************** *** 78,82 **** int eventPlayerID; int eventID; ! for (int rp=0; rp<registeredPlayers.Count(); rp++) { eventID = registeredPlayers[rp].GetInt("event_id"); --- 78,82 ---- int eventPlayerID; int eventID; ! for (unsigned long rp=0; rp<registeredPlayers.Count(); rp++) { eventID = registeredPlayers[rp].GetInt("event_id"); *************** *** 235,239 **** ClientConnectionSet* clientConnections = psserver->GetConnections(); Client* target; ! for (int p = 0; p < theEvent->playerID.Length(); p++) { // TODO original req here is only inform players <50m --- 235,239 ---- ClientConnectionSet* clientConnections = psserver->GetConnections(); Client* target; ! for (size_t p = 0; p < theEvent->playerID.Length(); p++) { // TODO original req here is only inform players <50m *************** *** 367,371 **** if (me->GetType() == MSGTYPE_GMEVENT_INFO) { ! int gmID; psGMEventInfoMessage msg(me); --- 367,371 ---- if (me->GetType() == MSGTYPE_GMEVENT_INFO) { ! //int gmID; psGMEventInfoMessage msg(me); *************** *** 445,449 **** GMEventManager::GMEvent* GMEventManager::GetGMEventByID(int id) { ! for (int e = 0; e < gmEvents.Length(); e++) { if (gmEvents[e]->id == id) --- 445,449 ---- GMEventManager::GMEvent* GMEventManager::GetGMEventByID(int id) { ! for (size_t e = 0; e < gmEvents.Length(); e++) { if (gmEvents[e]->id == id) *************** *** 457,461 **** GMEventManager::GMEvent* GMEventManager::GetGMEventByGM(int gmID, GMEventStatus status, int& startIndex) { ! for (int e = startIndex; e < gmEvents.Length(); e++) { startIndex++; --- 457,461 ---- GMEventManager::GMEvent* GMEventManager::GetGMEventByGM(int gmID, GMEventStatus status, int& startIndex) { ! for (size_t e = startIndex; e < gmEvents.Length(); e++) { startIndex++; *************** *** 472,476 **** GMEventManager::GMEvent* GMEventManager::GetGMEventByPlayer(int playerID, GMEventStatus status, int& startIndex) { ! for (int e = startIndex; e < gmEvents.Length(); e++) { startIndex++; --- 472,476 ---- GMEventManager::GMEvent* GMEventManager::GetGMEventByPlayer(int playerID, GMEventStatus status, int& startIndex) { ! for (size_t e = startIndex; e < gmEvents.Length(); e++) { startIndex++; Index: chatmanager.cpp =================================================================== RCS file: /cvsroot/planeshift/planeshift/src/server/chatmanager.cpp,v retrieving revision 1.163 retrieving revision 1.164 diff -C2 -d -r1.163 -r1.164 *** chatmanager.cpp 30 Dec 2006 12:35:41 -0000 1.163 --- chatmanager.cpp 4 Jan 2007 09:31:16 -0000 1.164 *************** *** 150,154 **** && msg.sText.StartsWith(pet->GetCharacterData()->GetCharName(), true)) { ! int n = strlen(pet->GetCharacterData()->GetCharName()); if (msg.sText.Length() >= n + 1 && msg.sText.GetAt(n) == ' ') { --- 150,154 ---- && msg.sText.StartsWith(pet->GetCharacterData()->GetCharName(), true)) { ! size_t n = strlen(pet->GetCharacterData()->GetCharName()); if (msg.sText.Length() >= n + 1 && msg.sText.GetAt(n) == ' ') { |