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

◆ IsEntityOnWaterSurface()

static bool IsEntityOnWaterSurface ( notnull EntityAI entity_ai)
staticprotected

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

2427 {
2428 vector fireplacePosition = entity_ai.GetPosition();
2429 string surfaceType;
2430 g_Game.SurfaceGetType3D(fireplacePosition[0], fireplacePosition[1] + g_Game.SurfaceGetSeaLevel(), fireplacePosition[2], surfaceType);
2431 if (!surfaceType)
2432 {
2433 float waterLevelDiff = fireplacePosition[1] - g_Game.SurfaceGetSeaLevel();
2434 return waterLevelDiff < 0.5;
2435 }
2436 else if (surfaceType.Contains("water"))
2437 {
2438 return true;
2439 }
2440
2441 return false;
2442 }
DayZGame g_Game
Определения DayZGame.c:3868
Определения EnConvert.c:106
bool Contains(string sample)
Returns true if sample is substring of string.
Определения EnString.c:286

Перекрестные ссылки string::Contains() и g_Game.