MCPcopy Create free account
hub / github.com/JACoders/OpenJK / FighterIsLaunching

Function FighterIsLaunching

code/game/FighterNPC.cpp:336–349  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

334}
335
336qboolean FighterIsLaunching( Vehicle_t *pVeh, playerState_t *parentPS )
337{
338
339 if ( FighterOverValidLandingSurface( pVeh )
340#ifdef QAGAME//only do this check on GAME side, because if it's CGAME, it's being predicted, and it's only predicted if the local client is the driver
341 && pVeh->m_pVehicleInfo->Inhabited( pVeh )//has to have a driver in order to be capable of landing
342#endif
343 && pVeh->m_ucmd.upmove > 0 //trying to take off
344 && parentPS->speed <= 200.0f )//going slow enough to start landing - was using pVeh->m_pVehicleInfo->speedIdle, but that's still too fast
345 {
346 return qtrue;
347 }
348 return qfalse;
349}
350
351qboolean FighterSuspended( Vehicle_t *pVeh, playerState_t *parentPS )
352{

Callers 1

ProcessMoveCommandsFunction · 0.70

Calls 1

Tested by

no test coverage detected