Viewports: Blender 3D Game Engine




 
5.  Optional:  Add a Bool Property named Vertical
 
Note:

The optional bool property named Vertical allows you to change the position of the viewports.
Vertical = False (default)
Viewports occupy top and bottom half of game screen.
Vetical = True
Viewports occupy left and right sides of game screen.

Note:
Property must be named Vertical.  Can't be named Fred or vertical or anything else.  The python code looks for a Property attached to the camera named Vertical.

Add a Bool Property named Vertical to the Camera
Buttons Window menu >> Logic (F4)
Add Property button
Type:  Bool
Name:  Vertical

  
6.  Add Viewport.py to the Text Editor

Note:
If you downloaded either the starting blend or the finished blend, you can find Viewport249.py and Viewport250.py in the Text Editor.  

Download:

Text Editor menu >> Text >> Open
Rename Viewport249.txt to Viewport.py

 
  
7.  Add an always sensor set to run once

Camera selected

Buttons Window menu >> Logic (F4)
Sensors
Add
Always
Set to Run Once

 
   
8.  Add a Python Controller

Camera selected

Buttons Window menu >> Logic (F4)
Controllers
Add
Python
 Script:  Viewport.py

 

 
  
Download free seamless game textures or you can create your own seamless game textures. Use reference photos to add realism to the seamless texture you create. Textures let you create the style and mood for your computer game. Textures are a way to add detail and color to 3D graphics. Photo realistic textures add realism. Download free game models for your video game or create your own game models. Use the game models in First Person Shooter, role playing games, racing simulations and more. Download free textures to add detail to your game models. You can use the free game models you downloaded or model your own game models.