error things

hello, today I was messing around with the example games shown in the bgt help system. However when I got to the point in a test thingy that I was working on where I had to define what the menu options did, I got compilation errors left and right. I tried all sorts of ways to fix them, looked through the part of the script that broak the game about 3 times looking for any errors with end statements and parenthesies and what not but couldn't find anything. I tried moving sections of code around but the errors didn't really change. I'll post both all of the code and the errors here.
code.
#include "dynamic_menu.bgt"
sound music;
sound error;
sound[] tone(4);
int menu_choice;
void main()
{
tone[0].load("1.wav");
tone[1].load("2.wav");
tone[2].load("3.wav");
tone[3].load("4.wav");
error.load("error.wav");
music.load("music.wav");music.volume=-10;
tts_voice voice;
show_game_window("swamp Memmory");
voice.speak_wait("wellcome to swamp memmory, made from the test game example in the bgt help system.");
music.play_looped();
dynamic_menu menu;
menu.add_item_tts("start getting bashed");
menu.add_item_tts("practice being bashed");
menu.add_item_tts("chicken out");
menu.allow_escape=true;
menu.wrap=true;
menu.run("here to get hit all over the place? well, this is a very good place to start!", true);
do
{
menu_choice=menu.run("here to get hit all over the place? well, this is a very good place to start!", true);
if(menu_choice==1)
{
music.stop();
play_round();
music.play_looped();
}
else if(menu_choice==2)
{
music.stop();
keyboard_practice();
music.play_looped();
}
}
while(menu_choice!=0 and menu_choice!=3 );
voice.speak_wait("ur, where do you think you're going? the zombies haven't had their dayly brain needs met oh well if you really want to go then, good bye.");
}
errors.
File: C:\Users\andawn\Documents\random bgt scripts for messing around\test project\Swamp simon.bgt
On line: 6 (1)
Information: Compiling void main()

File: C:\Users\andawn\Documents\random bgt scripts for messing around\test project\Swamp simon.bgt
On line: 32 (1)
Line: play_round();
Error: No matching signatures to 'play_round()'

File: C:\Users\andawn\Documents\random bgt scripts for messing around\test project\Swamp simon.bgt
On line: 38 (1)
Line: keyboard_practice();
Error: No matching signatures to 'keyboard_practice()'

from the errors here, my closest guess is that I haven't defined the functions "play_round" and "keyboard_practice" yet. But when defining them, I also w ouldn't know where to put the code for those functions. Sinse putting them at the bottum would make the script a lot messier and putting so much code into an if statement also doesn't seem logical.

_______________________________________________
Audiogames-reflector mailing list
Audiogames-reflector@sabahattin-gucukoglu.com
https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
  • ... AudioGames . net Forum — Developers room : connor142 via Audiogames-reflector
    • ... AudioGames . net Forum — Developers room : lukas via Audiogames-reflector
    • ... AudioGames . net Forum — Developers room : connor142 via Audiogames-reflector
    • ... AudioGames . net Forum — Developers room : lukas via Audiogames-reflector

Reply via email to