static char *getElementInfoText(int element)
{
- char *info_text = "unknown";
+ char *info_text = NULL;
+
+ if (element < NUM_FILE_ELEMENTS)
+ {
+ if (element_info[element].custom_description != NULL)
+ info_text = element_info[element].custom_description;
+ else if (element_info[element].editor_description != NULL)
+ info_text = element_info[element].editor_description;
+ }
+
+ if (info_text == NULL)
+ {
+ info_text = "unknown";
- if (element < NUM_FILE_ELEMENTS &&
- element_info[element].editor_description != NULL)
- info_text = element_info[element].editor_description;
- else
Error(ERR_WARN, "no element description for element %d", element);
+ }
return info_text;
}
if (!DelayReached(&action_delay, action_delay_value))
return;
-#if 1
-
DrawGraphicAnimationExt(drawto,
SX + xpos * TILEX,
SY + ypos * TILEY + MINI_TILEY / 2,
el2img(properties_element), -1, NO_MASKING);
-#else
- DrawGraphicAnimationExt(drawto,
- SX + xpos * TILEX,
- SY + ypos * TILEY + MINI_TILEY / 2,
- el_dir_act2img(properties_element,
- MV_NO_MOVING,
- ...), -1, NO_MASKING);
-#endif
-
MarkTileDirty(xpos, ypos);
MarkTileDirty(xpos, ypos + 1);