diff options
author | Florian Diebold <flodiebold@gmail.com> | 2014-04-26 12:34:47 +0200 |
---|---|---|
committer | Florian Diebold <flodiebold@gmail.com> | 2014-04-26 12:34:47 +0200 |
commit | fcf2c25d3fde45640bff8690f683a5a44e1b2b86 (patch) | |
tree | 46a43ad89119725862ab7e0b10f788eaf5deb0ca /crawl-ref/source/viewgeom.cc | |
parent | c0ec6cfa46fdd39af0bfdbff64104ea1c5f86f8b (diff) | |
download | crawl-ref-fcf2c25d3fde45640bff8690f683a5a44e1b2b86.tar.gz crawl-ref-fcf2c25d3fde45640bff8690f683a5a44e1b2b86.zip |
Ignore msg_min_height for Webtiles games.
Since they are recorded at 80x24, the game could otherwise fail to
start because there's not enough vertical space.
Diffstat (limited to 'crawl-ref/source/viewgeom.cc')
-rw-r--r-- | crawl-ref/source/viewgeom.cc | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/crawl-ref/source/viewgeom.cc b/crawl-ref/source/viewgeom.cc index a54d66067e..cf71ecdb8c 100644 --- a/crawl-ref/source/viewgeom.cc +++ b/crawl-ref/source/viewgeom.cc @@ -32,6 +32,16 @@ static void _increment(int& lvalue, int delta, int max_value) lvalue = min(lvalue+delta, max_value); } +static int _msg_min_height() +{ +#ifdef USE_TILE_WEB + if (tiles.is_controlled_from_web()) + return MSG_MIN_HEIGHT; + else +#endif + return Options.msg_min_height; +} + class _layout { public: @@ -39,7 +49,7 @@ public: termp(1,1), termsz(termsz_), viewp(-1,-1), viewsz(VIEW_MIN_WIDTH, VIEW_MIN_HEIGHT), hudp(-1,-1), hudsz(hudsz_), - msgp(-1,-1), msgsz(0, Options.msg_min_height), + msgp(-1,-1), msgsz(0, _msg_min_height()), mlistp(-1,-1), mlistsz(MLIST_MIN_WIDTH, 0), hud_gutter(HUD_MIN_GUTTER), valid(false) {} |