Jump to content

Object [object Object] has no method 'preUpdate'


Recommended Posts

I'm migrating a game I made with Phaser 1.1.3 to 2.0 and I'm having some issues.


On Chrome (33.0.1750.117 m):

Uncaught TypeError: Object [object Object] has no method 'preUpdate'

On Firefox (27.0.1):

TypeError: this.children[i].preUpdate is not a function

The offending line is the number 24,669 in Phaser.js (updated today):

    while (i--)    {        this.children[i].preUpdate();    }

I  performed a grep in all available examples looking for a hint about what I was missing but I had no success.


Any clue?


Thank you.

Link to comment
Share on other sites

There is a group somewhere that has a child that does not have a preUpdate function.

I ran into the same problem with Graphics objects when I first converted.

I'd recommend putting a conditional breakpoint on that line, breaking if the child has no preUpdate function, and finding out what particular object is causing the problem.

Link to comment
Share on other sites


  • Recently Browsing   0 members

    • No registered users viewing this page.
  • Create New...