X-Git-Url: https://git.verplant.org/?a=blobdiff_plain;f=src%2Fresources.h;h=35f264f9eeb8763c59008960a5473f52fa776a00;hb=99095f57c0c103f77fe0a12624450e6f99435830;hp=33c6719bc622b054046688fd26df62b4154814d1;hpb=73f0a062817f8ec1276aff4cc1428609672ab98d;p=supertux.git diff --git a/src/resources.h b/src/resources.h index 33c6719bc..35f264f9e 100644 --- a/src/resources.h +++ b/src/resources.h @@ -1,24 +1,68 @@ +// $Id$ +// +// SuperTux - A Jump'n Run +// Copyright (C) 2003 Tobias Glaesser +// +// This program is free software; you can redistribute it and/or +// modify it under the terms of the GNU General Public License +// as published by the Free Software Foundation; either version 2 +// of the License, or (at your option) any later version. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program; if not, write to the Free Software +// Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. #ifndef SUPERTUX_RESOURCES_H #define SUPERTUX_RESOURCES_H -extern texture_type img_waves[3]; -extern texture_type img_water; -extern texture_type img_pole; -extern texture_type img_poletop; -extern texture_type img_flag[2]; -extern texture_type img_cloud[2][4]; +#include "audio/musicref.h" -extern texture_type img_box_full; -extern texture_type img_box_empty; -extern texture_type img_mints; -extern texture_type img_coffee; -extern texture_type img_super_bkgd; -extern texture_type img_red_glow; +using namespace SuperTux; -void loadshared(); -void unloadshared(); +class SpriteManager; +class Menu; +class Font; +class Surface; +class SoundManager; +class TileManager; -#endif +extern Surface* img_super_bkgd; +extern Surface* tux_life; + +extern MusicRef herring_song; +extern MusicRef level_end_song; + +extern SpriteManager* sprite_manager; +extern TileManager* tile_manager; +extern SoundManager* sound_manager; + +extern Menu* contrib_menu; +extern Menu* contrib_subset_menu; +extern Menu* main_menu; +extern Menu* game_menu; +extern Menu* options_menu; +extern Menu* load_game_menu; -/* EOF */ +extern Font* gold_text; +extern Font* white_text; +extern Font* blue_text; +extern Font* gray_text; +extern Font* white_small_text; +extern Font* white_big_text; +extern Font* yellow_nums; +/** maps a virtual resource path to a real path (ie. levels/bla is mapped to + * $DATADIR/levels/bla or $HOME/.supertux/levels/bla) + * All paths inside the game should be handled in as virtual paths and then + * expanded with this function just before the call to fopen or std::ifstream. + */ +std::string get_resource_filename(const std::string& resource); + +void load_shared(); +void unload_shared(); + +#endif