LAB REPORT WEEK 2: Mini Platformer Instructions

Objective: My goal is to express what goes into making a simple moving cube that can jump and move using the Blender Game Engine and Blender Game Logic.

Materials:

  • Blender (the software)

Methods:

  1. Open Blender
  2. Set the rendering to “Blender Game”
  3. Click the button on the lower left and select Logic Editor
  4. In the main Blender window, create a cube
  5. Flatten the cube and make it wide
  6. Create another cube
  7. Flatten this cube and make it wide
  8. Position this “cube” and move it above the larger flat “cube”
  9. Create a final cube
  10. Go to physics and select Dynamic for the Physics Type
  11. Create 5 Keyboard sensors in the Logic Editor
  12. Name each one each of the following: Forward, Back, Left, Right, Jump
  13. Create a collision sensor
  14. For the assign the following keys to the following sensors:
    1. forward: w
    2. back: s
    3. left: a
    4. right: d
    5. jump: *spacebar*
  15. For jump, make sure the sensor has tap is pressed/highlighted
  16. Create five And controllers
  17. Create five Motion actuators
  18. Name them the same as your keyboard sensors
  19. For forward, put a positive number into Linear’s X equal to back’s
  20. For back, put a negative number into Linear’s X equal to forward’s
  21. For left, put a negative number into Linear’s Y equal to right’s
  22. For right, put a positive number into Linear’s Y equal to left’s
  23. For jump, put a positive number into Linear’s Z (I suggest 5 or more)
  24. At the end of Linear for each of the actuators, select L and A.
  25. Next to each sensor, controller, and actuator are small circles; connect them directly across for each keyboard sensor
  26. For the collision sensor, connect the circle to the final And controller

This is how it looks on my screen (click to make it bigger)

Results: A playable platformer! Quite fun. It worked exactly the way I wanted. Hopefully it will for anyone who follows the above methods as well.

Discussion: In the process of making this I ran into several problems, including jumping into space, hovering, jumping while jumping, and movement being too slow due to a low value. Despite this, it’s the second time I’ve used Blender Game Engine, and the first time I’ve managed something like this. I would like to figure out in the future how to make it so that the RGB value of an object changes when collided with, but that may be a ways off.

This entry was posted in Uncategorized and tagged , , , , , . Bookmark the permalink.