Commit graph

3392 commits

Author SHA1 Message Date
Rémi Verschelde c4ecec1d33
Merge pull request #32853 from OsamaElHariri/visual_script_setter_props_fix
Set the properties of a Set node after add_node
2019-11-07 13:13:33 +01:00
RevoluPowered 5fb160c7c6 Updated assimp to 308db73 from https://github.com/assimp/assimp/ 2019-11-05 20:38:26 +00:00
RevoluPowered 0bd877780f FBX Importer Generation 3
Basic skin support

Various fixes

- Fixes bind mount id and mesh index
- Fixed duplicate nodes being created
- Prevented leak when instances being freed during re-import.
- Improved camera and light transform import
- skeleton handling and technical debt removal
- ASSIMP: bone nodes were unlinked from bones by this code
- bone_add working can distinguish between armatutes
- Updated transform to be the correct offset
- Added safety for state.root node errors
- Fixed memory leak with leaf bones
- Implemented children re-parenting for mesh template
- import_animation fixes to basic skeleton data
- Adds some more debug messages
- Fixed Godot import segfault
- Fix build failing on mono
- Clear resources we use which are no longer required after import
- Fixed bone duplication issue
- Working skeleton_bone_map which can lookup armatures properly now.
- Fixed stack being used up when mesh swapped & Fixed bone ID

Additional notes:
We use a mesh template which is a fake node to instance the initial
mesh nodes . This is to ensure the entire tree can be built.

We replace mesh node templates with the real mesh after the
skeleton is available, since this makes it ensure that the fully
built skeleton exists with all bones, all nodes, etc.

The bone stack is a stack which pops when it finds bones,
this overcomes duplicate bones with the same names.

FBX has lots of these because animation armature has bone names like bone001
and another armature will also have bone001
Fixed errors in node path assignment

Simple explanation:
- Every mesh uses a node from the stack
- Node stack was empties before completed
- Every time node not found, stack must be rebuilt to maintain correct armature order :)

Additional fixes:
- Fixes destructor in assimp
- Implements aiNode* mArmature in bone data
- Implements aiNode* mParent in bone data
- Fixes parent ID on bones.

Implemented skeleton assignment in generate_mesh_indicies

This is the only place we can safely do a lookup for the skeleton for the mesh.h
I used a pointer reference so we can pass this back out, since the skeleton assignment happens inside the function.

Added mesh re-parenting to the armature node this is a permanent feature and must be enforced, just like GLTF2 specification.

Fixed import_animation spawning tracks per skin
2019-11-05 17:54:57 +00:00
Rémi Verschelde 6dca64140c
Merge pull request #33330 from nekomatata/fix-label-autowrap-size
Fixed cases where labels with autowrap can overflow the editor ui
2019-11-04 16:57:53 +01:00
PouleyKetchoupp 13c88878c4 Fixed cases where labels with autowrap can overflow the editor ui
Fixes #33155
2019-11-04 10:12:36 +01:00
Rémi Verschelde 76aa975460
Merge pull request #33266 from Xrayez/inst2dict-original-path
Use GDScript resource path over script path for `inst2dict`
2019-11-04 08:59:30 +01:00
Rémi Verschelde 0195ecdb0f
Merge pull request #33258 from aaronfranke/color8
Fix Color8 GDScript documentation
2019-11-02 23:08:23 +01:00
bruvzg 047ecffaac
Restore GDNative compatibility by moving new functions introduced in #33210 to core API 1.2 extension. 2019-11-02 15:25:43 +02:00
Andrii Doroshenko (Xrayez) 7f40b69022 Use GDScript resource path over script path for inst2dict
The resource path holds the original path which can be used to convert
a dictionary to instance consistently both within editor and exported projects
as the original path is automatically remapped from `gd` to `gdc` or `gde` in
exported projects.
2019-11-02 15:11:52 +02:00
Aaron Franke b67f252016
Fix Color8 GDScript documentation 2019-11-02 04:48:08 -04:00
Rémi Verschelde af4fd9de9c
Merge pull request #33238 from qarmin/other_fixes
Fix some crashes, overflows and using variables without  values
2019-11-01 22:12:47 +01:00
George Marques 9fcd38fc70
GDScript: validate instance before accessing it on error
Make sure the instance is valid before trying to access the script in
after an error happened. If the instance is not valid it's possible that
the script is invalid as well.

Fix #29623
2019-11-01 14:41:52 -03:00
Rafał Mikrut 9ddb3265e1 Fix some crashes, overflows and using variables without values 2019-11-01 16:16:31 +01:00
Omicron 79a59a3587
Fix: typo atleast -> at least
Typo found in source string, reported by linux-man on weblate
2019-11-01 16:10:21 +01:00
George Marques 15800b4db8
GDScript: Avoid editor crashes when there's cyclic inheritance
Make sure the script is fully compiled before looking into the base.
2019-11-01 12:00:20 -03:00
Rémi Verschelde 962fc725c0
Merge pull request #33210 from nekomatata/pool-array-empty
Added empty() function to pool array types
2019-11-01 14:04:16 +01:00
PouleyKetchoupp 475115c0c3 Added empty() function to pool array types 2019-10-31 16:27:32 +01:00
Andrii Doroshenko (Xrayez) 56925b9c28 Provide and print error messages for JSON parsing
Core is not touched, only for binding and scripting.
2019-10-31 13:15:44 +02:00
PouleyKetchoupp bcbe5b5850 Fixed leak in gdscript when creating empty WeakRef
Fixes #33150
2019-10-29 23:53:56 +01:00
Rémi Verschelde b8daad9779 i18n: Sync translation template with current source 2019-10-29 13:57:45 +01:00
Osama El Hariri 858afd53d8 Set the properties of a Set node after add_node 2019-10-28 21:03:12 +02:00
Rémi Verschelde 63c5cd7eb8
Merge pull request #33104 from qarmin/fix_some_crashes
Fix some crashes and using null pointers
2019-10-28 08:37:59 +01:00
Rafał Mikrut e53e1c566a Fix some crashes and using null pointers 2019-10-28 08:07:29 +01:00
Rémi Verschelde aa0fa6b14f doc: Sync classref with current source 2019-10-26 16:40:41 +02:00
Rémi Verschelde e38fd9a5e6
Merge pull request #32915 from Nehluxhes/gridmap_scaling
Gridmap : Mesh preview now scales + grid update on cell size change
2019-10-25 23:33:11 +02:00
Rémi Verschelde c43c3747cf
Merge pull request #32808 from bojidar-bg/30937-less-strict-mixed-spacing
Allow mixed tabs and spaces when indentation does not depend on tab size
2019-10-25 23:16:04 +02:00
bruvzg 1a0306abb1
Fix missing z_verbose and z_error symbols in debug iOS build. 2019-10-25 15:51:17 +03:00
Bojidar Marinov afbde3314a
Allow mixed tabs and spaces when indentation does not depend on tab size
(hopefully) Closes #30937, fixes #32612
2019-10-25 14:54:57 +03:00
SeleckyErik 61bda112bd Refactor VideoPlayer and VideoStream
VideoStream:
- Fix const correctenss

VideoPlayer:
- Remove unused member variable last_frame
- Move _mix_audios function definition to source file
- Fix function parameter naming to match p_ convention
- Fix const correctness
- Add null checking
2019-10-24 01:35:47 +01:00
Rémi Verschelde e96319c7f3
Merge pull request #32670 from aaronfranke/mono-plane
[Mono] Change Plane intersect methods to return nullable Vector3
2019-10-23 21:44:05 +02:00
Rémi Verschelde 4952e19ad0
Merge pull request #32991 from Chaosus/fix_bug2
Fix gridmap error spam at startup
2019-10-22 20:38:14 +02:00
Rémi Verschelde 365558b8b7
Merge pull request #32969 from Nehluxhes/palette_vanish
Fix gridmap palette remaining invisible
2019-10-22 18:51:11 +02:00
Yuri Roubinsky 51e5bcfc2c Fix gridmap error spam at startup 2019-10-22 18:21:42 +03:00
Rémi Verschelde 8228b93fcd
Merge pull request #32919 from vnen/gdscript-unused-args
Fix wrong counting of function argument usage
2019-10-22 14:15:58 +02:00
Rémi Verschelde e4cfb77961
Merge pull request #32903 from madmiraal/fix-27649-part9
Remove duplicate valid value check in gdscript_tokenizer.cpp.
2019-10-22 13:51:28 +02:00
Rémi Verschelde fddc60c85c
Merge pull request #32878 from EbbDrop/no_autocompletion_for_singeltons
Fixes auto completion for singletons
2019-10-22 13:50:25 +02:00
Rémi Verschelde 10518d5d84
Merge pull request #32893 from Nehluxhes/delete_gridmap
Disable gridmap selection actions when nothing is selected
2019-10-22 12:55:18 +02:00
Nehluxhes d67a9d1a94 Fix gridmap palette remaining invisible 2019-10-21 23:57:23 +02:00
Nehluxhes fa53c0b774 Mesh preview now scales + grid update on cell size change
The mesh preview now correctly scales with cell_scale
Refactor the grids creation into _draw_grids() and call it if the cell_size property is changed
2019-10-21 23:11:30 +02:00
Rémi Verschelde 3564547208
Merge pull request #32750 from Faless/js/fix_ws_refactor
Fix HTML5 build after 67a4c30.
2019-10-21 22:26:33 +02:00
Rémi Verschelde f5dd4d574f
Merge pull request #32863 from JFonS/navmesh_from_group
Add option to create navmesh from objects in group
2019-10-21 16:02:38 +02:00
George Marques 05465b9693
GDScript: Add _ prefix on class name in type compatibility check
This makes sure that the classes internally represented with an
underscore (_) prefix, such as singletons, are still properly checked
for inheritance in the ClassDB.
2019-10-19 13:45:52 -03:00
George Marques bb20e420af
Fix wrong counting of function argument usage
There's no need to subtract 1 from the assignment usages because it's
not incremented anywhere else.

Also put back the assignment with operators because they should not
count as usage if the argument is on the left side.
2019-10-19 10:59:57 -03:00
Marcel Admiraal 5b96233c34 Remove duplicate valid value check in gdscript_tokenizer.cpp. 2019-10-18 11:58:34 +02:00
Nehluxhes 28c274bc27 Disable gridmap selection actions when nothing is selected 2019-10-18 01:45:49 +02:00
EbbDrop f70fd781fc Fix autocompletion for singletons 2019-10-17 10:48:13 +02:00
Fabio Alessandrelli 2bb3e358e0 Trim protocol field from spaces in WS classes. 2019-10-16 16:16:27 +02:00
jfons 298bd3f88a Add option to create navmesh from objects in group
Adds a new NavigationMesh property to select which objects will be taken
into account for the generation.

By default it will use all the NavigationMeshInstance children to keep
compatibility. The new modes allow to build the NavigationMesh from
all the nodes belonging to a specific group, and optionally include
their children too.
2019-10-16 12:01:10 +02:00
Fabio Alessandrelli d75e0de729 Fix HTML5 build after 67a4c30.
I messed up a rebase and a commit was partly skipped
2019-10-15 14:15:02 +02:00
Rémi Verschelde a1033aea51
Merge pull request #32830 from timoschwarzer/remove-redundant-compiler-directives
Remove redundant compiler directives
2019-10-15 09:57:46 +02:00