14#ifndef COLLISIONHANDLERPHYSICAL_H
15#define COLLISIONHANDLERPHYSICAL_H
44 bool remove_collider(
const NodePath &collider);
45 bool has_collider(
const NodePath &collider)
const;
46 void clear_colliders();
48 INLINE
void set_center(
const NodePath ¢er);
49 INLINE
void clear_center();
50 INLINE
const NodePath &get_center()
const;
51 INLINE
bool has_center()
const;
52 INLINE
bool has_contact()
const;
55 MAKE_PROPERTY2(center, has_center, get_center, set_center, clear_center);
57 EXTENSION(PyObject *__reduce__(PyObject *self)
const);
58 EXTENSION(
void __setstate__(PyObject *self, vector_uchar data, PyObject *nodepaths));
67 INLINE
void set_target(
const NodePath &target,
69 INLINE
void updated_transform();
75 virtual bool handle_entries()=0;
76 virtual void apply_linear_force(ColliderDef &def,
const LVector3 &force)=0;
78 virtual bool validate_target(
const NodePath &target);
82 FromEntries _from_entries;
95 static void init_type() {
96 CollisionHandlerEvent::init_type();
98 CollisionHandlerEvent::get_class_type());
101 return get_class_type();
103 virtual TypeHandle force_init_type() {init_type();
return get_class_type();}
Defines a single collision event.
A specialized kind of CollisionHandler that throws an event for each collision detected.
virtual void begin_group()
Will be called by the CollisionTraverser before a new traversal is begun.
virtual void add_entry(CollisionEntry *entry)
Called between a begin_group() .
virtual bool end_group()
Called by the CollisionTraverser at the completion of all collision detections for this traversal.
The abstract base class for a number of CollisionHandlers that have some physical effect on their mov...
This is a TFormer, similar to Trackball, that moves around a transform matrix in response to mouse in...
The default class template does not define any methods.
NodePath is the fundamental system for disambiguating instances, and also provides a higher-level int...
TypeHandle is the identifier used to differentiate C++ class types.
This is our own Panda specialization on the default STL map.
This is our own Panda specialization on the default STL vector.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
void register_type(TypeHandle &type_handle, const std::string &name)
This inline function is just a convenient way to call TypeRegistry::register_type(),...