#include <map>#include <vector>#include <dirent.h>#include "picture.h"#include "moros.h"#include "../general/util.h"#include "../general/log.h"Classes | |
| class | edge |
| class | tile |
| class | terrain |
| class | addition |
| class | wall |
| class | unit |
| class | tpos |
Defines | |
| #define | DEBUG_ROUTINE "picture" |
| #define | MAX_CACHE 1000 |
| #define | side 36 |
| #define | hside 18 |
Functions | |
| int | epos (int n) |
| void | add_directory (std::string dir) |
| int | variant (pos p, int max) |
| pos | image (pos size) |
| void | add_terrains () |
| std::string | get_terrain (int terr, int type, bool snow, int from, int to) |
| void | add_additions () |
| void | add_walls () |
| void | add_units () |
| void | add_images () |
| void | set_terrain (int type, int x, int y) |
| void | set_add (int type, int x, int y, int dir) |
| void | set_castle (int type, int x, int y) |
| void | move_map (int dx, int dy) |
| int | set_unit (int type, int action, int x, int y, int d, int u) |
| void | paint () |
| tpos | calc_tpos (pos p) |
| pos | calc_pos (tpos p) |
Variables | |
| char * | edges [] = {"ne","n","nw","sw","s","se"} |
| char * | castles [] = {"e","ne","nw","w", "sw","se"} |
| int | dirnr = 0 |
| std::vector < std::string > | dirs |
| std::map < std::string, int > | files |
| std::vector< terrain > | terrains |
| char * | terrain_names [] |
| std::vector< addition > | additions |
| char * | adds_names [] |
| std::vector< wall > | walls |
| char * | wall_names [] |
| std::vector< unit > | units |
| char * | unit_names [] |
| #define DEBUG_ROUTINE "picture" |
| #define hside 18 |
| #define MAX_CACHE 1000 |
| #define side 36 |
| void add_additions | ( | ) |
| void add_directory | ( | std::string | dir | ) |
| void add_images | ( | ) |
| void add_terrains | ( | ) |
| void add_units | ( | ) |
| void add_walls | ( | ) |
| int epos | ( | int | n | ) |
| std::string get_terrain | ( | int | terr, | |
| int | type, | |||
| bool | snow, | |||
| int | from, | |||
| int | to | |||
| ) |
| void move_map | ( | int | dx, | |
| int | dy | |||
| ) |
| void paint | ( | ) |
Draw a map including units on it, keep the background for future usage
| void set_add | ( | int | type, | |
| int | x, | |||
| int | y, | |||
| int | dir | |||
| ) |
| void set_castle | ( | int | type, | |
| int | x, | |||
| int | y | |||
| ) |
| void set_terrain | ( | int | type, | |
| int | x, | |||
| int | y | |||
| ) |
set a terrain type
| int set_unit | ( | int | type, | |
| int | action, | |||
| int | x, | |||
| int | y, | |||
| int | d, | |||
| int | u | |||
| ) |
| int variant | ( | pos | p, | |
| int | max | |||
| ) |
| char* adds_names[] |
Initial value:
{
"pine", "great-tree", "willow", "farm-veg-spring", "tropical", "mountain_peak",
"mine-abandoned", "rock", "river", "road", "road-bridge", "reed", "tent", "flag", "mushrooms",
"windmill", "well", "village", "elven", "dwarven", "desert-village", "cave-village",
"tropical-village", "swamp-village", "signpost", "scarecrow", "temple"
}
| char* castles[] = {"e","ne","nw","w", "sw","se"} |
| int dirnr = 0 |
| std::vector<std::string> dirs |
| char* edges[] = {"ne","n","nw","sw","s","se"} |
| char* terrain_names[] |
Initial value:
{
"ocean", "coast", "ford", "lava", "ice", "cave", "grass", "savanna", "dirt", "swamp", "desert",
"desert-hills", "hills", "desert-mountains", "mountains", "wall"
}
| char* unit_names[] |
Initial value:
{
"peasant", "woodsman", "townsman", "ruffian", "bandit", "white-cleric", "white-mage", "mage",
"arch-mage", "bowman", "halberdier", "heavy-infantry", "horseman", "ranger",
"knight", "lancer", "longbowman", "paladin", "pikeman", "spearman", "swordsman",
"galleon", "pirate", "transport", "wagon", "horse", "falcon", "friar", "hunter", "shepherd",
"camel", "elephant"
}
| char* wall_names[] |
Initial value:
{
"castle", "encampment", "dwarven-castle", "elven-castle", "ruin"
}
Generated on Tue Jan 1 17:30:01 2008 for client/picture.cc File Reference by
Visit the project page on