/* * Copyright (C) 2002-2007 The Warp Rogue Team * Part of the Warp Rogue Project * * This software is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License. * This software is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY. * * See the license.txt file for more details. */ /* * Module Name: Ui * Description: - */ /* * Symbols */ #define Uses_ProgramManager #define Uses_Util #include "mheader.h" #include "ui.h" #define MAX_SPECIAL_SYMBOLS 2 #define SYMBOL_NAME_SIZE 16 /* * special symbol names */ static const char SpecialSymbolName[MAX_SPECIAL_SYMBOLS][SYMBOL_NAME_SIZE] = { "Floor", "Wall" }; /* * symbol name -> symbol */ SYMBOL name_to_symbol(const char *symbol_name) { SYMBOL i; for (i = 0; i < MAX_SPECIAL_SYMBOLS; i++) { if (strings_equal(symbol_name, SpecialSymbolName[i])) { return SPECIAL_SYMBOL_OFFSET + i; } } die("*** CORE ERROR *** invalid symbol: %s", symbol_name); return SYM_NIL; }