DayZ 1.28
DayZ Explorer by KGB
 
Загрузка...
Поиск...
Не найдено

◆ CheckForGag()

void ManBase::CheckForGag ( )
inlineprotected

См. определение в файле PlayerBase.c строка 6009

6010 {
6011 #ifdef SERVER
6012 Clothing item;
6013 Class.CastTo(item, GetInventory().FindAttachment(InventorySlots.MASK));
6014 if (!item)
6015 {
6016 Class.CastTo(item, GetInventory().FindAttachment(InventorySlots.HEADGEAR));
6017 }
6018
6019 if (item && item.IsObstructingVoice())
6020 {
6021 item.MutePlayer(this,true);
6022 }
6023 else //should probably check for relevant types before removing mumbling and obstruction specifically..
6024 {
6025 GetGame().SetVoiceEffect(this, VoiceEffectMumbling, false);
6026 GetGame().SetVoiceEffect(this, VoiceEffectObstruction, false);
6027 }
6028 #endif
6029 }
proto native void SetVoiceEffect(Object player, int effect, bool enable)
Enable/disable VoN effect (only on server)
proto native CGame GetGame()

Перекрестные ссылки Class::CastTo(), GetGame() и CGame::SetVoiceEffect().

Используется в OnSelectPlayer().