Panda3D
|
def __init__ | ( | self, | |
gravity = 64.348 , |
|||
standableGround = 0.707 , |
|||
hardLandingForce = 16.0 , |
|||
legacyLifter = False |
|||
) |
def addBlastForce | ( | self, | |
vector | |||
) |
def debugPrint | ( | self, | |
message | |||
) |
for debugging
def deleteCollisions | ( | self | ) |
def disableAvatarControls | ( | self | ) |
Ignore the arrow keys, etc.
def displayDebugInfo | ( | self | ) |
For debug use.
def doDeltaPos | ( | self | ) |
def enableAvatarControls | ( | self | ) |
Activate the arrow keys, etc.
def flushEventHandlers | ( | self | ) |
def getAirborneHeight | ( | self | ) |
def getCollisionsActive | ( | self | ) |
def getGravity | ( | self, | |
gravity | |||
) |
def getIsAirborne | ( | self | ) |
def getSpeeds | ( | self | ) |
Reimplemented in BattleWalker.
def getVelocity | ( | self | ) |
def handleAvatarControls | ( | self, | |
task | |||
) |
Check on the arrow keys and update the avatar.
Reimplemented in BattleWalker, BattleWalker, and TwoDWalker.
def initializeCollisions | ( | self, | |
collisionTraverser, | |||
avatarNodePath, | |||
avatarRadius = 1.4 , |
|||
floorOffset = 1.0 , |
|||
reach = 1.0 |
|||
) |
floorOffset is how high the avatar can reach. I.e. if the avatar walks under a ledge that is <= floorOffset above the ground (a double floor situation), the avatar will step up on to the ledge (instantly). Set up the avatar collisions
def oneTimeCollide | ( | self | ) |
Makes one quick collision pass for the avatar, for instance as a one-time straighten-things-up operation after collisions have been disabled.
def placeOnFloor | ( | self | ) |
Make a reasonable effor to place the avatar on the ground. For example, this is useful when switching away from the current walker.
def reset | ( | self | ) |
def setAirborneHeightFunc | ( | self, | |
unused_parameter | |||
) |
def setAvatar | ( | self, | |
avatar | |||
) |
def setAvatarPhysicsIndicator | ( | self, | |
indicator | |||
) |
indicator is a NodePath
def setCollisionRayHeight | ( | self, | |
height | |||
) |
def setCollisionsActive | ( | self, | |
active = 1 |
|||
) |
def setFloorBitMask | ( | self, | |
bitMask | |||
) |
def setGravity | ( | self, | |
gravity | |||
) |
def setMayJump | ( | self, | |
task | |||
) |
This function's use is internal to this class (maybe I'll add the __ someday). Anyway, if you want to enable or disable jumping in a general way see the ControlManager (don't use this).
def setPriorParentVector | ( | self | ) |
def setTag | ( | self, | |
key, | |||
value | |||
) |
def setupEventSphere | ( | self, | |
bitmask, | |||
avatarRadius | |||
) |
Set up the collision sphere
def setupFloorSphere | ( | self, | |
bitmask, | |||
avatarRadius | |||
) |
Set up the collision sphere
def setupRay | ( | self, | |
bitmask, | |||
floorOffset, | |||
reach | |||
) |
def setupWallSphere | ( | self, | |
bitmask, | |||
avatarRadius | |||
) |
Set up the collision sphere
def setWalkSpeed | ( | self, | |
forward, | |||
jump, | |||
reverse, | |||
rotate | |||
) |
def setWallBitMask | ( | self, | |
bitMask | |||
) |
def startJumpDelay | ( | self, | |
delay | |||
) |
def swapFloorBitMask | ( | self, | |
oldMask, | |||
newMask | |||
) |
tuple DiagonalFactor = math.sqrt(2.) [static] |
tuple earlyEventSphere = base.config.GetBool('early-event-sphere', 0) [static] |
Reimplemented in TwoDWalker.
Reimplemented in BattleWalker, and TwoDWalker.
Reimplemented in BattleWalker.
Reimplemented in BattleWalker.
tuple notify = directNotify.newCategory("GravityWalker") [static] |
Reimplemented in TwoDWalker.
Reimplemented in BattleWalker, and TwoDWalker.
Reimplemented in BattleWalker.
Reimplemented in BattleWalker.
Reimplemented in BattleWalker.
Reimplemented in BattleWalker.
tuple wantDebugIndicator = base.config.GetBool('want-avatar-physics-indicator', 0) [static] |
Reimplemented in TwoDWalker.
tuple wantFloorSphere = base.config.GetBool('want-floor-sphere', 0) [static] |
Reimplemented in TwoDWalker.