Dialog on checkpoint doesn't show up +rep - 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)
+--- Thread: Dialog on checkpoint doesn't show up +rep (
/showthread.php?tid=325046)
Dialog on checkpoint doesn't show up +rep -
vernz - 11.03.2012
Hello,
I am trying to do a bank system using checkpoint, the checkpoint apear but once im getting into it the dialog doesn't want to show up... what's wrong ?
Here my code:
pawn Код:
public OnPlayerSpawn(playerid)
{
Bank = CreateDynamicCP(-227.6468, 2605.7734 , 62.7031, -1, -1, -1, -1, 100);
if(PosX[playerid] !=0 && PosY[playerid] !=0 && PosZ[playerid] !=0 && Angle[playerid] != 0)
{
SetPlayerPos(playerid,PosX[playerid],PosY[playerid],PosZ[playerid]);
SetPlayerFacingAngle(playerid,Angle[playerid]);
SetPlayerInterior(playerid,Interior[playerid]);
SetPlayerVirtualWorld(playerid,VirtualWorld[playerid]);
}
SetPlayerSkin(playerid, PlayerInfo[playerid][pSkin]);
return 1;
}
pawn Код:
public OnPlayerEnterDynamicCP(playerid, checkpointid)
{
if(checkpointid == Bank)
{
if(IsPlayerInRangeOfPoint(playerid,10.0,-227.6468, 2605.7734 , 62.7031))
{
ShowPlayerDialog(playerid,DIALOG_BANK,DIALOG_STYLE_LIST,""COL_BLUE"Downtown Roleplay bank system","Deposit\nWithdraw","Choose","Cancel");
}
}
}
Thanks in advance.
Re: Dialog on checkpoint doesn't show up +rep -
Ballu Miaa - 11.03.2012
Why dont you use it with a SetPlayerCheckpoint and then use it under OnPlayerEnterCheckpoint. Try to show the dialog then! Hope it helps.
- BMiaa
Re : Dialog on checkpoint doesn't show up +rep -
vernz - 11.03.2012
For some reason DynamicCP is working now... thanks for trying to help me
. Thread close !