direct.controls.ObserverWalker

from direct.controls.ObserverWalker import ObserverWalker

ObserverWalker.py is for avatars.

A walker control such as this one provides:

  • creation of the collision nodes

  • handling the keyboard and mouse input for avatar movement

  • moving the avatar

it does not:

  • play sounds

  • play animations

although it does send messages that allow a listener to play sounds or animations based on walker events.

Inheritance diagram

Inheritance diagram of direct.controls.ObserverWalker

class ObserverWalker[source]

Bases: NonPhysicsWalker

deleteCollisions(self)[source]
disableAvatarControls(self)[source]

Ignore the arrow keys, etc.

enableAvatarControls(self)[source]

Activate the arrow keys, etc.

initializeCollisions(self, collisionTraverser, avatarNodePath, avatarRadius=1.4, floorOffset=1.0, reach=1.0)[source]

Set up the avatar for collisions

notify = <direct.directnotify.Notifier.Notifier object>
oneTimeCollide(self)[source]

Makes one quick collision pass for the avatar, for instance as a one-time straighten-things-up operation after collisions have been disabled.

setCollisionsActive(self, active=1)[source]
slideName = 'jump'