blender-girl

Changing the camera to orthogonal removed the deformation, but caused other problems as you said.

I think the solution is to change the code in Head.gd. That's what changes the view when you move the mouse. But I lack the knowledge to tell you how to do that. TwistedTwigleg is an expert on this subject.

blender-girl As a beginner, it's too difficult 🙁

Can you open the project and see for yourself?

I already did and I saw nothing abnormal, hence my previous question. If you just mean the perspective/lens distortion then a barrel distortion to counter it somewhat is likely the answer, the linked example is probably one of the simpler solutions but to implement something for this is probably best done, if not outright needs to be done on a engine source level. Trying to apply a shader implementing this on a viewport might be doable, but would likely have it's own artifacts and issues.

Simpler 'solution' might be to simply lower the FOV. FOV of 50 might perhaps be a good start to experiment with.

No existing FPS game is deforming models if you move the mouse, so why is godot doing this?

Could you record a video(or at least a screenshot) capture of this deformation, since I see nothing but the perspective distortion which very much is a rather normal thing in games that feature or allow you to change the FOV value to something really high. Very few games that far as I know have bothered actually implementing distortion remedies.

I have set the camera's keep aspect to keep width and POV to 50. Changing the POV solved the issue completely!

Can somebody tell me what code and where (in what file) I need to add to have a keyboard key for switching between full screen and window mode?

L_Main.gd looks like the logical place, since it's already handling other input actions.

You could define a new input action, such as "switch_view", in Project >> Project Settings... >> Input Map.

I don't know offhand what the code would be.

    DaveTheCoder I don't know offhand what the code would be.

    Something like this:

    func _input(event: InputEvent) -> void:
    	if event.is_action_pressed("ui_cancel"):
    		get_tree().quit() # Quits the game
    	
    	if event.is_action_pressed("change_mouse_input"):
    		match Input.get_mouse_mode():
    			Input.MOUSE_MODE_CAPTURED:
    				Input.set_mouse_mode(Input.MOUSE_MODE_VISIBLE)
    			Input.MOUSE_MODE_VISIBLE:
    				Input.set_mouse_mode(Input.MOUSE_MODE_CAPTURED)
    	
    	if event.is_action_pressed("window_toggle_fullscreen"):
    		match get_window().mode:
    			Window.MODE_WINDOWED:
    				get_window().mode = Window.MODE_FULLSCREEN
    			Window.MODE_FULLSCREEN:
    				get_window().mode = Window.MODE_WINDOWED
    			Window.MODE_EXCLUSIVE_FULLSCREEN:
    				#This mode is implemented on Windows only.
    				#On other platforms, it is equivalent to MODE_FULLSCREEN.
    				get_window().mode = Window.MODE_WINDOWED

    This is currently not taking the 'borderless' setting in project settings/window into account. May or may not be relevant. Also better naming scheme for the action so it would be more in line with the built-in actions would have been "wm_toggle_fullscreen" but I figured it would be clearer for the example so I'll leave it as is above. Keys to use could be for an example F11, Enter & KP Enter

    2 years later

    Megalomaniak This is exactly what I'm looking to do right now, but alas, my brain isn't big enough to make it a reality... Thanks for the link to the paper though, I no longer awkwardly need to explain to people what I want.