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.

Newcomers DBPro Corner / Simple Program Checking For Key Presses Causing Problem

Author
Message
Mr Monkey Man
20
Years of Service
User Offline
Joined: 22nd Feb 2004
Location: UK
Posted: 6th Apr 2004 23:26
Im just starting to use DBPro but have come across a problem - The program wont run.
After looking at the code you'll be able to see what Im trying to do(but wrong).
Please help. What have I done wrong.


*For every problem you come across you gain something from correcting it, I hope.
comando 300
20
Years of Service
User Offline
Joined: 23rd Nov 2003
Location:
Posted: 6th Apr 2004 23:30
change
Quote: "if keystate(28) then
cls"


to

Quote: "if keystate(28)=1 then cls"


and

Quote: "if keystate(1) then
end"


to

Quote: "if keystate(28)=1 then end"


CURRENT PROJECT: RETRO PAC-MAN
Mr Monkey Man
20
Years of Service
User Offline
Joined: 22nd Feb 2004
Location: UK
Posted: 6th Apr 2004 23:54
Thanks it runs now but when I press return an error pops up saying "object does not exist at line 6".
I figured this meant I didnt create the object properly but Im sure I have.
Got any ideas?
Thanks in advance.

*For every problem you come across you gain something from correcting it, I hope.
zircher
21
Years of Service
User Offline
Joined: 27th Dec 2002
Location: Oklahoma
Posted: 7th Apr 2004 00:25 Edited at: 7th Apr 2004 00:27
As a test, replace this...

Load Image "Cocuments and SettingsDaniel PayneMy DocumentsMy PicturesSky.png",1

...with this...

Load Image "Sky.png",1

... and place a copy of sky.png in the same directory as your exec file.

I've seen some other folks have problems with spaces in file names and this may be related. As a general rule, files should be local relative paths because you never know where the user will install their program and its resources.
--
TAZ

Also, without some wait or loop at the end of the program it will immediately finish execution and return.

Login to post a reply

Server time is: 2024-09-22 04:31:29
Your offset time is: 2024-09-22 04:31:29