From: Holger Schemel Date: Sun, 12 Oct 2014 23:31:58 +0000 (+0200) Subject: added detection of normal/steel characters when drawing text in editor X-Git-Tag: 4.0.0.0-rc1~335 X-Git-Url: https://git.artsoft.org/?a=commitdiff_plain;h=af5afdd0588973b29fe9c86f0212507abb3b6c59;p=rocksndiamonds.git added detection of normal/steel characters when drawing text in editor --- diff --git a/ChangeLog b/ChangeLog index dff5a36b..58a94a9c 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,7 @@ +2014-10-13 + * added automatic detection of normal/steel character elements in level + editor when drawing text (depending on currently selected element) + 2014-10-13 * eliminated historical ISO-8859-1 characters from source code files (but still using them internally for special character encodings) diff --git a/src/conftime.h b/src/conftime.h index 0b03ffe9..7d96b1e5 100644 --- a/src/conftime.h +++ b/src/conftime.h @@ -1 +1 @@ -#define COMPILE_DATE_STRING "2014-10-10 09:47" +#define COMPILE_DATE_STRING "2014-10-13 01:31" diff --git a/src/editor.c b/src/editor.c index cc1232f8..781a3efd 100644 --- a/src/editor.c +++ b/src/editor.c @@ -10285,6 +10285,10 @@ static int DrawLevelText(int sx, int sy, char letter, int mode) case TEXT_WRITECHAR: if (letter_element >= EL_CHAR_START && letter_element <= EL_CHAR_END) { + if (new_element1 >= EL_STEEL_CHAR_START && + new_element1 <= EL_STEEL_CHAR_END) + letter_element = letter_element - EL_CHAR_START + EL_STEEL_CHAR_START; + delete_buffer[sx - start_sx] = Feld[lx][ly]; Feld[lx][ly] = letter_element;