Create 3D tree

by Victor

Preparations

  1. Extract all files that are in this compressed file.
  2. Add the extension “3D box Object” inside your project.
  3. Add all pictures you've extract from the compressed file.

Objects' creation

  1. Create a sprite object called “point_arbre” with only one picture : “point_arbre.png”
  2. Create a Box3D object called “arbre” with as parameters :
    • Front : transparent.png
    • Top : arbre.png
    • Bottom : arbre.png
    • Left : transparent.png
    • Right : transparent.png
    • Back : transparent.png
    • Height : 2 pixels
    • You can adjust the width and the depth depending on that you want to have.
  3. Place “point_arbre” objects where you want to see 3D tree when you play the game

Events' creation

Rewrite this events :

ConditionActionExplication
At the beginning of the sceneHide the object point_arbre
For Each point_arbre, repeat the following actions :Category “Advanced”
Do =0 to variable rotationThe sign is =
Repeat 6 times the following actions :Category “Advanced”
Create object arbre at position OBJ(point_arbre[x]) and OBJ(point_arbre[y])The first position is the X position and the second is the Y position
Do =VAL(variable[rotation]) to yaw of arbre In 3D Box object > Angles / Sign =
Do +30 to variable rotationSign +
Do =1000 to z-Order of arbreIn All objects > Z Order

So, At the beginning of the scene, 3D tree will appear at the point_arbre object's positions.