Commit Graph

14 Commits

Author SHA1 Message Date
Harsimran Singh Virk 599ccb677f Add support for visual effects ("shaders") on objects. (#2901)
* This allows to generate interesting visual effects, which can be controlled by events. For example, you can use an outline on an object to highlight, make the player glow when launching a spell, blur objects, etc...
* A new "effects" tab is now present in the objects editor. From there, you can add visual effects, that were already available for layers, customize them from this editor.
* Actions and conditions are available to manipulate effects and change their parameters during the game.
* Learn more on the wiki: http://wiki.compilgames.net/doku.php/gdevelop5/objects/effects

Co-authored-by: Florian Rival <Florian.Rival@gmail.com>
2021-08-20 15:01:06 +02:00
Florian Rival 965f7aab32 Fix getting the length of an object array always returning 0 2021-06-22 10:16:43 +02:00
Florian Rival 3266559cb6 Add actions, conditions and expressions to get the position of an object center or set its position using its center (#2593)
* This is useful for making concise actions or conditions.
* This is also useful because for some objects, the center is not located at half the width and the height of the object.
* You can use `Object.CenterX()` and `Object.CenterY()` to get the position of the center of an object in an expression.
2021-05-02 18:43:28 +01:00
Aurélien Vivet 5f4fde7a56 Add new expressions XFromAngleAndDistance and YFromAngleAndDistance (#2558) 2021-04-25 21:08:29 +01:00
Florian Rival 35bf3861a5 Fix raycast conditions failing in some conditions
Fix #2450
2021-03-20 16:06:43 +00:00
Arthur Pacaud 4ec14ed498 Add Array and Boolean variables (#2137)
* In the list of variables (of the scene, of an object or global variables), you can now specify the type of the variable: number, text, boolean, array or structure.
* Boolean variables can be "true" or "false. They can have their values checked with conditions, and updated with actions. They are a good way to store information about if something is enabled or not (is an item equipped, is something selected, etc...).
* Array variables can contain multiple values, indexed by a number. New values, including any kind of variables, can be appended to an array during the game. Arrays can also have a value removed, and using the event "For each child variable", you can run conditions and actions for each value that is present in the array.
* Boolean and arrays are also supported when you transform a variable from or to the JSON format - which is ideal to send web requests, read configuration files or store any kind of arbitrary data.
* Finally, note that array values can themselves be arrays, structures or any variable. This can be useful to construct advanced logic. You can also access arrays (as well as any variable) from JavaScript code block events.
2021-03-07 21:53:12 +00:00
Arthur Pacaud baa597f6ae Improve overall GDJS typing (#2401)
Only show in developer changelog
2021-03-03 14:41:13 +00:00
Florian Rival b3b68612bf Fix collision (and raycast) not always triggered with sprite having a non default center (#2392) 2021-02-28 16:59:04 +00:00
Harsimran Singh Virk 131c9699a3 Fix lights shown during one frame at a wrong position after their creation (#2294) 2021-02-09 20:23:14 +01:00
Florian Rival 7206c41955 Remove outdated documentation
Don't show in changelog
2021-01-10 13:43:29 +01:00
Florian Rival 65d3688052 Fix duplicate classes in the generated GDJS documentation
Don't show in changelog
2021-01-08 19:55:20 +01:00
Florian Rival d4813282e8 Update documentation
Don't show in changelog
2021-01-08 19:55:13 +01:00
Florian Rival d639e0ea6e Translate more files to TypeScript
Don't show in changelog
2021-01-08 19:54:52 +01:00
Florian Rival 326ebb231c Translate all objects to TypeScript
Don't show in changelog
2021-01-08 19:54:47 +01:00