Search Unity

error Update() is too complex?

Discussion in 'Editor & General Support' started by jo82, Nov 25, 2017.

  1. jo82

    jo82

    Joined:
    Dec 3, 2015
    Posts:
    47
    Is there a certain limit of line that you can use in a project?

    I got this "Update() is too complex" error recently and had to trim down my code a bit and the error got away but my project will only increase with time.

    I work with unityscript mostly and I had around 19 500 line in my main .js update function when this error would popup.
     
  2. nat42

    nat42

    Joined:
    Jun 10, 2017
    Posts:
    353
    I don't know the answer, but 20 thousand lines in a single function is... well it probably means you should write it differently, 1000 lines is way too long.