Commit graph

102 commits

Author SHA1 Message Date
Rémi Verschelde b16c309f82 Update copyright statements to 2019
Happy new year to the wonderful Godot community!
2019-01-01 12:58:10 +01:00
Rémi Verschelde 616beb1041 ProjectManager: Warn when projects have different config_version
When opening projects for edition through the project manager, the
following checks are now done:

1. If the config_version is lower than the one used by the current
   engine version, users are asked if they want to convert to the new
   format or abort editing. Fixes #20626.
2. If the config_version is higher than the expected one (project
   from a more recent and incompatible engine version), projects are
   grayed out and can't be edited. Fixes #18758.

When editing from the command line, the behaviour is unchanged:
projects in situation (1) are automatically converted, while projects
in situation (2) show an error message (made more explicit).

The "Run" option from the project manager was not changed, so it will
still run (1) projects without converting them, and fail running (2)
projects.

Co-authored-by: groud <gilles.roudiere@gmail.com>
2018-12-21 12:45:27 +01:00
Marcelo Fernandez 8dad3811c5 Add application/config/project_settings_override option to override project settings 2018-12-13 18:23:51 -03:00
Rémi Verschelde 1169196f04
Merge pull request #22779 from Superwaitsum/LimitSettings
Limit several project settings
2018-10-25 11:38:06 +02:00
Superwaitsum e5041ad0f5 Add some limits on the Editor Settings 2018-10-24 19:46:33 -05:00
Rémi Verschelde 9d926b72e1 Fix .pck lookup for extensionless binary names with a dot
This was not a problem on Windows as binary names are guaranteed to end
with '.exe', but on Unix systems binary extensions are purely cosmetic
and thus optional, which is a problem when using `get_basename()` to
lookup a potential '.pck' file, as it can fail on e.g. "My Game 2.0" (#15188).

To fix this, ProjectSettings::setup now checks for both basename + '.pck'
and filename + '.pck'.

Fixes #15188, supersedes and closes #22755.

Also took the opportunity to improve documentation on this core method.
2018-10-24 20:11:39 +02:00
Rémi Verschelde 1a16dabfb5
Merge pull request #21982 from luzpaz/misc-typos
Misc. typos
2018-09-13 10:59:00 +02:00
luz.paz 08bde5b2de Misc. typos
Found via `codespell -q 3 -I ../godot-word-whitelist.txt --skip="./thirdparty,*.po"`
2018-09-12 21:39:17 -04:00
Rémi Verschelde 277b24dfb7 Make core/ includes absolute, remove subfolders from include path
This allows more consistency in the manner we include core headers,
where previously there would be a mix of absolute, relative and
include path-dependent includes.
2018-09-12 09:52:22 +02:00
Rémi Verschelde 52466d57e9 Make some debug prints verbose-only, remove others 2018-08-24 14:59:01 +02:00
groud 6ccf3d887c Fixes initialization of action list 2018-08-14 18:44:22 +02:00
Mattias Cibien 4462819e63 Fix main scene file filter 2018-07-26 11:48:12 +02:00
Hein-Pieter van Braam 0e29f7974b Reduce unnecessary COW on Vector by make writing explicit
This commit makes operator[] on Vector const and adds a write proxy to it.  From
now on writes to Vectors need to happen through the .write proxy. So for
instance:

Vector<int> vec;
vec.push_back(10);
std::cout << vec[0] << std::endl;
vec.write[0] = 20;

Failing to use the .write proxy will cause a compilation error.

In addition COWable datatypes can now embed a CowData pointer to their data.
This means that String, CharString, and VMap no longer use or derive from
Vector.

_ALWAYS_INLINE_ and _FORCE_INLINE_ are now equivalent for debug and non-debug
builds. This is a lot faster for Vector in the editor and while running tests.
The reason why this difference used to exist is because force-inlined methods
used to give a bad debugging experience. After extensive testing with modern
compilers this is no longer the case.
2018-07-26 00:54:16 +02:00
Juan Linietsky c69de2ba46 -Project/Editor settings now use new inspector
-Project/Editor settings now show tooltips properly
-Settings thar require restart now will show a restart warning
-Video driver is now visible all the time, can be changed easily
-Added function to request current video driver
2018-07-19 19:02:04 -03:00
matthew1006 25e64ffa20 Fixed OS.has_feature not using custom feature tags. 2018-07-18 09:22:59 +01:00
Juan Linietsky a3f1ee5c57 Global class names (and GDScript support for it) 2018-07-15 19:29:00 -03:00
Benjamin 4cd69e91fc Update resource file project settings on rename 2018-07-03 18:08:41 +02:00
matthew1006 1844704c20 Fixed project settings overrides not using custom feature tags. 2018-06-27 12:37:55 +01:00
Juan Linietsky 5bb412f389
Revert "Make the performance reporting update frequency customizable" 2018-05-28 08:47:09 -03:00
Hugo Locurcio 228ae60a63
Make the performance reporting update frequency customizable
The default update frequency has been changed from 1000ms to 250ms.
2018-05-18 11:49:21 +02:00
Manuel Moos 954f7cca60 Fix #17019 : overrides with unknown base setting
If at the time of the _GLOBAL_DEF call a setting itself was unknown,
the function would always return the supplied default value instead of
checking for overrides. This commit changes that, lookup now always
happens which correctly takes overrides into account.
2018-05-01 16:25:48 +02:00
Gilles Roudiere ebfa731012 Allow actions to provide an analog value 2018-04-16 23:20:43 +02:00
Fabio Alessandrelli c531262190
Merge pull request #16947 from Faless/ui_actions
GUI elements ui_action usage, improvements
2018-03-16 20:55:11 +01:00
robfram ea94a82596 Fix non working action names containing whitespaces
Now the action name is quoted if it contains spaces. Also, quotation
mark (") is added to the forbidden character list for action names, as
it was also a bug.

Fix #17322
2018-03-12 21:28:41 +01:00
Fabio Alessandrelli 920d2bfdfa Add two new default actions ui_end, ui_home
Used by Slider and Scrollbar
2018-02-23 13:01:28 +01:00
Rémi Verschelde 57d562b394 Fix loading project.binary from PCK file
Regression introduced in #16825.
My logic was correct, but not the error code I was expecting.
The error reporting in FileAccess likely needs a review too.
2018-02-21 09:07:59 +01:00
Rémi Verschelde 7839076f95 Improve error reporting of ProjectSettings::setup()
And use it to better report errors in the console and project manager
when a project.godot file is corrupted.

Fixes #14963.
2018-02-19 16:41:43 +01:00
Rémi Verschelde 9f479f096c Fix typos in code and docs with codespell
Using v1.11.0 from https://github.com/lucasdemarchi/codespell
2018-01-18 22:01:42 +01:00
Rémi Verschelde e4213e66b2 Add missing copyright headers and fix formatting
Using `misc/scripts/fix_headers.py` on all Godot files.
Some missing header guards were added, and the header inclusion order
was fixed in the Bullet module.
2018-01-05 01:22:23 +01:00
Rémi Verschelde b50a9114b1 Update copyright statements to 2018
Happy new year to the wonderful Godot community!
2018-01-01 14:40:47 +01:00
Rémi Verschelde af9c67db0c Allow customizing user:// path (folder in OS::get_data_path())
This allows to specify any valid folder name (including with subfolders) to use
as user:// on all platforms. The folder is constrained to the platform-specific
OS::get_data_path() (typically what `XDG_DATA_HOME` resolves to).

Fixes #13236.
2017-11-26 19:02:32 +01:00
Juan Linietsky bc2e8d99e5 Made Vector::ptrw explicit for writing, compiler was sometimes using the wrong function,
leading to unnecesary copy on writes and reduced performance.
2017-11-25 00:09:40 -03:00
Rémi Verschelde 73049d115e Rename OS::get_data_dir to OS::get_user_data_dir
Will be needed to avoid confusion with system data path (XDG_DATA_HOME)
and editor data dir in upcoming refactoring.
2017-11-17 20:55:09 +01:00
Leon Krause 9b7b46143d Move singleton management from ProjectSettings to Engine 2017-11-14 15:15:13 +01:00
Ferenc Arn f3436a841a Add an option to use zstd's recently introduced long range matching (off by default). 2017-10-27 12:26:13 -04:00
BastiaanOlij e9c606fd29 Made directory scan optional 2017-10-10 23:45:54 +11:00
Emmanuel Leblond 80b15fba1d
Fix trailing whitespaces in project settings header comment 2017-10-09 08:34:32 +02:00
Juan Linietsky 3d87b70f7a Added the set/get_setting function in Editor/Project settings. Renamed has() to has_setting. Fixes #11844 2017-10-05 15:34:34 -03:00
Juan Linietsky 3cadecf17b fixed the OS.has_feature() API, and added support for 32 and 64. 2017-10-03 17:36:14 -03:00
letheed 5ad9be4c24 Rename pos to position in user facing methods and variables
Rename user facing methods and variables as well as the corresponding
C++ methods according to the folloming changes:

* pos -> position
* rot -> rotation
* loc -> location

C++ variables are left as is.
2017-09-20 13:11:10 +02:00
Bastiaan Olij 913e5cabbd Fixed naming of pck file 2017-09-17 11:59:56 +10:00
Rémi Verschelde 42504ef0d4 Merge pull request #11062 from BastiaanOlij/osx_datapack
Fixed loading package from resource folder, exporting textures to bun…
2017-09-13 11:11:01 +02:00
geequlim 20442d0a89 Add user data directory support for ProjectSettings::globalize_path 2017-09-10 16:33:54 +08:00
BastiaanOlij 099546ac00 Fixed loading package from resource folder, exporting textures to bundle and added a bit of feedback for a debug compile 2017-09-08 11:39:32 +10:00
Poommetee Ketson ed606ded52 Fix files header 2017-09-01 21:07:55 +07:00
Rémi Verschelde 7ad14e7a3e Dead code tells no tales 2017-08-27 22:13:45 +02:00
Rémi Verschelde bd282ff43f Use HTTPS URL for Godot's website in the headers 2017-08-27 14:16:55 +02:00
Ignacio Etcheverry 2f290038d6 Removes type information from method binds 2017-08-10 07:17:50 +02:00
Bojidar Marinov 7b7c7c8dc0
Rename KEY_RETURN to KEY_ENTER and KEY_ENTER to KEY_KP_ENTER
Closes #7695
2017-08-06 16:26:07 +03:00
Pedro J. Estébanez 1619aabfe1 Fix mutating project.godot
Namely:
- comment block lost on first save;
- config_version doubled as 3 and null on second save;
- format change on first save.
2017-07-26 16:13:38 +02:00
Rémi Verschelde e4fe194fe5 Add newline after config_version and fix custom_features hint
Fixes #9818.
2017-07-25 21:02:38 +02:00
Juan Linietsky 25678b1876 -Renamed GlobalConfig to ProjectSettings, makes more sense.
-Added system for feature overrides, it's pretty cool :)
2017-07-19 17:06:03 -03:00
Renamed from core/global_config.cpp (Browse further)