Search found 19 matches

by Lone Boardgamer
24 June 2021, 13:56
Forum: Developers
Topic: Unexpected error: Invalid player number for this game: 1
Replies: 18
Views: 2207

Re: Unexpected error: Invalid player number for this game: 1

I was talking about the general setup of the game, so the setupNewGame and any game state before you reach your first (multi/single) active state. The only setup I am aware of is in states.inc.php, stats.inc.php, gameoptions.inc.php and gameinfos.inc.php files. I've checked them all, commented cust...
by Lone Boardgamer
24 June 2021, 12:36
Forum: Developers
Topic: Unexpected error: Invalid player number for this game: 1
Replies: 18
Views: 2207

Re: Unexpected error: Invalid player number for this game: 1

Tisaac wrote: 24 June 2021, 11:36 And you should probably join the discord server, it will be easier to help you over there
I don't use Discord, but if you really think it's easier to get help there, I can try. Which discord server exactly?
by Lone Boardgamer
24 June 2021, 12:27
Forum: Developers
Topic: Unexpected error: Invalid player number for this game: 1
Replies: 18
Views: 2207

Re: Unexpected error: Invalid player number for this game: 1

Only solution : comment everything in the setup and in the first state (return [ ] for args for instance). Once the game load, you can uncomment and refresh the page, you will be able to detect if something is wrong in the args of the first state. Otherwise simply uncomment setup step by step until...
by Lone Boardgamer
24 June 2021, 11:23
Forum: Developers
Topic: Unexpected error: Invalid player number for this game: 1
Replies: 18
Views: 2207

Re: Unexpected error: Invalid player number for this game: 1

I assume BGA Studio source code is not available anywhere, right? Would be much easier for me to simply debug the issue by looking into the parent class code.
by Lone Boardgamer
24 June 2021, 10:52
Forum: Developers
Topic: Unexpected error: Invalid player number for this game: 1
Replies: 18
Views: 2207

Re: Unexpected error: Invalid player number for this game: 1

thoun wrote: 24 June 2021, 10:34 I have this error sometimes, but can't remember the cause. Usually I rollback my changes until it works then reintroduce changes until I catch the culprit line
I've made too much changes, basically built the complete game starting routine, so I can't go back.
by Lone Boardgamer
24 June 2021, 10:49
Forum: Developers
Topic: Unexpected error: Invalid player number for this game: 1
Replies: 18
Views: 2207

Re: Unexpected error: Invalid player number for this game: 1

I've no idea about the "invalid player number" error, but given that the game starts with 2 players and then shortly after seems to think there's only 1 - are you doing something weird in setupNewGame that might accidentally remove a player from the players array, or remove a row from the...
by Lone Boardgamer
24 June 2021, 10:45
Forum: Developers
Topic: Unexpected error: Invalid player number for this game: 1
Replies: 18
Views: 2207

Re: Unexpected error: Invalid player number for this game: 1

I guess you're not familiar with PHP - there is a difference between using single quotes and double quotes for strings. Double quotes automatically interpolate variables, so anything inside a double-quoted string of the form $sometext or ${sometext} is treated as you wanting to substitute the value...
by Lone Boardgamer
24 June 2021, 10:18
Forum: Developers
Topic: Unexpected error: Invalid player number for this game: 1
Replies: 18
Views: 2207

Re: Unexpected error: Invalid player number for this game: 1

Error pops when startgame.html is called. Here's a stack, if it helps: #0 /var/tournoi/release/tournoi-210621-0932/www/action/table/table.action.php(119): Tablemanager->startGame('280128')#1 /var/tournoi/release/tournoi-210621-0932/www/include/webActionCore.inc.php(189): action_table->startgame()#2 ...
by Lone Boardgamer
24 June 2021, 09:51
Forum: Developers
Topic: Unexpected error: Invalid player number for this game: 1
Replies: 18
Views: 2207

Re: Unexpected error: Invalid player number for this game: 1

You are using " instead of ' in your states.php file Yes, this fixed "Undefined variable: actplayer/you" part. What a weird error, I would've NEVER guessed that quotes are the reason! Thank you. Still have an issue with player number. The new error message is: Unexpected error: Propa...

Go to advanced search