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 / Help in camera movement....

Author
Message
technotdc
13
Years of Service
User Offline
Joined: 13th Apr 2011
Location:
Posted: 13th Aug 2011 16:19 Edited at: 15th Aug 2011 03:50
Hi....

(sorry my bad english)...

I have this code to start ............it's the loadfpsclevel.dba.
Also I loaded a gun


Now doubts .

1 - How I can ease the movement of the gun when I walk?? (makes a tremor that is very ugly)

this is gun code



and in main (called with gosub_camera




================================================================
================================================================


2 - with this movement system .. how can I do to jump ????...
the camera/movement code






I put this line to jump:






It jump (gravity does the rest) ... but when it collided with an object on the level or the walls ......booooom........the camera shoots upward and out of the map (second floor of fpsc level)

=============================================================
=============================================================



3-how to make just before colliding with the wall (the gun put into the wall .....)

the collision system:



===========================
===========================


Well ... I wait your help,please (I'm starting DB Pro/noob)


I use this code because i want to make the levels with FPSC....
If someone have a better code to star with camera/gun/Fpsc level .....please ...send me....(i'm noob)

I have FPSC to make a FPS game.....but i want to learn DB_Pro.....¿what do you think about it???

thanks a lot
Mugen Wizardry
User Banned
Posted: 13th Aug 2011 21:29
set camera to follow object position x(obj), object position y(obj), object position z(obj), object angle y(obj), distfromobjtocamera#, distaboveobject#, 100.0, 1

call in main loop

CHECK OUT SOME MUSIC FROM MY NEW TECHNO CD! TECHNOKINESIS
http://www.youtube.com/watch?v=4a8KedfgVv0
ALSO, CHECK OUT MY NEW TECHNO CD AT Amazon.com!
technotdc
13
Years of Service
User Offline
Joined: 13th Apr 2011
Location:
Posted: 15th Aug 2011 03:53
sorry I edit ...because I put the code.....
chafari
Valued Member
18
Years of Service
User Offline
Joined: 2nd May 2006
Location: Canary Islands
Posted: 15th Aug 2011 04:08
Hi there.
Here is a piece of code that carry a gun and has all camera movements. I hope it can help you . Use the mouse to shoot




Cheers.

I'm not a grumpy grandpa
technotdc
13
Years of Service
User Offline
Joined: 13th Apr 2011
Location:
Posted: 15th Aug 2011 17:07 Edited at: 15th Aug 2011 17:10
Hi chafari.....

I also had tried this code (last week)....I'm testing with 3 codes (the fpsc level..this one you post..and other from a spanish forum)

I load my FPSC level without problems in this code,but i can't make collisions with it........

¿can someone help with this ?


PD- ¿you live in Canary Island ? ¿are you spanish ???? (i from Barcelona )
chafari
Valued Member
18
Years of Service
User Offline
Joined: 2nd May 2006
Location: Canary Islands
Posted: 15th Aug 2011 22:43
Ha Ha , well I'm as spanish as you are, but here in my land we say that we are "canarios" though my ID card says I am Spanish ...you know what I mean ?

If you need a collision system I can help you...just let me know.

cheers.

I'm not a grumpy grandpa
technotdc
13
Years of Service
User Offline
Joined: 13th Apr 2011
Location:
Posted: 16th Aug 2011 01:57
ok.....thanks chafari ("canarios" and "guagua"


=======================================

question 1 and 2 is solved .


but the number 3 ...........¿how can I do the colllision camera/level just before the wall?

chafari
Valued Member
18
Years of Service
User Offline
Joined: 2nd May 2006
Location: Canary Islands
Posted: 16th Aug 2011 03:59
Hi there. You are using an old collisiom system. I know differents system (sparky`s the best) but now I will show you an easy way to get sliding collision with your level. Download example . I hope you like it


Cheers

I'm not a grumpy grandpa

Attachments

Login to view attachments
technotdc
13
Years of Service
User Offline
Joined: 13th Apr 2011
Location:
Posted: 16th Aug 2011 05:02
thanks......

very good example (very easy to understand and in spanish¡¡¡)


now the problem.....

My level it's created with FPS Creator....is not .x model.....






and here is all the file

http://dl.dropbox.com/u/30898045/LoadFPSCLevel.rar



thanks


pd ¿pero hablas español o no???
chafari
Valued Member
18
Years of Service
User Offline
Joined: 2nd May 2006
Location: Canary Islands
Posted: 16th Aug 2011 05:46 Edited at: 16th Aug 2011 05:48
Quote: "pd ¿pero hablas español o no??? "


Yes, my mother is spanish and I can manage myself a bit. I have downloaded your example and it works in my PC. Perhaps the gun glitch a bit but works fine. You have to use a,s,d,w with this code but you could change it for arrowkeys. I'll have a look to your example and I`ll give you an answer tomorow.

Ahora como que es algo tarde en Canarias, las 3:45 de la mañana, y tengo los ojos medios cerrados, ademas mi mujer me echara la bronca..jaja

Cheers.

I'm not a grumpy grandpa
chafari
Valued Member
18
Years of Service
User Offline
Joined: 2nd May 2006
Location: Canary Islands
Posted: 16th Aug 2011 12:56
I have made some changes to the code. The gun had been scaled too big, so I just rem this line and re-position the gun. Notice that I have moved some part of code in order the gun don't has this annoying glitch.Use this code instead of the original and see if that is what you need. Now you can use a,s,d,w or arrowkeys .




Cheers.

I'm not a grumpy grandpa
technotdc
13
Years of Service
User Offline
Joined: 13th Apr 2011
Location:
Posted: 16th Aug 2011 16:52 Edited at: 16th Aug 2011 17:07
"Ahora como que es algo tarde en Canarias, las 3:45 de la mañana, y tengo los ojos medios cerrados, ademas mi mujer me echara la bronca..jaja"


jejeje......3.45 de la mañana en canarias es 4.45 en Barcelona..jejejeje...si mi mujer tambien me echo la bronca a mi......el darkbasic me quita el sueño

===========================================================
===========================================================


thanks colega...tu codigo funciona de puta madre.
chafari
Valued Member
18
Years of Service
User Offline
Joined: 2nd May 2006
Location: Canary Islands
Posted: 16th Aug 2011 18:41
Quote: " it`s so late... 3:45 am in Canarias, 4:45 am in Barcelona our women are going to kill us."



Quote: "thanks colega...tu codigo funciona de puta madre
Thanks colleague, your code works great
"


Enjoy it !! ,helping any time.
Que lo disfrutes, y si tienes alguna otra duda, aqui estamos .


Cheers.

I'm not a grumpy grandpa

Login to post a reply

Server time is: 2024-11-24 03:00:28
Your offset time is: 2024-11-24 03:00:28