mirror of
https://github.com/EQEmu/Server.git
synced 2025-12-11 16:51:29 +00:00
[Rule] Allow GMs to silently summon (#3910)
* [Rule] Allow GMs to silently summon Disable to silently summon players with #summon. Converted SummonPC to a MessageString * Implementing an automatic detection of gm hidden mode and silent summoning.
This commit is contained in:
parent
e6dc980315
commit
98928aee74
@ -11974,6 +11974,8 @@ std::string GetZoneModeString(ZoneMode mode)
|
||||
return "ZoneToSafeCoords";
|
||||
case GMSummon:
|
||||
return "GMSummon";
|
||||
case GMHiddenSummon:
|
||||
return "GMHiddenSummon";
|
||||
case ZoneToBindPoint:
|
||||
return "ZoneToBindPoint";
|
||||
case ZoneSolicited:
|
||||
|
||||
@ -112,14 +112,15 @@ enum { //scribing argument to MemorizeSpell
|
||||
|
||||
//Modes for the zoning state of the client.
|
||||
typedef enum {
|
||||
ZoneToSafeCoords, // Always send ZonePlayerToBind_Struct to client: Succor/Evac
|
||||
GMSummon, // Always send ZonePlayerToBind_Struct to client: Only a GM Summon
|
||||
ZoneToBindPoint, // Always send ZonePlayerToBind_Struct to client: Death Only
|
||||
ZoneSolicited, // Always send ZonePlayerToBind_Struct to client: Portal, Translocate, Evac spells that have a x y z coord in the spell data
|
||||
ZoneToSafeCoords, // Always send ZonePlayerToBind_Struct to client: Succor/Evac
|
||||
GMSummon, // Always send ZonePlayerToBind_Struct to client: Only a GM Summon
|
||||
GMHiddenSummon, // Always send ZonePlayerToBind_Struct to client silently: Only a GM Summon
|
||||
ZoneToBindPoint, // Always send ZonePlayerToBind_Struct to client: Death Only
|
||||
ZoneSolicited, // Always send ZonePlayerToBind_Struct to client: Portal, Translocate, Evac spells that have a x y z coord in the spell data
|
||||
ZoneUnsolicited,
|
||||
GateToBindPoint, // Always send RequestClientZoneChange_Struct to client: Gate spell or Translocate To Bind Point spell
|
||||
SummonPC, // In-zone GMMove() always: Call of the Hero spell or some other type of in zone only summons
|
||||
Rewind, // Summon to /rewind location.
|
||||
GateToBindPoint, // Always send RequestClientZoneChange_Struct to client: Gate spell or Translocate To Bind Point spell
|
||||
SummonPC, // In-zone GMMove() always: Call of the Hero spell or some other type of in zone only summons
|
||||
Rewind, // Summon to /rewind location.
|
||||
EvacToSafeCoords
|
||||
} ZoneMode;
|
||||
|
||||
|
||||
@ -91,7 +91,7 @@ void command_summon(Client *c, const Seperator *sep)
|
||||
c->GetZ(),
|
||||
c->GetHeading(),
|
||||
2,
|
||||
GMSummon
|
||||
c->GetHideMe() ? GMHiddenSummon : GMSummon
|
||||
);
|
||||
return;
|
||||
}
|
||||
|
||||
@ -88,6 +88,7 @@ void Client::Handle_OP_ZoneChange(const EQApplicationPacket *app) {
|
||||
target_zone_id = zone->GetZoneID();
|
||||
break;
|
||||
case GMSummon:
|
||||
case GMHiddenSummon:
|
||||
case ZoneSolicited: //we told the client to zone somewhere, so we know where they are going.
|
||||
target_zone_id = zonesummon_id;
|
||||
break;
|
||||
@ -276,6 +277,7 @@ void Client::Handle_OP_ZoneChange(const EQApplicationPacket *app) {
|
||||
target_heading = safe_heading;
|
||||
break;
|
||||
case GMSummon:
|
||||
case GMHiddenSummon:
|
||||
target_x = m_ZoneSummonLocation.x;
|
||||
target_y = m_ZoneSummonLocation.y;
|
||||
target_z = m_ZoneSummonLocation.z;
|
||||
@ -697,6 +699,9 @@ void Client::ProcessMovePC(uint32 zoneID, uint32 instance_id, float x, float y,
|
||||
Message(Chat::Yellow, "You have been summoned by a GM!");
|
||||
ZonePC(zoneID, instance_id, x, y, z, heading, ignorerestrictions, zm);
|
||||
break;
|
||||
case GMHiddenSummon:
|
||||
ZonePC(zoneID, instance_id, x, y, z, heading, ignorerestrictions, zm);
|
||||
break;
|
||||
case ZoneToBindPoint:
|
||||
ZonePC(zoneID, instance_id, x, y, z, heading, ignorerestrictions, zm);
|
||||
break;
|
||||
@ -704,7 +709,7 @@ void Client::ProcessMovePC(uint32 zoneID, uint32 instance_id, float x, float y,
|
||||
ZonePC(zoneID, instance_id, x, y, z, heading, ignorerestrictions, zm);
|
||||
break;
|
||||
case SummonPC:
|
||||
Message(Chat::Yellow, "You have been summoned!");
|
||||
MessageString(Chat::Yellow, PLAYER_SUMMONED);
|
||||
ZonePC(zoneID, instance_id, x, y, z, heading, ignorerestrictions, zm);
|
||||
break;
|
||||
case Rewind:
|
||||
@ -761,6 +766,7 @@ void Client::ZonePC(uint32 zoneID, uint32 instance_id, float x, float y, float z
|
||||
heading = zone_safe_point.w;
|
||||
break;
|
||||
case GMSummon:
|
||||
case GMHiddenSummon:
|
||||
m_Position = glm::vec4(x, y, z, heading);
|
||||
m_ZoneSummonLocation = m_Position;
|
||||
zonesummon_id = zoneID;
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user