You are not logged in. login register
Game coopconn4
name coopconn4
creator stephan
number of roles 4
stylesheet chess_like/chess_like_automatic.xsl
GDL v1
enabled
matches show matches
statistics show game statistics
description Connect Four played in two teams of two players each
GDL by: Arne König, Christian Drescher, Max Ostrowski and Torsten Grote
http://deepthought.23inch.de/

Game Description

(role white1)
(role white2)
(role black1)
(role black2)
(init (cell 1 1 b))
(init (cell 1 2 b))
(init (cell 1 3 b))
(init (cell 1 4 b))
(init (cell 1 5 b))
(init (cell 1 6 b))
(init (cell 2 1 b))
(init (cell 2 2 b))
(init (cell 2 3 b))
(init (cell 2 4 b))
(init (cell 2 5 b))
(init (cell 2 6 b))
(init (cell 3 1 b))
(init (cell 3 2 b))
(init (cell 3 3 b))
(init (cell 3 4 b))
(init (cell 3 5 b))
(init (cell 3 6 b))
(init (cell 4 1 b))
(init (cell 4 2 b))
(init (cell 4 3 b))
(init (cell 4 4 b))
(init (cell 4 5 b))
(init (cell 4 6 b))
(init (cell 5 1 b))
(init (cell 5 2 b))
(init (cell 5 3 b))
(init (cell 5 4 b))
(init (cell 5 5 b))
(init (cell 5 6 b))
(init (cell 6 1 b))
(init (cell 6 2 b))
(init (cell 6 3 b))
(init (cell 6 4 b))
(init (cell 6 5 b))
(init (cell 6 6 b))
(init (cell 7 1 b))
(init (cell 7 2 b))
(init (cell 7 3 b))
(init (cell 7 4 b))
(init (cell 7 5 b))
(init (cell 7 6 b))
(init (control white1))
(succ 1 2)
(succ 2 3)
(succ 3 4)
(succ 4 5)
(succ 5 6)
(succ 6 7)
(<= (cm ?c ?r)
    (or (true (cell ?c ?r x)) (true (cell ?c ?r o))))
(<= (sequential ?a ?b ?c ?d)
    (succ ?a ?b)
    (succ ?b ?c)
    (succ ?c ?d))
(<= (top-unused ?c ?r)
    (true (cell ?c ?r b))
    (cm ?c ?s)
    (succ ?s ?r))
(<= (top-unused ?c 1)
    (true (cell ?c 1 b)))
(<= (plays-on ?c ?r)
    (does ?x (drop ?c))
    (top-unused ?c ?r))
(<= (next (cell ?c ?r ?x))
    (true (cell ?c ?r ?x))
    (not (plays-on ?c ?r)))
(<= (next (control black1))
    (true (control white1)))
(<= (next (control white2))
    (true (control black1)))
(<= (next (control black2))
    (true (control white2)))
(<= (next (control white1))
    (true (control black2)))
(<= (legal ?x (drop ?c))
    (true (cell ?c 6 b))
    (true (control ?x)))
(<= (legal white1 noop)
    (or (true (control white2)) (true (control black1)) (true (control black2))))
(<= (legal white2 noop)
    (or (true (control white1)) (true (control black1)) (true (control black2))))
(<= (legal black1 noop)
    (or (true (control white1)) (true (control white2)) (true (control black2))))
(<= (legal black2 noop)
    (or (true (control white1)) (true (control white2)) (true (control black1))))
(<= (next (cell ?c ?r x))
    (or (does white1 (drop ?c)) (does white2 (drop ?c)))
    (top-unused ?c ?r))
(<= (next (cell ?c ?r o))
    (or (does black1 (drop ?c)) (does black2 (drop ?c)))
    (top-unused ?c ?r))
(<= (row ?x)
    (sequential ?a ?b ?c ?d)
    (true (cell ?a ?r ?x))
    (true (cell ?b ?r ?x))
    (true (cell ?c ?r ?x))
    (true (cell ?d ?r ?x)))
(<= (col ?x)
    (sequential ?a ?b ?c ?d)
    (true (cell ?e ?a ?x))
    (true (cell ?e ?b ?x))
    (true (cell ?e ?c ?x))
    (true (cell ?e ?d ?x)))
(<= (diag1 ?x)
    (sequential ?a ?b ?c ?d)
    (sequential ?e ?f ?g ?h)
    (true (cell ?a ?e ?x))
    (true (cell ?b ?f ?x))
    (true (cell ?c ?g ?x))
    (true (cell ?d ?h ?x)))
(<= (diag2 ?x)
    (sequential ?a ?b ?c ?d)
    (sequential ?e ?f ?g ?h)
    (true (cell ?a ?h ?x))
    (true (cell ?b ?g ?x))
    (true (cell ?c ?f ?x))
    (true (cell ?d ?e ?x)))
(<= (connfour ?x)
    (or (col ?x) (row ?x) (diag1 ?x) (diag2 ?x)))
(<= (goal ?x 50)
    (not (connfour x))
    (not (connfour o))
    (role ?x))
(<= (goal white1 100)
    (connfour x))
(<= (goal white2 100)
    (connfour x))
(<= (goal black1 0)
    (connfour x))
(<= (goal black2 0)
    (connfour x))
(<= (goal white1 0)
    (connfour o))
(<= (goal white2 0)
    (connfour o))
(<= (goal black1 100)
    (connfour o))
(<= (goal black2 100)
    (connfour o))
(<= terminal
    (or (connfour x) (connfour o)))
(<= (not-filled)
    (true (cell ?c 6 b)))
(<= terminal
    (not (not-filled)))

sees_XML(...) rules

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