From 0b34cd0ee76db6885342f91db2abc7d821d013b7 Mon Sep 17 00:00:00 2001 From: Ben Boeckel Date: Sat, 17 Jan 2009 11:18:14 -0500 Subject: Added more tests for Rules and fixes for numBoxes and boxSize --- sigmod/Rules.cpp | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) (limited to 'sigmod/Rules.cpp') diff --git a/sigmod/Rules.cpp b/sigmod/Rules.cpp index 9f9394a4..e8fa0d7b 100644 --- a/sigmod/Rules.cpp +++ b/sigmod/Rules.cpp @@ -1,5 +1,5 @@ /* - * Copyright 2007-2008 Ben Boeckel + * Copyright 2007-2009 Ben Boeckel * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -224,13 +224,10 @@ CHECK_BEGIN(Rules, bool, pausedATB) return false; } CHECK_END() -CHECK(Rules, int, numBoxes) +CHECK_BOUNDS(Rules, int, numBoxes, 0, INT_MAX) CHECK_BEGIN(Rules, int, boxSize) if (m_numBoxes) - { TBOUNDS(boxSize, 1, INT_MAX); - return false; - } CHECK_END() CHECK_BOUNDS(Rules, int, maxParty, 1, INT_MAX) CHECK_BOUNDS(Rules, int, maxFight, 1, m_maxParty) -- cgit