camera
camera
gets/sets the name of camera the actuator is set to switch to.
Type: string
Note:
set camera, use OB in front
of the camera name.
In other
words, use "OBCam_Race" and not "Cam_Race"
Sample
Code
################## Get camera
# get controller
controller = GameLogic.getCurrentController()
# get actuator attached to the controller named
switchCam
act = controller.actuators["switchCam"]
# get camera name
name = act.camera
################## Set camera
# get controller
controller = GameLogic.getCurrentController()
# get actuator attached to the controller named
switchCam
act = controller.actuators["switchCam"]
# get camera name
act.camera = "OBCam_Race"
|