Also das was jetzt folgt hat insgesamt glaub 2Stunden gedauert
naja es geht musste eben auswählen welche kategorie hoffe es hilft
Erst mal die News und Defines:
new stringa[200]; //für waffen liste
new stringb[200]; //für waffen liste
new stringc[400];//
new stringd[128];//
#define Schlagdia 999
#define Pistolendia 998
#define Gewehredia 997
#define mpistolendia 996
#define sonstigdia 995
#define bombendia 994
#define highdia 993
Dann der CMD:
if (strcmp("/waffen", cmdtext, true, 10) == 0)
if(IsInAdmin[playerid] == 1)
{
format(stringa, sizeof(stringa), "Schlagring \nGolfschläger \nSchlagstock \nMesser \nBaseballschläger \nSchaufel \nPoolstick \nKatana \nMotorsäge \nDildo1 \nDildo2 \nVibrator1 \nVibrator2 \nBlumen \nStock \nGranate \nTränengas \nMolotovkoktail \nColt-45 \nSchallgedämpfte Pistole");
format(stringb, sizeof(stringb), "Desert Eagle \nSchrotflinte \nAbgesägte Schrotflinte \nAutomatische Schrotflinte \nUZI \nMP5 \nAK-47 \nM4 \nTEC9 \nGewehr \nScharfschützengewehr \nRaketenwerfer \nWärmesuchender Raketenwerfer \nFlammenwerfer \nMinigun \nSutchel Sprengstoff \nKofferbombe \nSpraydose \nFeuerlöscher \nKamera \nFallschirm ");
format(stringc, sizeof(stringc), stringa,stringb);//string zusammenfassung
format(stringd, sizeof(stringd), "Schlagwaffen \nPistolen \n Normale und Maschinengewehre \nMaschinenpistolen \nSonstiges\n Granaten und Bomben\nHighend Waffen");
ShowPlayerDialog(playerid,1000,DIALOG_STYLE_LIST,"Verfügbahre Waffen......©East_Crips",stringd,"OK","");
return 1;
}
und jetzt am schluss (das hat am längsten gedauert(wegen dem ganzen sortieren und so))
die Responsen:
if(dialogid == 1000)
{
new stringe[200];
new stringf[200];
new stringg[200];
new stringh[200];
new stringi[200];
if(response)
switch(listitem)
{
case 0:
{
format(stringe, sizeof(stringe), "Schlagring \nGolfschläger \nSchlagstock \nBaseballschläger \nSchaufel \nPoolstick \nKatana \nDildo1 \nDildo2 \nVibrator1 \nVibrator2 \nBlumen \nStock ");
ShowPlayerDialog(playerid,999,DIALOG_STYLE_LIST,"Verfügbahre Waffen......©East_Crips",stringe,"OK","");
}
case 1:
{
format(stringe, sizeof(stringe), "Colt-45 \nSchallgedämpfte Pistole\nDesert Eagle ");
ShowPlayerDialog(playerid,998,DIALOG_STYLE_LIST,"Verfügbahre Waffen......©East_Crips",stringe,"OK","");
}
case 2:
{
format(stringe, sizeof(stringe), "Schrotflinte \nAbgesägte Schrotflinte \nAutomatische Schrotflinte \nGewehr \nScharfschützengewehr\nMP5 \nAK-47 \nM4 ");
ShowPlayerDialog(playerid,997,DIALOG_STYLE_LIST,"Verfügbahre Waffen......©East_Crips",stringe,"OK","");
}
case 3:
{
format(stringe, sizeof(stringe), "UZI \n TEC9");
ShowPlayerDialog(playerid,996,DIALOG_STYLE_LIST,"Verfügbahre Waffen......©East_Crips",stringe,"OK","");
}
case 4:
{
format(stringf, sizeof(stringf), " Motorsäge \n Molotovkoktail");
format(stringg, sizeof(stringg), " \nSpraydose \nFeuerlöscher \nKamera \nFallschirm ");
format(stringe, sizeof(stringe), " %s %s",stringf,stringg);
ShowPlayerDialog(playerid,995,DIALOG_STYLE_LIST,"Verfügbahre Waffen......©East_Crips",stringe,"OK","");
}
case 5:
{
format(stringi, sizeof(stringi), "Granate \nTränengas");
format(stringh, sizeof(stringh), " \nSutchel Sprengstoff \nKofferbombe");
format(stringe, sizeof(stringe), " %s %s",stringi,stringh);
ShowPlayerDialog(playerid,994,DIALOG_STYLE_LIST,"Verfügbahre Waffen......©East_Crips",stringe,"OK","");
}
case 6:
{
format(stringe, sizeof(stringe), "Raketenwerfer\nWärmesuchender Raketenwerfer \nFlammenwerfer \nMinigun ");
ShowPlayerDialog(playerid,993,DIALOG_STYLE_LIST,"Verfügbahre Waffen......©East_Crips",stringe,"OK","");
}
}
}
if(dialogid == 999)
{
if(response)
switch(listitem)
{
case 0:
{
GivePlayerWeapon(playerid,1,50);
}
case 1:
{
GivePlayerWeapon(playerid,2,50);
}
case 2:
{
GivePlayerWeapon(playerid,3,50);
}
case 3:
{
GivePlayerWeapon(playerid,5,50);
}
case 4:
{
GivePlayerWeapon(playerid,6,50);
}
case 5:
{
GivePlayerWeapon(playerid,7,50);
}
case 6:
{
GivePlayerWeapon(playerid,8,50);
}
case 7:
{
GivePlayerWeapon(playerid,10,50);
}
case 8:
{
GivePlayerWeapon(playerid,11,50);
}
case 9:
{
GivePlayerWeapon(playerid,12,50);
}
case 10:
{
GivePlayerWeapon(playerid,13,50);
}
case 11:
{
GivePlayerWeapon(playerid,14,50);
}
case 12:
{
GivePlayerWeapon(playerid,15,50);
}
}
}
if(dialogid == 998)
{
if(response)
switch(listitem)
{
case 0:
{
GivePlayerWeapon(playerid,22,50);
}
case 1:
{
GivePlayerWeapon(playerid,23,50);
}
case 2:
{
GivePlayerWeapon(playerid,24,50);
}
}
}
if(dialogid == 997)
{
if(response)
switch(listitem)
{
case 0:
{
GivePlayerWeapon(playerid,25,50);
}
case 1:
{
GivePlayerWeapon(playerid,26,50);
}
case 2:
{
GivePlayerWeapon(playerid,27,50);
}
case 3:
{
GivePlayerWeapon(playerid,33,50);
}
case 4:
{
GivePlayerWeapon(playerid,37,50);
}
case 5:
{
GivePlayerWeapon(playerid,29,50);
}
case 6:
{
GivePlayerWeapon(playerid,30,50);
}
case 7:
{
GivePlayerWeapon(playerid,31,50);
}
}
}
if(dialogid == 996)
{
if(response)
switch(listitem)
{
case 0:
{
GivePlayerWeapon(playerid,28,50);
}
case 1:
{
GivePlayerWeapon(playerid,32,50);
}
}
}
if(dialogid == 995)
{
if(response)
switch(listitem)
{
case 0:
{
GivePlayerWeapon(playerid,8,50);
}
case 1:
{
GivePlayerWeapon(playerid,18,50);
}
case 2:
{
GivePlayerWeapon(playerid,41,50);
}
case 3:
{
GivePlayerWeapon(playerid,42,50);
}
case 4:
{
GivePlayerWeapon(playerid,43,50);
}
case 5:
{
GivePlayerWeapon(playerid,46,50);
}
}
}
if(dialogid == 994)
{
if(response)
switch(listitem)
{
case 0:
{
GivePlayerWeapon(playerid,16,50);
}
case 1:
{
GivePlayerWeapon(playerid,17,50);
}
case 2:
{
GivePlayerWeapon(playerid,39,50);
}
case 3:
{
GivePlayerWeapon(playerid,40,50);
}
}
}
if(dialogid == 993)
{
if(response)
switch(listitem)
{
case 0:
{
GivePlayerWeapon(playerid,35,50);
}
case 1:
{
GivePlayerWeapon(playerid,36,50);
}
case 2:
{
GivePlayerWeapon(playerid,37,50);
}
case 3:
{
GivePlayerWeapon(playerid,38,50);
}
}
}
Falls was unklar ist oder nicht gehen sollte einfach melden
Gruß Blackybecks