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.

Author
Message
Zen Master
16
Years of Service
User Offline
Joined: 6th Mar 2008
Location:
Posted: 7th Mar 2008 17:17
Decided to test DBPro on my friends old notebook, booted it up and spent 4 hours writing


But i get nothing on the screen the media is in my project file and i want to after this make the sprite appear where the mouse is clicked then drop and rotate! But i couldnt get it to even load. I did enter in the sync commands and below this is



This works but i cant get my sprite to load!

Please help as this is really simple but i just dont get it!!

Apologies for a noob question and Thanks for any replies

Zen

"Face it, if crime didnt pay there would be very few criminals."
Laughton Lewis Burdock
White Fang 12
17
Years of Service
User Offline
Joined: 28th Aug 2007
Location: In my office coding
Posted: 7th Mar 2008 20:41
I my be a noob my self but it looks like you forgot to make the program wait for any input which will cause the code to run and not give you a chance to do anything

I'm a noob help will be accepted
TDK
Retired Moderator
21
Years of Service
User Offline
Joined: 19th Nov 2002
Location: UK
Posted: 7th Mar 2008 20:43
If you are using Dark Basic, what are the semicolons doing on the end of each line?

Ignoring the semicolons, your first code snippet makes sense, but the second one doesn't.

I suggest you get rid of the semicolons and post all the code you are using because without it there are just too many things you could have done wrong.

TDK_Man

Zen Master
16
Years of Service
User Offline
Joined: 6th Mar 2008
Location:
Posted: 7th Mar 2008 21:22
Sorry, only read rules after posted this that full code is better heres full code



I know its not much but this is just starting up and loading a sprite, was the first thing i tried and i couldnt lol.

Zen

"Face it, if crime didnt pay there would be very few criminals."
Laughton Lewis Burdock
Paul08
16
Years of Service
User Offline
Joined: 20th Feb 2008
Location: Oxford, UK
Posted: 8th Mar 2008 00:29
Im not being funny but are you literally running a marathon before you can crawl?

I might be off my head but it looks to me as though your starting an if statement for no reason?
if mouseclick() = 1

(READ IT OUT LOUD TO YOURSELF)
does it make sense.

No.

Do i make sense?

No.

perhaps
if something = 1 then dosomethingelsehere()

or alternatively

if something = 1
dosomethingelsehere()
endif

? make sense?,...

Paul
LBFN
17
Years of Service
User Offline
Joined: 7th Apr 2007
Location: USA
Posted: 8th Mar 2008 00:33
Your code has some syntax errors. Also, you didn't code what you wanted it to do if you pressed the left mouse button. I made it so that sprite #1 will be displayed where your mouse is located.



Good luck,
LB
TDK
Retired Moderator
21
Years of Service
User Offline
Joined: 19th Nov 2002
Location: UK
Posted: 8th Mar 2008 01:20
Quote: "Your code has some syntax errors."


That's an understatement!

But, that's normal if you've just started programming...

With the experience you appear to have, I agree that you need to step back and learn the basics before going any further.

Read tutorials 1 to 4 here:

http://forum.thegamecreators.com/?m=forum_view&t=99497&b=10

and just check out what other topics are covered for future reference. 1 to 4 are for complete newcomers so they assume you've never programmed before.

TDK_Man

Login to post a reply

Server time is: 2024-09-27 12:27:05
Your offset time is: 2024-09-27 12:27:05