Dialog problem - 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 problem (
/showthread.php?tid=341308)
Dialog problem -
k3nw00d_kri5ty - 10.05.2012
Hi all.
How i can check if a player enters a another players name or id in a inputt dialog?
I have this, but doesn't working:
Код:
if(dialogid == DIALOG_GIVEHIT)
{
giveplayerid = ReturnUser(tmp);
if(strlen(inputtext) == giveplayerid && IsPlayerConnected(giveplayerid))
{
if(PlayerInfo[playerid][pRank] < 4) return SendClientMessage(playerid, COLOR_ERROR, "Info: You need Rank 4 to Give Contracts to Hitmans.");
if(hitfound == 0) return SendClientMessage(playerid, COLOR_ERROR, "Info: There is no Hit Founded yet, use Contracts in the Portable first !");
if(IsPlayerConnected(giveplayerid))
{
if(giveplayerid != INVALID_PLAYER_ID)
{
if(PlayerInfo[giveplayerid][pMember] != 8) return SendClientMessage(playerid, COLOR_ERROR, "Info: That player is not a Hitman.");
if(GoChase[giveplayerid] < 999) return SendClientMessage(playerid, COLOR_ERROR, "Info: That Hitman is already busy with a Contract.");
if(IsPlayerConnected(hitid))
{
GetPlayerName(playerid, sendername, sizeof(sendername)); GetPlayerName(giveplayerid, giver, sizeof(giver)); GetPlayerName(hitid, giveplayer, sizeof(giveplayer));
format(string, sizeof(string), "* Hitman %s, assigned Hitman %s to kill: %s(ID:%d), for %s.", sendername, giver, giveplayer, hitid, FormatMoney(PlayerInfo[hitid][pHeadValue]));
SendFamilyMessage(8, COLOR_YELLOW, string);
GoChase[giveplayerid] = hitid; GetChased[hitid] = giveplayerid; GotHit[hitid] = 1; hitid = 0; hitfound = 0;
return 0;
}
else return SendClientMessage(playerid, COLOR_ERROR, "Info: That player is not connected.");
}
return 1;
}
else return SendClientMessage(playerid, COLOR_ERROR, "Info: That Hitman is not Online, or ain't a Hitman !");
}
}
Re: Dialog problem -
imnoob - 10.05.2012
dude do u know ho to make dialog when leader invites LIKE THIS:
J (ex:Name_Surname--of the leader) inviting you to join in my organization and be my member
IF u accept click on "Accept"
IF u dont accept click on "Refuse"
exp picture:
http://zaslike.com/viewer.php?file=2...3398qlfygf.png <---translated on english with red
Re: Dialog problem -
k3nw00d_kri5ty - 10.05.2012
I don't know what you want to explain to me.
Re: Dialog problem -
k3nw00d_kri5ty - 10.05.2012
As command ? I don't want.
I want when i typyng /portable commad to show another dialog, i select a line (givehit) and to
show this input dialog to enter the hitman name.
Re: Dialog problem -
k3nw00d_kri5ty - 11.05.2012
Ok, but how ?