//===========================================================================// // File: btl4.cpp // // Project: BattleTech Brick: BattleTech LBE Application // // Contents: Application launcher (main) // //---------------------------------------------------------------------------// // Date Who Modification // // -------- --- ---------------------------------------------------------- // // // //---------------------------------------------------------------------------// // Copyright (C) 1995, Virtual World Entertainment, Inc. // // All Rights reserved worldwide // // This unpublished sourcecode is PROPRIETARY and CONFIDENTIAL // //===========================================================================// #include #pragma hdrstop #if !defined(BTL4APP_HPP) # include #endif #if !defined(APPMGR_HPP) # include #endif #if !defined(BTL4VER_HPP) # include #endif //########################################################################## //#################### BTL4Application Globals ####################### //########################################################################## extern const char* const ProgName; const char* const ProgName = "btl4"; static Byte version[3] = {MAJOR_DATA_VERSION, RELEASE_VERSION, MINOR_DATA_VERSION}; // //############################################################################# // main //############################################################################# // int main(int argc, char *argv[]) { DEBUG_STREAM << "BattleTech v4.10" << endl; if (!L4Application::ParseCommandLine(argc, argv, L4Application::ParseToken)) { return 1; } StreamableResourceFile resources("btl4.res", version); ApplicationManager *application_manager = NULL; if (L4Application::GetMissionReviewMode() < 1) { application_manager = new ApplicationManager(GetTicksPerSecond()); Application *application = new BTL4Application(&resources); application_manager->StartApplication(application); } else { // //------------------------------------------------------------------- // Mission review / live-camera launch (missionReviewMode >= 1): // a MissionReviewApplicationManager with a SPOOLSIZE-byte packet // spool plus BTL4PlaybackApplication -- those bricks are not yet // reconstructed (see BTL4.NOTES.md for the decompiled structure). //------------------------------------------------------------------- // Fail("btl4.cpp -- mission review/camera launch not yet reconstructed"); return 1; } application_manager->RunMissions(); delete application_manager; return Exit_Code; }