next up previous contents
Next: gnotify Up: Setting Commands Previous: censor


  Usage: set formula formula-expression

The formula variable allows you to filter out match requests. If you have a formula set, then any match request that does not satisfy your formula is automatically ignored. Instead of having an option to accept it, you are simply notified that the offer was made and ignored. The following is an explantion of how the formula can be set and used.


The following formula operators are allowed, in order of precedence in the calculations and evaluations:

! (not)
- (negation)
*, /, +, - (calculation)
<, <=, =<, >, >=, => (comparison, (<= and =< are equivalent, as are >= and =>)
=, ==, !=, <> (two ways of saying both equals or not equals)
&, && (both "and")
|, || (both "or").

Parentheses () are also allowed, as is a pound sign '#' for comments. The program divides by a fudge factor of .001 instead of dividing by 0.


The following variables are allowed in formulas:

abuser Player is on the abuser list
assesswin Win would gain # rating points
assessdraw Draw would change rating by # points
assessloss Loss would decrease rating by # points
atomic Match will be wild/atomic in type
blitz Match will be blitz in type
computer Player is a computer
inc Increment time for each player
maxtime(n) The maximum time n moves will take BOTH players (in seconds)
mymaxtime(n) The maximum time n moves will take YOU (in seconds)
myrating Your rating
nonstandard Different time controls for the two players
private Game will be private (not observable)
rated Game will be rated
rating Opponent's rating
ratingdiff Value equal to rating - myrating
registered Opponent is a registered user
standard Game will be standard in type
time Start time for each player
timeseal Opponent uses the timeseal program
untimed Game will not involve the clock
wild Game will be wild in type

Also, the word "minutes" is allowed after a number that is not enclosed in parentheses (but right now, you must use "1 minutes"; the singular is not recognized). The word has the effect of multiplying the previous number by 60, thus turning minute-values into seconds-values - important for the maxtime and mymaxtime variables.


F1 through f9 are user-defined formula variables. They can be used to avoid having to retype your entire formula when you want to change one part of it, or to adjust your formula depending on your mood. For example, if your various f#'s were ...

  set f1 rated & time=5 & inc=0    # rated 5 minute games
  set f2 ratingdiff
  set f3 maxtime(40) >= 2*8minutes # at least 8 mins each for 40 moves
  set f4 f2>400                    # I want a REAL fight
  set f5 !abuser

... then, depending on your mood, you could type:

      set formula f1 & f5     # rated 5 min. games only
      set formula f2 > -100   # long games, decent competition
      set formula f1 & !f4
      set formula f2 >= 0 | blitz

MAXTIME EXAMPLE: If your formula (or f#) were ...

      set formula maxtime(30) <= 10 minutes

... this would allow no more than 10 minutes total time for the first 30 moves of the game (5 minutes for each player, or any other combination).

CREDITS: Formula program for FICS written by Dave Herscovici (hersco)

See also: blitz, match, variables

next up previous contents
Next: gnotify Up: Setting Commands Previous: censor

Klaus Knopper <>