17 #ifndef HEADER_SUPERTUX_SUPERTUX_LEVEL_HPP 18 #define HEADER_SUPERTUX_SUPERTUX_LEVEL_HPP 20 #include "supertux/statistics.hpp" 35 static Level* current() {
return s_current; }
38 static Level* s_current;
41 explicit Level(
bool m_is_worldmap);
45 void save(
const std::string& filename,
bool retry =
false);
46 void save(std::ostream& stream);
48 void add_sector(std::unique_ptr<Sector> sector);
49 const std::string& get_name()
const {
return m_name; }
50 const std::string& get_author()
const {
return m_author; }
52 Sector* get_sector(
const std::string& name)
const;
54 size_t get_sector_count()
const;
55 Sector* get_sector(
size_t num)
const;
56 const std::vector<std::unique_ptr<Sector> >& get_sectors()
const {
return m_sectors; }
58 std::vector<Player*> get_players()
const;
60 const std::string& get_tileset()
const {
return m_tileset; }
62 int get_total_coins()
const;
63 int get_total_badguys()
const;
64 int get_total_secrets()
const;
68 bool is_worldmap()
const {
return m_is_worldmap; }
70 const std::string& get_license()
const {
return m_license; }
82 std::string m_contact;
83 std::string m_license;
84 std::string m_filename;
86 std::vector<std::unique_ptr<Sector> > m_sectors;
89 std::string m_tileset;
90 bool m_suppress_pause_menu;
91 bool m_is_in_cutscene;
94 std::string m_icon_locked;
95 std::string m_wmselect_bkg;
Definition: level_parser.hpp:27
This class is a layer between level and worldmap to keep track of stuff like scores, and minor, but funny things, like number of jumps and stuff.
Definition: statistics.hpp:36
Represents one of (potentially) multiple, separate parts of a Level.
Definition: sector.hpp:61
Represents a collection of Sectors running in a single GameSession.
Definition: level.hpp:30
Definition: reader_mapping.hpp:32
This module contains methods controlling the player.
Definition: player.hpp:47
Definition: writer.cpp:23