HELP!----Error: "function at line 2577 has more than 60 upvalues"

Hi,

I´m working on one of my games and Corona shows the error that show the attach image.

The line 2577 is the line of the creation of the scene (  function scene:create( event )  )

I think this is due to the ‘scene:create’ function has been enclosed on another function but I´d review all my code and I do not see anything

I will appreciate any help

Your module has way too much code in it. It will be difficult to resolve. You need to (a) post the lines which are shown in the error and (b) boil your module down so that some of its work is done in other files.

Some lua editors, such as Zerobrane Studio, have a function to autoindent your code. You’ll then be able to see which function, loop etc. matches with which end statement, and crucially find the missing one.

Thanks horacebury, I have solve the problema just a hour ago. I do not understand yet but a simple condition that incriminates a global variable was the cause.

Thanks nick_sherman, I use Zerobrane Studio but I solve the problem already.

Your module has way too much code in it. It will be difficult to resolve. You need to (a) post the lines which are shown in the error and (b) boil your module down so that some of its work is done in other files.

Some lua editors, such as Zerobrane Studio, have a function to autoindent your code. You’ll then be able to see which function, loop etc. matches with which end statement, and crucially find the missing one.

Thanks horacebury, I have solve the problema just a hour ago. I do not understand yet but a simple condition that incriminates a global variable was the cause.

Thanks nick_sherman, I use Zerobrane Studio but I solve the problem already.