14 #ifndef COLLISIONHANDLEREVENT_H
15 #define COLLISIONHANDLEREVENT_H
43 INLINE
void clear_in_patterns();
44 INLINE
void add_in_pattern(
const std::string &in_pattern);
45 INLINE
void set_in_pattern(
const std::string &in_pattern);
46 INLINE
int get_num_in_patterns()
const;
47 INLINE std::string get_in_pattern(
int n)
const;
48 MAKE_SEQ(get_in_patterns, get_num_in_patterns, get_in_pattern);
50 INLINE
void clear_again_patterns();
51 INLINE
void add_again_pattern(
const std::string &again_pattern);
52 INLINE
void set_again_pattern(
const std::string &again_pattern);
53 INLINE
int get_num_again_patterns()
const;
54 INLINE std::string get_again_pattern(
int n)
const;
55 MAKE_SEQ(get_again_patterns, get_num_again_patterns, get_again_pattern);
57 INLINE
void clear_out_patterns();
58 INLINE
void add_out_pattern(
const std::string &out_pattern);
59 INLINE
void set_out_pattern(
const std::string &out_pattern);
60 INLINE
int get_num_out_patterns()
const;
61 INLINE std::string get_out_pattern(
int n)
const;
62 MAKE_SEQ(get_out_patterns, get_num_out_patterns, get_out_pattern);
64 MAKE_SEQ_PROPERTY(in_patterns, get_num_in_patterns, get_in_pattern);
65 MAKE_SEQ_PROPERTY(again_patterns, get_num_again_patterns, get_again_pattern);
66 MAKE_SEQ_PROPERTY(out_patterns, get_num_out_patterns, get_out_pattern);
72 EXTENSION(PyObject *__reduce__(PyObject *
self)
const);
73 EXTENSION(
void __setstate__(PyObject *
self, vector_uchar data));
75 void write_datagram(
Datagram &destination)
const;
79 void throw_event_for(
const vector_string &patterns,
CollisionEntry *entry);
80 void throw_event_pattern(
const std::string &pattern,
CollisionEntry *entry);
82 vector_string _in_patterns;
83 vector_string _again_patterns;
84 vector_string _out_patterns;
93 INLINE
void operator = (
const SortEntries &other);
97 Colliding _current_colliding;
98 Colliding _last_colliding;
104 static void init_type() {
105 CollisionHandler::init_type();
107 CollisionHandler::get_class_type());
110 return get_class_type();
112 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.
The abstract interface to a number of classes that decide what to do when a collision is detected.
virtual bool end_group()
Called by the CollisionTraverser at the completion of all collision detections for this traversal.
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() .
A class to retrieve the individual data elements previously stored in a Datagram.
An ordered list of data elements, formatted in memory for transmission over a socket or writing to a ...
TypeHandle is the identifier used to differentiate C++ class types.
This is our own Panda specialization on the default STL set.
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(),...
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.