Game Description Language

from Wikipedia, the free encyclopedia

Game Description Language (GDL) is a description language developed by Michael Genesereth as part of the General Game Playing Project at Stanford University , California . GDL describes the state of a game as a series of facts and the mechanics of the game as logical rules. GDL is used as the basic language for developing game descriptions in a scientific environment. Based on this language, any finite, deterministic games with complete knowledge (i.e. without chance) can be modeled and played against each other via a suitable interface .

description

A GDL description takes the form of a series of logical sentences. These sentences must be given at every stage of the game in question. The following terms are defined as given sentences:

  • Role - used to set or add a player's name or role;
  • Init - denotes the initial, true game state (the true fact given at that point in time);
  • True - denotes the current state of the game (the true fact given at this point in time);
  • Does - The move, the action that the player is taking in the current state of the game;
  • Next - indicates a true fact about the following game state;
  • Legal - refers to a legal step ("Does") in the current state;
  • Goal - is used to define the goal of the game in the current state;
  • Terminal - means the current state of the endgame;

GDL is an open language, the vocabulary of which can be expanded, but the meaning of these basic terms is always the same for all games.

Definition of terms game Tic-Tac-Toe (two players)

Role - two players - xplayer and oplayer

(role xplayer)
(role oplayer)

Init - xplayer starts

(init (control xplayer))
(init (cell 1 1 blank))
 ...
(init (cell 3 3 blank))

True - xplayer active in the current state

(true (control xplayer))
(true (cell 1 1 b))
(true (cell 3 2 x))
(true (cell 3 3 o))

Does - xplayer marks cell (1, 2) while oplayer does nothing

(does xplayer (mark 1 2))
(does oplayer noop)

Next - often depends on the moves chosen

(<= (next (control xplayer))
(true (control oplayer)))

Legal - at least one move for each player in each (non-terminal) state

(<= (legal ?player (mark ?x ?y))
(true (cell ?x ?y b))
(true (control ?player)))

Goal - assigns ratings to these states

(<= (goal ?player 100)
(line ?player))

Terminal - Defines terminal states

(<= terminal
(role ?player)
(line ?player))

Web links

Individual evidence

  1. Standord University - Game Description Language Specification (PDF, 285 kB) - accessed on December 5, 2016
  2. (GDL) Action planning and general game docstoc.com - accessed on March 1, 2013