Ambiera Forum

Discussions, Help and Support.

Ambiera Forum > CopperCube > Programming and Scripting
3rd Person Player & Camera Controller 2021

csp-games
Guest
Quote
2021-02-27 21:06:23

Marcw, absolutely no problem.


csp-games
Guest
Quote
2021-02-28 11:36:46

just a little update on the idea i described a few posts earlier, this 4-linepick method to fix the collision problem:

Forget about it, I was wrong. As beautiful it's simplicity may be, it only works in a world in which all walls are 90 degrees angular.


floydness
Registered User
Quote
2021-03-02 16:58:34

Thanks to all ! Works Great and just what I wanted.


smnmhmdy
Registered User
Quote
2021-03-05 16:06:20

What you guys have achieved here is really good, and I think with further tweaks it can turn out to be an excellent vehicle handling controller too.

I'll hopefully release the first version of my third person controller tonight, and from there we can only improve it further and further.

Thanks a lot for your hard work on this :)


Robo
Guest
Quote
2021-03-08 11:15:39

Thanks heaps 'csp-game' (Dieter) for your nice third person controller. My game is only first person so I took your code and modified to suit FPS also...and its works !

Yet more...I was able to work out how to get all character animations to directly change the camera movemnt bobbing and swaying etc - cant beleive I finally got this working as I want crouch and wasnt really possible till now...and accurate walking bob etc...it look good and fairly smooth...

Will post in the announcements soon...

Hopefully you can get it and adjust the max and min verical angle better as having trouble with this part and the fact that you cant centre the mouse position on start to my knowledge so the initial mouse position affects the max movements once loaded...


just_in_case
Moderator
Quote
2021-03-08 13:50:57

Thanks a lot Dieter, your efforts for tpp cam are really appreciatable. I will love to see some shaders from your side as well if you are still around then please let me know what is the exact problem with alpha transparency in shaders.


csp-games
Guest
Quote
2021-03-11 17:40:04

Glad to see it is of some use for somebody. As mentioned earlier, economical problems (caused by "govt") force me out of societly these days. I wish you all the best.


hadoken
Guest
Quote
2021-03-11 19:39:40

Dear Dieter,

I also wish you all the best and hopefully better days soon again for your personal life. Thanks for all your highly appreciated contributions which altogether helped a lot. We like having you here with us.

P.S.:
Did you notice the solution of the 3rdPersonCam horizontal mouse cursor limitation problem by using the built-in Model Viewer or FPS cam? Last piece of the puzzle, ingenious, right?


adamscott
Registered User
Quote
2021-04-26 08:37:59

Thanks to all ! Works Great and just what I wanted.


veganpete
Registered User
Quote
2021-08-26 12:39:10

Maybe I'm missing something? - but this very simple to do (without any coding)...

In my game I wanted a 3rd person camera which can look around with the mouse, instead of just facing forward.

So I just added a 1st person camera with the "follow" behaviour set to follow my player character. The camera then follows my player, but looks around with the mouse (eg: like in Skyrim).

I refined this further by having 2 cameras - one which looks wherever the player is facing (3rd Person), then a second which looks with the mouse(1st Person). I set camera 1 as default and use "switch to camera 2" when right mouse button is pressed (and "switch to camera 1" when right mouse is released).

So now my game has a 3rd person camera by default which can freely look around whenever right mouse is pressed down. (Kinda the same as a "right analogue stick" on a joypad, used for looking around which re-centres when you let go of it.)

Here's the demo game so far (right-click for mouse look)....
https://drive.google.com/file/d/...


Guru
Guest
Quote
2021-09-19 15:54:00

Sorry @veganpete and no offense at all, but I think the point was to make the third person character rotate and also steer plus walk into the direction of the free mouse look. So I doubt your non-coding solution would be enough to offer that feature from smnmhmdy's behavior script.


Guru
Guest
Quote
2021-09-21 08:47:26

I also like that smnmhmdy's solution does offer real free 3rdPerson camera mouse look and player control without the need of something like right mouse button mode switching (look <-> move in desired direction) or keyboard player rotation.


aiming_bullets
Guest
Quote
2021-09-23 05:29:34

CSP-Games hope you are doing well, It's been a long we have seen you. You have contributed good knowledge of yours to the community.


VP
Guest
Quote
2021-09-23 09:22:23

Guru wrote:
Sorry @veganpete and no offense at all, but I think the point was to make the third person character rotate and also steer plus walk into the direction of the free mouse look. So I doubt your non-coding solution would be enough to offer that feature from smnmhmdy's behavior script. I also like that smnmhmdy's solution does offer real free 3rdPerson camera mouse look and player control without the need of something like right mouse button mode switching (look <-> move in desired direction) or keyboard player rotation.

Ah, ok - so the mouse movement controls the player rotation too? That's interesting, I think a simple, non-code version of that would be to attach a plane to the camera and have the player face the plane every few milliseconds. As for having to press the right-mouse button for free-view - you don't "need" to press a mouse button to switch cameras - I just added that feature because I prefer it for my game (as a sniper scope aim). If you prefer free-look all the time, just don't add the the second camera. I'll try to make it and upload it here later, just for reference.


VP
Guest
Quote
2021-09-23 12:50:35

Here's a .ccb file I made, demonstrating the standard 1st person camera being used as 3rd person, free-view controlled by mouse, with no coding and no mouse button click to activate...

https://drive.google.com/file/d/...


Create reply:


Posted by: (you are not logged in)


Enter the missing letter in: "Internationa?" (you are not logged in)


Text:

 

  

Possible Codes


Feature Code
Link [url] www.example.com [/url]
Bold [b]bold text[/b]
Image [img]http://www.example.com/image.jpg[/img]
Quote [quote]quoted text[/quote]
Code [code]source code[/code]

Emoticons


   






Copyright© Ambiera e.U. all rights reserved.
Privacy Policy | Terms and Conditions | Imprint | Contact