소스 검색

adding flush()

Josh Wilson 18 년 전
부모
커밋
5b105d3968
2개의 변경된 파일12개의 추가작업 그리고 0개의 파일을 삭제
  1. 11 0
      panda/src/collide/collisionHandlerEvent.cxx
  2. 1 0
      panda/src/collide/collisionHandlerEvent.h

+ 11 - 0
panda/src/collide/collisionHandlerEvent.cxx

@@ -162,6 +162,17 @@ clear() {
   _current_colliding.clear();
 }
 
+////////////////////////////////////////////////////////////////////
+//     Function: CollisionHandlerEvent::flush
+//       Access: Public
+//  Description: Same as clear() except "out" events are thrown.
+////////////////////////////////////////////////////////////////////
+void CollisionHandlerEvent::
+flush() {
+  begin_group();
+  end_group();
+}
+
 ////////////////////////////////////////////////////////////////////
 //     Function: CollisionHandlerEvent::throw_event_for
 //       Access: Private

+ 1 - 0
panda/src/collide/collisionHandlerEvent.h

@@ -66,6 +66,7 @@ PUBLISHED:
   INLINE string get_out_pattern(int n) const;
 
   void clear();
+  void flush();
 
 protected:
   void throw_event_for(const vector_string &patterns, CollisionEntry *entry);