void ArmyRole::update() { //getEnviromentInfo(); //getGL().setFuncType(GLSL::FUNS_LIGHT_PHONG);//FUNS_LIGHT_PHONG FUNS_LIGHT_EASY //getGL().chooseMatrix(GLSL::MMATRIX); //getGL().setIdentity(); //pAFG->getFrameNum(); onUpdateStart(); if(hasChange) { setRotateY(changeRotateY); hasChange=false; } draw(); onUpdateEnd(); //getGL().setFuncType(GLSL::FUNS_LIGHT_EASY);//FUNS_LIGHT_PHONG FUNS_LIGHT_EASY //getGL().chooseMatrix(GLSL::MMATRIX); //getGL().setIdentity(); pMHP->setPos(pTransform->pTOmatrix->mMatrixQueue.back()[12], pTransform->pTOmatrix->mMatrixQueue.back()[13]+19, pTransform->pTOmatrix->mMatrixQueue.back()[14] ); pMHP->setHPAll(HPAll); pMHP->setHP( HP ); pMHP->draw(); //if(moveCode==2) dealMovementRun1(); }
bool Room::go() { while ( !shouldExit() ) { VALIDATE( onUpdateStart() ); VALIDATE( update() ); VALIDATE( render() ); VALIDATE( onUpdateEnd( kTimeStepMilliseconds ) ); } return true; }