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

Game Description

(role player1)
(role player2)

(init (chocolate 1 1))
(init (chocolate 1 2))
(init (chocolate 1 3))
(init (chocolate 1 4))
(init (chocolate 1 5))
(init (chocolate 1 6))
(init (chocolate 1 7))

(init (chocolate 2 1))
(init (chocolate 2 2))
(init (chocolate 2 3))
(init (chocolate 2 4))
(init (chocolate 2 5))
(init (chocolate 2 6))
(init (chocolate 2 7))

(init (chocolate 3 1))
(init (chocolate 3 2))
(init (chocolate 3 3))
(init (chocolate 3 4))
(init (chocolate 3 5))
(init (chocolate 3 6))
(init (chocolate 3 7))

(init (chocolate 4 1))
(init (chocolate 4 2))
(init (chocolate 4 3))
(init (chocolate 4 4))
(init (chocolate 4 5))
(init (chocolate 4 6))
(init (chocolate 4 7))

(init (chocolate 5 1))
(init (chocolate 5 2))
(init (chocolate 5 3))
(init (chocolate 5 4))
(init (chocolate 5 5))
(init (chocolate 5 6))
(init (chocolate 5 7))

(init (chocolate 6 1))
(init (chocolate 6 2))
(init (chocolate 6 3))
(init (chocolate 6 4))
(init (chocolate 6 5))
(init (chocolate 6 6))
(init (chocolate 6 7))

(init (chocolate 7 1))
(init (chocolate 7 2))
(init (chocolate 7 3))
(init (chocolate 7 4))
(init (chocolate 7 5))
(init (chocolate 7 6))
(init (chocolate 7 7))

(init (chocolate 8 1))
(init (chocolate 8 2))
(init (chocolate 8 3))
(init (chocolate 8 4))
(init (chocolate 8 5))
(init (chocolate 8 6))
(init (chocolate 8 7))

(init (control player1))

(<= (legal ?player (bite ?x ?y))
    (true (control ?player))
    (true (chocolate ?x ?y)))

(<= (legal player1 noop)
    (true (control player2)))
(<= (legal player2 noop)
    (true (control player1)))

(<= (next (control player1))
    (true (control player2)))
(<= (next (control player2))
    (true (control player1)))

(<= (next (poisoned ?p))
    (does ?p (bite 1 1)))

(<= (next (chocolate ?x ?y))
    (true (chocolate ?x ?y))
    (does ?player (bite ?i ?j))
    (less_than ?x ?i))

(<= (next (chocolate ?x ?y))
    (true (chocolate ?x ?y))
    (does ?player (bite ?i ?j))
    (less_than ?y ?j))

(<= (next (chocolate ?x ?y))
    (true (chocolate ?x ?y))
    (not (true (control player1)))
    (not (true (control player2))))

(<= terminal
    (true (poisoned ?p)))

(<= (goal ?player 100)
    (true (poisoned ?other))
    (role ?player)
    (distinct ?player ?other))
(<= (goal ?player 0)
    (true (poisoned ?player)))
(<= (goal ?player 0)
    (role ?player)
    (not (true (poisoned player1)))
    (not (true (poisoned player2))))

(number 1)
(number 2)
(number 3)
(number 4)
(number 5)
(number 6)
(number 7)
(number 8)
(number 9)
(number 10)

(<= (less_than ?n ?m)
    (succ ?n ?m))
(<= (less_than ?n ?m)
    (number ?n)
    (number ?m)
    (distinct ?n ?m)
    (succ ?k ?m)
    (less_than ?n ?k))

(succ 1 2)
(succ 2 3)
(succ 3 4)
(succ 4 5)
(succ 5 6)
(succ 6 7)
(succ 7 8)
(succ 8 9)
(succ 9 10)

sees_XML(...) rules

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