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

◆ CheckSurfaceBelowGardenPlot()

void ActionDigGardenPlot::CheckSurfaceBelowGardenPlot ( PlayerBase player,
GardenPlot item_GP,
Hologram hologram )
inlineprivate

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

63 {
64 vector min_max[2];
65 item_GP.GetCollisionBox(min_max);
66 float offset = min_max[1][1] - min_max[0][1];
67 //Print(offset);
68 vector pos_adjusted = item_GP.GetPosition();
69 pos_adjusted[1] = pos_adjusted[1] + offset;
70
71 if (item_GP.CanBePlaced(player, /*item_GP.GetPosition()*/pos_adjusted) )
72 {
73 if (item_GP.CanBePlaced(NULL, item_GP.CoordToParent(hologram.GetLeftCloseProjectionVector())))
74 {
75 if (item_GP.CanBePlaced(NULL, item_GP.CoordToParent(hologram.GetRightCloseProjectionVector())))
76 {
77 if (item_GP.CanBePlaced(NULL, item_GP.CoordToParent(hologram.GetLeftFarProjectionVector())))
78 {
79 if (item_GP.CanBePlaced(NULL, item_GP.CoordToParent(hologram.GetRightFarProjectionVector())))
80 {
81 hologram.SetIsCollidingGPlot(false);
82
83 return;
84 }
85 }
86 }
87 }
88 }
89
90 hologram.SetIsCollidingGPlot(true);
91 }
void SetIsCollidingGPlot(bool is_colliding_gplot)
Определения Hologram.c:1311
vector GetLeftFarProjectionVector()
Определения Hologram.c:1056
vector GetRightFarProjectionVector()
Определения Hologram.c:1065
vector GetLeftCloseProjectionVector()
Определения Hologram.c:1038
vector GetRightCloseProjectionVector()
Определения Hologram.c:1046

Перекрестные ссылки Hologram::GetLeftCloseProjectionVector(), Hologram::GetLeftFarProjectionVector(), Hologram::GetRightCloseProjectionVector(), Hologram::GetRightFarProjectionVector() и Hologram::SetIsCollidingGPlot().

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