material.inc.php in front-end

Game development with Board Game Arena Studio
Post Reply
User avatar
pickardj79
Posts: 17
Joined: 26 July 2020, 04:34

material.inc.php in front-end

Post by pickardj79 »

Quick question, the docs here http://en.doc.boardgamearena.com/BGA_St ... ipt_module state that "... store in material.inc.php so both server and client have access to it" (under heading "Multi Step Interactions: Action Stack - Using Client States").

Does material.inc.php get to the front-end automagically (and if so, how is it accessible there) or do you have to pass it explicitly through, for instance, getAllData()? My guess is the latter, but I wanted to check because I prefer not to have to do work that I don't have to :)
User avatar
quietmint
Posts: 299
Joined: 31 July 2017, 00:28

Re: material.inc.php in front-end

Post by quietmint »

It is not automatic. You need to send the data yourself in getAllDatas, for example, or as part of an "arg" function for the state that needs it.
User avatar
pickardj79
Posts: 17
Joined: 26 July 2020, 04:34

Re: material.inc.php in front-end

Post by pickardj79 »

Awesome - thanks. Added a quick note to the material.inc.php doc.
Post Reply

Return to “Developers”