How to change graphics options with GDScript (3D)

:information_source: Attention Topic was automatically imported from the old Question2Answer platform.
:bust_in_silhouette: Asked By Liemaeu

How can you change graphics options (anti-aliasing, texture quality, etc.) of a 3D game with GDScript?
(It must work in the exported game, not only in the Godot editor.)

:bust_in_silhouette: Reply From: Calinou

Most graphics settings can be changed at run-time by calling methods in VisualServer or modifying properties in the Environment resource currently in use. See this script for an example.

Godot supports shrinking all textures by a 2× factor, but keep in mind this also affects 2D elements. Note that texture quality generally doesn’t impact FPS noticeably, so I would leave it as-is at first.

I don’t understand how to connect the code. I’m new

Djukati | 2021-03-17 14:57