Excellent, the break down on the math for how the radius is calculated was very appreciated as well. Never a fan of copy what I do and don't think about why types of tutorials.
Any chance you could upload this to github? it would be nice to be able to follow along and not have to reconstruct the project :) Either way thank you very much for sharing this knowledge!
Probably not. For this type of video I think people want to integrate specific features like camera behavior in their already existing project. So I try to make the tutorials work in a way that allows people to "get the idea" instead of having to use the actual source code. However I also plan on uploading more base projects on martin-senges.itch.io/ Those projects will be designed to be used as as a base to develop a game around. Similar to the stuff someone can find in the Unity Asset store etc.
@@martin_senges With respect, if you publicly share code for educational purposes without providing an accessible copy, you create an unnecessary barrier for anyone who enjoyed your lesson and wishes to develop their intuition further. Sure, once people are confident they'll integrate the idea into their own project and make it their own, but nobody truly learns anything without first experimenting. Being forced to recreate this scene (or similar) from scratch just to play around and get a feel for things is a pain. That's my two cents anyway. Thanks for the helpful video.
I had an issue where as it rotated the thirdperson camera would get closer. A fix is to, before any transformations, save the camera's distance to the lookat point. Then, after all transformations, normalize the camera's transform and multiply it by the original distance. This was with my camera parented inside a kinematic body. Line before transformations: var dist = camera.translation.length() Line after: camera.translation = camera.translation.normalized() * dist;
Can you please make a video how to control camera movement using, instead of mouse, controller. Thank you for sharing your knowledge about godot engine.
The script should work for any Player object inheriting from Spatial, as only Spatial node attributes/methods are used (rotation, translation, look_at). But as I mentioned at the end of the video: This is a basic script to understand how camera rotation works. Depending on your exact game, you'll probably have to tweak and add stuff.
Sir, just seeing you video now...thank you very much for this and all you do...I've subscribed to your channel and liked this video and will check out your others which I'm sure will also help me very much in getting started with working in Godot 3d game dev. The issue I'm having at the moment, which I'm not sure if you covered or not is that it seems that the $Player.FirstPersonCamera and $ThirdPersonCamera.make_current() and .clear_current() calls don't appear to be native to the camera objects and I'm not sure if you had covered how to actually code this functionality in another tutorial or not, if you have could you point me in the right direction, and if not could you please quickly explain how this functionality works if you wouldn't mind? I understand the concept and basic call but not sure if there's a native attribute to decide which camera is active or not which I'm guessing there must be? Thanks again for this!
Ok, think I figured out what's happening after looking at the Godot documentation for the camera function. It appears the issue wasn't with make_current() or clear_current() calls but the actual check to see the current view, there doesn't appear to be a method to do this within the native Camera functions, I basically just added my own function to both Camera objects I have to check if current by returning the Current bool that belongs to that object....one would think the functionality would exist as an inherent method within the function without having to be user defined, but eh not a hard thing to add...