From ceeda2e337077b2edaf1af09cc4df2c30e8205a1 Mon Sep 17 00:00:00 2001 From: Ben Longbons Date: Tue, 15 Apr 2014 20:05:17 -0700 Subject: Wouldn't it be nice to have some integers too? --- src/map/magic-expr.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'src/map/magic-expr.cpp') diff --git a/src/map/magic-expr.cpp b/src/map/magic-expr.cpp index 786f870..b6f3208 100644 --- a/src/map/magic-expr.cpp +++ b/src/map/magic-expr.cpp @@ -504,14 +504,14 @@ int fun_bitshr(dumb_ptr, val_t *result, Slice args) static int fun_max(dumb_ptr, val_t *result, Slice args) { - RESULTINT = max(ARGINT(0), ARGINT(1)); + RESULTINT = std::max(ARGINT(0), ARGINT(1)); return 0; } static int fun_min(dumb_ptr, val_t *result, Slice args) { - RESULTINT = min(ARGINT(0), ARGINT(1)); + RESULTINT = std::min(ARGINT(0), ARGINT(1)); return 0; } @@ -639,7 +639,7 @@ int fun_skill(dumb_ptr, val_t *result, Slice args) if (ENTITY_TYPE(0) != BL::PC // don't convert to enum until after the range check || ARGINT(1) < 0 - || ARGINT(1) >= uint16_t(MAX_SKILL)) + || ARGINT(1) >= static_cast(MAX_SKILL)) { RESULTINT = 0; } @@ -944,7 +944,7 @@ int fun_distance(dumb_ptr, val_t *result, Slice args) if (ARGLOCATION(0).m != ARGLOCATION(1).m) RESULTINT = 0x7fffffff; else - RESULTINT = max(abs(ARGLOCATION(0).x - ARGLOCATION(1).x), + RESULTINT = std::max(abs(ARGLOCATION(0).x - ARGLOCATION(1).x), abs(ARGLOCATION(0).y - ARGLOCATION(1).y)); return 0; } -- cgit v1.2.3-60-g2f50