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 / Small RPG snippet?

Author
Message
Cian Rice
20
Years of Service
User Offline
Joined: 8th Jun 2004
Location:
Posted: 18th Sep 2004 02:45
I'm not at that point yet. I'm just making the ground works for an RPG. I've got NPC ai, and I can cast spells and you can talk to one npc, and there is a house, but you can't enter it. The spells have suddenly stopped working though so I've got to fix them, and how can I replace the spheres in part of the code that creates them with an object I've created?

Got anime?I do.
OldTifu
21
Years of Service
User Offline
Joined: 10th Jan 2003
Location: Scotland
Posted: 18th Sep 2004 04:17
Yeah, I gots no use for Gmail. I rarely ever use e-mail.

So... the NPC movement is working now?
To replace spheres with proper objects, just replace 'make object sphere' with 'load object "duuude.x" or whatever
Cian Rice
20
Years of Service
User Offline
Joined: 8th Jun 2004
Location:
Posted: 18th Sep 2004 04:23
That's what I thought I should do for the spheres, but because there is a variable for the amount of monsters, it does not work.

Got anime?I do.
OldTifu
21
Years of Service
User Offline
Joined: 10th Jan 2003
Location: Scotland
Posted: 18th Sep 2004 05:04
Odd... I don't see anything in the code that would only work with spheres and not any objects... what error message do you get? And, when you get an error it should usually tell you what line of code the prob is on. Might help to see what is there
Cian Rice
20
Years of Service
User Offline
Joined: 8th Jun 2004
Location:
Posted: 18th Sep 2004 05:13
This is the line

When I replace it with load object it just doesn't work, I can't remember the error of the top of my head though.

Got anime?I do.
Cian Rice
20
Years of Service
User Offline
Joined: 8th Jun 2004
Location:
Posted: 18th Sep 2004 05:20
Really what I ant now is some ai who follow you, and help fight, I'm trying to think out how I should do, I don't want a snippet for this, just some suggestions would be nice.

Got anime?I do.
OldTifu
21
Years of Service
User Offline
Joined: 10th Jan 2003
Location: Scotland
Posted: 18th Sep 2004 07:34
hm... you aren't keeping all those numbers right? Cos most of the numbers in that line of code are to do with the size and proportions of the sphere (how many rows and columns it consists of).
make object sphere a,3,6,6 = load object "sphere.x",a
and then if the object you've loaded is too big you can use the scale command to fix it: scale object a,100,100,100
(the 100's represent scaling on the X (width),Y(height) and Z(depth) axes... it's a percentage so 100 is normal. 50 is half etc...)

An aide? Running before you can walk? :p
Your enemies can already follow you, basically. You'd do something like that... but instead of following you, the aide would have to follow a point a little behind you (so that he's not actually jumping inside you, but a little behind... or perhaps to the side)
You'd need some code in him too to determine if an enemy is close. And if he does RAR! ATTACK!
You could also set him up so that if he's hurt bad, he'll run away for realism and such...
Cian Rice
20
Years of Service
User Offline
Joined: 8th Jun 2004
Location:
Posted: 18th Sep 2004 07:43
Thanks Tifu, your the man.

Got anime?I do.
freak_oz
20
Years of Service
User Offline
Joined: 20th Jul 2004
Location: castricum
Posted: 19th Sep 2004 01:22
i added battle engine to the engine of aura or something...


uhum....
Cian Rice
20
Years of Service
User Offline
Joined: 8th Jun 2004
Location:
Posted: 19th Sep 2004 01:35
Thanks for trying, but I've already gotten one with a very good battle engine that I'm improving on right now.

Got anime?I do.
freak_oz
20
Years of Service
User Offline
Joined: 20th Jul 2004
Location: castricum
Posted: 19th Sep 2004 02:56 Edited at: 19th Sep 2004 02:58
srry

uhum....
freak_oz
20
Years of Service
User Offline
Joined: 20th Jul 2004
Location: castricum
Posted: 19th Sep 2004 02:57 Edited at: 19th Sep 2004 03:01
i maded the engine better...
freak_oz

edit:srry im a little bit out of time... i thougt that the first page whas the only
freal_oz

uhum....
Cian Rice
20
Years of Service
User Offline
Joined: 8th Jun 2004
Location:
Posted: 19th Sep 2004 03:00
Don't be sorry, someone might ahve liked the atmosphere of Aura's better but wanted a battle engine and then can come here and say,
Quote: "Sweet! Aura's with a battle Engine! feak_oz you rock!"

Why should you be sorry if you were trying to help? I hope you didn't take what I said as
Quote: "your code sucks!"

type of thing, I was just saying I already have a battle engine, but thanks for trying to help.

Got anime?I do.
Cian Rice
20
Years of Service
User Offline
Joined: 8th Jun 2004
Location:
Posted: 19th Sep 2004 05:48
OKay, I ahve an image I would like to go behind the health,magic, and xp bar, but, I can't find a command that will paste the image behind them, anyone know how exactly this can bedone, because I could make huds in DBC, but it seems to be completly differnt in DBP.

Got anime?I do.
OldTifu
21
Years of Service
User Offline
Joined: 10th Jan 2003
Location: Scotland
Posted: 19th Sep 2004 06:07 Edited at: 19th Sep 2004 06:08
the command to paste an image? why it's "paste image"

load image "filename.extension",1
paste image 1,x,y

You need to put the paste image thing in the main loop of the game, unlike sprites they delete when the screen refreshes (sync)
load image just goes at the start someplace...
Cian Rice
20
Years of Service
User Offline
Joined: 8th Jun 2004
Location:
Posted: 19th Sep 2004 06:13
I figured that much out, jsut how do I put the image in so it's behind the xp,magic,and health meters, when I use the command it's above them. Do I have to put the command before the bars or something else?

Got anime?I do.
Cian Rice
20
Years of Service
User Offline
Joined: 8th Jun 2004
Location:
Posted: 19th Sep 2004 06:56
Okay, I fixed it, being sick really does stuff to your mind, I can't think straight at all.

Got anime?I do.
Cian Rice
20
Years of Service
User Offline
Joined: 8th Jun 2004
Location:
Posted: 19th Sep 2004 07:54
Anyone know what this function is supposed to do? Doug made some very odd variiables and the fact that there is no REM makes it very hard to make out what's going on, I think it has to do with attacking, but I'm not entirely sure:


Got anime?I do.
OldTifu
21
Years of Service
User Offline
Joined: 10th Jan 2003
Location: Scotland
Posted: 19th Sep 2004 08:58
I think, though i'm not 100% sure, that it is both checking for a button being pressed (the keyz variable defining what key it's checking) and making sure that that button isn't already being held (like, making sure you don't just hold the attack button down to repeatedly slash your sword)
I think... seems to be that
Cian Rice
20
Years of Service
User Offline
Joined: 8th Jun 2004
Location:
Posted: 19th Sep 2004 09:13
That's weird, because I can repeadtly(sic) slash my sword. Better variable wording would definatly help here I emailed Doug about it but I have not gotten a response. Now to get back to the coding, I'll have another question in awhile so staytuned!

Got anime?I do.
Kohaku
20
Years of Service
User Offline
Joined: 3rd May 2004
Location: The not very United Kingdom
Posted: 19th Sep 2004 09:14
Hows the snippet coming along?

Infra-Dark
Bring the 20 liners back!
#coding, like coding, but with a #
Cian Rice
20
Years of Service
User Offline
Joined: 8th Jun 2004
Location:
Posted: 19th Sep 2004 09:16
Great, I have npcs to talk with, tons of enemies to fight, a nice hud, atext box an icon to tell you that you can do something, and right now I'm implementing attacking with another button and then I hope to move on to button combos, don't know how I'll do that though. Also I can cast spells, I've had alot of help from Tifu, and I thank him alot, as do I thank you, and doug.

Got anime?I do.
Kohaku
20
Years of Service
User Offline
Joined: 3rd May 2004
Location: The not very United Kingdom
Posted: 19th Sep 2004 09:20
Cool

Infra-Dark
Bring the 20 liners back!
#coding, like coding, but with a #
Cian Rice
20
Years of Service
User Offline
Joined: 8th Jun 2004
Location:
Posted: 19th Sep 2004 09:22
Isn't it.

Got anime?I do.
Cian Rice
20
Years of Service
User Offline
Joined: 8th Jun 2004
Location:
Posted: 19th Sep 2004 11:12
Okay, there are three different attacks, one using the / button, one using the shift button and one using the ctrl button. What I want to do is make it so if a three button combo is pressed instead of doing 3 things of 16 damage it gives you a bonus but you have to press each exactly five seconds apart? I don't need a snippet with every combo I'll insert that my self but how would I do it so I could have a combo of /,shift,ctrl?

Got anime?I do.
Cian Rice
20
Years of Service
User Offline
Joined: 8th Jun 2004
Location:
Posted: 20th Sep 2004 01:01
Right now I'm goding agosub that hopefully will make the player do more damage if he presses /,shift,ctrl with exactly five seconds in between, I'll post it when it's done and you guys and comment on it, I just hope it works when I finish it.

Got anime?I do.
WarGoat
20
Years of Service
User Offline
Joined: 19th Sep 2004
Location: Montreal
Posted: 20th Sep 2004 01:31
hi im new on darkbasic and i need an small code spinnet of an rpg game that i can work on it plz

seto
OldTifu
21
Years of Service
User Offline
Joined: 10th Jan 2003
Location: Scotland
Posted: 20th Sep 2004 02:20
This thread is kinda full of such. Your question is vague. A code snippet for a turn-based RPG would be very different from a Action RPG which would be very different from a Tactics RPG... if it's an action RPG, go to page 3 and look at the code Doug submitted
Cian Rice
20
Years of Service
User Offline
Joined: 8th Jun 2004
Location:
Posted: 20th Sep 2004 02:22
And for a tunrbased, go back to page one and you'll find another code from doug, but you'd have to do alot of editing to the battle system so it actually does battle,because in that snippet it just allows you to win by pressing a spacebar. Now back to the combo coding...

Got anime?I do.
Cian Rice
20
Years of Service
User Offline
Joined: 8th Jun 2004
Location:
Posted: 20th Sep 2004 04:11
What time realted commmands are there in DBPro? I need some time commands to have my combo system work cuz I've gotten the base of it on paper.

Got anime?I do.
WarGoat
20
Years of Service
User Offline
Joined: 19th Sep 2004
Location: Montreal
Posted: 20th Sep 2004 04:45
Ok but i dont have darkbasic pro I have darkbasic

for getting a better question rpg game whith just a world and batle engine and I can work on it

seto
Cian Rice
20
Years of Service
User Offline
Joined: 8th Jun 2004
Location:
Posted: 20th Sep 2004 10:14
Can't help you there, take Aura's RPG snippet for DBC on the first page and try to implement a battle system like the one Doug put in on his action rpg one. Just change any commands so the game works in DBC.Tifu,if you are reading please check your email. I have some questions on time related commands, because I've pretty figured how I can implement combos I just need some commands so it can work.

Got anime?I do.
OldTifu
21
Years of Service
User Offline
Joined: 10th Jan 2003
Location: Scotland
Posted: 21st Sep 2004 02:10 Edited at: 21st Sep 2004 02:14
timer() related stuff... in reply to e-mail I haven't used timer things much. In making my RPG the only timer related stuff i've ever had to use was A display for time taken (as all good RPGs must have and a couple of levels have time limits

The code for that stuff was all tea-leafed from Underware Design in the DB/pro source codes section titled "Convert Timer Milliseconds to Hours / Min / Seconds" its's near the bottom. Useful stuff to get hours, minutes and seconds... and eh... that's useful but it's not necessarily what you need (though like I say, all RPGs do need a total of how much you've spent playing, not only is it cool, but lets you tell files apart from one another.

Anyway! the timer() thing is what you want I guess... you'd do something like...
when the timer is to start countdown=timer() and that just needs read once, to get the initial value when the timer is to begin to count teh five seconds...
and then... we have a value of what the computers clock reading thing (yeah, i really don't understand this too well so you'll get vague help like this...) is at that precise moment. the timer() is always updated to what the computers clock is...
so we then have if timer()>countdown+5000 then 5 seconds have passed (though I have no idea what the actual timer() value is for 5 seconds... probably more than 5000... that site I linked above could helped you find out)
hm... *sucks at explaining things he doesn't really know too well* and there may well be a better way of doing this, like I say, i've not looked into it much meself
freak_oz
20
Years of Service
User Offline
Joined: 20th Jul 2004
Location: castricum
Posted: 21st Sep 2004 03:47 Edited at: 21st Sep 2004 03:48
uuuh dougsworld owner(forgot your name )
i got on code+ Code Snippet
health as integer

and then i got another code+ Code Snippet
for a = 1 to 8
a.health = 10
next a

but it says that the health no integer is why?
thx
freak_oz
srry for the sloppy post but i posted it first in the wrong topic

uhum....
Cian Rice
20
Years of Service
User Offline
Joined: 8th Jun 2004
Location:
Posted: 21st Sep 2004 08:58 Edited at: 21st Sep 2004 11:17
for an integer you need a #symbol after it.
Thanks for the help Tifu, and remember when I said I need help on collision? Well I've got that in the game, not the best collision but it does stop the character from walking through NPCS and houses.
Also, Tifu, why don't you come and join DarkTutor, you could write us some really helpful tutorials for everyone to use!
BTW, Dougsworld owner is Doug!

Got anime?I do.
Cian Rice
20
Years of Service
User Offline
Joined: 8th Jun 2004
Location:
Posted: 21st Sep 2004 11:22
This is odd, howcome these commands no longer exist:
and
then?
I'm confuzzeled, I'll now haveto rethink my code, arrgghhh.

Got anime?I do.
Fox Dark Master
20
Years of Service
User Offline
Joined: 20th Jul 2004
Location: Portugal
Posted: 21st Sep 2004 22:18
I have a little diferent code for the status bar



is not much, but i'm working
Cian Rice
20
Years of Service
User Offline
Joined: 8th Jun 2004
Location:
Posted: 21st Sep 2004 22:27
Dark Fox Master, who is this directed at? Me or Freak_Oz? Because if it's at me thanks for trying, but I've got pretty much everything I need. URRGGHHH , now to figure out how to get those combos working...

Got anime?I do.
OldTifu
21
Years of Service
User Offline
Joined: 10th Jan 2003
Location: Scotland
Posted: 22nd Sep 2004 05:03
Well, it's good just to have RPG related codes in this thread. Even if it's not useful for thee, other newcomers looking for RPG help are likely to come here looking for answers.

Join DarkTutor? I know nothing of Tutorials. I'm just giving ickle bits of code, i've never even released a decent game (well, Munchy was alright... controls were a huge let down for it though... mehr) so making tutorials is crazee-talk

If you're still stuck on combos in like a months time, i'll probably be writing a sub-game into my RPG that will require me to learn such... until then, i'm of no help mehehe
Cian Rice
20
Years of Service
User Offline
Joined: 8th Jun 2004
Location:
Posted: 22nd Sep 2004 06:28
Gotcha, I'm going to focus on having different kinds of enemies and quests and come back to the combos, as it is being a pain in the ass.

Got anime?I do.
Fox Dark Master
20
Years of Service
User Offline
Joined: 20th Jul 2004
Location: Portugal
Posted: 22nd Sep 2004 20:39
Sorry, it's a litlle incomplete, but it's the first good piece of code i've made in DB.
Yesterday, i've update the code whith the death function but somethin on the code is not right, the compiler doesn't stop on the "wait for key"

Note: the update code is the next
Cian Rice
20
Years of Service
User Offline
Joined: 8th Jun 2004
Location:
Posted: 22nd Sep 2004 20:41
This has become a huge resource. I'm suprised more people haven't been coming to look, there's a ton of rpg stuff that can really get someone going in the right direction!

Got anime?I do.
Fox Dark Master
20
Years of Service
User Offline
Joined: 20th Jul 2004
Location: Portugal
Posted: 22nd Sep 2004 20:43
Sorry, but it's the first good DarkBASIC code i've make . I've update the compliler don't stop on the "wait key". Can you guys help me?
Cian Rice
20
Years of Service
User Offline
Joined: 8th Jun 2004
Location:
Posted: 22nd Sep 2004 20:45
Isn't the command

supposed to be:

Because that could be the problem FDM.

Got anime?I do.
Cian Rice
20
Years of Service
User Offline
Joined: 8th Jun 2004
Location:
Posted: 25th Sep 2004 05:39
How would I go about making blood like a particle effect? I'm just wondering as I'm thinking of things that I would like to add and I'm modeling some new enemies to add into the snippet, and a house, that you can enter.

Got anime?I do.
Cian Rice
20
Years of Service
User Offline
Joined: 8th Jun 2004
Location:
Posted: 25th Sep 2004 09:47
Soon I'll post some screenies on what the snippet has produced, it's really just the core of what will become an rpg, I'll post the screenies tomorow, one will show interactino,one will show magic, and one will show combat with a sword. Now, if I could add some blood...

Got anime?I do.
TEH_CODERER
21
Years of Service
User Offline
Joined: 12th Nov 2003
Location: Right behind you!
Posted: 26th Sep 2004 03:00
Depends what style you are going for. Mine being cartoony, I just make a bitmap of cartoony blood with a black background, texture it onto planes, make the black parts transparent and make it draw all faces, then cal a mini explosion function at the position of the hit whilst pointing all the planes at the camera. Works well enough. I'll try and get a snippet together to show you.

Realms Of Tutopia: Rise Of Evil v0.2
www.freewebs.com/elbsoftware/index.htm
Cian Rice
20
Years of Service
User Offline
Joined: 8th Jun 2004
Location:
Posted: 26th Sep 2004 03:05
It's an anime style, so cartoony would fit, just it's a more mature animestyle like rurouni kenshin or samurai X.

Got anime?I do.
gothboy 101
20
Years of Service
User Offline
Joined: 31st May 2004
Location: Watonga, ok, usa
Posted: 26th Sep 2004 08:17
hey anime sorry i've been gone for a while but its cause i'm getting the battle engine for midtime almost perfect i'll post it when i get it bug free. (the website might look crappy cause my copy of frontpage ran out and i'm not supposed to activate it cause its my dad's

www.dragonseige.tk
http://dragonseige.tk
Cian Rice
20
Years of Service
User Offline
Joined: 8th Jun 2004
Location:
Posted: 26th Sep 2004 13:23
Oh. I'm waiting to implement blood into my game along with time based combos to make it more like Soul Calibur rather than Zelda.

Got anime?I do.

Login to post a reply

Server time is: 2024-11-27 22:35:09
Your offset time is: 2024-11-27 22:35:09