Check weapon
#1

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?
Reply
#2

pawn Код:
if(GetPlayerWeapon(playerid) != 0 && !IsPlayerInRangeOfPoint(playerid, x, y, z)) // Put here DM zone x y and z
{
    SetPlayerArmedWeapon(playerid, 0);
}
Just an example
Reply
#3

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
Reply
#4

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
Reply
#5

Search
Reply
#6

Quote:
Originally Posted by iRemix
Посмотреть сообщение
Okay, if you're so good and tell me to search..
Say me the search keyword than.. -.-
Reply
#7

GetPlayerWeaponData
Reply
#8

I think i can make a code that remove player weapons when he is near the non-dm zone! With ResetPlayerWeapons
Reply
#9

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?
Reply
#10

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
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)