i created a GameLogic class to manager the game flow, instead of write all game code directly in loop hooks.
i will re-new it in each begining of loop, and serialize and store it in the end of loop.
now i want print out some debug information inside of it.
console.log
is not work.
and i try to transfer the logger object from the paramter of loop handler to the GameLogic when create it. like new GameLogic(logger)
. however, it is not work.
has any one got clue to solve it?