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 / Rotate Camera & Arming characters

Author
Message
Ambitious Guy
16
Years of Service
User Offline
Joined: 1st Aug 2008
Location: Florida, USA
Posted: 6th Jan 2009 18:59 Edited at: 6th Jan 2009 19:00
1. How would I rotate a third person camera by just moving my mouse (like Mecs 2 or GTA IV).
2. How would I give my third person character a gun?

The Geek of our time
Tom0001
18
Years of Service
User Offline
Joined: 30th Dec 2005
Location:
Posted: 7th Jan 2009 11:04
1. There is a tutorial on creating huge dungeons in DBP that uses a camera system similar to the one which you are describing. Search on Google for DarkBASIC Pro Tutorials and you're sure to find it on TGC site. Read through it and you should figure out how to make a mouse controlled camera system.

2. You would need a model for said weapon first, I think or, if you'd rather not use a model then you can just jump straight into the coding. It'll require you to use certain logical algorithms including the aiming, firing and what occurs when fire is pressed, as well as when a collision is detected between the object fired and the object it hits.

Ambitious Guy
16
Years of Service
User Offline
Joined: 1st Aug 2008
Location: Florida, USA
Posted: 7th Jan 2009 15:58 Edited at: 7th Jan 2009 16:39
1. Well I looked at that dungeon tut and the camera code it gave me to rotate the player. I meant rotate the camera around the player.

2. I have the model and the character model what do I do from there to GIVE my character the gun.

The Geek of our time
BatVink
Moderator
21
Years of Service
User Offline
Joined: 4th Apr 2003
Location: Gods own County, UK
Posted: 7th Jan 2009 17:20 Edited at: 7th Jan 2009 17:21
Ambitious Guy
16
Years of Service
User Offline
Joined: 1st Aug 2008
Location: Florida, USA
Posted: 7th Jan 2009 20:53
Sorry.

The Geek of our time
BatVink
Moderator
21
Years of Service
User Offline
Joined: 4th Apr 2003
Location: Gods own County, UK
Posted: 7th Jan 2009 21:39
No need to apologise - it's for your own benefit as well as everyone else's

Ambitious Guy
16
Years of Service
User Offline
Joined: 1st Aug 2008
Location: Florida, USA
Posted: 8th Jan 2009 17:38 Edited at: 8th Jan 2009 19:42
Ok here is the co for the camera I have so far. What do I need to change is this code to make it just like Mercs 2's? I just found out I don't need the mouse to rotate around the character.


The Geek of our time

Login to post a reply

Server time is: 2024-09-28 00:28:26
Your offset time is: 2024-09-28 00:28:26