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 / RPG Battle timer question

Author
Message
Evad
23
Years of Service
User Offline
Joined: 7th Apr 2003
Location: United States
Posted: 15th May 2003 19:12
Hello, I have a question, I am working on an RPG, but I am not sure how to do the timer for the battle..what I mean is, I am not sure how to syncronize the coding with the actual graphics, any help would be nice. Thanks

--Dave
UberTuba
23
Years of Service
User Offline
Joined: 5th Oct 2002
Location: Brittania
Posted: 15th May 2003 19:20
Sync on
Sync rate 60
do
sync
loop

Is that what u want

Life is a terminal disease.
You never survive it.
Eponick
23
Years of Service
User Offline
Joined: 18th Mar 2003
Location:
Posted: 15th May 2003 21:41
Just turn sync on and
something like


If CanAttack=1 then
DoBattle
sync
else
DoWaiting
endif

With sync on, it will only update the screen when you tell it to. A very nice feature =)

Evad
23
Years of Service
User Offline
Joined: 7th Apr 2003
Location: United States
Posted: 15th May 2003 22:18
What??? you misunderstood....first..I need to figure out how to do the graphics aka. the timer increasing..animation! ATB system.

And then, I want to know how to syncronize it...you are thinking in to basic terms...yes I know the sync command..sheesh. I am not a complete newbie! hell...anyway
I want to know how to add the timer feature...with graphics..and the math..please..help me now.

Nilrem
23
Years of Service
User Offline
Joined: 27th Feb 2003
Location: United Kingdom
Posted: 16th May 2003 02:55
Quote: "please..help me now.
"

Whilst I do not know how to help you, I for one definately know the above quotation of your post is not the way to go for getting help Evad.

I hear and I forget. I see and I remember. I do and I understand.
AtomR
23
Years of Service
User Offline
Joined: 4th Apr 2003
Location: Portugal
Posted: 16th May 2003 03:26 Edited at: 16th May 2003 03:29
I know what you mean. A year ago I started working on my next game (LOL it's in the backburner for when I finish my current game and DBPro is a lot more bug free), an FF clone. I did most of the battle system but that part was a bit tricky. How to have 6 different timers for the 6 different character in the battle (My party of 3 and 3 enemies). Let's see if I can remember how I did it.



Man it only took me an hour to figure this out this. Last year It took me the best part of a day.

Of course, I used Darkedit's types instead of arrays. It's the same thing only tidier. And for better results the total time values should be quite big. Around 500.
Hope this is what you wanted.

If you want a demo of this in action you can download mine
http://pwp.netcabo.pt/atomr/battle2.zip

Take care
AtomR
Evad
23
Years of Service
User Offline
Joined: 7th Apr 2003
Location: United States
Posted: 16th May 2003 05:46
AtomR, thanks. that helped alot!

Nilrem, you misunderstood...I wasn't demanding...I was stating, now that you have the correct question, go ahead and answer it now.

I hate text..you can't tell the tone of somebody's voice..by text

anyway, AtomR, really thanks alot.

Evad
23
Years of Service
User Offline
Joined: 7th Apr 2003
Location: United States
Posted: 16th May 2003 06:33
I have a few more problems..., how would I be able to add the character name to that code?, I mean right now it is showing 1:.. and I cannot remove the 1, any suggestions?

AtomR
23
Years of Service
User Offline
Joined: 4th Apr 2003
Location: Portugal
Posted: 16th May 2003 08:58
That's easy.
Create an array called Character_names$(5) and in the following line
text 0,character*20,str$(character+1)+":Time waited= "+STR$(character_total_wait#(character))+" Attack= "+str$(character_attacks(character))+" "
substitute str$(character+1) with character_names$(character).
That's pretty basic. You sure you shouldn't be in the newbies forum?

Take care
AtomR
Evad
23
Years of Service
User Offline
Joined: 7th Apr 2003
Location: United States
Posted: 16th May 2003 23:02
yes I know it was basic. But thanks for the help anyway...I am not really a newbie....well kinda...but I got what I needed, thanks...I like your demo too by the way.

--Dave

Login to post a reply

Server time is: 2026-07-11 12:03:18
Your offset time is: 2026-07-11 12:03:18