Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Dark GDK / Problems with Hello world tutorial

Author
Message
GameDesignNoob
15
Years of Service
User Offline
Joined: 8th Oct 2009
Location:
Posted: 9th Oct 2009 05:48
Every time I try to run the first tutorial program it says that the program is out of date and asks if I want to build it. This is the Build log that i get with errors.

Build started: Project: Hello World, Configuration: Debug|Win32

Command Lines


Creating temporary file "c:\Documents and Settings\Doug\My Documents\Visual Studio 2008\Projects\Hello World\Hello World\Debug\RSP0000012852384.rsp" with contents
[
/FD /EHsc /MTd /Fo"Debug\\" /Fd"Debug\vc90.pdb" /c /ZI /TP ".\Main.cpp"
]
Creating command line "cl.exe @"c:\Documents and Settings\Doug\My Documents\Visual Studio 2008\Projects\Hello World\Hello World\Debug\RSP0000012852384.rsp" /nologo /errorReport:prompt"

Output Window


Compiling...
Main.cpp
c:\documents and settings\doug\my documents\visual studio 2008\projects\hello world\hello world\main.cpp(17) : error C2065: '“animatedsprite' : undeclared identifier
c:\documents and settings\doug\my documents\visual studio 2008\projects\hello world\hello world\main.cpp(17) : error C2228: left of '.png”' must have class/struct/union
type is ''unknown-type''

Results


Build log was saved at "file://c:\Documents and Settings\Doug\My Documents\Visual Studio 2008\Projects\Hello World\Hello World\Debug\BuildLog.htm"
Hello World - 2 error(s), 0 warning(s)

I have followed the tutorial to the letter and I have all of the file paths correct so far as i can tell, so I have no idea why I am getting these errors.
puppyofkosh
17
Years of Service
User Offline
Joined: 9th Jan 2007
Location:
Posted: 9th Oct 2009 13:50
It sounds like you forgot to put "animatedsprite.png" in quotes somewhere.

And btw next time you get an error, code usually helps...
GameDesignNoob
15
Years of Service
User Offline
Joined: 8th Oct 2009
Location:
Posted: 9th Oct 2009 15:21
[// Dark GDK - The Game Creators - www.thegamecreators.com

// the wizard has created a very simple project that uses Dark GDK
// it contains the basic code for a GDK application

// whenever using Dark GDK you must ensure you include the header file
#include "DarkGDK.h"

// the main entry point for the application is this function
void DarkGDK ( void )
{
// turn on sync rate and set maximum rate to 60 fps
dbSyncOn ( );
dbSyncRate ( 60 );

dbLoadImage ( “animatedsprite.png”, 1 );
dbSprite ( 1, 0, 0, 1 );
// our main loop
while ( LoopGDK ( ) )
{
// update the screen
dbSync ( );
}

// return back to windows
return;
}]
Chamill
16
Years of Service
User Offline
Joined: 29th Sep 2008
Location:
Posted: 9th Oct 2009 15:27
Copy the image loading line and show us, the problem is definetly there

You can only get smarter by playing a smarter opponent.
GameDesignNoob
15
Years of Service
User Offline
Joined: 8th Oct 2009
Location:
Posted: 9th Oct 2009 18:43
Quote: "Copy the image loading line and show us, the problem is definetly there

"


I think that I posted the whole code in my last post. It probably just hadnt been approved when you posted.
GameDesignNoob
15
Years of Service
User Offline
Joined: 8th Oct 2009
Location:
Posted: 9th Oct 2009 19:08
Quote: "Copy the image loading line and show us, the problem is definetly there

"


I think that I posted the whole code in my last post. It probably just hadnt been approved when you posted.
GameDesignNoob
15
Years of Service
User Offline
Joined: 8th Oct 2009
Location:
Posted: 9th Oct 2009 19:10
Quote: "Copy the image loading line and show us, the problem is definetly there

"


I think that I posted the whole code in my last post. It probably just hadnt been approved when you posted.
Willy
21
Years of Service
User Offline
Joined: 17th Jun 2003
Location: Ohio
Posted: 9th Oct 2009 20:28 Edited at: 9th Oct 2009 20:31
I'm getting exactly the same error message.
The load image line was copied from the tutorial.
I first copied it to Notepad, to insure there weren't any strange or invisible .pdf characters.
I've double checked it against the format for dbLoadImage.
I also hand entered it.

It looks like it is not recognizing "dbLoadImage" as a valid command. (I also tried moving the include files into the project.)
_________________
Rather than duplicate the post here, please take a look at my post in "Installation and Wizards." It's currently the last post on page 3. That may give a clue as to the problem.
I don't believe the problem is a source code typo...

Willy
Mireben
16
Years of Service
User Offline
Joined: 5th Aug 2008
Location:
Posted: 9th Oct 2009 22:18 Edited at: 9th Oct 2009 22:44
Solution: Notice that the quotation marks around “animatedsprite.png” look different than the quotation marks around "DarkGDK.h" a few lines above. The quotation marks around “animatedsprite.png” are SLANTED inwards, which is often done by text editors to beautify text, but these will not be recognized by the compiler because it's a different character. Erase just the quotation marks and re-type them in the Visual C++ editor, to replace them with straight quotes. It will compile.

Login to post a reply

Server time is: 2024-11-20 13:26:38
Your offset time is: 2024-11-20 13:26:38