Page 1 of 1

Using material.inc.php in gamename.game.php

Posted: 02 February 2019, 17:56
by Toto65
I have some trouble using variables defined in material.inc.php in the function setupNewGame of gamename.game.php.
I simply define "$this->toto = array(2 => 150, 4 => 150);" in material,
but when I try to access them in the function setupNewGame of gamename.game.php with "$this->toto[2]", I get an error "Undefined property: GameName::$Array " when I start a new game.

Re: Using material.inc.php in gamename.game.php

Posted: 02 February 2019, 18:54
by A-dam
Looks good to me, are you sure the problem is not somwhere else?