After click new game, my player will clone in the middle of plane and controller will be enable at the right corner. In order to control the movement of player, I using
this.app.root.findByTag method to get my player (my player has a tag call myPlayer). While console.log the player with tag, the array showing that it able to find my player. But when I trying to move the controller, I giving out that my Cannot read property ‘MyScriptName’ of undefined. What I should do to pass the controller value to the player movement value? The value that when I move the controller store in
dragnwescript.js and the pass the value to
playerMovement.js to move the player.
That my project link here PlayCanvas 3D HTML5 Game Engine