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 / Tutorial 1 is not compiling

Author
Message
Yorel
16
Years of Service
User Offline
Joined: 23rd Jan 2008
Location:
Posted: 24th Jan 2008 04:37
I'm trying to work my way through the Dark GDK tutorial #1. Everything works as it should until I add the follwing code:
dbCreateAnimatedSprite ( 1, “animatedsprite.png”, 4, 4, 1 );
dbSprite ( 1, 0, 0, 1 );

The program compiles with the following two errors:
error C2065: '“animatedsprite' : undeclared identifier
C2228: left of '.png”' must have class/struct/union
type is ''unknown-type''
I'm using Visual C++ 2008 Express to compile this code.

Can anyone give me a hint how to get this to run?
based on other posts on this site I added:
#include "stdio.h"

This didn't make any difference.
axiagame
16
Years of Service
User Offline
Joined: 6th Dec 2007
Location: far far away...
Posted: 24th Jan 2008 10:00
Are you sure all your quotes are placed? the compiler acts as if the first one isn't present or another one is present before your call...
kBessa
17
Years of Service
User Offline
Joined: 8th Nov 2006
Location: Manaus, Amazonas, Brazil
Posted: 24th Jan 2008 13:39
I think this has been a problem with some people's keyboard inserting the wrong character. Your string should go between ".

Like this: dbCreateAnimatedSprite ( 1, "animatedsprite.png", 4, 4, 1 );

Not this: dbCreateAnimatedSprite ( 1, “animatedsprite.png”, 4, 4, 1 );

See if it solves your problem.

-Thiago
Yorel
16
Years of Service
User Offline
Joined: 23rd Jan 2008
Location:
Posted: 25th Jan 2008 03:21
That did it. Thank you. I will pay closer attention to this in the future.
axiagame
16
Years of Service
User Offline
Joined: 6th Dec 2007
Location: far far away...
Posted: 25th Jan 2008 03:38
Yes, I think it should be this, we had the same problem at school when our teacher gave us a part of code written with word 2003 for an Oracle database. Oracle doesn't recongnize the “ and ” characters as double quotes.
kBessa
17
Years of Service
User Offline
Joined: 8th Nov 2006
Location: Manaus, Amazonas, Brazil
Posted: 25th Jan 2008 05:05
My clients (at my real life, not games, of course) did have this problem with their website's CMS.

They inserted “ or ” and it was saved on SQL Server (without the application, that I developed, converting them to HTML codes). When rendered in the browser it showed a square, and I'd get phone calls every couple of days (Shame on me, for not converting them to their html counterparts, corrected now).

People always learn the hard (me included).

Best regards,
-Thiago

Login to post a reply

Server time is: 2024-09-29 09:29:08
Your offset time is: 2024-09-29 09:29:08