- Edited
I'm doing a picross game and stumble about a serious performance issue. As any picross fan know you quickly end up with a LOT of case to manage (a 40x40 grid is 1600 case ...)
I tried two solution : one 2Dnode per case (easier to manage input and easier to check for bug since i got separate .gd for the main process and the update case one) and using a single script (lot of computing position involved but perhaps better performance)
in both case FPS drop to 16 or so when the grid reach size like 30x30
To make sure my code wasn't the issue i put all but the grid initialization and the _draw process as comment (setting size through a variable manually set in editor) and got the same result. i double check for no update call hidden somewhere.
Does it means a 30x30 2DArray is too much for the engine to manage ? If so is there a better way to do this ?
I use $"Label".set_text(String(int(Engine.get_frames_per_second()))) to check FPS. perhaps it's not the good way ?
As a side note i use \ a lot (those corrd check can have long if condition ...) but when i comment using """ it give me error about misplaced \ I just have to remove them but when using commenting to temporarily disable part of code it's annoying as hell ... is there a solution ?