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 / 2 Stupid Questions...

Author
Message
Evilcatt09
21
Years of Service
User Offline
Joined: 2nd Oct 2003
Location:
Posted: 27th Apr 2004 05:58
1. Can anyone tell me what is wrong with this


I also tried it this way but it wont work either



Or is there something else wrong with it?

2. Is there any legal thing that would stop me from putting the DarkBASIC logo in the beginning loading thingy, I know there probably isn't but I just wanted to make sure.

You want me to get a life? Ok, hold on a sec. *picks up the controller and presses Up,Down,Right,A,Left,B,Y* There you go now I have 50!
DarkLord
20
Years of Service
User Offline
Joined: 21st Apr 2004
Location: Canada
Posted: 27th Apr 2004 08:22
i dont know crap... i dont even know how to make a program to make text apear. but try this. dunno if it will work, i saw something like that in the forum not too long ago!

Self built, 1.3ghz, 1024mb ram, 128mb ati radeon 9600se
DarkLord
20
Years of Service
User Offline
Joined: 21st Apr 2004
Location: Canada
Posted: 27th Apr 2004 08:22


Self built, 1.3ghz, 1024mb ram, 128mb ati radeon 9600se
Cookyzue
21
Years of Service
User Offline
Joined: 12th Oct 2003
Location: Who Cares?!
Posted: 27th Apr 2004 08:23
1. try this:


it sould work.


2. What do you mean?


Cookyzue
21
Years of Service
User Offline
Joined: 12th Oct 2003
Location: Who Cares?!
Posted: 27th Apr 2004 08:25 Edited at: 27th Apr 2004 08:25
oops, sorry here:



Yu Une
20
Years of Service
User Offline
Joined: 26th Apr 2004
Location: under my own little rock
Posted: 27th Apr 2004 10:18
Oh boy I'm sooo rusty at basic
Mentor
22
Years of Service
User Offline
Joined: 27th Aug 2002
Location: United Kingdom
Posted: 27th Apr 2004 21:27 Edited at: 27th Apr 2004 21:30
put

if upkey()=1 then y=y-5

don`t split across lines like that, to do it correctly you would do

if upkey()
y=y-5
endif

DB sometimes has problems with if/then line format, you don`t get an error...it just don`t work, generaly the if/endif style works all the time, if/then lines can mess up when you have more than a couple of statements following on, I trust that isn`t all your code as well, you have to load an image before you can paste it, plus you might like to start your code with sync on:sync rate <value> and then place a sync at the bottom of the loop, don`t rely on the autotragic system sync, it often messes up and ignores new data and makes the screen flickery.

Mentor.

PS it says in the readme for DB that you can include a logo or just a small text line if you wish (with the demo it`s compulsory), but most people don`t put them in since if you are selling the code then telling the customer it`s a basic program is a sure fire way to get him to spend his money elsewhere (basic has an undeserved reputation as a "bad" language for "decent" games)

PC1: P4 hyperthreading 3ghz, 1gig mem, 2x160gig hd`s, ATI radeon 9800 pro gfx, 6 way surround sound, PC2: AMD 1.2ghz, 512mb ram, FX5200 ultra gfx, stereo 16 bit soundblaster, ups.
kidsa
20
Years of Service
User Offline
Joined: 8th Dec 2003
Location: MA,usa
Posted: 28th Apr 2004 00:36
is this the I don't know how to click edit convention?

i used to be kidsa the random one i guess im not as random anymore.

any language used by me will be dbpro(saves me a lot of typing)
Evilcatt09
21
Years of Service
User Offline
Joined: 2nd Oct 2003
Location:
Posted: 28th Apr 2004 05:19
Now that stuff works but when I try to run the program, my computer freezes, I think something is screwed up in here somewhere...

this is getting annoying, every little thing freezes my computer



I have the coolest signature, here it is...
I have the coolest signature, here it is...
Evilcatt09
21
Years of Service
User Offline
Joined: 2nd Oct 2003
Location:
Posted: 28th Apr 2004 05:21
It used to run all of that until I added this part of it



I have the coolest signature, here it is...
I have the coolest signature, here it is...
Cookyzue
21
Years of Service
User Offline
Joined: 12th Oct 2003
Location: Who Cares?!
Posted: 28th Apr 2004 06:53
put sync on in the do loop!


Night Giant
21
Years of Service
User Offline
Joined: 26th Jul 2003
Location:
Posted: 28th Apr 2004 07:37 Edited at: 28th Apr 2004 07:37
no no no, do not put sync on in the do loop. put sync in the do loop, and also put a sync on and then a do at the top of your code (the full code you posted). ala:



you should also develop better formatting practices, your code will get very difficult to read, even for you, when it starts getting larger.

oh, wow. insignificantpunks.cjb.net. we like orange treble clef notes, just for future reference.

no: website for progs yet.
Evilcatt09
21
Years of Service
User Offline
Joined: 2nd Oct 2003
Location:
Posted: 30th Apr 2004 06:15
I'm sorry about all of the stupid questions, I'm a big newb, this is the first program I've really tried making.

How can I make the controls more realistic, like instead of rising and falling at the same speed, how would I make it accelerate, or take more time to stop when it is falling faster?

I also wanted to try to make a health bar I know the basic code for it but I just can't figure out how to get different damages for different speeds, because it would be kind of stupid to have the damage for falling at 30 feet as for falling at 5 feet?

Once again, I'm sorry for all of the questions.

I have the coolest signature, here it is...
I have the coolest signature, here it is...
Social Disease
21
Years of Service
User Offline
Joined: 30th Sep 2003
Location: State of Confusion, beyond Denial...
Posted: 1st May 2004 02:11
To make it different speeds, set it as a varible
your varible would be speed#, and it could be equal to 1 at first
speed# = 1
then as you want to go faster
speed# = 2
speed# = 3
so on
then, to make it work:
If upkey()=1 Then y=y-speed#
do you see?

as for falling damage, according to D&D a character should take 1 to 6 damage per 10 feet they fall. So before you start falling, set the height with a variable, set the height of the landing to a varible, then subtract to get how far you fell, then make a formula to apply damage based on the distance you fell!

Is this clear or mud? my first assist, so give me some feed back.

Think Gad fro Spill Chock!
Evilcatt09
21
Years of Service
User Offline
Joined: 2nd Oct 2003
Location:
Posted: 3rd May 2004 01:39
it would proly be ok to anyone good at DB but, its a little confusing to me, I think it would help a lot to have a code snippet in there someone, but I can figure it out.

Thnx

I have the coolest signature, here it is...
I have the coolest signature, here it is...
Evilcatt09
21
Years of Service
User Offline
Joined: 2nd Oct 2003
Location:
Posted: 3rd May 2004 03:01
Ok, now I'm really confused, I tryed to look at some code and make its speed up and slow down, now it speeds up, but when I stop pressing up, it keeps going...

I'm in desprate need of someone who can help me.

I have the coolest signature, here it is...
I have the coolest signature, here it is...
Lost in Thought
20
Years of Service
User Offline
Joined: 4th Feb 2004
Location: U.S.A. : Douglas, Georgia
Posted: 3rd May 2004 06:59 Edited at: 3rd May 2004 07:02
Does this help?


I really don't understand exactly what you want to do.

"People don't fail ..... they stop trying." Specs. P4 2.8GHz 800 FSB | 512MB DDR333
GeForce FX 5200 AGP 256MB | Windows XP Pro Full

Login to post a reply

Server time is: 2024-11-26 17:39:43
Your offset time is: 2024-11-26 17:39:43