sorry für mein dritten post in folge, aba als gast kann man ja "logischerweise" nicht editieren. Also das mitm Speichern und Laden geht, jetzt nur noch 1 Problem:
[ags]
GUI0: ScummMenü
GUI1: Unbenuztes Menü
GUI2: Unbenuztes Menü
GUI3: Menü - Button0: Weiterspielen, Button1: Laden, Button2: Speichern, Button3: Beenden
GUI4: Speichermenü - Button0: Speichern, Button1: Abbruch
GUI5: Lademenü - Button0: Laden, Button1: Abbruch
GUI6: Meldung "Kein Platz für weitere Speicherstände vorhaden" - Button0: Abbruch
-----------------------
if (interface == 0) {
if (button == 0) { // Gib
SetCursorMode(2);
SetGlobalInt(1,0);
SetGlobalInt(80,2);
}
if (button == 1) { // Öffne
SetCursorMode(8);
SetGlobalInt(80,3);
}
if (button == 2) { // Schau
SetCursorMode(1);
SetGlobalInt(80,8);
}
if (button == 3) { // Benutze
SetCursorMode(2);
SetGlobalInt(1,1);
SetGlobalInt(80,7);
}
if (button == 4) { // schliesse
SetCursorMode(8);
SetGlobalInt(80,1);
}
if (button == 5) { // druecke
SetCursorMode(8);
SetGlobalInt(80,4);
}
if (button == 6) { // nimm
SetCursorMode(5);
SetGlobalInt(80,6);
}
if (button == 7) { // rede
SetCursorMode(3);
SetGlobalInt(80,9);
}
if (button ==

{ // ziehe
SetCursorMode(8);
SetGlobalInt(80,5);
}
if ((button == 10) & (game.top_inv_item < game.num_inv_items - 7))
game.top_inv_item = game.top_inv_item + 4;
if ((button == 9) & (game.top_inv_item > 0))
game.top_inv_item = game.top_inv_item - 4;
}
if (interface == 3) {
if (button == 0) {
GUIOff(3);
GUIOn(0);
}
if (button == 1) {
ListBoxSaveGameList(4,3);
GUIOff(3);
GUIOn(4);
}
if (button == 2) {
int index;
SetTextBoxText(5,2,"");
ListBoxSaveGameList(5,3);
index=ListBoxGetNumItems(5,3);
GUIOff(3);
if (index>4) {
GUIOn(6);
}
GUIOn(5);
}
if (button == 3) {
QuitGame(0);
}
}
if (interface == 4) {
int index;
if (button == 0) {
index=ListBoxGetSelected(4,3);
RestoreGameSlot(savegameindex[index]);
}
if (button == 1) {
GUIOff(4);
GUIOn(3);
}
}
if (interface == 5) {
string text;
int index;
if (button == 1) {
GUIOn(3);
GUIOff(5);
}
if (button == 0) {
index=ListBoxGetNumItems(5,3);
if (index<5) {
GetTextBoxText(5,2,text);
GUIOff(5);
GUIOn(0);
SaveGameSlot(index+1,text);
}
else {
index=ListBoxGetSelected(5,3);
GetTextBoxText(5,2,text);
GUIOff(5);
GUIOn(0);
SaveGameSlot(savegameindex[index],text);
}
}
if (interface == 6) {
if (button == 0) {
GUIOff(6);
GUIOn(5);
}
}
}
[/ags]
Problem: Wenn ich zu viel Speicherstände habe und die Liste voll ist, dann öffnet sich das Menü schön. Doch wenn ich auf Abbruch drücke passiert nix, warum=?[/code]