Clean up excess teleport to code using get_av_pos
This commit is contained in:
@@ -347,18 +347,6 @@ void track_av(const LLUUID& id)
|
|||||||
LLTracker::trackLocation(avatars[id], LLStringUtil::null, LLStringUtil::null);
|
LLTracker::trackLocation(avatars[id], LLStringUtil::null, LLStringUtil::null);
|
||||||
}
|
}
|
||||||
|
|
||||||
void teleport_to(const LLUUID& id)
|
|
||||||
{
|
|
||||||
if (auto entry = LLFloaterAvatarList::instanceExists() ? LLFloaterAvatarList::instance().getAvatarEntry(id) : nullptr)
|
|
||||||
gAgent.teleportViaLocation(entry->getPosition());
|
|
||||||
else
|
|
||||||
{
|
|
||||||
LLWorld::pos_map_t avatars;
|
|
||||||
LLWorld::instance().getAvatars(&avatars);
|
|
||||||
gAgent.teleportViaLocation(avatars[id]);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
static void cmd_profile(const LLAvatarListEntry* entry);
|
static void cmd_profile(const LLAvatarListEntry* entry);
|
||||||
static void cmd_toggle_mark(LLAvatarListEntry* entry);
|
static void cmd_toggle_mark(LLAvatarListEntry* entry);
|
||||||
static void cmd_ar(const LLAvatarListEntry* entry);
|
static void cmd_ar(const LLAvatarListEntry* entry);
|
||||||
@@ -416,7 +404,7 @@ namespace
|
|||||||
{
|
{
|
||||||
bool handleEvent(LLPointer<LLEvent> event, const LLSD& userdata)
|
bool handleEvent(LLPointer<LLEvent> event, const LLSD& userdata)
|
||||||
{
|
{
|
||||||
teleport_to(LFIDBearer::getActiveSelectedID());
|
gAgent.teleportViaLocation(get_av_pos(LFIDBearer::getActiveSelectedID()));
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|||||||
Reference in New Issue
Block a user