--- trunk/OOPSE/libBASS/interface.c 2003/03/21 17:42:12 378 +++ trunk/OOPSE/libBASS/interface.c 2004/01/19 16:08:21 957 @@ -2,11 +2,11 @@ #include #include -#include -#include -#include +#include "parse_interface.h" +#include "BASS_interface.h" +#include "simError.h" #ifdef IS_MPI -#include +#include "mpiBASS.h" #endif void interface_error( event* the_event ); @@ -36,6 +36,23 @@ void init_molecule( int mol_index ){ the_event->event_type = MOLECULE; the_event->err_msg = NULL; the_event->evt.blk_index = mol_index; + + if( !event_handler( the_event ) ) interface_error( the_event ); +#ifdef IS_MPI + throwMPIEvent(the_event); +#endif + + free( the_event ); +} + +void init_rigidbody( int rigidbody_index ){ + event* the_event; + + the_event = (event* )malloc( sizeof( event ) ); + + the_event->event_type = RIGIDBODY; + the_event->err_msg = NULL; + the_event->evt.blk_index = rigidbody_index; if( !event_handler( the_event ) ) interface_error( the_event ); #ifdef IS_MPI @@ -113,7 +130,24 @@ void init_torsion( int torsion_index ){ free( the_event ); } +void init_zconstraint( int zconstraint_index ){ + event* the_event; + the_event = (event* )malloc( sizeof( event ) ); + + the_event->event_type = ZCONSTRAINT; + the_event->err_msg = NULL; + the_event->evt.blk_index = zconstraint_index; + + if( !event_handler( the_event ) ) interface_error( the_event ); +#ifdef IS_MPI + throwMPIEvent(the_event); +#endif + + free( the_event ); +} + + /* * the next few deal with the statement initializations */