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 / DarkBasic Huge Dungeon Tutorial

Author
Message
Sneeky lital devil
17
Years of Service
User Offline
Joined: 28th Mar 2007
Location:
Posted: 28th Mar 2007 09:24
I've loaded the entire Huge Dungeon Tutorial word for word and I dont get any errors during compiling, but whenever I try to run the exe, it seems like it's loading, but when the black screen maximizes, it instantly closes and returns to the editor. Yes, I've searched the forums, all threads are too old to be able to reply or post in. I'm looking for some help from anyone.



Thats my source, now you'll notice I put RemStart and RemEnd around the function.



It IS the function thats crashing the program because with the rem around it the program doesn't crash, but nothing can be seen. Can you guys help me please?
Hammaman
20
Years of Service
User Offline
Joined: 11th Feb 2004
Location:
Posted: 28th Mar 2007 14:13
I have recently looked at this tutorial and didn't have any problems ... but I think that the problem may be where the function is located in your code. Have you tried moving the function loadmap ... endfunction part of your code to the end (after the loop command)?
BatVink
Moderator
21
Years of Service
User Offline
Joined: 4th Apr 2003
Location: Gods own County, UK
Posted: 28th Mar 2007 14:24
DB Pro has changed dramatically since this tutorial was written, it may not be compatible anymore.
Quisco DaLuse
17
Years of Service
User Offline
Joined: 3rd Feb 2007
Location: USA
Posted: 28th Mar 2007 16:28
I loaded the tutorial and it worked fine. I'm using DBP v 6.3. In comparing what you have to the tutorial code, I see some differences. I would suggest you delete what you have, reload it and try it again.

You idiots! You've captured their stunt doubles!
Sneeky lital devil
17
Years of Service
User Offline
Joined: 28th Mar 2007
Location:
Posted: 28th Mar 2007 17:13
Ok, you know how the tutorial files comes with two files, a DarkBasicPro file and a DarkBasic file, are those files suppsoed to be empty or are they supposed to already have code in them, because i've downloaded them numerous times, but every time I open them, they're empty.
Quisco DaLuse
17
Years of Service
User Offline
Joined: 3rd Feb 2007
Location: USA
Posted: 28th Mar 2007 20:55
I know what you're saying. If the file type (.DBA or .DBPRO) does not show up in the window, just point the mouse at the icon for a few seconds and it will show you which one it is. You want to load the one maked .DBA. It is confusing because it seems like you should use the other one.

You idiots! You've captured their stunt doubles!
Sneeky lital devil
17
Years of Service
User Offline
Joined: 28th Mar 2007
Location:
Posted: 28th Mar 2007 20:57
Well, whether I load the (.DBA or the .DBPRO) they're both empty inside.
Quisco DaLuse
17
Years of Service
User Offline
Joined: 3rd Feb 2007
Location: USA
Posted: 28th Mar 2007 22:03 Edited at: 28th Mar 2007 22:06
Here is the source code:


You'll need to copy / paste this in DBP and save it in the same folder where the original one was.

You idiots! You've captured their stunt doubles!
Sneeky lital devil
17
Years of Service
User Offline
Joined: 28th Mar 2007
Location:
Posted: 29th Mar 2007 11:35
Thanks so much Quisco, you're extremely helpful!

I restarted my computer entered the code you gave me and it worked!
I just have a quick question. I changed the mouseclick=1 to upkey()=1 and mouseclick=2 to downkey()=1 in order to control the movement with up and down...

Do you think you can help me convert the turning so that instead of the mouse controlling direction of the character, i can use the left and right keys, to control it?
Quisco DaLuse
17
Years of Service
User Offline
Joined: 3rd Feb 2007
Location: USA
Posted: 30th Mar 2007 02:19 Edited at: 30th Mar 2007 02:21
You're Welcome. I'm glad it worked for you. This is a cool tutorial. You can use the arrow keys to turn in the dungeon. First, put this code just before the do - loop:


Then put this code inside of the do loop:


Then delete the line that says ry#=wrapvalue(ry#+mousemovex()).

That's it. You can make it turn faster/slower by increasing/decreasing the 3.0 value in the code above.

You idiots! You've captured their stunt doubles!
Sneeky lital devil
17
Years of Service
User Offline
Joined: 28th Mar 2007
Location:
Posted: 30th Mar 2007 03:33
Wow worked perfect, thanks again!
Quisco DaLuse
17
Years of Service
User Offline
Joined: 3rd Feb 2007
Location: USA
Posted: 30th Mar 2007 14:44
Np

You idiots! You've captured their stunt doubles!

Login to post a reply

Server time is: 2024-09-25 19:26:31
Your offset time is: 2024-09-25 19:26:31