mirror of
https://github.com/EQEmu/Server.git
synced 2026-05-19 17:38:26 +00:00
Merge pull request #1228 from EQEmu/anon_afk_client
[Quest API] Add Anon/AFK methods to Perl and Lua.
This commit is contained in:
@@ -10134,3 +10134,27 @@ std::vector<int> Client::GetScribedSpells() {
|
||||
}
|
||||
return scribed_spells;
|
||||
}
|
||||
|
||||
void Client::SetAnon(uint8 anon_flag) {
|
||||
m_pp.anon = anon_flag;
|
||||
auto outapp = new EQApplicationPacket(OP_SpawnAppearance, sizeof(SpawnAppearance_Struct));
|
||||
SpawnAppearance_Struct* spawn_appearance = (SpawnAppearance_Struct*)outapp->pBuffer;
|
||||
spawn_appearance->spawn_id = this->GetID();
|
||||
spawn_appearance->type = AT_Anon;
|
||||
spawn_appearance->parameter = anon_flag;
|
||||
entity_list.QueueClients(this, outapp);
|
||||
Save();
|
||||
UpdateWho();
|
||||
safe_delete(outapp);
|
||||
}
|
||||
|
||||
void Client::SetAFK(uint8 afk_flag) {
|
||||
AFK = afk_flag;
|
||||
auto outapp = new EQApplicationPacket(OP_SpawnAppearance, sizeof(SpawnAppearance_Struct));
|
||||
SpawnAppearance_Struct* spawn_appearance = (SpawnAppearance_Struct*)outapp->pBuffer;
|
||||
spawn_appearance->spawn_id = this->GetID();
|
||||
spawn_appearance->type = AT_AFK;
|
||||
spawn_appearance->parameter = afk_flag;
|
||||
entity_list.QueueClients(this, outapp);
|
||||
safe_delete(outapp);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user