options in javascript

Game development with Board Game Arena Studio
Post Reply
User avatar
Emanuele Ornella
Posts: 23
Joined: 09 January 2016, 19:07

options in javascript

Post by Emanuele Ornella »

Is there a way to get the options in javascript?

From here: http://en.doc.boardgamearena.com/Game_o ... ns.inc.php

it is indicated how to get in php: $this->gamestate->table_globals[100]

but not how to get in javascript.

There is a way for preferences:

this.prefs[100].value

but what about options?
this.options[100].value does not work...

Thx,
Ema
User avatar
Emanuele Ornella
Posts: 23
Joined: 09 January 2016, 19:07

Re: options in javascript

Post by Emanuele Ornella »

Ok, never mind..
I am passing:

$result['roundwinner'] = $this->gamestate->table_globals[100];

from getAllDatas

and getting it from javascript as

this.gamedatas.roundwinner

So sorted.
Ema
User avatar
Inaofr
Posts: 142
Joined: 26 March 2020, 22:26

Re: options in javascript

Post by Inaofr »

I'm doing the same. I don't know another way.
You should edit your first post to add [SOLVED] in front of the title.
Post Reply

Return to “Developers”