if(dialogid == DIALOG_TRADE)
{
if(response)
{
new string[128], Float
, Float:y, Float:z;
new tradeid = strval(inputtext);
if(!IsPlayerConnected(tradeid)) return ShowPlayerDialog(playerid, DIALOG_TRADE, DIALOG_STYLE_INPUT, "{FF8000}Invalid ID", "{FFFFFF}Who would you like to trade with?\n(ID)", "Next", "Cancel");
if(ptrade[tradeid] != 999) return SendClientMessage(playerid, COLOR_ORANGE, "** {AFAFAF}This player is already trading with someone else.");
if(pdeath[playerid] == 1 || ptazed[playerid] == 1 || pcuffed[playerid] == 1) return SendClientMessage(playerid, COLOR_ORANGE, "** {AFAFAF}This player can't trade anyone in his current condition.");
if(tradeid == playerid) return SendClientMessage(playerid, COLOR_ORANGE, "** {AFAFAF}You can't trade yourself.");
GetPlayerPos(tradeid, x, y, z);
if(!IsPlayerInRangeOfPoint(playerid, 5.0, x, y, z)) return SendClientMessage(playerid, COLOR_ORANGE, "** {AFAFAF}You aren't near this player.");
format(string, sizeof(string), "{FFFFFF}%s would like to trade with you.", GPN(playerid));
ShowPlayerDialog(tradeid, DIALOG_TRADEREQUEST, DIALOG_STYLE_MSGBOX, "{FF8000}Trade", string, "Trade", "Cancel");
ptrade[playerid] = tradeid;
ptrade[tradeid] = playerid;
ptradep1[tradeid] = 1;
ptradep2[tradeid] = 0;
ptradep2[playerid] = 1;
ptradep1[playerid] = 0;
}
}
This is what i have under that dialog