ProjectSettings¶
Inherits: Object
Contiene variables globales accesibles desde cualquier lugar.
Descripción¶
Contains global variables accessible from everywhere. Use get_setting, set_setting or has_setting to access them. Variables stored in project.godot
are also loaded into ProjectSettings, making this object very useful for reading custom game configuration options.
When naming a Project Settings property, use the full path to the setting including the category. For example, "application/config/name"
for the project name. Category and property names can be viewed in the Project Settings dialog.
Feature tags: Project settings can be overridden for specific platforms and configurations (debug, release, ...) using feature tags.
Overriding: Any project setting can be overridden by creating a file named override.cfg
in the project's root directory. This can also be used in exported projects by placing this file in the same directory as the project binary. Overriding will still take the base project settings' feature tags in account. Therefore, make sure to also override the setting with the desired feature tags if you want them to override base project settings on all platforms and configurations.
Tutoriales¶
Propiedades¶
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
rendering/batching/parameters/colored_vertex_format_threshold |
|
|
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
rendering/limits/buffers/canvas_polygon_index_buffer_size_kb |
|
|
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
rendering/quality/intended_usage/framebuffer_allocation.mobile |
|
|
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
rendering/quality/reflections/texture_array_reflections.mobile |
|
|
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
Métodos¶
void |
add_property_info ( Dictionary hint ) |
void |
|
get_setting ( String name ) const |
|
globalize_path ( String path ) const |
|
has_setting ( String name ) const |
|
load_resource_pack ( String pack, bool replace_files=true, int offset=0 ) |
|
localize_path ( String path ) const |
|
property_can_revert ( String name ) |
|
property_get_revert ( String name ) |
|
save ( ) |
|
save_custom ( String file ) |
|
void |
set_initial_value ( String name, Variant value ) |
void |
|
void |
set_setting ( String name, Variant value ) |
Descripciones de Propiedades¶
String android/modules
Default |
|
Comma-separated list of custom Android modules (which must have been built in the Android export templates) using their Java package path, e.g. "org/godotengine/godot/MyCustomSingleton,com/example/foo/FrenchFriesFactory"
.
Note: Since Godot 3.2.2, the org/godotengine/godot/GodotPaymentV3
module was deprecated and replaced by the GodotPayment
plugin which should be enabled in the Android export preset under Plugins
section. The singleton to access in code was also renamed to GodotPayment
.
Color application/boot_splash/bg_color
Default |
|
Color de fondo para la imagen de arranque.
bool application/boot_splash/fullsize
Default |
|
If true
, scale the boot splash image to the full window size (preserving the aspect ratio) when the engine starts. If false
, the engine will leave it at the default pixel size.
String application/boot_splash/image
Default |
|
Path to an image used as the boot splash. If left empty, the default Godot Engine splash will be displayed instead.
Note: Only effective if application/boot_splash/show_image is true
.
bool application/boot_splash/show_image
Default |
|
If true
, displays the image specified in application/boot_splash/image when the engine starts. If false
, only displays the plain color specified in application/boot_splash/bg_color.
bool application/boot_splash/use_filter
Default |
|
If true
, applies linear filtering when scaling the image (recommended for high-resolution artwork). If false
, uses nearest-neighbor interpolation (recommended for pixel art).
String application/config/custom_user_dir_name
Default |
|
Este directorio de usuario se utiliza para almacenar datos persistentes (sistema de archivos user://
). Si se deja vacío, user://
se resuelve en una carpeta específica del proyecto en la propia carpeta de configuración de Godot (véase OS.get_user_data_dir). Si se define un nombre de directorio personalizado, este nombre se utilizará en su lugar y se añadirá al directorio de datos de usuario específico del sistema (la misma carpeta principal que la carpeta de configuración de Godot documentada en OS.get_user_data_dir).
El ajuste application/config/use_custom_user_dir debe estar activado para que esto surta efecto.
String application/config/description
Default |
|
La descripción del proyecto, que se muestra como una sugerencia en el Administrador de Proyectos cuando se pasa el cursor por encima del proyecto.
String application/config/icon
Default |
|
Icono utilizado para el proyecto, establecido cuando el proyecto se carga. Los exportadores también usarán este icono cuando sea posible.
String application/config/macos_native_icon
Default |
|
Icon set in .icns
format used on macOS to set the game's icon. This is done automatically on start by calling OS.set_native_icon.
String application/config/name
Default |
|
The project's name. It is used both by the Project Manager and by exporters. The project name can be translated by translating its value in localization files. The window title will be set to match the project name automatically on startup.
Note: Changing this value will also change the user data folder's path if application/config/use_custom_user_dir is false
. After renaming the project, you will no longer be able to access existing data in user://
unless you rename the old folder to match the new project name. See Data paths in the documentation for more information.
String application/config/project_settings_override
Default |
|
Specifies a file to override project settings. For example: user://custom_settings.cfg
. See "Overriding" in the ProjectSettings
class description at the top for more information.
Note: Regardless of this setting's value, res://override.cfg
will still be read to override the project settings.
bool application/config/use_custom_user_dir
Default |
|
Si true
, el proyecto guardará los datos de los usuarios en su propio directorio de usuarios (véase application/config/custom_user_dir_name). Esta configuración sólo es efectiva en las plataformas de escritorio. Se debe establecer un nombre en el parámetro application/config/custom_user_dir_name para que esto tenga efecto. Si false
, el proyecto guardará los datos del usuario en (directorio de datos de usuario del sistema operativo)/Godot/app_userdata/(nombre del proyecto)
.
Default |
|
If true
, the project will use a hidden directory (.import
) for storing project-specific data (metadata, shader cache, etc.).
If false
, a non-hidden directory (import
) will be used instead.
Note: Restart the application after changing this setting.
Note: Changing this value can help on platforms or with third-party tools where hidden directory patterns are disallowed. Only modify this setting if you know that your environment requires it, as changing the default can impact compatibility with some external tools or plugins which expect the default .import
folder.
String application/config/windows_native_icon
Default |
|
Icon set in .ico
format used on Windows to set the game's icon. This is done automatically on start by calling OS.set_native_icon.
bool application/run/delta_smoothing
Default |
|
Time samples for frame deltas are subject to random variation introduced by the platform, even when frames are displayed at regular intervals thanks to V-Sync. This can lead to jitter. Delta smoothing can often give a better result by filtering the input deltas to correct for minor fluctuations from the refresh rate.
Note: Delta smoothing is only attempted when display/window/vsync/use_vsync is switched on, as it does not work well without V-Sync.
It may take several seconds at a stable frame rate before the smoothing is initially activated. It will only be active on machines where performance is adequate to render frames at the refresh rate.
bool application/run/delta_sync_after_draw
Default |
|
Experimental. Shifts the measurement of delta time for each frame to just after the drawing has taken place. This may lead to more consistent deltas and a reduction in frame stutters.
bool application/run/disable_stderr
Default |
|
If true
, disables printing to standard error. If true
, this also hides error and warning messages printed by @GDScript.push_error and @GDScript.push_warning. See also application/run/disable_stdout.
Changes to this setting will only be applied upon restarting the application.
bool application/run/disable_stdout
Default |
|
If true
, disables printing to standard output. This is equivalent to starting the editor or project with the --quiet
command line argument. See also application/run/disable_stderr.
Changes to this setting will only be applied upon restarting the application.
bool application/run/flush_stdout_on_print
Default |
|
If true
, flushes the standard output stream every time a line is printed. This affects both terminal logging and file logging.
When running a project, this setting must be enabled if you want logs to be collected by service managers such as systemd/journalctl. This setting is disabled by default on release builds, since flushing on every printed line will negatively affect performance if lots of lines are printed in a rapid succession. Also, if this setting is enabled, logged files will still be written successfully if the application crashes or is otherwise killed by the user (without being closed "normally").
Note: Regardless of this setting, the standard error stream (stderr
) is always flushed when a line is printed to it.
Changes to this setting will only be applied upon restarting the application.
bool application/run/flush_stdout_on_print.debug
Default |
|
Debug build override for application/run/flush_stdout_on_print, as performance is less important during debugging.
Changes to this setting will only be applied upon restarting the application.
int application/run/frame_delay_msec
Default |
|
Fuerza un retardo entre fotogramas en el bucle principal (en milisegundos). Esto puede ser útil si planea deshabilitar la sincronización vertical.
bool application/run/low_processor_mode
Default |
|
Si true
, habilita el modo de uso del procesador bajo. Esta configuración sólo funciona en plataformas de escritorio. La pantalla no se redibuja si nada cambia visualmente. Esto está pensado para escribir aplicaciones y editores, pero es bastante inútil (y puede perjudicar el rendimiento) en la mayoría de los juegos.
int application/run/low_processor_mode_sleep_usec
Default |
|
Cantidad de sueño entre fotogramas cuando se activa el modo de uso del procesador bajo (en microsegundos). Valores más altos resultarán en un menor uso de la CPU.
String application/run/main_scene
Default |
|
Ruta al archivo de la escena principal que se cargará cuando se ejecute el proyecto.
float audio/channel_disable_threshold_db
Default |
|
Los buses de audio se desactivarán automáticamente cuando el sonido baje de un determinado umbral de dB durante un tiempo determinado. Esto ahorra a la CPU ya que los efectos asignados a ese bus ya no harán ningún tipo de procesamiento.
float audio/channel_disable_time
Default |
|
Los buses de audio se desactivarán automáticamente cuando el sonido baje de un determinado umbral de dB durante un tiempo determinado. Esto ahorra a la CPU ya que los efectos asignados a ese bus ya no harán ningún tipo de procesamiento.
String audio/default_bus_layout
Default |
|
Archivo de recursos AudioBusLayout por defecto para usar en el proyecto, a menos que sea sobreescrito por la escena.
String audio/driver
Especifica el controlador de audio a utilizar. Esta configuración depende de la plataforma, ya que cada plataforma admite diferentes controladores de audio. Si se deja en blanco, se utilizará el controlador de audio predeterminado.
bool audio/enable_audio_input
Default |
|
Si true
, se permitirá la entrada del micrófono. Esto requiere que se establezcan los permisos apropiados al exportar a Android o iOS.
int audio/mix_rate
Default |
|
The mixing rate used for audio (in Hz). In general, it's better to not touch this and leave it to the host operating system.
int audio/mix_rate.web
Default |
|
Safer override for audio/mix_rate in the Web platform. Here 0
means "let the browser choose" (since some browsers do not like forcing the mix rate).
int audio/output_latency
Default |
|
Specifies the preferred output latency in milliseconds for audio. Lower values will result in lower audio latency at the cost of increased CPU usage. Low values may result in audible cracking on slower hardware.
Audio output latency may be constrained by the host operating system and audio hardware drivers. If the host can not provide the specified audio output latency then Godot will attempt to use the nearest latency allowed by the host. As such you should always use AudioServer.get_output_latency to determine the actual audio output latency.
Note: This setting is ignored on Windows.
int audio/output_latency.web
Default |
|
Sobreescritura más segura para audio/output_latency en la plataforma web, para evitar problemas de audio especialmente en los dispositivos móviles.
int audio/video_delay_compensation_ms
Default |
|
Ajustar el retardo de audio hardcode cuando se reproduce el video. Es mejor dejar esto intacto a menos que sepas lo que estás haciendo.
int compression/formats/gzip/compression_level
Default |
|
El nivel de compresión por defecto para el gzip. Afecta a las escenas y recursos comprimidos. Los niveles más altos dan como resultado archivos más pequeños a costa de la velocidad de compresión. La velocidad de descompresión no se ve afectada por el nivel de compresión. -1
utiliza el nivel de compresión predeterminado de gzip, que es idéntico al de 6
pero podría cambiar en el futuro debido a las actualizaciones subyacentes de zlib.
int compression/formats/zlib/compression_level
Default |
|
El nivel de compresión por defecto para Zlib. Afecta a las escenas y recursos comprimidos. Los niveles más altos dan como resultado archivos más pequeños a costa de la velocidad de compresión. La velocidad de descompresión no se ve afectada por el nivel de compresión. -1
utiliza el nivel de compresión predeterminado de gzip, que es idéntico al de 6
pero podría cambiar en el futuro debido a las actualizaciones subyacentes de zlib.
int compression/formats/zstd/compression_level
Default |
|
El nivel de compresión por defecto para Zstandard. Afecta a las escenas y recursos comprimidos. Los niveles más altos dan como resultado archivos más pequeños a costa de la velocidad de compresión. La velocidad de descompresión no se ve afectada por el nivel de compresión.
bool compression/formats/zstd/long_distance_matching
Default |
|
Habilita la coincidencia a larga distancia en Zstandard.
int compression/formats/zstd/window_log_size
Default |
|
Límite de tamaño más grande (en potencia de 2) permitido cuando se comprime usando la correspondencia a larga distancia con Zstandard. Valores más altos pueden resultar en una mejor compresión, pero requerirán más memoria al comprimir y descomprimir.
bool debug/gdscript/completion/autocomplete_setters_and_getters
Default |
|
Si true
, muestra los resultados de getters y setters en autocompletado en el editor de scripts. Esta configuración está pensada para ser usada cuando se portan proyectos antiguos (Godot 2), ya que el uso de variables de miembros es el estilo preferido a partir de Godot 3.
bool debug/gdscript/warnings/constant_used_as_function
Default |
|
Si true
, habilita las advertencias cuando se utiliza una constante como función.
bool debug/gdscript/warnings/deprecated_keyword
Default |
|
If true
, enables warnings when deprecated keywords such as slave
are used.
bool debug/gdscript/warnings/enable
Default |
|
Si true
, habilita advertencias específicas de GDScript (véase la configuración de debug/gdscript/warnings/*
). Si false
, desactiva todas las advertencias de GDScript.
bool debug/gdscript/warnings/exclude_addons
Default |
|
Si true
, los scripts de la carpeta res://addons
no generarán advertencias.
bool debug/gdscript/warnings/function_conflicts_constant
Default |
|
If true
, enables warnings when a function is declared with the same name as a constant.
bool debug/gdscript/warnings/function_conflicts_variable
Default |
|
If true
, enables warnings when a function is declared with the same name as a variable. This will turn into an error in a future version when first-class functions become supported in GDScript.
bool debug/gdscript/warnings/function_may_yield
Default |
|
If true
, enables warnings when a function assigned to a variable may yield and return a function state instead of a value.
bool debug/gdscript/warnings/function_used_as_property
Default |
|
Si true
, habilita las advertencias cuando se utiliza una función como si fuera una propiedad.
bool debug/gdscript/warnings/incompatible_ternary
Default |
|
Si true
, habilita advertencias cuando un operador ternario puede emitir valores con tipos incompatibles.
bool debug/gdscript/warnings/integer_division
Default |
|
Si true
, habilita las advertencias al dividir un entero por otro entero (la parte decimal será descartada).
bool debug/gdscript/warnings/narrowing_conversion
Default |
|
Si true
, habilita las advertencias al pasar un valor de real a una función que espera un número entero (se convertirá y perderá precisión).
bool debug/gdscript/warnings/property_used_as_function
Default |
|
Si true
, habilita las advertencias cuando se utiliza una propiedad como si fuera una función.
bool debug/gdscript/warnings/return_value_discarded
Default |
|
Si true
, habilita advertencias cuando se llama a una función sin utilizar su valor de retorno (asignándolo a una variable o utilizándolo como argumento de la función). Esos valores de retorno se utilizan a veces para denotar posibles errores mediante el uso de enum Error.
bool debug/gdscript/warnings/shadowed_variable
Default |
|
Si true
, habilita las advertencias al definir una variable miembro local o de subclase que ensombrecería una variable en un nivel superior (como una variable miembro).
bool debug/gdscript/warnings/standalone_expression
Default |
|
Si true
, permite advertencias cuando se llama a una expresión que no tiene efecto en el código circundante, como escribir 2 + 2
como una declaración.
bool debug/gdscript/warnings/standalone_ternary
Default |
|
Si true
, habilita advertencias cuando se llama a una expresión ternaria que no tiene efecto en el código circundante, como escribir 42 si está activo o 0
como una declaración.
bool debug/gdscript/warnings/treat_warnings_as_errors
Default |
|