You are not logged in. login register
Game knightazons
name knightazons
creator admin
number of roles 2
stylesheet knightsgames/knightsgames_10x10.xsl
GDL v1
enabled
matches show matches
statistics show game statistics
description

Game Description

(role white)
(role black)
(init (cell 4 1 white))
(init (cell 7 1 white))
(init (cell 1 4 white))
(init (cell 10 4 white))
(init (cell 1 7 black))
(init (cell 10 7 black))
(init (cell 4 10 black))
(init (cell 7 10 black))
(init (control white))
(<= (legal white noop)
    (true (control black)))
(<= (legal black noop)
    (true (control white)))
(<= (legal ?player (play ?x1 ?y1 ?x2 ?y2 ?x3 ?y3))
    (true (control ?player))
    (true (cell ?x1 ?y1 ?player))
    (knightmove ?x1 ?y1 ?x2 ?y2)
    (emptycell ?x2 ?y2)
    (knightmove ?x2 ?y2 ?x3 ?y3)
    (emptycell ?x3 ?y3))
(<= (legal ?player (play ?x1 ?y1 ?x2 ?y2 ?x1 ?y1))
    (true (control ?player))
    (true (cell ?x1 ?y1 ?player))
    (knightmove ?x1 ?y1 ?x2 ?y2)
    (emptycell ?x2 ?y2))
(<= (next (cell ?x ?y ?state))
    (true (cell ?x ?y ?state))
    (does ?player (play ?x1 ?y1 ?x2 ?y2 ?x3 ?y3))
    (distinctcell ?x ?y ?x1 ?y1))
(<= (next (cell ?x2 ?y2 ?player))
    (does ?player (play ?x1 ?y1 ?x2 ?y2 ?x3 ?y3)))
(<= (next (cell ?x3 ?y3 arrow))
    (does ?player (play ?x1 ?y1 ?x2 ?y2 ?x3 ?y3)))
(<= (next (control black))
    (true (control white)))
(<= (next (control white))
    (true (control black)))
(<= terminal
    (not (legalmove white)))
(<= terminal
    (not (legalmove black)))
(<= (goal white 100)
    (not (legalmove black)))
(<= (goal white 0)
    (legalmove black))
(<= (goal black 100)
    (not (legalmove white)))
(<= (goal black 0)
    (legalmove white))
(<= (legalmove ?player)
    (true (cell ?x ?y ?player))
    (knightmove ?x ?y ?xany ?yany)
    (emptycell ?xany ?yany))
(<= (knightmove ?x1 ?y1 ?x2 ?y2)
    (plus 1 ?x1 ?x2)
    (plus 2 ?y1 ?y2))
(<= (knightmove ?x1 ?y1 ?x2 ?y2)
    (plus 1 ?x1 ?x2)
    (plus 2 ?y2 ?y1))
(<= (knightmove ?x1 ?y1 ?x2 ?y2)
    (plus 1 ?x2 ?x1)
    (plus 2 ?y1 ?y2))
(<= (knightmove ?x1 ?y1 ?x2 ?y2)
    (plus 1 ?x2 ?x1)
    (plus 2 ?y2 ?y1))
(<= (knightmove ?x1 ?y1 ?x2 ?y2)
    (plus 2 ?x1 ?x2)
    (plus 1 ?y1 ?y2))
(<= (knightmove ?x1 ?y1 ?x2 ?y2)
    (plus 2 ?x1 ?x2)
    (plus 1 ?y2 ?y1))
(<= (knightmove ?x1 ?y1 ?x2 ?y2)
    (plus 2 ?x2 ?x1)
    (plus 1 ?y1 ?y2))
(<= (knightmove ?x1 ?y1 ?x2 ?y2)
    (plus 2 ?x2 ?x1)
    (plus 1 ?y2 ?y1))
(<= (cell ?x ?y)
    (index ?x)
    (index ?y))
(<= (emptycell ?x ?y)
    (cell ?x ?y)
    (not (true (cell ?x ?y white)))
    (not (true (cell ?x ?y black)))
    (not (true (cell ?x ?y arrow))))
(<= (distinctcell ?x1 ?y1 ?x2 ?y2)
    (cell ?x1 ?y1)
    (cell ?x2 ?y2)
    (distinct ?x1 ?x2))
(<= (distinctcell ?x1 ?y1 ?x2 ?y2)
    (cell ?x1 ?y1)
    (cell ?x2 ?y2)
    (distinct ?y1 ?y2))
(index 1)
(index 2)
(index 3)
(index 4)
(index 5)
(index 6)
(index 7)
(index 8)
(index 9)
(index 10)
(plus 1 1 2)
(plus 1 2 3)
(plus 1 3 4)
(plus 1 4 5)
(plus 1 5 6)
(plus 1 6 7)
(plus 1 7 8)
(plus 1 8 9)
(plus 1 9 10)
(plus 2 1 3)
(plus 2 2 4)
(plus 2 3 5)
(plus 2 4 6)
(plus 2 5 7)
(plus 2 6 8)
(plus 2 7 9)
(plus 2 8 10)

sees_XML(...) rules

(<= (sees_xml random ?t) (true ?t))
(<= (sees_xml ?p ?t) (role ?p) (distinct ?p random) (true ?t))