The Battle for Wesnoth 1.21.0-dev
 
Loading...
Searching...
No Matches
help_topic_generators.hpp
Go to the documentation of this file.
1/*
2 Copyright (C) 2003 - 2025
3 by David White <dave@whitevine.net>
4 Part of the Battle for Wesnoth Project https://www.wesnoth.org/
5
6 This program is free software; you can redistribute it and/or modify
7 it under the terms of the GNU General Public License as published by
8 the Free Software Foundation; either version 2 of the License, or
9 (at your option) any later version.
10 This program is distributed in the hope that it will be useful,
11 but WITHOUT ANY WARRANTY.
12
13 See the COPYING file for more details.
14*/
15
16#pragma once
17
18#include "help_impl.hpp"
19
20#include <string> // for string
21#include <vector> // for vector
22class terrain_type; // lines 20-20
23class unit_type;
24
25namespace help {
26
28{
30
31
32public:
34
35 virtual std::string operator()() const;
36};
37
38
39
41{
43 const std::string variation_;
44public:
45 unit_topic_generator(const unit_type &t, std::string variation="") : type_(t), variation_(variation) {}
46 virtual std::string operator()() const;
47};
48
49} // end namespace help/
double t
virtual std::string operator()() const
terrain_topic_generator(const terrain_type &type)
Generate a topic text on the fly.
Definition help_impl.hpp:59
unit_topic_generator(const unit_type &t, std::string variation="")
virtual std::string operator()() const
A single unit type that the player may recruit.
Definition types.hpp:43