1
\$\begingroup\$

I am using the Phaser framework for game development, but while working on it I face a bug which is annoying, I have the following message:

InvalidStateError: An attempt was made to use an object that is not, or is no longer, usable

enter image description here

The consequence is that because of it I now cannot move my hero, I need to first click once on the phaser window and then it worked, so I tried to debug it, and even by using the default phaser demo the same error message appear and cause the same but, so i concluded that my code is not the problem.

Do you please have any idea? Is there a way to know how to fix it ? Otherwise how can have more details about it in the console?

Note: if you wanna download the official starting tutorial to reproduce the error:

  1. Download .zip: here
  2. Beginner Tutorial: here
\$\endgroup\$

Your Answer

By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Browse other questions tagged or ask your own question.