AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Scripting Help (https://forums.alliedmods.net/forumdisplay.php?f=11)
-   -   How do i check if a player is rescuing an hostage? (https://forums.alliedmods.net/showthread.php?t=95028)

zacky 06-18-2009 16:21

How do i check if a player is rescuing an hostage?
 
Read title.

Thanks
-zacky

alan_el_more 06-18-2009 18:20

Re: How do i check if a player is rescuing an hostage?
 
http://www.amxmodx.org/funcwiki.php?go=func&id=182

zacky 06-19-2009 04:34

Re: How do i check if a player is rescuing an hostage?
 
No it's not that.

Exolent[jNr] 06-19-2009 04:38

Re: How do i check if a player is rescuing an hostage?
 
http://forums.alliedmods.net/showthr...hlight=hostage

hleV 06-19-2009 04:56

Re: How do i check if a player is rescuing an hostage?
 
I'd use something like this:
Code:
#include <amxmodx> #include <hamsandwich>   new g_bIsRescuing[33];   public plugin_init() {         RegisterHam(Ham_Use, "hostage_entity", "fwdHostageUse", 1);         RegisterHam(Ham_Use, "monster_scientist", "fwdHostageUse", 1); }   public client_disconnect(iCl)         g_bIsRescuing[iCl] = false;   public fwdHostageUse(iEnt, iCl)         if (is_user_alive(iCl))                 g_bIsRescuing[iCl] = !g_bIsRescuing[iCl];
Also some checks like if players has died or spawned should be made.

zacky 06-19-2009 12:52

Re: How do i check if a player is rescuing an hostage?
 
Thank you Exolent, that was what i needed.


All times are GMT -4. The time now is 15:34.

Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.