A little question - 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: A little question (
/showthread.php?tid=253590)
A little question -
fubar - 07.05.2011
This is just a quick question,i just need someone to double check this and tell me if they can see anything wrong with it.
The problem i had was if a player in a car went into the checkpoint the diaolog would show for him/her,but it would also show for the passenger too,so i think this should work,but im not sure,well here it is
Код:
public OnPlayerEnterInvisibleCP(playerid,icpid){
new State=GetPlayerState(playerid);
if(CP1 == 1) {
if(IsPlayerInICp(playerid, CP1) && State!=PLAYER_STATE_DRIVER) {
ShowPlayerDialog(playerid, 100, DIALOG_STYLE_LIST, "Pick Neon Color", "Blue\nRed\nGreen\nWhite\nPink\nYellow\nPolice Strobe\nInterior Lights\nBack Neon\nFront neon\nUndercover Roof Light\nRemove All Neon", "Select", "Cancel");
PlayerPlaySound(playerid, 1133, 0.0, 0.0, 10.0);}}
return 1;}
As i said it worked perfectly before,but would show for the passenger in the car too,so the bit in red is the bit i changed.
Re: A little question -
[DM]Kane - 07.05.2011
pawn Код:
public OnPlayerEnterInvisibleCP(playerid,icpid){
new State=GetPlayerState(playerid);
if(CP1 == 1) {
if(IsPlayerInICp(playerid, CP1) && State==PLAYER_STATE_DRIVER) {
ShowPlayerDialog(playerid, 100, DIALOG_STYLE_LIST, "Pick Neon Color", "Blue\nRed\nGreen\nWhite\nPink\nYellow\nPolice Strobe\nInterior Lights\nBack Neon\nFront neon\nUndercover Roof Light\nRemove All Neon", "Select", "Cancel");
PlayerPlaySound(playerid, 1133, 0.0, 0.0, 10.0);}}
return 1;
}
Re: A little question -
fubar - 07.05.2011
cheers kane i will try a bit later and see what happens
Re: A little question -
[DM]Kane - 07.05.2011
okay
Re: A little question -
fubar - 07.05.2011
yer i just tried it and i think it works a treat,thank for the help kane
Re: A little question -
[DM]Kane - 07.05.2011
No problem