You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
// Pure virtual interface for classes defining the rules by which the next digits may be placed in the grid
class IRuleSet
{
public:
virtual ~IRuleSet() {};
virtual int NextX(unsigned int currentX, Direction direction) = 0; // Returns the x-coordinate for the given direction. Returns -1 if currentX equals -1.
virtual int NextY(unsigned int currentY, Direction direction) = 0; // Returns the y-coordinate for the given direction. Returns -1 if currentY equals -1.
};
// The rules used in the original game
class DefaultRuleSet : public IRuleSet
{
public:
int NextX(unsigned int currentX, Direction direction);
int NextY(unsigned int currentY, Direction direction);