| 549 | } |
| 550 | |
| 551 | void KOTHPlayerPaused::process(bz_EventData* eventData) { |
| 552 | if (eventData->eventType != bz_ePlayerPausedEvent || !koth.enabled) { |
| 553 | return; |
| 554 | } |
| 555 | |
| 556 | bz_PlayerPausedEventData_V1* PauseData = (bz_PlayerPausedEventData_V1*) eventData; |
| 557 | bz_BasePlayerRecord* player = bz_getPlayerByIndex(PauseData->playerID); |
| 558 | |
| 559 | if (player) { |
| 560 | if (kothzone.pointIn(player->currentState.pos)) { |
| 561 | bz_killPlayer(PauseData->playerID, true, BZ_SERVER); |
| 562 | bz_sendTextMessage(BZ_SERVER, PauseData->playerID, "Cannot pause while on the Hill."); |
| 563 | } |
| 564 | } |
| 565 | bz_freePlayerRecord(player); |
| 566 | |
| 567 | return; |
| 568 | } |
| 569 | |
| 570 | void KOTHPlayerJoined::process(bz_EventData* eventData) { |
| 571 | if (eventData->eventType != bz_ePlayerJoinEvent || !koth.enabled) { |
nothing calls this directly
no test coverage detected