Using pointers instead of references is so uncool.

This commit is contained in:
Lirusaito
2015-11-17 05:54:40 -05:00
parent 16daa6850e
commit 46fa98419c

View File

@@ -1286,10 +1286,10 @@ public:
S32 target_index = input["body"]["Index"][0]["Prey"].asInteger(); S32 target_index = input["body"]["Index"][0]["Prey"].asInteger();
S32 you_index = input["body"]["Index"][0]["You" ].asInteger(); S32 you_index = input["body"]["Index"][0]["You" ].asInteger();
std::vector<U32>* avatar_locs = &region->mMapAvatars; std::vector<U32>& avatar_locs = region->mMapAvatars;
std::vector<LLUUID>* avatar_ids = &region->mMapAvatarIDs; std::vector<LLUUID>& avatar_ids = region->mMapAvatarIDs;
avatar_locs->clear(); avatar_locs.clear();
avatar_ids->clear(); avatar_ids.clear();
//LL_INFOS() << "coarse locations agent[0] " << input["body"]["AgentData"][0]["AgentID"].asUUID() << LL_ENDL; //LL_INFOS() << "coarse locations agent[0] " << input["body"]["AgentData"][0]["AgentID"].asUUID() << LL_ENDL;
//LL_INFOS() << "my agent id = " << gAgent.getID() << LL_ENDL; //LL_INFOS() << "my agent id = " << gAgent.getID() << LL_ENDL;
@@ -1329,13 +1329,13 @@ public:
pos |= y; pos |= y;
pos <<= 8; pos <<= 8;
pos |= z; pos |= z;
avatar_locs->push_back(pos); avatar_locs.push_back(pos);
//LL_INFOS() << "next pos: " << x << "," << y << "," << z << ": " << pos << LL_ENDL; //LL_INFOS() << "next pos: " << x << "," << y << "," << z << ": " << pos << LL_ENDL;
if(has_agent_data) // for backwards compatibility with old message format if(has_agent_data) // for backwards compatibility with old message format
{ {
LLUUID agent_id(agents_it->get("AgentID").asUUID()); LLUUID agent_id(agents_it->get("AgentID").asUUID());
//LL_INFOS() << "next agent: " << agent_id.asString() << LL_ENDL; //LL_INFOS() << "next agent: " << agent_id.asString() << LL_ENDL;
avatar_ids->push_back(agent_id); avatar_ids.push_back(agent_id);
} }
} }
if (has_agent_data) if (has_agent_data)