TIP BridgePlugin is not installed on Foswiki.org.

Bridge Plugin

Render bridge hands and auction from RBN

Features

The Bridge plugin supports the display of bridge games from data about the hands and auction stored in data fields. The plugin supports three types of display through macros:
Macro Purpose
BRIDGEHANDS Displays the hands dealt.
BRIDGEAUCTION Displays the auction as recorded.
BRIDGEPLAY Supports the play of the hands dealt. Incomplete hands are randomly completed.

All data is expected in Richard's Bridge Notation (RBN) which is well documented and in the public domain. Three fields are required for the plugin to be fully functional.
Field Purpose
Board RBN "B" entry: Board Number
Hands RBN "H" entry: Hands (cards held by each player)
Auction RBN "A" entry: Auction (dealer, vulnerability and (optional) call sequence)

The Bridge plugin accepts incomplete deals that have full hands missing. This is useful if you want to practice bidding. When you play these hands, the missing hands are completed randomly.

This plugin supports a wiki application, which is documented separately as the BridgeApp. The application requires the Wiki Workbench and other plugins and contributions. For details refer to the documentation of the BridgeApp.

Syntax

Common parameters for all macros

Parameter Purpose Default
web The web where the topics that contain the hand descriptions are stored. BASEWEB
topic The topic that contains the record of the hand to be played. Format web.topic is accepted. [BASEWEB].BASETOPIC

%BRIDGEHANDS{ ... }%

Parameter Purpose Default
board Show the dealt hands around a table. This parameter points to the gif presenting the table. on is shorthand for the default gif. (on) System.BridgePlugin/bridgeboard.gif

%BRIDGEAUCTION{ ... }%

Parameter Purpose Default
rounds The number of rounds of the auction that will be displayed. <integer> | practice. Practice will display the auction in successive rounds from the bid of the dealer foreward. all

%BRIDGEPLAY{ ... }%

Parameter Purpose Default
deal Is the description of the hand complete? Values: full | partial | new. An incomplete hand will be randomly completed for play. partial
zoom Scale the display from the size presented at ... Format x.y. 0.7

Examples - BridgePlugin

The examples below assume the following field values associated with the BASEWEB.BASETOPIC:
Field Value
Board B 12
Hands H W:T2.Q73.AK972.K95::QJ95.AKJ2.43.JT2
Auction A WB:1DXR1S:PPXA

BRIDGEHANDS

%BRIDGEHANDS% %BRIDGEHANDS{ board="on" }%
BridgeHands.png BridgeHandsTable.png

BRIDGEAUCTION

%BRIDGEAUCTION%  
Auction3.png  
%BRIDGEAUCTION{ rounds="practice" }% %BRIDGEAUCTION{ rounds="practice" }%
Auction1.png Auction2.png

BRIDGEPLAY

%BRIDGEPLAY%{ zoom="0.5" }%  
Bridgeplay.JPG

Installation

You do not need to install anything in the browser to use this extension. The following instructions are for the administrator who installs the extension on the server.

Open configure, and open the "Extensions" section. Use "Find More Extensions" to get a list of available extensions. Select "Install".

If you have any problems, or if the extension isn't available in configure, then you can still install manually from the command-line. See http://foswiki.org/Support/ManuallyInstallingExtensions for more help.

Dependencies

NameVersionDescription
Foswiki::Contrib::WikiWorkbenchContrib>=4.00Required
Foswiki::Contrib::CopyContrib>=3.00Required

Change History

1.00 (31 Oct 2018) Initial release

I Attachment Action Size Date Who Comment
Auction1.pngpng Auction1.png manage 2 K 01 Nov 2018 - 07:06 BramVanOosterhout  
Auction2.pngpng Auction2.png manage 2 K 01 Nov 2018 - 07:06 BramVanOosterhout  
Auction3.pngpng Auction3.png manage 3 K 01 Nov 2018 - 07:06 BramVanOosterhout  
BridgeHands.pngpng BridgeHands.png manage 6 K 01 Nov 2018 - 07:05 BramVanOosterhout  
BridgeHandsTable.pngpng BridgeHandsTable.png manage 4 K 01 Nov 2018 - 07:06 BramVanOosterhout  
BridgePlugin.md5md5 BridgePlugin.md5 manage 159 bytes 01 Nov 2018 - 07:08 BramVanOosterhout  
BridgePlugin.sha1sha1 BridgePlugin.sha1 manage 183 bytes 01 Nov 2018 - 07:08 BramVanOosterhout  
BridgePlugin.tgztgz BridgePlugin.tgz manage 265 K 01 Nov 2018 - 07:07 BramVanOosterhout  
BridgePlugin.zipzip BridgePlugin.zip manage 287 K 01 Nov 2018 - 07:07 BramVanOosterhout  
BridgePlugin_installerEXT BridgePlugin_installer manage 10 K 01 Nov 2018 - 07:08 BramVanOosterhout  
Bridgeplay.JPGJPG Bridgeplay.JPG manage 27 K 01 Nov 2018 - 07:07 BramVanOosterhout  
bridgeboard.gifgif bridgeboard.gif manage 531 bytes 01 Nov 2018 - 07:05 BramVanOosterhout The bridge board
Topic revision: r1 - 01 Nov 2018, BramVanOosterhout
The copyright of the content on this website is held by the contributing authors, except where stated elsewhere. See Copyright Statement. Creative Commons License    Legal Imprint    Privacy Policy