--- trunk/OOPSE/libmdtools/DirectionalAtom.cpp 2004/06/07 14:26:33 1252 +++ trunk/OOPSE/libmdtools/DirectionalAtom.cpp 2004/08/23 15:11:36 1452 @@ -35,7 +35,8 @@ void DirectionalAtom::setCoords(void){ &trq, &Amat, &mu, - &ul); + &ul, + &quat); } else{ sprintf( painCave.errMsg, @@ -431,6 +432,23 @@ void DirectionalAtom::getTrq( double theT[3] ){ sprintf( painCave.errMsg, "Attempt to get Trq for atom %d before coords set.\n", + index ); + painCave.isFatal = 1; + simError(); + } +} + +void DirectionalAtom::setTrq( double theT[3] ){ + + if( hasCoords ){ + trq[offsetX] = theT[0]; + trq[offsetY] = theT[1]; + trq[offsetZ] = theT[2]; + } + else{ + + sprintf( painCave.errMsg, + "Attempt to add Trq for atom %d before coords set.\n", index ); painCave.isFatal = 1; simError();