Commit graph

223 commits

Author SHA1 Message Date
Juan Linietsky 5b3709d309 Removal of InputEvent as built-in Variant type..
this might cause bugs I haven't found yet..
2017-05-20 17:05:38 -03:00
Juan Linietsky 98a3296702 Removal of Image from Variant, converted to a Resource. 2017-05-17 07:37:45 -03:00
honix 73385e362b Particles potential crash fix 2 2017-05-16 16:24:33 +03:00
Rémi Verschelde b6e0eaf3ca Merge pull request #8509 from nunodonato/fixspatialmaterial
Fixed #8102, by renaming FixedSpatialMaterial to SpatialMaterial
2017-04-24 12:05:43 +02:00
Nuno Donato c1e771dfe9 Fixed #8102, by renaming FixedSpatialMaterial to SpatialMaterial 2017-04-24 10:20:32 +01:00
Rémi Verschelde 05d35bb156 Merge pull request #8395 from 20kdc/master
Ported move_and_slide to KinematicBody (3D)
2017-04-24 11:20:10 +02:00
Rémi Verschelde 90ef1fd03d Merge pull request #8102 from bd339/iss3172
Show 3D raycasts when debugging collisions
2017-04-24 11:11:04 +02:00
20kdc e2df5d661d Ported/fixed move_and_slide to KinematicBody (3D+floor/ceiling args)
This version of the commit has the on_ceiling/on_wall fix without any
 explaination of that code, since apparently it wasn't complicated enough.

As for the notes at the top of the function, they're still there.

move_and_slide is rather useful for character-controllers, etc.
It reduces the amount of boilerplate code.
Not having move_and_slide makes the APIs somewhat inconsistent.

(It might be nice to figure out a way to share the code between the two
move_and_slide implementations, but that's for someone who knows what
the policy is on shared code like that.)
2017-04-21 21:19:41 +01:00
Juan Linietsky 4286aef693 Particle system is complete. Rejoice! 2017-04-08 22:40:06 -03:00
Rémi Verschelde df61dc4b2b Add "Godot Engine contributors" copyright line 2017-04-08 00:11:42 +02:00
Juan Linietsky 74808ac4d9 New particle system, mostly working, some small features missing. 2017-04-06 23:49:27 -03:00
Andreas Haas 0a287cfe4c
Fix more property names in _change_notify calls. 2017-04-03 18:35:15 +02:00
Benjamin Dahse 93d6003aa8 Show 3D raycasts when debugging collisions
Represent a raycast by a line segment using the direction and magnitude of the cast_to vector.
The entire line segment will become red while a collision occurs.
2017-03-30 22:34:05 +02:00
Rémi Verschelde 5dbf1809c6 A Whole New World (clang-format edition)
I can show you the code
Pretty, with proper whitespace
Tell me, coder, now when did
You last write readable code?

I can open your eyes
Make you see your bad indent
Force you to respect the style
The core devs agreed upon

A whole new world
A new fantastic code format
A de facto standard
With some sugar
Enforced with clang-format

A whole new world
A dazzling style we all dreamed of
And when we read it through
It's crystal clear
That now we're in a whole new world of code
2017-03-05 16:44:50 +01:00
Rémi Verschelde e1c1d7d1d7 Add a bunch of missing Godot headers in own files 2017-03-05 15:47:28 +01:00
Juan Linietsky de0045cf1b -renamed globals.h to global_config.cpp (this seems to have caused a few modified files)
-.pck and .zip exporting redone, seems to be working..
2017-02-21 00:06:30 -03:00
Juan Linietsky 903a3aa5f0 a ton of bug fixes to the renderer 2017-02-16 08:55:43 -03:00
Juan Linietsky da11d6d9e8 Many fixes to make exported scenes work better, still buggy. 2017-02-15 08:34:02 -03:00
Hein-Pieter van Braam 411ee71b4d Rename the _MD macro to D_METHOD
This new name also makes its purpose a little clearer

This is a step towards fixing #56
2017-02-13 12:50:02 +01:00
Hein-Pieter van Braam 0f687f0ccb Remove use of _SCS from ADD_METHOD
This saves typing and is a step towards fixing #56
2017-02-13 10:37:47 +01:00
Juan Linietsky 07bbcf91f7 basic contact shadows implementation, will most likely need some polishing 2017-02-08 07:35:14 -03:00
Juan Linietsky 5cc63dee0f ability to adjust propagation in gi probe 2017-02-06 05:12:15 -03:00
Juan Linietsky 6f2e16306a Several bugfixes, improving the import workflow 2017-02-06 00:38:39 -03:00
Juan Linietsky ee0f53df52 Merge pull request #7528 from tagcup/real_t_float_fixes
Use real_t rather than float or double in generic functions (core/mat…
2017-01-20 19:24:49 -03:00
Ray Koopa faa13adad3 Fix editor method calls to is_visible for Spatial and CanvasItem and is_visible itself for Spatial 2017-01-18 22:00:00 +01:00
Ferenc Arn 6f4f9aa6de Overloaded basic math funcs (double and float variants). Use real_t rather than float or double in generic functions (core/math) whenever possible.
Also inlined some more math functions.
2017-01-16 13:36:33 -06:00
BastiaanOlij 3a02df7739 Working on compile issues for iOS 2017-01-16 23:14:13 +11:00
Rémi Verschelde f44ee891be Style: Fix statements ending with ';;' 2017-01-16 08:49:52 +01:00
Juan Linietsky b400c69cd4 Oops! Audio engine has vanished :D 2017-01-15 16:07:51 -03:00
Rémi Verschelde e0faf8a51b Style: Cosmetic fixes to play nice with clang-format 2017-01-15 16:42:17 +01:00
Juan Linietsky dcb95ec147 removed duplicated functions in class hierarchy that were bound more than once
added a check to detect this case in the future
2017-01-14 11:10:42 -03:00
Rémi Verschelde 93ab45b6b5 Style: Fix whole-line commented code
They do not play well with clang-format which aligns the `//` part
with the rest of the code block, thus producing badly indented commented code.
2017-01-14 14:52:23 +01:00
Juan Linietsky d093cc8bf8 Renamed call_group to call_group_flags, made call_group without flags the default 2017-01-14 10:03:53 -03:00
Juan Linietsky f3b6177ece rename monitoring functions 2017-01-13 20:03:51 -03:00
Juan Linietsky 6e88b1096a Vector2.get_aspect() renamed to Vector2.aspect() to keep consistent method naming 2017-01-13 20:00:43 -03:00
Juan Linietsky 0ad9939603 Rename collision layer as suggested in #5696 2017-01-13 11:01:19 -03:00
Juan Linietsky 04c749a1f0 New API for visibility in both CanvasItem and Spatial
visible (property) - access set_visible(bool) is_visible()
is_visible_in_tree() - true when visible and parents visible
show() hide() - for convenience
2017-01-13 10:45:50 -03:00
Juan Linietsky a2903fc51d Must now register with set_transform_notify() to get NOTIFICATION_TRANSFORM_CHANGED 2017-01-12 20:35:46 -03:00
Juan Linietsky 35b404ba08 Unify naming of blendshape / morphtarget into just "Blend Shape" 2017-01-12 08:34:00 -03:00
Juan Linietsky 83cb84753f Renamed most signals so they refer to:
-An action being requested to the user in present tense: (ie, draw, gui_input, etc)
-A notification that an action happened, in past tense (ie, area_entered, modal_closed, etc).
2017-01-12 00:51:08 -03:00
Juan Linietsky bc26f90581 Type renames:
Matrix32 -> Transform2D
	Matrix3 -> Basis
	AABB -> Rect3
	RawArray -> PoolByteArray
	IntArray -> PoolIntArray
	FloatArray -> PoolFloatArray
	Vector2Array -> PoolVector2Array
	Vector3Array -> PoolVector3Array
	ColorArray -> PoolColorArray
2017-01-11 00:52:51 -03:00
Juan Linietsky 710692278d Merge pull request #7426 from m4nu3lf/bugfix/physics
Fixed inertia tensor computation and center of mass
2017-01-10 22:27:32 -03:00
Juan Linietsky 0acd4fccd5 Merge pull request #7438 from tagcup/matrix3_rotate_fix
Fix the order in which additional transformations are applied
2017-01-10 22:22:56 -03:00
Juan Linietsky 4338c90163 It is now possible to name layers of different kinds! 2017-01-10 22:20:57 -03:00
Juan Linietsky f3f4a11cfb - _ready() callback only happens once now, if you want to receive it again, use request_ready()
- C++ Nodes mostly do an internal process callback, so it does not conflict with users willing to use their own process callbacks
- callbacks such as _input, _process, _fixed_process _unhandled_input, _unhandled_key_input do not requiere calling a function to enable them. They are enabled automatically if found on the script.
2017-01-10 18:04:33 -03:00
BastiaanOlij bf990b0822 Few small fixes so tools=no and target=release compiles 2017-01-10 21:42:14 +11:00
m4nu3lf 2e38b32e0f Fixed inertia tensor computation and center of mass 2017-01-09 00:13:54 +00:00
Ferenc Arn 6b1252cdfa Fix the order in which additional transformations are applied in Matrix3 and Transform.
This is a part of the breaking changes proposed in PR #6865, solving the issue regarding the order of affine transformations described in #2565. This PR also fixes the affected code within Godot codebase. Includes improvements to documentation too.

Another change is, Matrix3::get_scale() will now return negative scaling when the determinant of the matrix is negative. The rationale behind this is simple: when performing a polar decomposition on a basis matrix M = R.S, we have to ensure that the determinant of R is +1, such that it is a proper rotation matrix (with no reflections) which can be represented by Euler angles or a quaternion.

Also replaced the few instances of float with real_t in Matrix3 and Transform.

Furthermore, this PR fixes an issue introduced due to the API breakage in #6865. Namely Matrix3::get_euler() now only works with proper rotation matrices. As a result, the code that wants to get the rotation portion of a transform needs to use Matrix3::get_rotation() introduced in this commit, which complements Matrix3::get_scaled(), providing both parts of the polar decomposition.

Finally, it is now possible to construct a rotation matrix from Euler angles using the new constructor Matrix3::Matrix3(const Vector3 &p_euler).
2017-01-08 10:36:14 -06:00
Juan Linietsky 2ab83e1abb Memory pool vectors (DVector) have been enormously simplified in code, and renamed to PoolVector 2017-01-07 18:26:38 -03:00
Juan Linietsky 76c2e8583e Merge branch 'master' of https://github.com/godotengine/godot 2017-01-04 01:17:41 -03:00