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)
+---- Forum: Help Archive (
https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: Dialog problem (
/showthread.php?tid=153843)
Dialog problem -
Buwla - 11.06.2010
Hello.
I already have some dialogs works well, however my last one gives shitloads of errors..
Had this problem some time ago dont remember what i did to solve it.
Anyway, heres the code.
pawn Код:
if(dialogid == 10 && response) // Weapon setups
{
switch(listitem)
{
case 0: //Kit1
{
GivePlayerWeapon(playerid, 24, 35578);
GivePlayerWeapon(playerid, 29, 35578);
SendClientMessage(playerid, COLOR_WHITE, "You have selected Kit1! Have fun.");
}
case 1: //Kit2
{
GivePlayerWeapon(playerid, 24, 35578);
GivePlayerWeapon(playerid, 31, 35578);
SendClientMessage(playerid, COLOR_WHITE, "You have selected Kit2! Have fun.");
}
case 2: //Kit3
{
GivePlayerWeapon(playerid, 24, 35578);
GivePlayerWeapon(playerid, 34, 35578);
SendClientMessage(playerid, COLOR_WHITE, "You have selected Kit3! Have fun.");
{
case 3: //Kit4
{
GivePlayerWeapon(playerid, 25, 35578);
GivePlayerWeapon(playerid, 29, 35578);
SendClientMessage(playerid, COLOR_WHITE, "You have selected Kit4! Have fun.");
{
case 4: //Kit5
{
GivePlayerWeapon(playerid, 25, 35578);
GivePlayerWeapon(playerid, 31, 35578);
SendClientMessage(playerid, COLOR_WHITE, "You have selected Kit5! Have fun.");
{
case 5: //Kit6
{
GivePlayerWeapon(playerid, 27, 35578);
GivePlayerWeapon(playerid, 30, 35578);
SendClientMessage(playerid, COLOR_WHITE, "You have selected Kit6! Have fun.");
{
case 6: //Kit7
{
GivePlayerWeapon(playerid, 29, 35578);
GivePlayerWeapon(playerid, 31, 35578);
SendClientMessage(playerid, COLOR_WHITE, "You have selected Kit7! Have fun.");
}
}
}
I will post the warning if its needed .
Re: Dialog problem -
ViruZZzZ_ChiLLL - 11.06.2010
Should be fixed now
pawn Код:
if(dialogid == 10 && response) // Weapon setups
{
switch(listitem)
{
case 0: //Kit1
{
GivePlayerWeapon(playerid, 24, 35578);
GivePlayerWeapon(playerid, 29, 35578);
SendClientMessage(playerid, COLOR_WHITE, "You have selected Kit1! Have fun.");
}
case 1: //Kit2
{
GivePlayerWeapon(playerid, 24, 35578);
GivePlayerWeapon(playerid, 31, 35578);
SendClientMessage(playerid, COLOR_WHITE, "You have selected Kit2! Have fun.");
}
case 2: //Kit3
{
GivePlayerWeapon(playerid, 24, 35578);
GivePlayerWeapon(playerid, 34, 35578);
SendClientMessage(playerid, COLOR_WHITE, "You have selected Kit3! Have fun.");
}
case 3: //Kit4
{
GivePlayerWeapon(playerid, 25, 35578);
GivePlayerWeapon(playerid, 29, 35578);
SendClientMessage(playerid, COLOR_WHITE, "You have selected Kit4! Have fun.");
}
case 4: //Kit5
{
GivePlayerWeapon(playerid, 25, 35578);
GivePlayerWeapon(playerid, 31, 35578);
SendClientMessage(playerid, COLOR_WHITE, "You have selected Kit5! Have fun.");
}
case 5: //Kit6
{
GivePlayerWeapon(playerid, 27, 35578);
GivePlayerWeapon(playerid, 30, 35578);
SendClientMessage(playerid, COLOR_WHITE, "You have selected Kit6! Have fun.");
}
case 6: //Kit7
{
GivePlayerWeapon(playerid, 29, 35578);
GivePlayerWeapon(playerid, 31, 35578);
SendClientMessage(playerid, COLOR_WHITE, "You have selected Kit7! Have fun.");
}
}
}
Re: Dialog problem -
Buwla - 11.06.2010
Haha, wow I blame that im tired!
looked at it for a good 15-20min without any clue what it was..
Saw that I used '{' insted of '}'
![Cheesy](images/smilies/biggrin.png)
made me laugh.
Ty for the help.