rayLength
rayLength
Note:
Distance Constraint only.
gets/sets the maximum length of the distance constraint ray.
Type: float
Sample Code
#################### Get rayLength
# get the controller
controller = GameLogic.getCurrentController()
# get the constraint actuator attached to the
controller named act
act = controller.actuators["act"]
# get the length of the ray
rayLen = act.rayLength
#################### Set rayLength
# get the controller
controller = GameLogic.getCurrentController()
# get the constraint actuator attached to the
controller named act
act = controller.actuators["act"]
# set the length of the ray
act.rayLength = 2.5
|