Okay guys, thanks for the help so far. Just got a bit more to do. The program still is experiencing problems (even with the suggested modifications). The new code is attached as well as the error message. Im not sure what it could be, if i figure it out during my usual star off with the code, i'll remove it.
SOURCE CODE:
#include "DarkGDK.h"
void DarkGDK(void) {
dbSyncOn();
dbSyncRate(0);
char fname[25]="Test.txt";
char teststring[25]="This is a test file.";
char imageone[35]="media\\backdrops\\backdrop 1.png";
int width=dbScreenWidth();
int height=dbScreenHeight();
//set sprite priority 2, 1
dbLoadImage(imageone,2,1,1);
dbSprite(2,0,0,2);
dbSizeSprite(2,width,(height/100*101);
/* Checks if the file already exists */
if (dbFileExist(fname)) {
/* MakeFile() will fail if it already exists */
dbDeleteFile(fname);
}
/* Make the file in the current directory */
dbOpenToWrite(1,fname);
dbWriteString(1,teststring);
while (LoopGDK()) {
dbSprite(2,0,0,2);
dbSync();
//dbWaitKey();
}
}
ERROR CODES:
1>------ Build started: Project: Dark GDK - Game3, Configuration: Debug Win32 ------
1>Compiling...
1>Main.cpp
1>c:\users\james\documents\visual studio 2008\projects\dark gdk - game3\dark gdk - game3\main.cpp(18) : error C2143: syntax error : missing ')' before ';'
1>Build log was saved at "file://c:\Users\James\Documents\Visual Studio 2008\Projects\Dark GDK - Game3\Dark GDK - Game3\Debug\BuildLog.htm"
1>Dark GDK - Game3 - 1 error(s), 0 warning(s)
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========
Thanks for all the help guys, Arenas.