--- deliantra/server/random_maps/random_map.h 2010/06/26 23:53:31 1.27 +++ deliantra/server/random_maps/random_map.h 2010/06/30 01:32:57 1.28 @@ -31,10 +31,8 @@ { char wall_name[512]; char monsterstyle[512]; - char treasurestyle[512]; char layoutstyle[512]; char doorstyle[512]; - char decorstyle[512]; shstr origin_map; shstr final_map; shstr this_map; @@ -53,26 +51,35 @@ int dungeon_level; int dungeon_depth; - int decoroptions; int orientation; - int origin_y; int origin_x; + int origin_y; uint32_t random_seed; uint64_t total_map_hp; int map_layout_style; - int treasureoptions; int symmetry_used; struct region *region; HV *hv; + void hv_clone (); // replaces the hv by a clone'd copy (%new_hv = { %hv }) + + shstr_tmp as_shstr () const; // fetch something from the options hash - const_utf8_string get_str (const_utf8_string option, const_utf8_string fallback = "") const; - IV get_iv (const_utf8_string option, IV fallback = 0) const; + SV *get_sv (const char *option) const; + const_utf8_string get_str (const char *option, const_utf8_string fallback = "") const; + IV get_iv (const char *option, IV fallback = 0) const; + UV get_uv (const char *option, UV fallback = 0) const; + NV get_nv (const char *option, NV fallback = 0) const; + + void set (const char *option, SV *value) const; + void set (const char *option, const_utf8_string value) const; + void set (const char *option, IV value) const; + void set (const char *option, UV value) const; + void set (const char *option, NV value) const; - void set (const_utf8_string option, const_utf8_string value); - void set (const_utf8_string option, IV value); + void set (const char *option, int value) const { set (option, (IV)value); } // "private", adjusted sizes int Xsize;