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 Discussion / RPG engine questions?

Author
Message
Jadelion
22
Years of Service
User Offline
Joined: 14th Jan 2003
Location:
Posted: 14th Jan 2003 09:21
Ok, I've been using Darkbasic for awhile now but I still can't seem to get the grasp of actually programming anything. So I'm gonna ask lots of really dumb questions in hopes that all the better programmers out there will guide me into creating a game.
So lets start Ok...
I want to make and RPG Batte engine but try as I might I have accomplished very little.
Ok, so there is a flat plan that all the characters get to stand on I do this with

make object palin,1,10,10 (good so far right...right...dear god i dumb)

and we load characters

load object "hero1.x",2
load object "villan.x",3

we would bother with some animation but I can't seem to find a program that will let me animate .x files. but thats not really important right now. we position the 2 characters on the plain so that they are facing eachother rather menacingly.

Now we come to some horrible problems. There needs to be a file that contains all the reference information for our to characers. I know I can make such a file with darkbasic, but how do I do this and then reference it during the battle ?

Please help... I know nothing...
pagio
22
Years of Service
User Offline
Joined: 8th Jan 2003
Location: - Please Select -
Posted: 14th Jan 2003 14:27
about that 3d program i use 3d canbas pro works exelent
http://www.amabilis.com/
I want to make an rpg too!!!!like final fantasy!!!

Dont forget the retro games
Kentaree
22
Years of Service
User Offline
Joined: 5th Oct 2002
Location: Clonmel, Ireland
Posted: 14th Jan 2003 16:36
My advice is: read through the help files and any tutorials you can find. If you couldnt be bothered to do that, there's no point being in this forum or programming any language as you have to experiment first, ask questions later.

Whatever I did I didn't do it!
Jadelion
22
Years of Service
User Offline
Joined: 14th Jan 2003
Location:
Posted: 14th Jan 2003 21:36
I've read through the entire DB tutorial and most of the examples, I couldn't find anything that seemed to be helpfull. I can post all the coding I've done so you can see where I really am but I don't think it will help much.

Kentaree
22
Years of Service
User Offline
Joined: 5th Oct 2002
Location: Clonmel, Ireland
Posted: 15th Jan 2003 00:27
Make an array with all the data contained in it, then use save array and load array to save and load it from a file.

Whatever I did I didn't do it!
Kentaree
22
Years of Service
User Offline
Joined: 5th Oct 2002
Location: Clonmel, Ireland
Posted: 15th Jan 2003 00:29
Oh, and, btw, that IS in the helpfile

Whatever I did I didn't do it!
Bogboy2000
22
Years of Service
User Offline
Joined: 8th Nov 2002
Location: United Kingdom
Posted: 15th Jan 2003 00:29
you could use memblocks rather than a file or even variables

what i mean is you start with the origional stats in you actual code then after each hit you reduce some of the values i.e. Health, stamina

and after a battle you increase some of the values i.e. strength, dexterity, helth(if you drink a health potion)

all you need to do is acess the stats at the beginig of the game and save them into a variable

We're all just a figment of somebodys imagination
Dr DooMer
22
Years of Service
User Offline
Joined: 22nd Dec 2002
Location: United Kingdom
Posted: 15th Jan 2003 02:18
If you're talking about permanent variables, you could make a seperate .dba file with a function in it that returns the value you need; then you can reference to it providing you've used the "#include" command.

The only real use for this though is to keep all your static vaiables in one easy-to-access place.

"I am a living, thinking entity who was created in the sea of information."
indi
22
Years of Service
User Offline
Joined: 26th Aug 2002
Location: Earth, Brisbane, Australia
Posted: 15th Jan 2003 04:10
write down your RPG on paper.
Imagine u never had a computer and u only had paper to write down the steps and rules.

from this u can virtually code the game provided u have explored many commands so u know what it all does.

Jadelion
22
Years of Service
User Offline
Joined: 14th Jan 2003
Location:
Posted: 15th Jan 2003 05:12
Thank you,
I hadn't considered using an array probably because I was trying to use the "open to write" and "open to read" commands from DBPro (not realizing that they aren't even in then original DB)

using the #include seems usfull mabey for calling maps but not for character files as they will need to change

As for writing it down on paper I have acutally been doing that mostly because I am not a programmer I work for programmers, I guess I was just getting ahead of myself trying to accomplish making an engine withought ther're help.

Xsniper
22
Years of Service
User Offline
Joined: 29th Dec 2002
Location:
Posted: 15th Jan 2003 05:40
I would suggest taking a piece of paper or opening up notepad and start writing down all the things you will need to make an rpg and then write out some of the main things you'd like to accomplish with this. I personally am going to write an rpg engine at some point and so I thought to myself, if I'm gonna do this then I should probably start with a 2d rpg engine and move on to 3d at a later time. Then I thought to myself, for an rpg to be an rpg you need to have maps or worlds or levels, whatever you want to call them. So the first thing I started to do was code a map editor because I felt having maps would be one of the most important parts of the game and should thus be one of the first things coded. Once I get a map editor completed I will then code the 2d rpg engine that will be able to load up a map made with my editor and display it in the game. You'll also have to do loads of other things to make it work well. I'm thinking something like a scripting language to use with your engine so that you can write the majority of your game externally from the engine code itself, etc. I hope these examples get you thinking in the right thought process, and good luck with your game!

indi
22
Years of Service
User Offline
Joined: 26th Aug 2002
Location: Earth, Brisbane, Australia
Posted: 15th Jan 2003 12:30
I started with a prototype
then from this more refined idea then made the editor.

Its worked for me but I dont reccomend it.
I have to go back to the prototype and update the entity list.

the editor will do a few things
teach u more about DB and help u make it hell easy to modify the editor if u play your cards right into the game engine.


if u want to stay digital u can always create a spreadsheet.

this spreadsheet has pages that represent a character a combat engine etc.

u hand variables over from cells to see if your magic bonuses are ok in different situations as an example for why u would want to do it this way.




One major one that u can goof up is the weather system.
u dont want to hard code it in but bolt it on so u can switch it on and off.

I had wolfs howling and snow falling in my dungeons until
I sorted this probelm.


Every object in your world is either an obstacle or a
interactive element.


Work out what u can afford to move and animate and leave the rest as static obstacles or something similar.

Every Interactive entity in the world will have a series of variables that are all similar.
Keep track of these as you are going to need them to save them.


NPCS.
Dealing with NPCS is a big thing to acheive.
they are bascially points of interactive space.

each NPC has buttons for whatever purpose talk trade insult push etc.

Each NPC also can posess a similar trait variable layout like your player.

Each time u find crossovers like this try and group them as best u can then u can deploy a typed array and make up the whole selection of entities in one loop.


try to setup a layer of code that just starts the basics.
after this basic shell is made then apply one thing at a time.

Dont add any media until u have most of the code completed or each time u rebuild it your going to magnify the wait times and create headaches introducing new problems.

save the code each time u progress to a new step and rename it with what u did.

Anytime u experience a "brainfry" and you will like we all do, you can just go back one step and try to add that feature again.


Your always going to find ideas that are not possible but write them down as later some of them become possible.


A big problem to leap over is how to reduce code for so many objects.

Explore types with an array to solve many RPG issues.

What land and style are u going to choose?
What Camera style?
will it be top down or 3d angle or 3d top down, theres lots of opportunities here as its the key element to the players usability and access.

theres some more ideas I had when I was developing the framework for DwarvenTales.

good luck

John H
Retired Moderator
22
Years of Service
User Offline
Joined: 14th Oct 2002
Location: Burlington, VT
Posted: 16th Jan 2003 00:36
Im working on an RPG right now. Battle systems being worked on. Lots and lots of arrays, they are your friends. Learn them fully. Try to make it as simple as possible first, then build on it

RPGamer

Current - RPG: Eternal Destiny : Help Wanted!
http://www.halbrosproductions.netfirms.com
Dont ask those questions! Read the help files lazy!
Boegiboe
22
Years of Service
User Offline
Joined: 9th Dec 2002
Location: United Kingdom
Posted: 17th Jan 2003 16:18
Something a bit like this????




_loadStats:

Filename$=Station$ + ".dat"
Open To Read 1,Filename$
Read String 1,T$: systemName$=T$
Read String 1,T$: stationX=Val(T$)
Read String 1,T$: stationY=Val(T$)
Read String 1,T$: stationZ=Val(T$)
Read String 1,T$: stationScale=Val(T$)
Read String 1,T$: stationName$=T$
Read String 1,T$: stationMapfile$=T$
Read String 1,T$: noOfStock=Val(T$)
Read String 1,T$: stationAlign=Val(T$)
Read String 1,T$: stationAban$=T$
Read String 1,T$: stationHull=Val(T$)
Read String 1,T$: stationShields=Val(T$)
Read String 1,T$: stationGunMounts=Val(T$)
Read String 1,T$: stationMinCrew=Val(T$)
Close File 1

return


` ----------------------------------------------------------


_saveStats:

Filename$=Station$ + ".dat"
if file exist(Filename$) then delete file Filename$
Open To Write 1,Filename$
Write String 1,systemName$
Write String 1,str$(stationX)
Write String 1,str$(stationY)
Write String 1,str$(stationZ)
Write String 1,str$(stationScale)
Write String 1,stationName$
Write String 1,stationMapfile$
Write String 1,str$(stationAlign)
Write String 1,stationAban$
Write String 1,str$(stationHull)
Write String 1,str$(stationShields)
Write String 1,str$(stationGunMounts)
Write String 1,str$(stationMinCrew)
Close File 1

return

If we could strike, I guarantee you there would be martial law.
http://www32.brinkster.com/boegiboe

Login to post a reply

Server time is: 2025-05-14 03:26:56
Your offset time is: 2025-05-14 03:26:56