MCPcopy Create free account
hub / github.com/OpenFodder/openfodder / Sprite_Handle_Helicopter_Callpad_InRange

Method Sprite_Handle_Helicopter_Callpad_InRange

Source/Fodder.cpp:7374–7403  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

7372}
7373
7374int16 cFodder::Sprite_Handle_Helicopter_Callpad_InRange(sSprite* pSprite, sSprite*& pData2C) {
7375 sSprite** Data28 = mSprite_TroopsAlive;
7376 int16 Data0 = 0;
7377
7378 do {
7379 if (*Data28 == INVALID_SPRITE_PTR || *Data28 == 0)
7380 return -1;
7381
7382 pData2C = *Data28++;
7383
7384 if (pData2C->field_6E)
7385 continue;
7386 if (pData2C->field_38)
7387 continue;
7388
7389 Data0 = pSprite->field_0 - 2;
7390 int16 Data4 = pSprite->field_4 - 8;
7391 int16 Data8 = pData2C->field_0;
7392 int16 DataC = pData2C->field_4;
7393 int16 Data10 = 0x20;
7394
7395 Map_Get_Distance_BetweenPoints(Data0, Data4, Data8, Data10, DataC);
7396
7397 if (Data0 < 9)
7398 break;
7399
7400 } while (1);
7401
7402 return 0;
7403}
7404
7405void cFodder::Sprite_Handle_Helicopter_Human_CallCheck(sSprite* pSprite) {
7406 if (pSprite->field_75)

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected