// showCheckpointForPlayer(checkpointid, playerid) bool CCheckpointModuleNatives::ShowForPlayer(EntityId checkpointId, EntityId playerId) { CCheckpoint * pCheckpoint = g_pCheckpointManager->Get(checkpointId); if(pCheckpoint) { pCheckpoint->ShowForPlayer(playerId); return true; } return false; }
// showCheckpointForPlayer(checkpointid, playerid) SQInteger CCheckpointNatives::ShowForPlayer(SQVM * pVM) { EntityId checkpointId; EntityId playerId; sq_getentity(pVM, -2, &checkpointId); sq_getentity(pVM, -1, &playerId); CCheckpoint * pCheckpoint = g_pCheckpointManager->Get(checkpointId); if(pCheckpoint) { pCheckpoint->ShowForPlayer(playerId); sq_pushbool(pVM, true); return 1; } sq_pushbool(pVM, false); return 1; }