30.07.2018, 14:28
error 029: invalid expression, assumed zero
30.07.2018, 15:23
You miss if, need else if no just else, if you put else you don't need next code
30.07.2018, 15:38
Quote:
PHP код:
if(playertextid == GUI_HuongDan[playerid][1]) // nhan cong viec
{
PlayerTextDrawShow(playerid, GUI_HuongDan[playerid][10]);
}
else if(playertextid == GUI_HuongDan[playerid][2]) // mua dien thoai
{
PlayerTextDrawShow(playerid, GUI_HuongDan[playerid][6]); // muadienthoai p1
GUI_MuaDienThoai[playerid] = 1;
}
else if(playertextid == GUI_HuongDan[playerid][17] && GUI_MuaDienThoai[playerid] == 1) // tiep theo
{
PlayerTextDrawShow(playerid, GUI_HuongDan[playerid][7]); // muadienthoai p2
PlayerTextDrawDestroy(playerid, GUI_HuongDan[playerid][6]);
PlayerTextDrawShow(playerid, GUI_HuongDan[playerid][16]);
GUI_MuaDienThoai[playerid] = 2;
}
else if(playertextid == GUI_HuongDan[playerid][16] && GUI_MuaDienThoai[playerid] == 2) // quay lai
{
PlayerTextDrawShow(playerid, GUI_HuongDan[playerid][6]); // muadienthoai p1
PlayerTextDrawDestroy(playerid, GUI_HuongDan[playerid][7]);
PlayerTextDrawShow(playerid, GUI_HuongDan[playerid][17]);
}
else if(playertextid == GUI_HuongDan[playerid][3]) // mua phuong tien
{
PlayerTextDrawShow(playerid, GUI_HuongDan[playerid][9]); // muaphuongtien p1
}
else if(playertextid == GUI_HuongDan[playerid][5])
{
PlayerTextDrawShow(playerid, GUI_HuongDan[playerid][11]);
}
else if(playertextid == GUI_HuongDan[playerid][13])
{
for(new i = 0; i < 22; i++) {
PlayerTextDrawDestroy(playerid, GUI_HuongDan[playerid][i]);
}
if(playertextid == GUI_HuongDan[playerid][1]) // nhan cong viec
{
PlayerTextDrawShow(playerid, GUI_HuongDan[playerid][10]);
}
if(playertextid == GUI_HuongDan[playerid][2]) // mua dien thoai
{
PlayerTextDrawShow(playerid, GUI_HuongDan[playerid][6]); // muadienthoai p1
GUI_MuaDienThoai[playerid] = 1;
}
if(playertextid == GUI_HuongDan[playerid][17] && GUI_MuaDienThoai[playerid] == 1) // tiep theo
{
PlayerTextDrawShow(playerid, GUI_HuongDan[playerid][7]); // muadienthoai p2
PlayerTextDrawDestroy(playerid, GUI_HuongDan[playerid][6]);
PlayerTextDrawShow(playerid, GUI_HuongDan[playerid][16]);
GUI_MuaDienThoai[playerid] = 2;
}
if(playertextid == GUI_HuongDan[playerid][16] && GUI_MuaDienThoai[playerid] == 2) // quay lai
{
PlayerTextDrawShow(playerid, GUI_HuongDan[playerid][6]); // muadienthoai p1
PlayerTextDrawDestroy(playerid, GUI_HuongDan[playerid][7]);
PlayerTextDrawShow(playerid, GUI_HuongDan[playerid][17]);
}
if(playertextid == GUI_HuongDan[playerid][3]) // mua phuong tien
{
PlayerTextDrawShow(playerid, GUI_HuongDan[playerid][9]); // muaphuongtien p1
}
if(playertextid == GUI_HuongDan[playerid][5])
{
PlayerTextDrawShow(playerid, GUI_HuongDan[playerid][11]);
}
if(playertextid == GUI_HuongDan[playerid][13])
{
for(new i = 0; i < 22; i++) {
PlayerTextDrawDestroy(playerid, GUI_HuongDan[playerid][i]);
}
[/PHP]
If i helped you, pls give me +1 rep.
30.07.2018, 15:44
Quote:
PHP код:
if(playertextid == GUI_HuongDan[playerid][1]) // nhan cong viec { PlayerTextDrawShow(playerid, GUI_HuongDan[playerid][10]); } if(playertextid == GUI_HuongDan[playerid][2]) // mua dien thoai { PlayerTextDrawShow(playerid, GUI_HuongDan[playerid][6]); // muadienthoai p1 GUI_MuaDienThoai[playerid] = 1; } if(playertextid == GUI_HuongDan[playerid][17] && GUI_MuaDienThoai[playerid] == 1) // tiep theo { PlayerTextDrawShow(playerid, GUI_HuongDan[playerid][7]); // muadienthoai p2 PlayerTextDrawDestroy(playerid, GUI_HuongDan[playerid][6]); PlayerTextDrawShow(playerid, GUI_HuongDan[playerid][16]); GUI_MuaDienThoai[playerid] = 2; } if(playertextid == GUI_HuongDan[playerid][16] && GUI_MuaDienThoai[playerid] == 2) // quay lai { PlayerTextDrawShow(playerid, GUI_HuongDan[playerid][6]); // muadienthoai p1 PlayerTextDrawDestroy(playerid, GUI_HuongDan[playerid][7]); PlayerTextDrawShow(playerid, GUI_HuongDan[playerid][17]); } if(playertextid == GUI_HuongDan[playerid][3]) // mua phuong tien { PlayerTextDrawShow(playerid, GUI_HuongDan[playerid][9]); // muaphuongtien p1 } if(playertextid == GUI_HuongDan[playerid][5]) { PlayerTextDrawShow(playerid, GUI_HuongDan[playerid][11]); } if(playertextid == GUI_HuongDan[playerid][13]) { for(new i = 0; i < 22; i++) { PlayerTextDrawDestroy(playerid, GUI_HuongDan[playerid][i]); } [/PHP] If i helped you, pls give me +1 rep. |
Do you have Discord or Faceb00k?
« Next Oldest | Next Newest »
Users browsing this thread: 2 Guest(s)