mirror of
https://github.com/diasurgical/devilution.git
synced 2025-07-23 04:23:01 +02:00
Add Diablo Version 1.08-Specific Behavior with Preprocessor Directives (#2292)
* add preprocessor directive for version 1.08 * Update MakefileVC * Missed "endif" * revise handling of diablo version
This commit is contained in:
@@ -51,6 +51,10 @@ endif
|
||||
CFLAGS=/nologo /c /GX /W3 /O1 /I $(VC_INC_DIR) /FD /Gr /MT /D "NDEBUG" /D "WIN32" /D "_WINDOWS" /Fp"Diablo.pch" /YX /G5 /Zi /FAs
|
||||
LINKFLAGS=/nologo /subsystem:windows /machine:I386 /incremental:no
|
||||
|
||||
VERSION := 109
|
||||
|
||||
CFLAGS += /D "VERSION=$(VERSION)"
|
||||
|
||||
ifeq ($(HELLFIRE),1)
|
||||
CFLAGS += /D "HELLFIRE"
|
||||
endif
|
||||
|
@@ -102,7 +102,11 @@ int path_get_h_cost(int sx, int sy, int dx, int dy)
|
||||
int max = delta_x > delta_y ? delta_x : delta_y;
|
||||
|
||||
// see path_check_equal for why this is times 2
|
||||
#if VERSION == 108
|
||||
return min + (2 * max);
|
||||
#else
|
||||
return 2 * (min + max);
|
||||
#endif
|
||||
}
|
||||
|
||||
/**
|
||||
|
Reference in New Issue
Block a user