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 / Castle FPS game

Author
Message
Captain America
20
Years of Service
User Offline
Joined: 8th Apr 2005
Location: Here
Posted: 16th Nov 2005 05:42 Edited at: 16th Nov 2005 05:46
Hi,
I am currently in the process of creating a FPS game that is set back along time ago when they used swords and bows. I am having trouble with walking up scaffolding, stairs and such.

I am sorta a noob because I dont know how to do alot of things in DBC, but I have had it for almost 2 years now (just havent had alot of time to spend learning because of school), so bear with me!

Here's my code:


and the media is attached.

also my castle level that i built using DeleD LITE is soppossed to be textured all differently (i.e. the ground is dirt texture, walls are brick texture, etc...) but i am not able to texture certain things differently than other things because the whole level is one object.

I would greatly appreciate an help!

Thanks!

-Captain-


Cheers,
Capt. America

Attachments

Login to view attachments
devastation
19
Years of Service
User Offline
Joined: 11th Aug 2005
Location:
Posted: 16th Nov 2005 22:02
havent used DeleD, but most any level editor should let you pick the texture for each component of the level and then export the textures it uses with the .x file. .X files keep the info on where to put each texture (or else cshop would suck) so all you really need to do it assign textures in DeleD. But I'm pretty sure this kind of thing only works with .bmps (I had a big problem with that a while back) so you may need to convert them.

here's a program that will convert and or scale a folder of images for you. very handy for textuers
http://www.mnwright.btinternet.co.uk/download/convim.zip

and if all else fails, you could save your level different times for each texture and in each one, delete everything but what is textured with the texture you're using on that area, so like all your metal would be one object, and dirt, and grass, and stone...
you'd have to load each one but they'd be in the right spots if you didn't modify them and if you scaled them all the same. to save having to write more collision, you could turn all the collision off for the textured ones, then load the entire level and hide it and use it for collision.

good luck with your project

verydevastating.com
Captain America
20
Years of Service
User Offline
Joined: 8th Apr 2005
Location: Here
Posted: 18th Nov 2005 03:18
thats a great idea!
did you run my code?
did it work for you?
cuz i cant seem to get the collision to work, ill turn it on, and then ill still go right through walls?

also the link you gave me for the file converter didnt work, it was missing a .dll file. well thanks for helping me with the level part!

-Captain-


Cheers,
Capt. America
devastation
19
Years of Service
User Offline
Joined: 11th Aug 2005
Location:
Posted: 19th Nov 2005 05:11
hello cap'n

sry i didn't reply earlier; just got home

I did run teh codez and it did sorta work... I could walk around and the mouse look is fine. If I walked perfectly into a wall, I'd catch, but otherwise I'd walk right through.

Also, you can't strafe and walk forward at the same time because I'm pretty sure that inkey can only equal one thing at a time. use


and furthermore, my advice to you is to work off of a .x collision demo. It's really ambitious to try to make your own code from scratch, especially with the built in collision. You'll be much better off if you work off of someone's walking code that they released and it would let you focus more on your actual game.

I'm not sure if it would work in dbpro's backwards compatability, but there's an excellent .x walking demo that plays like half-life and does stairs, ramps, and gravity for you. it would work for your ladders (which were a nice touch by the way; too bad I couldn't walk up em) if you made each rung that was higher up the ladder a little bit further in, like extremely steep stairs. the x demo i've used would treat them like stairs and give you no problems. you should atlest give it a try; its up for download in the codebase.

If you want, ill upload a version of it i made with jumping and crouching but I g2g now

and as for the missing dlls: theres another exe in the isntaller folder that will unpack the dlls for you

I hope your project goes smoothly. I've never seen anyone try a medival fps. good luck

verydevastating.com
Captain America
20
Years of Service
User Offline
Joined: 8th Apr 2005
Location: Here
Posted: 19th Nov 2005 05:55
thanks devastation, i will look for the x demo thing right now.
Ill also try the ladder thing so i dont have to make my own code for that. thanks again!

-Captain-


Cheers,
Capt. America

Login to post a reply

Server time is: 2025-05-22 19:33:22
Your offset time is: 2025-05-22 19:33:22