[Problem] Dialog
#4

pawn Код:
public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
{
    if(dialogid==HouseD)
    {
        if(response)
        {      
        SendClientMessage(playerid,COLOR_WHITE,"Something");
        if (!strlen(inputtext)) return ShowPlayerDialog(playerid, HouseD, DIALOG_STYLE_INPUT, "House Price",         "Price:", "Accept", "Cancel");
        new Float:PosX,Float:PosY,Float:PosZ,str[256],string[256];
        LastHouseID(playerid);
        GetPlayerPos(playerid,PosX,PosY,PosZ);
        format(str,sizeof(str),"%f,%f,%f",PosX,PosY,PosZ);
        if(!isNumeric(inputtext) || strval(inputtext)<0 || strval(inputtext)>9999999) return      ShowPlayerDialog(playerid, HouseD, DIALOG_STYLE_INPUT, "Houses Price", "Price between 0-99999999", "Accept",  "Cancel");
        format(string,sizeof(string),"INSERT INTO `rHouses` (`ID`,`Owner`,`Price`, `Lock`,`Level`,`IconPos`,`IntPos`,`Interior`,`Renter`,`RentPrice`) VALUES (%d,'ForSale',%d,'1',0,'%s','2308.79,-1212.88,1048.03',6,'None',-1)",hCount,inputtext,str);
        mysql_query(string);
        mysql_free_result();
        HousePickup[hCount] = CreatePickup(1273, 23, PosX, PosY, PosZ);
        new txt[128];
        format(txt,sizeof(txt),"You Created House Number %d",hCount);
        return SendClientMessage(playerid,COLOR_WHITE,txt);
}  
}
    return 1;
}
Try This
Reply


Messages In This Thread
[Problem] Dialog - by XePloiT - 22.11.2010, 17:06
Re: [Problem] Dialog - by Alex_Valde - 22.11.2010, 17:47
Re: [Problem] Dialog - by XePloiT - 22.11.2010, 18:00
Re: [Problem] Dialog - by ColdXX - 22.11.2010, 18:34
Re: [Problem] Dialog - by XePloiT - 22.11.2010, 20:00
Re: [Problem] Dialog - by XePloiT - 22.11.2010, 22:26

Forum Jump:


Users browsing this thread: 2 Guest(s)