Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBenoit Bolsee <benoit.bolsee@online.be>2009-04-10 03:10:12 +0400
committerBenoit Bolsee <benoit.bolsee@online.be>2009-04-10 03:10:12 +0400
commit5031fe982ea464ccb49ccfb4df857bf9dcb27c33 (patch)
tree9d4b29ff7542d6d0a4b1d8177c00c33876d1b0ff /source/gameengine/PyDoc
parentac45472a1707934573a12d629a21a81c3ed409ba (diff)
BGE API cleanup: ConstraintActuator.
Diffstat (limited to 'source/gameengine/PyDoc')
-rw-r--r--source/gameengine/PyDoc/KX_ConstraintActuator.py69
-rw-r--r--source/gameengine/PyDoc/KX_StateActuator.py18
2 files changed, 87 insertions, 0 deletions
diff --git a/source/gameengine/PyDoc/KX_ConstraintActuator.py b/source/gameengine/PyDoc/KX_ConstraintActuator.py
index 7c7ad5aa0fa..a30b859548b 100644
--- a/source/gameengine/PyDoc/KX_ConstraintActuator.py
+++ b/source/gameengine/PyDoc/KX_ConstraintActuator.py
@@ -5,6 +5,75 @@ from SCA_IActuator import *
class KX_ConstraintActuator(SCA_IActuator):
"""
A constraint actuator limits the position, rotation, distance or orientation of an object.
+
+ Properties:
+
+ @ivar damp: time constant of the constraint expressed in frame (not use by Force field constraint)
+ @type damp: integer
+
+ @ivar rotDamp: time constant for the rotation expressed in frame (only for the distance constraint)
+ 0 = use damp for rotation as well
+ @type rotDamp: integer
+
+ @ivar direction: the reference direction in world coordinate for the orientation constraint
+ @type direction: 3-tuple of float: [x,y,z]
+
+ @ivar option: Binary combination of the following values:
+ Applicable to Distance constraint:
+ KX_ACT_CONSTRAINT_NORMAL ( 64) : Activate alignment to surface
+ KX_ACT_CONSTRAINT_DISTANCE ( 512) : Activate distance control
+ KX_ACT_CONSTRAINT_LOCAL (1024) : direction of the ray is along the local axis
+ Applicable to Force field constraint:
+ KX_ACT_CONSTRAINT_DOROTFH (2048) : Force field act on rotation as well
+ Applicable to both:
+ KX_ACT_CONSTRAINT_MATERIAL ( 128) : Detect material rather than property
+ KX_ACT_CONSTRAINT_PERMANENT ( 256) : No deactivation if ray does not hit target
+ @type option: integer
+
+ @ivar time: activation time of the actuator. The actuator disables itself after this many frame.
+ If set to 0, the actuator is not limited in time.
+ @type time: integer
+
+ @ivar property: the name of the property or material for the ray detection of the distance constraint.
+ @type property: string
+
+ @ivar min: The lower bound of the constraint
+ For the rotation and orientation constraint, it represents radiant
+ @type min: float
+
+ @ivar distance: the target distance of the distance constraint
+ @type distance: float
+
+ @ivar max: the upper bound of the constraint.
+ For rotation and orientation constraints, it represents radiant.
+ @type max: float
+
+ @ivar rayLength: the length of the ray of the distance constraint.
+ @type rayLength: float
+
+ @ivar limit: type of constraint, use one of the following constant:
+ KX_ACT_CONSTRAINT_LOCX ( 1) : limit X coord
+ KX_ACT_CONSTRAINT_LOCY ( 2) : limit Y coord
+ KX_ACT_CONSTRAINT_LOCZ ( 3) : limit Z coord
+ KX_ACT_CONSTRAINT_ROTX ( 4) : limit X rotation
+ KX_ACT_CONSTRAINT_ROTY ( 5) : limit Y rotation
+ KX_ACT_CONSTRAINT_ROTZ ( 6) : limit Z rotation
+ KX_ACT_CONSTRAINT_DIRPX ( 7) : set distance along positive X axis
+ KX_ACT_CONSTRAINT_DIRPY ( 8) : set distance along positive Y axis
+ KX_ACT_CONSTRAINT_DIRPZ ( 9) : set distance along positive Z axis
+ KX_ACT_CONSTRAINT_DIRNX (10) : set distance along negative X axis
+ KX_ACT_CONSTRAINT_DIRNY (11) : set distance along negative Y axis
+ KX_ACT_CONSTRAINT_DIRNZ (12) : set distance along negative Z axis
+ KX_ACT_CONSTRAINT_ORIX (13) : set orientation of X axis
+ KX_ACT_CONSTRAINT_ORIY (14) : set orientation of Y axis
+ KX_ACT_CONSTRAINT_ORIZ (15) : set orientation of Z axis
+ KX_ACT_CONSTRAINT_FHPX (16) : set force field along positive X axis
+ KX_ACT_CONSTRAINT_FHPY (17) : set force field along positive Y axis
+ KX_ACT_CONSTRAINT_FHPZ (18) : set force field along positive Z axis
+ KX_ACT_CONSTRAINT_FHNX (19) : set force field along negative X axis
+ KX_ACT_CONSTRAINT_FHNY (20) : set force field along negative Y axis
+ KX_ACT_CONSTRAINT_FHNZ (21) : set force field along negative Z axis
+ @type limit: integer
"""
def setDamp(time):
"""
diff --git a/source/gameengine/PyDoc/KX_StateActuator.py b/source/gameengine/PyDoc/KX_StateActuator.py
index fb6ae5a3621..fe3669d3809 100644
--- a/source/gameengine/PyDoc/KX_StateActuator.py
+++ b/source/gameengine/PyDoc/KX_StateActuator.py
@@ -5,9 +5,26 @@ from SCA_IActuator import *
class KX_StateActuator(SCA_IActuator):
"""
State actuator changes the state mask of parent object.
+
+ Property:
+
+ @ivar operation: type of bit operation to be applied on object state mask.
+ You can use one of the following constant:
+ KX_STATE_OP_CPY (0) : Copy state mask
+ KX_STATE_OP_SET (1) : Add bits to state mask
+ KX_STATE_OP_CLR (2) : Substract bits to state mask
+ KX_STATE_OP_NEG (3) : Invert bits to state mask
+ @type operation: integer
+
+ @ivar mask: value that defines the bits that will be modified by the operation.
+ The bits that are 1 in the mask will be updated in the object state,
+ the bits that are 0 are will be left unmodified expect for the Copy operation
+ which copies the mask to the object state
+ @type mask: integer
"""
def setOperation(op):
"""
+ DEPRECATED: Use the operation property instead.
Set the type of bit operation to be applied on object state mask.
Use setMask() to specify the bits that will be modified.
@@ -16,6 +33,7 @@ class KX_StateActuator(SCA_IActuator):
"""
def setMask(mask):
"""
+ DEPRECATED: Use the mask property instead.
Set the value that defines the bits that will be modified by the operation.
The bits that are 1 in the value will be updated in the object state,
the bits that are 0 are will be left unmodified expect for the Copy operation