Add a translated "description" attribute to the [time_of_day] tag.

This is meant to be used in the help browser.
This commit is contained in:
fendrin 2014-10-19 09:08:08 +02:00
parent ddfb600ffb
commit 22b6687b0c
2 changed files with 6 additions and 1 deletions

View file

@ -29,7 +29,9 @@ std::ostream &operator<<(std::ostream &s, const tod_color& c){
time_of_day::time_of_day(const config& cfg):
lawful_bonus(cfg["lawful_bonus"]),
bonus_modified(0),
image(cfg["image"]), name(cfg["name"].t_str()), id(cfg["id"]),
image(cfg["image"]), name(cfg["name"].t_str()),
description(cfg["description"].t_str()),
id(cfg["id"]),
image_mask(cfg["mask"]),
color(cfg["red"], cfg["green"], cfg["blue"]),
sounds(cfg["sound"])
@ -41,6 +43,7 @@ time_of_day::time_of_day()
, bonus_modified(0)
, image()
, name(N_("Stub Time of Day"))
, description(N_("This Time of Day is only a Stub!"))
, id("nulltod")
, image_mask()
, color(0,0,0)
@ -56,6 +59,7 @@ void time_of_day::write(config& cfg) const
cfg["blue"] = color.b;
cfg["image"] = image;
cfg["name"] = name;
cfg["description"] = description;
cfg["id"] = id;
cfg["mask"] = image_mask;
cfg["sound"] = sounds;

View file

@ -73,6 +73,7 @@ struct time_of_day
/** The image to be displayed in the game status. */
std::string image;
t_string name;
t_string description;
std::string id;
/**