zp_user_infect_attempt
Called on a player infect/cure attempt. You can use this to block an infection/humanization by returning ZP_PLUGIN_HANDLED in your plugin. Note: Right now this is only available after the ZP round starts, since some situations (like blocking a first zombie's infection) are not yet handled.
Syntax
forward zp_user_infect_attempt(id, infector, classid) forward zp_user_humanize_attempt(id, classid) /** * Called when an admin selects a custom game mode from the ZP admin menu. * * Note: You should trigger the custom game mode here with out any checks * * @param gameid Internal custom game mode ID * @param id Player index who selected the game mode */ forward zp_game_mode_selected(gameid, id) /** * Called when a player spawns. This is also called for CZ bots * which are spawning * * Note: You should use this, instead of other spawn forwards, * when you want to change some one's class after spawning. * * Note: If you have used this forward then you must return * ZP_PLUGIN_HANDLED to inform the main plugin that you have used * this forward * * @param id Player index who has spawned * @param resp_zombie This is passed by the main plugin as 1 if * the player needs to be spawned as a zombie * otherwise it is passed as zero */ forward zp_player_spawn_post(id, resp_zombie)
Usage
| id | — |
| infector | — |
| classid | — |
Defined in
zombie_plague_special.inc
at line 830
.
This documentation was automatically generated from source.