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.

DarkBASIC Professional Discussion / Care to help out a nooby?

Author
Message
Aritus
15
Years of Service
User Offline
Joined: 12th Sep 2010
Location:
Posted: 13th Sep 2010 02:02
Hello, I'm pretty knew at this... I was following along with a screen scrolling tutorial and I ended up with an error. "Cannot grab image due to illegal area at line 38."

everything is written exactly as shown in the tutorial (except for notes that I have been taking in comment regions).

This is line 38 and 39.



can anyone spot anything that strikes them as bad coding? I tried taking out the rem and it still gave the same error...

"I am paid too much for what I do and too little for what I could do."
- Wolfgang Amadeus Mozart
Jimmy
22
Years of Service
User Offline
Joined: 20th Aug 2003
Location: Back in the USA
Posted: 13th Sep 2010 14:53
Are you calling Set Display Mode to set your resolution to at least 800x600? If not, check your project settings to make sure your resolution is not defaulting at 640x480. Or put Set Display Mode 800, 600, 32 at the beginning of your program.

NaGaFailMo.
DVader
22
Years of Service
User Offline
Joined: 28th Jan 2004
Location:
Posted: 13th Sep 2010 17:20
Sounds like that is the answer, unless you are not defining x1,y1 etc properly.

http://s6.bitefight.org/c.php?uid=103081
GIDustin
18
Years of Service
User Offline
Joined: 30th May 2008
Location:
Posted: 14th Sep 2010 01:44
IIRC, when using GET IMAGE, you make your end points one less than you really wanted. I.E.

get image 1,0,0,799,599,0 `creates the background image

See if that helps.

thenerd
17
Years of Service
User Offline
Joined: 9th Mar 2009
Location: Boston, USA
Posted: 14th Sep 2010 01:59
could we see all the code? It's hard to help with just two lines as a reference.

Madscientist
16
Years of Service
User Offline
Joined: 23rd Aug 2009
Location: Between a rock and a hard place
Posted: 14th Sep 2010 02:25
@GIDustin That doesn't matter, it works by starting at 0,0 and going to your image dimentions.

You probably just don't have x1,y1,x2,y2 at the right positions.

My computer surpasses all the technologies of the day. What computer do I have?

Login to post a reply

Server time is: 2026-07-22 12:41:29
Your offset time is: 2026-07-22 12:41:29