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 / Could not close nest line....

Author
Message
Justice Lord
15
Years of Service
User Offline
Joined: 10th Feb 2009
Location: Hueco Mundo
Posted: 24th Mar 2009 16:28
This error message appears saying it can't close the last line
and when I put a THEN in my IF statement then it says COMMAND OUT OF PLACE AT LINE 26


Virtual Nomad
Moderator
18
Years of Service
User Offline
Joined: 14th Dec 2005
Location: SF Bay Area, USA
Posted: 24th Mar 2009 18:52 Edited at: 24th Mar 2009 18:52
there are a couple issues with your code.

when you click the mouse, you want to delete image 2, sleep 1 and cls, right?

so:




then, you have a do but no loop, or is the code above incomplete?

=PRoF=
21
Years of Service
User Offline
Joined: 17th Mar 2003
Location: Milton Keynes, UK
Posted: 24th Mar 2009 20:01 Edited at: 24th Mar 2009 20:05
Thats not how you use the if/then commands.

Either do...


Or



You don't need both then and endif in the same if statement.

Without Music or Love the world would be a very empty place... Thank god I still have music.. --'-<@
Justice Lord
15
Years of Service
User Offline
Joined: 10th Feb 2009
Location: Hueco Mundo
Posted: 26th Mar 2009 12:41
i tried those it still don't work, the COULD NOT CLOSE NEST AT LINE 30 message keeps coming up.

this is what i changed it to:

Load music "Z:\Unit 12 - Developing Computer Games\Game\Gundam_00_Second_Season_-_Unlimited_Sky.mp3",1
Play music 1
set display mode 800,600,32
load animation "Opening.avi",1
play animation 1
wait 3000
delete animation 1


set cursor 270,240
Load image "Title_Screen.jpg",1
Paste Image 1, 0, 0
Load Image "Press start.jpg", 2
Paste Image 2, 277, 271
end

do
If Mouseclick()Then Delete Image 2


wait key
cls
print "Welcome to AWESOME WARS (EPIC DOOD)"
input "Enter Name>", player$
[/Code]
=PRoF=
21
Years of Service
User Offline
Joined: 17th Mar 2003
Location: Milton Keynes, UK
Posted: 26th Mar 2009 18:41
As Virtual Nomad said earlier, you have a do without a loop command to close the nest.

Code compiles fine with that addition.

Without Music or Love the world would be a very empty place... Thank god I still have music.. --'-<@

Login to post a reply

Server time is: 2024-09-28 04:24:17
Your offset time is: 2024-09-28 04:24:17