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 / Screen always black? And other questions...

Author
Message
Captain Coder
FPSC Reloaded TGC Backer
13
Years of Service
User Offline
Joined: 6th Jul 2011
Playing: Elite: Dangerous
Posted: 31st Oct 2011 01:28
Hello coders,

I was doing some coding in DBP a few months back but got annoyed with how "hard" it was and dropped it. After getting an inkling for how difficult some of the other languages could be, I had second thoughts about DB, and have just started coding with it again, using v7.5.

So, I am trying to load a 3D object with the following code:



However, when I compile it, it gives me a black screen! I am not sure what to do. When the problem persisted, I inserted CLS (as shown in my code above), even though I knew it was for 2D. Still black. Any thoughts?

Also, I was wondering if I should buy the Hands on DBPro books TGC has. When I learned my first language, Microworlds LOGO, I was gently guided by a book, and have loved programming since. I am not sure if I am going to get far with DBP if I am picking commands from a command list and figuring out if they'll work as opposed to reading how they work.

Also, I've read that it is better to start straight-away on hard projects as opposed to simple things, because it helps prevent the learning of bad habbits. Is this true? What is your opinion?

Thank you,
Captain Coder

One of the most humbling days in your life will be the day you discover you AREN'T the best at what you love to do.
- Me
LBFN
17
Years of Service
User Offline
Joined: 7th Apr 2007
Location: USA
Posted: 31st Oct 2011 01:32 Edited at: 31st Oct 2011 01:36
You need to place a SYNC near the end of your DO - LOOP:



EDIT:
Also, I would not recommend hard-coding the object load like that. Just place your media file within the folder that contains the game .dba file, then use:



Hodgey
15
Years of Service
User Offline
Joined: 10th Oct 2009
Location: Australia
Posted: 31st Oct 2011 01:38 Edited at: 31st Oct 2011 01:39
You need to put the sync command inside your do-loop, preferably at the bottom of it. Like this:


Quote: "Also, I've read that it is better to start straight-away on hard projects"

I totally disagree with that. You need to learn to walk before you can run. It's like learning a verbal language. You need to learn the words before you write a speech. Just because you start off with simple projects doesn't mean you'll develop poor programming habits. My advice is to start off with simple projects and build your way up from there. If you start off with something too hard it is most likely you'll just give up.

Here are some tutorials which are designed for newcomers and teach good programming practice.

Hope this helps

Edit- LBFN beat me to it!

Captain Coder
FPSC Reloaded TGC Backer
13
Years of Service
User Offline
Joined: 6th Jul 2011
Playing: Elite: Dangerous
Posted: 31st Oct 2011 21:41
Oh, okay! I had the same problem when I was working with v1 of DBP, and I couldn't figure out what it was! Well, that fixes it!

Oh, and I do understand that I ought to copy the model into a "media" folder for my projects - something the Dark Game Studio Getting Started guide taught me. I just wanted to refresh my self on how to load an object by way of trial and error (probably not the best way to learn )without creating a whole other folder for it.

@Hodgey:

Quote: "I totally disagree with that. You need to learn to walk before you can run."


That's what I thought. I've seen it said at least a couple of times in other threads, but the idea of starting with a big project sounded a little to daunting, so I thought I ought to ask.

On a side note, when I said "bad habbits," that probably was not correct; I was in a hurry when I typed this and couldn't think so I put down that. I think the better thing to say would be "to learn the wrong things," (at least depending on what kind of game you want to make.)

And thanks for the tutorials; I've actually already read them, but thanks for finding it for me! Do you believe the tutorials are a good alternative to buying the books?

Thanks for the help,
Captain Coder

One of the most humbling days in your life will be the day you discover you AREN'T the best at what you love to do.
- Me
Hodgey
15
Years of Service
User Offline
Joined: 10th Oct 2009
Location: Australia
Posted: 1st Nov 2011 01:59
Quote: "I think the better thing to say would be "to learn the wrong things," (at least depending on what kind of game you want to make.) "

To be honest I think that if you try to tackle a large project when you're still learning the basics you aren't likely to learn much, if anything. I've actually been there and now that I look back I laugh at how I tried to do something.

When it comes to large projects I believe that experience is a huge factor for success which is why newcomers are typically advised to start off with small projects. Pick out an arcade game like space invaders or asteroids and have a go at those. Once you feel you have mastered those then try something larger. I reprogrammed asteroids about 5 times as I learnt about new and more efficient systems. It just takes time.

Quote: "And thanks for the tutorials; I've actually already read them, but thanks for finding it for me!"

Since you've read them then you're probably ready for something small like placing a sprite on the screen and moving it with arrowkeys. Once you've done that you could give it a goal to reach. And once you've done that you can give it objects to avoid and then you have a little game to play.

Quote: "Do you believe the tutorials are a good alternative to buying the books?"

There is one thing that TDK's tutorials don't seem to teach you and that is how to use types. I did buy a book called "DarkBASIC Pro - Game Programming 2nd Edition" by J.S Harbour and it was handy in teaching me the basics as well as a few hints, tips and tricks but most of my programming knowledge has come from just giving myself a task and getting stuck into it. If you feel as though you need the books then it might be worth getting them, they do make a good reference.

Chaotic BroOfThe1
13
Years of Service
User Offline
Joined: 21st Nov 2011
Location: wherever i wanna be
Posted: 21st Nov 2011 21:32
HI I'm trying to compile some things in DB but each time I try it says i need to do an update on the site but i don't know how to find the update
Darkzombies
13
Years of Service
User Offline
Joined: 25th Dec 2010
Location: In multiple tabs, most likely youtube.
Posted: 21st Nov 2011 23:48
The second I saw the title I was going to just say sync, but pretty much EVERYONE beat me lol.

-------------------------------------------------------------
Hodgey
15
Years of Service
User Offline
Joined: 10th Oct 2009
Location: Australia
Posted: 22nd Nov 2011 08:30
Quote: "HI I'm trying to compile some things in DB but each time I try it says i need to do an update on the site but i don't know how to find the update "

Right here.

Chaotic BroOfThe1
13
Years of Service
User Offline
Joined: 21st Nov 2011
Location: wherever i wanna be
Posted: 25th Nov 2011 01:53
[quote]Quote: "HI I'm trying to compile some things in DB but each time I try it says i need to do an update on the site but i don't know how to find the update "
Right here.

thank you very much
Chaotic BroOfThe1
13
Years of Service
User Offline
Joined: 21st Nov 2011
Location: wherever i wanna be
Posted: 25th Nov 2011 02:18
OK i updated it but now whenever i try to compile it, it says
"Failed to 'Loadprojectfile'
Failed to 'Load DBA'
Failed to 'Load DBA'"
Hodgey
15
Years of Service
User Offline
Joined: 10th Oct 2009
Location: Australia
Posted: 25th Nov 2011 05:15
Which IDE are you using? I've seen the "Failded to Load DBA" error messages in the Indigo IDE. If that's the one your using just select a resolution in the IDE for the project and it might go away. Don't ask why but this has worked for me. If your using a different IDE we're going to need a screenshot.

Chaotic BroOfThe1
13
Years of Service
User Offline
Joined: 21st Nov 2011
Location: wherever i wanna be
Posted: 25th Nov 2011 17:42
[quote]Which IDE are you using? I've seen the "Failded to Load DBA" error messages in the Indigo IDE. If that's the one your using just select a resolution in the IDE for the project and it might go away. Don't ask why but this has worked for me. If your using a different IDE we're going to need a screenshot.

this is probably going to sound like a stupid question but what's an IDE?
Hodgey
15
Years of Service
User Offline
Joined: 10th Oct 2009
Location: Australia
Posted: 25th Nov 2011 22:48
Quote: "what's an IDE?"

IDE stands for Integrated Development Environment and in short, it's what you use to write the code in.

Chaotic BroOfThe1
13
Years of Service
User Offline
Joined: 21st Nov 2011
Location: wherever i wanna be
Posted: 26th Nov 2011 00:22
ok but I don't know how to find what IDE i'm using I'm just starting to write my own codes in DB.

There is no right or wrong- there is only belief.
Darkzombies
13
Years of Service
User Offline
Joined: 25th Dec 2010
Location: In multiple tabs, most likely youtube.
Posted: 26th Nov 2011 03:26
Are you opening up darkbasic, or another program to start coding?
Thats the question.

-------------------------------------------------------------
LBFN
17
Years of Service
User Offline
Joined: 7th Apr 2007
Location: USA
Posted: 27th Nov 2011 22:36 Edited at: 29th Nov 2011 01:03
Chaotic BroOfThe1:

When you open up DarkBASIC Pro, does the screen look like this? (this is top part of the screen on the standard IDE)



After doing a quick search, this thread came up:

http://forum.thegamecreators.com/?m=forum_view&t=182393&b=1

IanM suggested that you disable your antivirus program and try it. That could be what's wrong.


Attachments

Login to view attachments
Chaotic BroOfThe1
13
Years of Service
User Offline
Joined: 21st Nov 2011
Location: wherever i wanna be
Posted: 29th Nov 2011 00:51
similar but like this

There is no right or wrong- there is only belief.

Attachments

Login to view attachments
LBFN
17
Years of Service
User Offline
Joined: 7th Apr 2007
Location: USA
Posted: 29th Nov 2011 06:06 Edited at: 29th Nov 2011 06:09
Okay, that looks like the old version of the standard IDE. First, I suggest you update DBPro to the most current version available. I have 1.0761, but I believe there is a newer version than that. To see which version you have, open the IDE and click on the HELP button, and there should be something like ABOUT DBP - click that and it will tell you.

You can post images on the forum easily by uploading a .jpg or .png version of it. Some people would not have MS Word, so they wouldn't be able to view doc files.

Anyway, in my post above yours, I gave a link to a thread for a guy that had similar troubles. It might be your antivirus software that is causing the problem. Also, you should run it as administrator if you aren't already. Check out the thread and see if it helps.

EDIT:
Apologies to the OP, as this thread has gotten off the intended path.



Chaotic BroOfThe1
13
Years of Service
User Offline
Joined: 21st Nov 2011
Location: wherever i wanna be
Posted: 2nd Dec 2011 00:48
ok i read the thread but i didn't et vey much out of it, ill try running it as the administrator. I do have version 1.0761.

There is no right or wrong- there is only belief.

Login to post a reply

Server time is: 2024-11-22 10:55:01
Your offset time is: 2024-11-22 10:55:01