Differences

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
Next revisionBoth sides next revision
quick:design [2018/05/18 21:48] pedroquick:design [2020/09/03 08:56] pedro
Line 1: Line 1:
 +<markdown>
 # Quick Start Guide # Quick Start Guide
  
Line 135: Line 136:
  
 - Close the editor. Remember that behaviors are automatically saved. - Close the editor. Remember that behaviors are automatically saved.
-- Select, if needed, the `Enemy` game object and observe the behavior executor parameters. Remember that the `wanderArea` is still unestablished so the `GetRandomInArea` does not know the area where the position should be chosen from. Specifically, `GetRandomInArea` requires a game object _with a box or sphere collider_.+ 
 +If neededor if you haven't used the "InitialScene": 
 + 
 +- Select, the `Enemy` game object and observe the behavior executor parameters. Remember that the `wanderArea` is still unestablished so the `GetRandomInArea` does not know the area where the position should be chosen from. Specifically, `GetRandomInArea` requires a game object _with a box or sphere collider_.
 - Select the `Floor` game object, and add it a Box collider. Set (10, 0, 10) as its size. - Select the `Floor` game object, and add it a Box collider. Set (10, 0, 10) as its size.
 - Select the `Enemy` game object, and drag and drop the `Floor` into the `wanderArea` parameter. - Select the `Enemy` game object, and drag and drop the `Floor` into the `wanderArea` parameter.
Line 345: Line 349:
         public GameObject prefab;         public GameObject prefab;
         public GameObject wanderArea;         public GameObject wanderArea;
 +        public GameObject player;
 +
  
         public int Spawns = 750;         public int Spawns = 750;
Line 352: Line 358:
         void Start()         void Start()
         {         {
-            entities =  +            entities = new List<GameObject>(); 
-              new List<GameObject>(FindObjectsOfType(typeof(GameObject))  +            entities.Add(player);
-                as GameObject[]); +
-            entities.RemoveAll(e => e.GetComponent<BehaviorExecutor>() == null);+
             InvokeRepeating("Spawn", 0f, 1.0f / 1000.0f);             InvokeRepeating("Spawn", 0f, 1.0f / 1000.0f);
         }         }
Line 431: Line 435:
  
 Congratulations! You've just finished the first Behavior Bricks tutorial. You have learned the basics of the editor, and the main concepts: actions, conditions, blackboard, internal nodes, and reusability. If you want to test your newly acquired knowledge, you can, for example, improve the player behavior. Currently, once a position has been selected, it cannot be changed until the player avatar has reached it. It would be great if the player could select a different position using the mouse to overwrite the previous one. Using a priority selector it is easier that it sounds! And it you need some inspiration, you can always have a look at the behavior in the Collection. Finally, remember if you have had any problem following this tutorial, you have available the final scene in the `Samples\QuickStartGuide\Done` folder of the Behavior Bricks package. Congratulations! You've just finished the first Behavior Bricks tutorial. You have learned the basics of the editor, and the main concepts: actions, conditions, blackboard, internal nodes, and reusability. If you want to test your newly acquired knowledge, you can, for example, improve the player behavior. Currently, once a position has been selected, it cannot be changed until the player avatar has reached it. It would be great if the player could select a different position using the mouse to overwrite the previous one. Using a priority selector it is easier that it sounds! And it you need some inspiration, you can always have a look at the behavior in the Collection. Finally, remember if you have had any problem following this tutorial, you have available the final scene in the `Samples\QuickStartGuide\Done` folder of the Behavior Bricks package.
 +
 +</markdown>