Note: This diff is for Nethack 3.4.0 which is already OUTDATED. For newer game versions I have included the functionality in the makedefs diff ( http://www.iki.fi/jslahti/nethack.html#makedefs ). I recommend using the newest version of the source instead of still compiling 3.4.0. *** src/version.c.off Thu Mar 21 01:43:20 2002 --- src/version.c Sun Apr 28 18:49:48 2002 *************** *** 14,19 **** --- 14,27 ---- #include "patchlevel.h" #endif + /* Features to be ignored for checking version compatibility (JL): + * 23 TIMED_DELAY + * 21 SCORE_ON_BOTL + * 20 EXP_ON_BOTL + * 17 TEXTCOLOR + */ + #define FEATURE_MASK 1L << 23 | 1L << 21 | 1L << 20 | 1L << 17 + /* fill and return the given buffer with the nethack version string */ char * getversionstring(buf) *************** *** 64,70 **** if (complain) pline("Version mismatch for file \"%s\".", filename); return FALSE; ! } else if (version_data->feature_set != VERSION_FEATURES || version_data->entity_count != VERSION_SANITY1 || version_data->struct_sizes != VERSION_SANITY2) { if (complain) --- 72,84 ---- if (complain) pline("Version mismatch for file \"%s\".", filename); return FALSE; ! } else if ( ! #ifdef FEATURE_MASK ! (version_data->feature_set | FEATURE_MASK) != ! (VERSION_FEATURES | FEATURE_MASK) || ! #else ! version_data->feature_set != VERSION_FEATURES || ! #endif version_data->entity_count != VERSION_SANITY1 || version_data->struct_sizes != VERSION_SANITY2) { if (complain) *************** *** 72,77 **** --- 86,95 ---- filename); return FALSE; } + #ifdef FEATURE_MASK + else if (complain && version_data->feature_set != VERSION_FEATURES) + pline("Slightly different features in file \"%s\".", filename); + #endif return TRUE; }