Posts: 194
Threads: 27
Joined: May 2013
Reputation:
0
How to make when some player come in-front of the table he clicks F and the item of weapon shows him which weapon he wants to get? Thanks!
Posts: 194
Threads: 27
Joined: May 2013
Reputation:
0
Thanks it works, but how do I make, instead of pressing N, to click enter to shows the weapons?
Posts: 96
Threads: 11
Joined: Feb 2013
Reputation:
0
that line, change it:
if(newkeys == KEY_SECONDARY_ATTACK ) // this is key Enter
Posts: 194
Threads: 27
Joined: May 2013
Reputation:
0
Cool, thanks. but when I click the weapon it doesn't give me, can you help me please?
Posts: 194
Threads: 27
Joined: May 2013
Reputation:
0
and sorry for spamming if I do, this is a script what i've got;
{
if(newkeys == KEY_SECONDARY_ATTACK) // this is key Entetr
{
if(IsPlayerInRangeOfPoint(playerid,2.0,1261.1431,-1669.2919,25.2772)) // this 3 pos is the X Y Z you just copy
{
ShowPlayerDialog(playerid,5000,DIALOG_STYLE_LIST," Choose your weapons","Katana\nDeagle\nMP5\nM4\nGrenade\nParach ute\nSawnoff","Select","Cancel");
}
}
return 1;
}
this is on dialog response, up was a keystatechange
{
if(dialogid == 5000)
{
if(response)
{
switch(listitem)
{
case 0:
{
GivePlayerWeapon(playerid,8,10000);
}
case 1:
{
GivePlayerWeapon(playerid,24,10000);
}
case 2:
{
GivePlayerWeapon(playerid,29,10000);
}
case 3:
{
GivePlayerWeapon(playerid,31,10000);
}
case 4:
{
GivePlayerWeapon(playerid,16,10000);
}
case 5:
{
GivePlayerWeapon(playerid,46,10000);
}
case 6:
GivePlayerWeapon(playerid,26,10000);
}
}
}
return 1;
}
Posts: 1,351
Threads: 35
Joined: Sep 2011
Reputation:
0
Are you sure you've not got some type of anti-cheats that require you to use a different GivePlayerWeapon tactic?
Posts: 194
Threads: 27
Joined: May 2013
Reputation:
0
I think no, because guy above xyang helped me about it and he said this;
if(newkeys == KEY_NO) // this is key N
so I click N to choose the weapons, and guess what it worked, so when i've return from school, I've pmed him how to make that i press enter for weapons, he said this;
if(newkeys == KEY_SECONDARY_ATTACK) // this is key Enter
so when i came ingame, i clicked enter and the dialog of weapons work, when I choose any gun it doesn't give me, so I've had in mind, let's get back to "N" button, but still if I press N choose the weapon it doesn't give me, it's like, first time it works second time it's not. help me please :SS
Posts: 1,351
Threads: 35
Joined: Sep 2011
Reputation:
0
Can you show all of OnDialogResponse in [ pawn ] and [ / pawn ] tags? Without the spaces.