This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
gdevelop5:behaviors [2018/09/26 22:49]
valiant_curiosity [Add behavior to an object.]
gdevelop5:behaviors [2020/12/03 08:39] (current)
Line 1: Line 1:
 # Behaviors # Behaviors
-Behaviors ​add extra capabilities ​to objects. All objects ​can have one or more behaviors ​attached to it.+In GDevelop, _behaviors_ ​add features ​to [[gdevelop5:​objects|objects]]. For example, the [[gdevelop5:​behaviors:​platformer|Platformer character]] behavior makes an object behave as a playable character in a platforming game. This lets the player control the object with their keyboard and makes the object affected by gravity.
-==== Add behavior ​to an object====+Behaviors add significant features ​to a game in a matter of clicks. You can also customize behaviors to make your game feel unique and use [[gdevelop5:​events|events]] to manipulate behaviors.
-To add a behavior to an object, you need to open the object'​s properties. There are two ways that this can be accomplished:​+## List of behaviors
-  * 1. Mouse click on the three dots in the Objects menu located ​to the right of the scene. Select "Edit object"​ from the popup listing.+This section lists the different types of behaviors, each of which is useful for adding different types of features ​to objects.
-{{ :gdevelop5:editplayerobject.jpg?​nolink }}+- [[gdevelop5:behaviors:​anchor|Anchor]] 
 +- [[gdevelop5:behaviors:​bounce|Bounce]] 
 +- [[gdevelop5:​behaviors:​destroyoutside|Destroy outside screen]] 
 +- [[gdevelop5:​behaviors:​draggable|Draggable]] 
 +- [[gdevelop5:​behaviors:​pathfinding|Pathfinding]] 
 +- [[gdevelop5:​behaviors:​physics2|Physics 2]] 
 +- [[gdevelop5:​behaviors:​platformer|Platformer objects and platforms]] 
 +- [[gdevelop5:​behaviors:​topdown|Top-down movement]] 
 +- [[gdevelop5:​behaviors:​tween|Tween]]
-  * 2.  Right mouse click on the object within the scene. Select "Edit object"​ from the popup listing.+Refer to the linked pages to learn more about each type of behavior.
-You should see the properties of the selected object. Ignore the properties tab for now. Select the "​Behaviors"​ tab on the bar. +### Deprecated ​behaviors
-{{ :gdevelop5:behaviors-tab.png?​nolink }}+
-Here you will see a list of behaviors ​added to the object. It is probably empty now. To add a behavior to the object, click the Add behavior button. +- [[gdevelop5:​behaviors:physics|Old Physics]]
-{{ :gdevelop5:​add-behavior-button.png?​nolink }}+
-Next you should see list of available behaviors. +## Adding ​a behavior ​to an object
-{{ :​gdevelop5:​add-behavior-list.png?​nolink }}+
-You may need to scroll down to see the full list of behaviors+1. Right-click an object in the **Objects** panel. 
-Finally, just click on a behavior ​to add that behavior ​to the object+2. Select **Edit object**. 
-==== Learn more ====+3. Switch ​to the **Behaviors** tab
 +4. Click the **+** icon. 
 +5. Select ​a behavior ​from the list. 
 +6. Customize the behavior. The available settings depend on the behavior
 +7. Click **Apply**.
-You can learn more about each behavior ​by clicking on the following links:+{{ :​gdevelop5:​new-behavior-dialog.png?​nolink |}} 
 +## Installing new behaviors 
 +Anyone can [[gdevelop5:​behaviors:​events-based-behaviors|create custom behaviors]] and share them with the GDevelop community. 
 +{{ :gdevelop5:​search-new-behaviors.png?​nolink |}} 
 +To search for and install community-created behaviors:​ 
 +1. Right click an object in the **Objects** panel. 
 +2. Select **Edit object**. 
 +3. Switch to the **Behaviors** tab. 
 +4. Click the **+** icon. 
 +5. Switch to the **Search new behaviors** tab. 
 +6. Search for a behavior. 
 +7. Select a behavior. 
 +8. Click **Install in project**. 
 +Installed behaviors appear in the **Installed behaviors** tab.
-  * [[gdevelop5:​behaviors:​physics|Physics behavior]] 
-  * [[gdevelop5:​behaviors:​pathfinding|Pathfinding]] 
-  * [[gdevelop5:​behaviors:​destroyoutside|Destroy outside screen]] 
-  * [[gdevelop5:​behaviors:​platformer|Platformer objects and platforms]] 
-  * [[gdevelop5:​behaviors:​draggable|Draggable object]] 
-  * [[gdevelop5:​behaviors:​topdown|Top-down movement]]