Check weapon - Printable Version
+- SA-MP Forums Archive (
https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (
https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (
https://sampforum.blast.hk/forumdisplay.php?fid=12)
+---- Forum: Help Archive (
https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: Check weapon (
/showthread.php?tid=218065)
Check weapon -
Ihsan-Cingisiz - 29.01.2011
Hello,
I want to make a zone where players can't be in if they have weapons,
how can i do that the script detects if the player is holding any weapon?
For ex. If player is in range of point no-dm zone.. and if the player
carries a weapon sendclient..... You may not enter the no-dm zone because
you have weapons.. Okay, how can i do this?
Re: Check weapon -
Mean - 29.01.2011
pawn Код:
if(GetPlayerWeapon(playerid) != 0 && !IsPlayerInRangeOfPoint(playerid, x, y, z)) // Put here DM zone x y and z
{
SetPlayerArmedWeapon(playerid, 0);
}
Just an example
Re: Check weapon -
Ihsan-Cingisiz - 29.01.2011
Quote:
Originally Posted by Mean
pawn Код:
if(GetPlayerWeapon(playerid) != 0 && !IsPlayerInRangeOfPoint(playerid, x, y, z)) // Put here DM zone x y and z { SetPlayerArmedWeapon(playerid, 0); }
Just an example
|
Isn't this just for the carried weapon? I mean, even if the player has weapons
scrolled (He has weapon but is on fist mode) it needs to detect, so i'll wait for
the next reaction. Thanks for your reaction/help anyways
Re: Check weapon -
Ihsan-Cingisiz - 30.01.2011
Quote:
Originally Posted by Ihsan-Cingisiz
Isn't this just for the carried weapon? I mean, even if the player has weapons
scrolled (He has weapon but is on fist mode) it needs to detect, so i'll wait for
the next reaction. Thanks for your reaction/help anyways 
|
Bump
Re: Check weapon -
iRemix - 30.01.2011
Search
Re: Check weapon -
Ihsan-Cingisiz - 30.01.2011
Quote:
Originally Posted by iRemix
|
Okay, if you're so good and tell me to search..
Say me the search keyword than.. -.-
Re: Check weapon -
Vince - 30.01.2011
GetPlayerWeaponData
Re: Check weapon -
ricardo178 - 30.01.2011
I think i can make a code that remove player weapons when he is near the non-dm zone! With ResetPlayerWeapons
Re: Check weapon -
Ihsan-Cingisiz - 30.01.2011
Quote:
Originally Posted by ricardo178
I think i can make a code that remove player weapons when he is near the non-dm zone! With ResetPlayerWeapons
|
Okay, but that's not the one where i'm searching for.
I just want to detect if the player has a weapon, it needs to
detect even if the player has scrolled his weapon to fist more.
I tries the search engine, i can't find anythin'. Could someone please
help me further?
Re: Check weapon -
Ihsan-Cingisiz - 30.01.2011
Quote:
Originally Posted by Ihsan-Cingisiz
Okay, but that's not the one where i'm searching for.
I just want to detect if the player has a weapon, it needs to
detect even if the player has scrolled his weapon to fist more.
I tries the search engine, i can't find anythin'. Could someone please
help me further?
|
Another bump