Search found 18 matches

by RichardSPeters
10 July 2026, 02:14
Forum: Developers
Topic: gamestate label issue
Replies: 3
Views: 42

Re: gamestate label issue

will do - thanks
by RichardSPeters
09 July 2026, 06:46
Forum: Developers
Topic: Executing action when not active
Replies: 5
Views: 70

Re: Multi Player Players

Sorted (after some prodding in the right direction). Client Side code to add a button that can be clicked when not your turn is this.bga.statusBar.addActionButton(_("~ SNAP ~"), () => this.bga.actions.performAction("actSNAP", {}, { checkAction: false }), ); Server side code is us...
by RichardSPeters
09 July 2026, 05:53
Forum: Developers
Topic: Executing action when not active
Replies: 5
Views: 70

Re: Multi Player Players

Ok - figured it out. What I need to do is pass
{ checkAction: false },
as a paramenter to the performAction call.

This stops the error message 'This is not your turn' appearing BUT now I am getting "The server reported an error."
by RichardSPeters
08 July 2026, 22:51
Forum: Developers
Topic: Executing action when not active
Replies: 5
Views: 70

Re: Multi Player Players

Lets imagine a game of SNAP being implemented. So for SNAP if we have three players Bilbo, Gollum and Frodo where Bilbo is currently the active player and the Jack of Spades is on the table and the onEnteringState in playerTurn.js looks like this onEnteringState(args, isCurrentPlayerActive) { if (is...
by RichardSPeters
08 July 2026, 05:53
Forum: Developers
Topic: Executing action when not active
Replies: 5
Views: 70

Executing action when not active

Edit:Take first couple few comments with grain of salt as I had nade a few incorrect assumptions! Working my way through a v simple first game which has a multi player component - i.e. Player Turn state is MULTIPLE_ACTIVE_PLAYER Can anyone point me in the direction of games (the simpler the better) ...
by RichardSPeters
07 July 2026, 03:27
Forum: Developers
Topic: gamestate label issue
Replies: 3
Views: 42

Re: gamestate label issue

Issue was with how my intpretation of how game state lables work. Assumed that when they are initated i.e. public function __construct() { parent::__construct(); $this->initGameStateLabels( [ "numbaValue" => 0 ] ); the the value uased, "0", is the default value - WRONG it's a lab...
by RichardSPeters
07 July 2026, 00:15
Forum: Developers
Topic: Help needed - Setting project basics for the game Last Prime Minister
Replies: 2
Views: 64

Re: Help needed - Setting project basics for the game Last Prime Minister

Suggest you start with the Hearts tutorial (https://en.doc.boardgamearena.com/Tutorial_hearts) as this helped me greatly (as also a newbie to PHP and the BGA framework) plus there is a huge amount of info in these pages https://en.doc.boardgamearena.com/Game_ ... c:_Game.js
by RichardSPeters
06 July 2026, 23:16
Forum: Developers
Topic: gamestate label issue
Replies: 3
Views: 42

gamestate label issue

Code is currently in ALPHA state and yesterday could start game no issues. This morning when starting up I get Unexpected error: Propagating error from gameserver 1 (method: createGame): Fatal error during numbabeta setup: Unknown gamestate label: numbaValue (reference: GS1 07/07 00:05:15) (referenc...
by RichardSPeters
05 July 2026, 23:18
Forum: Developers
Topic: Repeatable database table of cards
Replies: 3
Views: 54

Re: Repeatable database table of cards

debug function to set the db how you want
That's perfect - thanks and coupling with the state buttons will sort all my problems.
by RichardSPeters
05 July 2026, 10:45
Forum: Developers
Topic: Repeatable database table of cards
Replies: 3
Views: 54

Repeatable database table of cards

Ok - first game being developed and pack of cards are stored in the database using the logic not dissimilar to the hearts tutorial. Have found that every time the game is launched the card_id in the database table is randomised – even without using the shuffle function. In the deployed version this ...

Go to advanced search