Commit Graph

1733 Commits

Author SHA1 Message Date
George Marques 3cec24baa8
Fix positive operator in GDScript compiler 2018-05-23 17:43:56 -03:00
Kelly Thomas b335274bcd mono: add Slerp method to vector classes, expose Cross method for Vector2, and fix unnecessary casts in Basis 2018-05-22 08:27:49 +08:00
Kelly Thomas c7e98eef67 Fix index out of range error in string.Extension() 2018-05-21 18:48:53 +08:00
Carter Anderson 56262ceafe Reduce allocations when converting mono arrays to pool arrays 2018-05-20 18:18:06 -07:00
Rémi Verschelde 228b09bafb
Merge pull request #18974 from KellyThomas/c-sharp-feature-parity-basis
Mono: Basis constructor for euler parameter
2018-05-18 21:09:57 +02:00
Ignacio Etcheverry fc90f41f53
Merge pull request #18975 from KellyThomas/c-sharp-feature-parity-color
mono: New Color methods:  Darkened, Lightened and ToRgba32
2018-05-18 20:09:01 +02:00
Kelly Thomas 16e1b4bacf mono: Plane, expose Normal, and D 2018-05-17 23:04:20 +08:00
Kelly Thomas 88bd33f451 mono: New Color methods: Darkened, Lightened and ToRgba32 2018-05-17 21:41:19 +08:00
Kelly Thomas c26d30986a Mono: Basis constructor for euler parameter 2018-05-17 21:31:14 +08:00
Michele Valente 6c74f3de6d fixes build error on Linux after its introduction in #18949
The function expects now a return value. Returning NULL seems to work in
this case.
2018-05-17 11:34:05 +02:00
Rémi Verschelde b0649d2718
Merge pull request #18405 from flashyincceo/gdscript-constants-help
Fix Ctrl+click on @GDScript constants
2018-05-17 09:36:55 +02:00
Rémi Verschelde c3510cd981
Merge pull request #18949 from neikeq/alo
Mono: Project building fixes
2018-05-17 08:33:54 +02:00
Ignacio Etcheverry 01397a10d9 Mono: Project building fixes
- Set (Csc/Vbc/Fsc)ToolExe environment variables to point to the batch files in Mono's bin directory when building with Mono's MSBuild.
- Set Mono's MSBuild as the default build tool on Windows.
- Generate projects with portable DebugType instead of full.
2018-05-17 01:26:23 +02:00
Ignacio Etcheverry 41f79a6f14
Merge pull request #18889 from madadam/async-await-fix
Set current SynchronizationContext before the game loop starts
2018-05-16 23:44:55 +02:00
Guilherme Felipe 35024d4e7b Add missing copyright headers 2018-05-16 14:50:44 -03:00
Juan Linietsky dfd1331690 Allow editing of some unbound properties when hinted (or no range hinted) 2018-05-16 09:13:41 -03:00
Rémi Verschelde dfee637ff9
Merge pull request #18897 from volzhs/libwebp-1.0.0
Update libwebp to 1.0.0
2018-05-16 02:31:01 +02:00
Juan Linietsky 005b69cf6e -New inspector.
-Changed UI resizing code, gained huge amount of speed.
-Reorganized timer sync to clean up behavior (sorry forgot commit this before)

-
2018-05-15 17:14:31 -03:00
volzhs 6ed8124923 Update libwebp to 1.0.0 2018-05-16 01:00:55 +09:00
Adam Cigánek f25240cfe6 Set current SynchronizationContext before the game loop starts
This fixes the problem that `SynchronizationContext.Current` would be null
during the call to `_EnterTree`, `_Ready` and the first call to `_Process` thus
the task continuations would be scheduled outside the main thread, which is unexpected and might lead to crashes.

With this change, task continuations are scheduled always on the main thread and so async/await can be used without any explicit synchronization, which is what is expected.

Fixes #18849
2018-05-15 15:09:40 +02:00
Juan Linietsky 47d4a011d8
Merge pull request #18545 from vnen/editor-autoload
Enable autoload in editor
2018-05-14 17:59:34 -03:00
Leon Krause b8c35b4078 Fix duplicate definitions with FreeType 2018-05-13 15:20:05 +02:00
Fabio Alessandrelli f95e4c72df Expose channels in NetworkedMultiplayerENet 2018-05-12 23:51:58 +02:00
Rémi Verschelde 9af5cab32e
Merge pull request #18802 from bruvzg/fix_x11_arm_build
Fix X11 build on ARM Linux
2018-05-12 09:39:51 +02:00
Rémi Verschelde 3d9deda8b3 Sync classref with current source 2018-05-12 09:38:00 +02:00
bruvzg ce64c2a32e
Fix Linux/X11 build on ARMs. 2018-05-11 17:34:43 +03:00
Pieter-Jan Briers 27d70924a0 Fixes ObjectDB leak printout with mono.
Fixes #18767
2018-05-11 13:50:56 +02:00
karroffel 70866bbafd changed GDNative API json format 2018-05-10 22:03:06 +02:00
Rémi Verschelde 919d802e66
Merge pull request #18183 from Paulb23/gdscript_highlighter_inital_changes
GDScript function definition and get_node shortcut syntax highlighting
2018-05-10 01:25:51 +02:00
Marcelo Fernandez e64bbcc429 Fix some enums missing its bind 2018-05-08 21:14:31 -03:00
Max Hilbrunner e744d12e56
Merge pull request #18709 from Faless/multiplayer_docs
Rename multiplayer_api to multiplayer, add docs
2018-05-09 01:41:01 +02:00
Pedro J. Estébanez 474eda9e30 Fix Variant leak in call_native 2018-05-08 21:27:33 +02:00
Fabio Alessandrelli dd546dc5b8 Document websocket module, further document enet 2018-05-08 21:15:50 +02:00
Juan Linietsky b190afe084
Merge pull request #15549 from SaracenOne/bmp
BMP module
2018-05-08 10:46:13 -03:00
Rémi Verschelde de9683b605
Merge pull request #17559 from simedis/joint_motors
Implemented interface for bullet linear motors
2018-05-08 10:23:41 +02:00
Juan Linietsky 299d8a80ba
Merge pull request #16106 from poke1024/gdscript-lerp
GDScript: generalize lerp
2018-05-07 20:36:31 -03:00
Juan Linietsky ff1e7cfbf4 Add is_instance_valid() method to GDScript, ending more than a decade of pain. 2018-05-07 17:30:03 -03:00
AndreaCatania 9e57a07fb6 Implemented ragdoll
Implementing ragdoll

Implementing ragdoll

Implementing ragdoll

Implementing ragdoll

Implementing ragdoll

a

Implemented implicit hierarchy.

Improved

Added some physics properties

Added bone offset to preserve COM, partially fixed scaling

work in progress

WIP

wip

Implemented Joint Gizmos

Implemented pin joint joint

Implemented all joints
2018-05-07 21:03:16 +02:00
mhilbrunner ba4600757a Enet: Add wait time param to close_connection()
Enet: Allow to set client interface/address and port

Enet: More error checks

Fix comment
2018-05-07 01:37:15 +02:00
Kelly thomas a6bd2c6e72 round / ceil methods for c sharp vectors 2018-05-04 20:17:10 +08:00
Max Hilbrunner ffb6f8f1ca
Merge pull request #18406 from YeldhamDev/script_templates_period
Changed periods in the script templates
2018-05-04 11:20:16 +02:00
Rémi Verschelde 460e551ddf
Merge pull request #16418 from bojidar-bg/15961-gdscript-array-export
Allow exporting arrays of resources in GDScript
2018-05-03 21:19:15 +02:00
Juan Linietsky f056b09f5a
Merge pull request #18589 from karroffel/oahashmap-robinhood
updated OAHashMap to use robinhood hashing
2018-05-03 14:47:07 -03:00
karroffel bf24d570bb updated OAHashMap to use robinhood hashing 2018-05-03 17:00:21 +02:00
Rémi Verschelde b774156729
Merge pull request #18514 from neikeq/api-hash-fixes
API hash fixes
2018-05-03 14:36:32 +02:00
Ignacio Etcheverry a02fec47a0
Merge pull request #18562 from neikeq/issue-18526
Fix MSVC check when building with mono
2018-05-02 18:24:57 +02:00
Michael Alexsander Silva Dias 093b069bf6 Changed periods in the script templates. 2018-05-02 11:42:09 -03:00
Ignacio Etcheverry a1aa98e05a Fix MSVC check when building with mono 2018-05-02 15:19:02 +02:00
Ignacio Etcheverry c0192e405d
Merge pull request #18561 from neikeq/fix-find-msbuild-2
Fix editor detecting msbuild with a msvc 'tools only' install
2018-05-02 15:13:44 +02:00
Ignacio Etcheverry 93d13bee8b Fix editor detecting msbuild with a msvc 'tools only' install 2018-05-02 15:06:25 +02:00
Rémi Verschelde d33308921d
Merge pull request #18553 from bzztbomb/fix/stack_underflow_when_debuggin_in_release
Fix a crash when trying to run Godot debugger on a release build.
2018-05-02 10:48:45 +02:00
Rémi Verschelde b0cf3628aa
Merge pull request #18452 from flashyincceo/enum-no-class
Fix enums without class name not opening docs page
2018-05-02 10:32:19 +02:00
Rémi Verschelde fb917b5568
Merge pull request #18531 from KidRigger/issue5972
Adds keywords to autocomplete predictions.
2018-05-02 10:22:08 +02:00
Brian Richardson 9149b11973 Fix a crash when trying to run Godot debugger on a release build.
The GDScriptLanguage::enter_function is wrapped in #ifdef DEBUG but the exit_function is not, resulting in a stack underflow error.
2018-05-01 15:40:30 -07:00
Rémi Verschelde de97339a2d
Merge pull request #18291 from akien-mga/coverity-uninitialized-scalar-var
Fix Coverity reports of uninitialized scalar variable
2018-05-01 19:14:07 +02:00
George Marques decf178033
Enable autoload in editor
- Tool scripts will be executed and can be accessed by plugins.
- Other script languages can implement add/remove_named_global_constant
to make use of this functionality.
2018-05-01 11:44:08 -03:00
Peter Folkins ccd986f53e Fix enums without class name not opening docs page 2018-05-01 07:57:53 -05:00
Zumo ef74954e66 Fully exposes data variable on AudioStreamSample/AudioStreamOGGVorbis...
...and also changes "_set_data" and "_get_data" to "set_data" and "get_data" respectively.
2018-05-01 12:19:15 +02:00
Rémi Verschelde 9834b690ae
Merge pull request #18334 from Faless/coverity_net
Various coverity scan fixes, WS FreeBSD fixes
2018-05-01 08:44:11 +02:00
Rémi Verschelde 4cce6f3417
Merge pull request #18321 from Crazy-P/Fixes-logically-dead-code
Fixes logically dead code (Coverity)
2018-05-01 08:35:10 +02:00
Anish 6e32157a65 Adds keywords to autocomplete predictions.
Adds keywords to the autocomplete prediction in GDScript so
they are not replaced by irrelevant predictions.

Fixes: #5972
2018-05-01 11:48:16 +05:30
Pieter-Jan Briers 99e871f45f More stuff! 2018-05-01 00:39:28 +02:00
Max Hilbrunner 813acef973
Merge pull request #18523 from hpvb/fix-clang-lto
Fix lto builds on clang compilers
2018-04-30 17:12:13 +02:00
Hein-Pieter van Braam cee5117d3b Fix lto builds on clang compilers
The --no-lto option only works on GCC compilers. This breaks LTO builds
on MacOS and iPhone when building the gdnative wrappers.

-fno-lto works on both brands of compilers.
2018-04-30 12:59:08 +02:00
Hein-Pieter van Braam 0ec912a79e Fix msbuild with a msvc 'tools only' install
Taken from https://github.com/Microsoft/vswhere/wiki/Find-MSBuild
without '-products *' vswhere does not locate msbuild when installing a
tools-only (no IDE) version of the microsoft compilers.
2018-04-30 12:52:18 +02:00
Saracen e30b0656e8 BMP module 2018-04-30 01:33:14 +01:00
Pieter-Jan Briers 8d9d847a1a Move things into the title bars of Visual Script nodes.
This is an attempt to make VS slightly nicer to use.

WiP.
2018-04-30 01:28:31 +02:00
Ignacio Etcheverry 7034d48032 Fix binding some core API methods only in tools builds 2018-04-29 19:49:26 +02:00
Ignacio Etcheverry fbc808012f Mono: BindingsGenerator enum fixes
- Make enums have an unique signature name of int. This means that when generating internal methods, there is no difference between different enums types nor between enums and int. This way enums can re-use internal methods.
- Make type resolver fallback to int if a type is not found and it's an enum.
2018-04-28 22:25:25 +02:00
Juan Linietsky 1226720c01 Add poly triangulation order check, ensures faces do not flip on different order 2018-04-28 12:59:45 -03:00
Juan Linietsky f8520dbba7 -Changed how operators work, any shape can operate on any other
-Added some break condition for bad poly data to avoid editor freezes
2018-04-28 12:33:23 -03:00
Juan Linietsky ec7ed5f360 Avoid CSG freeze condition on degenerates 2018-04-28 09:47:16 -03:00
Juan Linietsky c4d0f528b1 Do not crash if the polygon is invalid 2018-04-28 08:53:27 -03:00
Juan Linietsky afb4ce8d2d Reduce false positives in interior detection by adding a small offset to raycast, fixes #18476 2018-04-28 08:16:26 -03:00
Juan Linietsky 8d199a9b2c CSG Support for Godot!
-Missing Icons
-Missing freezing option (for baking light and faster load)
-Missing a way to export from Godot (GLTF2?)
-Probably buggy (may freeze editor, can be worked around easily, but let me know if this happens so it's easier to catch bugs)
Happy testing!
2018-04-27 21:55:10 -03:00
Ignacio Etcheverry b5e6e142ef Add option to link mono statically on Windows 2018-04-25 21:15:35 +02:00
Peter Folkins 825d49dfe2 Fix Ctrl+click on @GDScript constants 2018-04-24 20:50:21 -05:00
Ignacio Etcheverry 6faa96fb89
Merge pull request #18399 from neikeq/u
Mono fixes
2018-04-24 20:58:25 +02:00
Ignacio Etcheverry ff7fe9e771 Mono: Fix '!t' error messages when generating bindings
This error wasn't affecting the bindings generation process.
2018-04-24 20:47:06 +02:00
Ignacio Etcheverry f8ce412560 Mono: Do not spam script class not found error
Print this error only when trying to instantiate the script. This way we prevent errors being printed for source files which are not meant to be used as scripts.
2018-04-24 20:46:57 +02:00
Ignacio Etcheverry 89e84185e8 Mono: Fix crash on script load if the scripts domain isn't loaded 2018-04-24 20:46:53 +02:00
Hugo Locurcio 1c419531a0 Change ".." punctuation for "..." in editor strings (#16507) 2018-04-22 19:36:01 +02:00
Crazy-P e6deba8d19 Fixes logically dead code (Coverity)
Fixes reported logically dead codes by Coverity

* image.cpp: Doesn't really need any modification. But to remove the bug
report then we have to move the MAX call away from the for loop
statement.

* rasterizer_gles3.cpp: Removes unnecessary elif condition since it is
checked earlier in the function

* collada.cpp: If stamement never reached due to macro ERR_CONTINUE does
the same.

* navigation_mesh.cpp: Variables should always be null - however, also
checked for the very same condition in their function call. Leaving this
for review (whether the function call is necessary or not)

* path_editor_plugin.cpp: If cancel is true, then it should restore the
edited value to the original provided.
http://docs.godotengine.org/en/3.0/classes/class_editorspatialgizmo.html#class-editorspatialgizmo-commit-handle

* spatial_editor_gizmos.cpp: the very condition of i >= 3 is
predetermined in the if case right before it. Thus case 1 is always '1'
and case 2 is always '-1'

* grid_map_editor.cpp: Same as above in spatial_editor_gizmos.cpp

* voxel_light_baker.cpp: Same as above in spatial_editor_gizmos.cpp

* visual_server.cpp: Same as above in spatial_editor_gizmos.cpp

* visual_script_expression.cpp: char '-' is already true in the switch
case mechanism. Thus it can never reach to default case.

* particles.cpp: Case 'PARAM_MAX' is unreachable due to index checking
right before the switch execution.

* shader_language.cpp: Invalid index is handled in switch default case.
`type < TYPE_FLOAT && type > TYPE_VEC4` -> `(type < TYPE_FLOAT || type > TYPE_VEC4`)
Fixes the "always false problem" in TODO comment.
2018-04-21 22:35:23 +08:00
Fabio Alessandrelli 03bf783f3c Various coverity scan fixes for networking
Fix FreeBSD websocket compilation error
2018-04-21 15:36:41 +02:00
Paulb23 adeed58477 Added GDScript NodePath highlighting 2018-04-20 21:00:07 +01:00
Paulb23 4cd16f6ba9 Added GDScript function definition highlighting 2018-04-20 20:54:31 +01:00
Paulb23 28dfc7f915 GDScript highlighter now remembers previous state 2018-04-20 20:46:08 +01:00
Paulb23 c3d93edf3d Exclude GDScriptSyntaxHighlighter from non-tool builds 2018-04-20 20:45:57 +01:00
Rémi Verschelde df79cc86a5
Merge pull request #18119 from sheepandshepherd/nativescript_property_list
Fix NativeScript property list order
2018-04-19 21:37:46 +02:00
Rémi Verschelde bf7ca623a6 Fix Coverity reports of uninitialized scalar variable
Fixes most current reports on Coverity Scan of uninitialized scalar
variable (CWE-457): https://cwe.mitre.org/data/definitions/457.html

These happen most of the time (in our code) when instanciating structs
without a constructor (or with an incomplete one), and later returning
the instance. This is sometimes intended though, as some parameters are
only used in some situations and should not be double-initialized for
performance reasons (e.g. `constant` in ShaderLanguage::Token).
2018-04-19 15:20:45 +02:00
Rémi Verschelde 3018132244
Merge pull request #18204 from tagcup/quat_scale
Avoid converting Quat to Euler angles when not necessary.
2018-04-18 13:55:35 +02:00
Rémi Verschelde 952f7d71aa
Merge pull request #18142 from AndreaCatania/coverity1
Removed useless check
2018-04-18 12:49:47 +02:00
Xavier Cho 6b611e6431 #18051: Fix indentation issues introduced during clean up 2018-04-17 07:53:27 +09:00
Xavier Cho e59fad3924 #18051: Do not use `var` in a for-loop, or where type is not obvious 2018-04-17 07:39:37 +09:00
Xavier Cho 94edd92248 #18051: Use common name for Color type argument 2018-04-17 07:39:37 +09:00
Xavier Cho f0bf5532fa #18051: Remove redundant verbatim prefixes 2018-04-17 07:39:37 +09:00
Xavier Cho 85787776a5 #18051: Use default parameter value 2018-04-17 07:39:37 +09:00
Xavier Cho b765c051cb #18051: Use array initializer when applicable 2018-04-17 07:39:37 +09:00
Xavier Cho 9097c71255 #18051: Remove redundant parenthesis 2018-04-17 07:39:37 +09:00
Xavier Cho 93dd59d763 #18051: Remove unnecessary variable assignments 2018-04-17 07:39:37 +09:00