#include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include "Minigames.h" #include #include "DLLDateien.h" #include #include #include #include #include struct HINSTANCE__; using namespace Framework; void FClose( void *p, void *zF ) { StopNachrichtenSchleife( ( (WFenster*)zF )->getFensterHandle() ); } void doStuff() { Network::Start( 1 ); WFenster *f = new WFenster(); WNDCLASS fc = F_Normal( 0 ); fc.lpszClassName = "Test"; f->erstellen( WS_OVERLAPPEDWINDOW, fc ); f->setSize( 800, 500 ); f->setPosition( Punkt( 100, 100 ) ); f->setVSchließAktion( FClose ); f->setMausAktion( _ret1ME ); f->setTastaturAktion( _ret1TE ); f->setAnzeigeModus( 1 ); Bildschirm *b = new Bildschirm3D( f->getThis() ); b->setBackBufferSize( 800, 500 ); f->setBildschirm( b->getThis() ); b->setTestRend( 0 ); LTDSDatei sd; sd.setPfad( new Text( "normal.ltds" ) ); sd.leseDaten(); Schrift *schrift = sd.ladeSchrift(); DLLDateien dlls; API *api = new API( f ); MiniGames *mGames = new MiniGames( schrift, dlls.getThis(), b, api ); b->addMember( mGames->getThis() ); b->update(); RenderTh *r = new RenderTh(); r->setBildschirm( b->getThis() ); r->setMaxFps( 60 ); r->setTickFunktion( []( void*p, void*o, double t ) { if( getTastenStand( T_F1 ) ) std::cout << t << "\n"; } ); r->beginn(); StartNachrichtenSchleife(); r->beenden(); r->release(); mGames->release(); f->setBildschirm( 0 ); b->release(); f->release(); schrift->release(); delete api; Network::Exit(); } int main() { #ifdef _DEBUG _CrtSetDbgFlag( _CRTDBG_ALLOC_MEM_DF | _CRTDBG_LEAK_CHECK_DF ); #endif initFramework(); doStuff(); releaseFramework(); return 0; }