Nomyx-Language-0.5.0: Language to express rules for Nomic

Safe HaskellNone

Language.Nomyx.Expression

Contents

Description

This module containt the type definitions necessary to build a Nomic rule.

Synopsis

Documentation

Nomyx Expression

data Eff Source

Constructors

Effect 
NoEffect 

type Nomex = Exp EffectSource

A Nomex (Nomyx Expression) allows the players to write rules. within the rules, you can access and modify the state of the game.

type NomexNE = Exp NoEffectSource

A NomexNE (Nomyx Expression No Effect) is a specialisation of the type that guaranties that the instructions will have no effects.

data Exp whereSource

Variables

data V a Source

a container for a variable name and type

Constructors

V 

Fields

varName :: String
 

Instances

Events

data Player Source

events types

Constructors

Arrive 
Leave 

data Time Source

Instances

data Message m Source

Instances

data Input a Source

Instances

Typeable1 Input 
Eq e => Eq (Input e) 
Show a => Show (Input a) 

data InputForm a Source

Constructors

Radio [(a, String)] 
Text 
TextArea 
Button 
Checkbox [(a, String)] 

Instances

data Event a whereSource

events names

Instances

data EventData a whereSource

data associated with each events

type Msg a = Event (Message a)Source

Rule

type Rule = Nomex ()Source

Type of a rule function.

data RuleStatus Source

the status of a rule.

Constructors

Active 
Pending 
Reject 

Player

Victory

concatMapM :: Monad m => (a -> m [b]) -> [a] -> m [b]Source