indexing description: "[ Brick Breaker - Cow Edition ]" date: "$Date$" revision: "$Revision$" class BRICK_BREAKER inherit EM_APPLICATION EM_SHARED_THEME export {NONE} all end EM_AUDIO_CONSTANTS export {NONE} all end BB_SHARED_AUDIO export {NONE} all end BB_CONSTANTS SHARED_BB_SETTINGS create make feature {NONE} -- Initialization make is -- Start main application. local keyboard: EM_KEYBOARD do set_application_id ("brick_breaker_ce") -- *** Enable required subsystems *** -- bb_settings.set_user_file ("./", "config.xml") bb_settings.read_user_settings -- Initialize subsystems set_window_height (bb_window_height) set_window_width (bb_window_width) set_screen_resolution (bb_screen_resolution) Video_subsystem.set_fullscreen (bb_settings.fullscreen) set_opengl (opengl_enabled) video_subsystem.set_hardware_surface (False) video_subsystem.set_software_surface (True) Video_subsystem.enable Audio_subsystem.enable Network_subsystem.enable Joystick_subsystem.enable initialize_screen -- Check subsystem initialization if Video_subsystem.is_enabled and Audio_subsystem.is_enabled and Network_subsystem.is_enabled and Joystick_subsystem.is_enabled -- and then -- Set global options set_window_title ("Brick Breaker - Cow Edition") set_window_icon ("icon.png") video_subsystem.show_cursor -- Open mixer with a frequency of 44.10 kHz audio_subsystem.mixer.open (44100, Em_audio_format_s16sys, Em_stereo, Em_default_chunk_size) create keyboard.make_snapshot keyboard.enable_unicode_characters load_eclipse_theme -- Set first scene and launch it set_scene (create {BB_MAINMENU}.make) play_music ("./bgm/menu.ogg") launch -- Disable subsystems Video_subsystem.disable Audio_subsystem.disable Network_subsystem.disable else if not Video_subsystem.is_enabled then io.error.put_string ("Failed to initialise video subsystem.%N") end if not Audio_subsystem.is_enabled then io.error.put_string ("Failed to initialise audio subsystem.%N") end if not Network_subsystem.is_enabled then io.error.put_string ("Failed to initialise network subsystem.%N") end if not Joystick_subsystem.is_enabled then io.error.put_string ("Failed to initialise joystick subsystem.%N") end end end feature {NONE} -- Implementation end