Wrote a basic logic engine for determining game turn results.