示例#1
0
void DlSatTester :: restore ( unsigned int newTryLevel )
{
	fpp_assert ( !Stack.empty () );
	fpp_assert ( newTryLevel > 0 );

	// skip all intermediate restores
	setCurLevel(newTryLevel);

	// update split level
	if ( getCurLevel() < splitRuleLevel )
		splitRuleLevel = 0;

	// restore local
	bContext = Stack.top(getCurLevel());
	restoreBC();

	// restore tree
	CGraph.restore(getCurLevel());

	// restore TODO list
	TODO.restore(getCurLevel());

	incStat(nStateRestores);

	if ( LLM.isWritable(llSRState) )
		LL << " sr(" << getCurLevel() << ")";
#ifdef __DEBUG_SAVE_RESTORE
	writeRoot(llSRState);
#endif
}
示例#2
0
void WorldEditor::openScene( char const* name )
{	
	FnLight lgt;
	lgt.Object( sceneLevel.CreateLight() );
	lgt.Translate(70.0f, -70.0f, 70.0f, REPLACE);
	lgt.SetColor(1.0f, 1.0f, 1.0f);

	camControl.setPosition( Vec3D( 500 , 500 , 500 ) );
	camControl.setLookPos( Vec3D( 0,0,0 ) );

	TLevel* preLevel = m_curLevel;
	TLevel* level = new TLevel( name );

	setCurLevel( level );
	getWorldEditor()->changeLevel( level );

	//level->getFlyTerrain().Show( TRUE );


	delete preLevel;

	if ( !loadLevelData() )
		getWorldEditor()->initEditData();
	
}
示例#3
0
void GAMEDATA::init(){
    setCurLevel(0);
    setCurScore(0);
    setHistoryScore(UserDefault::getInstance()->getIntegerForKey("highestScore",0));
}