本文整理汇总了C++中PlayerObject::removeWaypointBySpecialType方法的典型用法代码示例。如果您正苦于以下问题:C++ PlayerObject::removeWaypointBySpecialType方法的具体用法?C++ PlayerObject::removeWaypointBySpecialType怎么用?C++ PlayerObject::removeWaypointBySpecialType使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类PlayerObject
的用法示例。
在下文中一共展示了PlayerObject::removeWaypointBySpecialType方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: removeMember
void GroupObjectImplementation::removeMember(SceneObject* member) {
ManagedReference<SceneObject*> obj = member;
for (int i = 0; i < groupMembers.size(); i++) {
SceneObject* scno = groupMembers.get(i).get().get();
if (scno == member) {
GroupObjectDeltaMessage6* grp = new GroupObjectDeltaMessage6(_this.getReferenceUnsafeStaticCast());
grp->startUpdate(1);
groupMembers.remove(i, grp);
grp->close();
broadcastMessage(grp);
}
}
if (member->isPlayerCreature()) {
// Remove member's pets
CreatureObject* playerCreature = cast<CreatureObject*>(member);
RemovePetsFromGroupTask* task = new RemovePetsFromGroupTask(playerCreature, _this.getReferenceUnsafeStaticCast());
task->execute();
//Close any open Group SUIs.
ManagedReference<PlayerObject*> ghost = playerCreature->getPlayerObject();
if (ghost != NULL) {
ghost->closeSuiWindowType(SuiWindowType::GROUP_LOOT_RULE);
ghost->closeSuiWindowType(SuiWindowType::GROUP_LOOT_CHANGED);
ghost->closeSuiWindowType(SuiWindowType::GROUP_LOOT_PICK_LOOTER);
}
//Reset Master Looter if needed.
if (getMasterLooterID() == playerCreature->getObjectID()) {
ManagedReference<CreatureObject*> groupLeader = (getLeader()).castTo<CreatureObject*>();
GroupManager::instance()->changeMasterLooter(_this.getReferenceUnsafeStaticCast(), groupLeader, false);
}
if (hasSquadLeader()) {
removeGroupModifiers(playerCreature);
}
if (playerCreature->getPlayerObject() != NULL) {
PlayerObject* ghost = playerCreature->getPlayerObject();
ghost->removeWaypointBySpecialType(WaypointObject::SPECIALTYPE_NEARESTMISSIONFORGROUP);
}
Zone* zone = playerCreature->getZone();
if (zone != NULL) {
scheduleUpdateNearestMissionForGroup(zone->getPlanetCRC());
}
}
calcGroupLevel();
}
示例2: disband
void GroupObjectImplementation::disband() {
// this locked
ManagedReference<ChatRoom* > chat = chatRoom;
for (int i = 0; i < groupMembers.size(); i++) {
if (groupMembers.get(i) == NULL) {
continue;
}
Reference<CreatureObject*> groupMember = getGroupMember(i).castTo<CreatureObject*>();
try {
Locker clocker(groupMember, _this.get());
if (groupMember->isPlayerCreature()) {
if (chat != NULL) {
chat->removePlayer(groupMember, false);
chat->sendDestroyTo(groupMember);
ChatRoom* room = chat->getParent();
room->sendDestroyTo(groupMember);
}
if (groupMember->getPlayerObject() != NULL) {
PlayerObject* ghost = groupMember->getPlayerObject();
ghost->removeWaypointBySpecialType(WaypointObject::SPECIALTYPE_NEARESTMISSIONFORGROUP);
}
}
groupMember->updateGroup(NULL);
//play->updateGroupId(0);
//sendClosestWaypointDestroyTo(play);
//removeSquadLeaderBonuses(play);
} catch (Exception& e) {
System::out << "Exception in GroupObject::disband(Player* player)\n";
}
}
destroyChatRoom();
if (hasSquadLeader())
removeGroupModifiers();
groupMembers.removeAll();
//The mission waypoints should not be destroyed. They belong to the players.
//missionWaypoints.removeAll();
}
示例3: disband
void GroupObjectImplementation::disband() {
//Group is locked
for (int i = 0; i < groupMembers.size(); i++) {
if (groupMembers.get(i) == NULL)
continue;
Reference<CreatureObject*> groupMember = getGroupMember(i);
try {
Locker clocker(groupMember, _this.getReferenceUnsafeStaticCast());
if (groupMember->isPlayerCreature()) {
PlayerObject* ghost = groupMember->getPlayerObject();
if (ghost != NULL) {
ghost->removeWaypointBySpecialType(WaypointObject::SPECIALTYPE_NEARESTMISSIONFORGROUP);
}
}
groupMember->updateGroup(NULL);
} catch (Exception& e) {
System::out << "Exception in GroupObject::disband(Player* player)\n";
}
}
if (hasSquadLeader())
removeGroupModifiers();
while (groupMembers.size() > 0) {
CreatureObject* member = groupMembers.get(0).get().get();
updatePvPStatusNearCreature(member);
groupMembers.remove(0);
}
destroyChatRoom();
}