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

◆ IsIgnoredObject()

bool EntityAI::IsIgnoredObject ( Object o)
inlineprotected

If the player can't interact (hint: collide) with the object, then it is ignored

Ignore any player that is currently in this vehicle

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

551 {
552 if (!o)
553 return false;
554
556 int layer = dBodyGetInteractionLayer(o);
557 bool interacts = dGetInteractionLayer(this, PhxInteractionLayers.CHARACTER, layer);
558 if (!interacts)
559 {
560 return true;
561 }
562
563 DayZPlayer player;
564 if (Class.CastTo(player, o))
565 {
567 HumanCommandVehicle hcv = player.GetCommand_Vehicle();
568 if (hcv && hcv.GetTransport() == this)
569 {
570 return true;
571 }
572 }
573
574 EntityAI e = EntityAI.Cast(o);
575 // CanBeSkinned means it is a dead entity which should not block the door
576 return ( ( e && (e.IsZombie() || e.IsHologram()) ) || o.CanBeSkinned() || o.IsBush() || o.IsTree() );
577 }
class LogManager EntityAI
PhxInteractionLayers
Определения DayZPhysics.c:2
proto native Transport GetTransport()
proto native bool dGetInteractionLayer(notnull IEntity worldEntity, int mask1, int mask2)
proto native int dBodyGetInteractionLayer(notnull IEntity ent)

Перекрестные ссылки Class::CastTo(), dBodyGetInteractionLayer(), dGetInteractionLayer() и HumanCommandVehicle::GetTransport().

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