Random window issues since 164

Bugs will be moved here once resolved.

Post » Fri May 02, 2014 4:08 pm

I don't know what could be done other than impose an arbitrary limit of say 1000 icons, and stop returning icons after that. But then if you have a project with 2000 objects, it just won't show icons for half of them, which isn't great.
Scirra Founder
B
402
S
238
G
89
Posts: 24,628
Reputation: 196,023

Post » Wed May 14, 2014 7:41 am

@damainman, have you tried to close all C2 tabs? When you visit your layouts of event sheets it remains open in a tab consuming memory. I had this random error/crashing issue long time ago due to C2 memory leak. All my issues resolved when I started closing tabs regularly.
B
44
S
5
G
5
Posts: 412
Reputation: 5,771

Post » Wed May 14, 2014 12:16 pm

@nemo It does it with only one tab open. It can be any tab, and sometimes it happens as soon as you open C2. We have removed all of the extras from the game now. We might take a flogging from a couple of the Kickstarter backers possibly but I think more people are worried about playing the full game working instead of playing the extras or the NES version. We are just going to have the NES styled version of the game as a separate download now for customers.

The temp fix was killing disabled lines in events, deleting objects, and clearing out unused layouts (some of the maps have been redesigned 3-4 times so there were a couple of old maps still). It's not just the objects causing it, it's everything - overall game size I guess.
B
47
S
12
G
7
Posts: 341
Reputation: 7,953

Post » Wed May 21, 2014 4:56 am

You're not alone in this, @damainman at all. I regularly have those display issues and at times get the hicon error you posted in the op. My C2 failures almost always happen after running a preview (or export) of the game. Any subsequent preview (if I can get one to work at all) will have all text tiny and missing values and the C2 IDE is largely unresponsive and throws errors left and right.

@Ashley if it is indeed linked with a need for windows to show icons, would it be possible to add a text-only option for projects that intend to be large? I've done some toying and I can increase how many successful previews I can achieve by having the object and property bars closed, saving, restarting, and previewing from there so those things don't have to load. It also did help a little to split up my biggest event sheet (500 events down to 2x250).

I'm not being wasteful or poorly planning Courier. I could probably reduce the object count by around 50 or 60 if I really tried, but the project is at 1,200 objects by my best count. About half of it comes from Spriter and how many NPCs I have in the game (and all the objects created for it). My events aren't crazy--for the whole project I'm at 2,600 events split up across a bunch of event sheets. It's as efficient as I can make a large, varied RPG. It never reaches 40 MB of vram and never more than 1,500 objects in the heaviest of situations.

So a (relatively) simple fix like having and option to make objects in the project bar text-only may correct the problem if I'm thinking about this correctly. An option down the road would be something like a small preview window of an object when you click on it in the list, but something to help larger projects run more stably in C2 would be a huge help.
B
103
S
38
G
19
Posts: 962
Reputation: 17,996

Post » Wed May 21, 2014 6:28 am

I was chatting with C7 about this earlier, and had some thoughts: I don't know how icons work, but could they possibly be 'spritesheeted' the same way sprite animation frames are on export so multiple icons would be on one texture? Could that increase the number of icons possible?

Or could the icon system currently used be subverted somehow by displaying object icons in some other manner, like drawing them manually?

Or could C2 have a max limit on the number of icons and start replacing currently unused icons with the onscreen icons once it goes past the limit rather than just trying to create more of them?
Moderator
B
95
S
34
G
33
Posts: 3,007
Reputation: 27,876

Post » Wed May 21, 2014 12:29 pm

Does this still happen on the 64-bit version of C2? The OP error message indicated a 32-bit install of Construct 2.

I've looked in to this, and it appears Windows simply has a hard limit of 10,000 UI objects, even in the latest versions, which sucks. C2 also provides icons in 3 sizes (16x16, 32x32, 64x64) so with 2000 object types in your project you could get up to 6000, and then I guess there's a bunch of other UI stuff going on, so it hits the limit and basically the UI starts falling apart as it can't allocate any more UI objects from the OS.

I've read a few posts by MS engineers along the lines of "10000 should be enough for anybody" (sigh) so doesn't look like this will change any time soon. I will review the code in C2 and make sure it's as efficient as possible, but I'm not sure how to avoid creating all the necessary icons for components like the project bar, where it needs to be able to show everything at once. Icons are also already lazy-loaded per size requested so that should keep the counts down too. Perhaps there's something else I'm missing, but I'm not sure what it could be.

Possible hackish workaround - do not attempt if you're not comfortable with possibly system restoring/booting in to safe mode to fix things: from what I've read you can increase Windows' limits slightly, by modifying the registry. Head to HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Windows. There are two keys initially set to 10000: GDIProcessHandleQuota, and USERProcessHandleQuota. Set them both to 18000 (decimal) and reboot the machine, and hopefully C2 will have more breathing room with icons.
Scirra Founder
B
402
S
238
G
89
Posts: 24,628
Reputation: 196,023

Post » Wed May 21, 2014 12:42 pm

Yes, I use 64-bit C2. It's a little strange since it doesn't happen every time, but almost always immediately following a preview.
B
103
S
38
G
19
Posts: 962
Reputation: 17,996

Post » Thu May 22, 2014 1:19 pm

OK, so I've added a new preference to the next build allowing you to turn off the icon cache, so it has fewer icons sitting in memory. It will slow down the editor since every time it needs an icon it must re-load the original image and stretch it down to an icon size. To help keep that as fast as possible it will also reduce the icon quality. r170 should be out soon with that option, so you can try it out and see if it helps - let me know.
Scirra Founder
B
402
S
238
G
89
Posts: 24,628
Reputation: 196,023

Post » Thu May 22, 2014 9:21 pm

That sounds awesome! You're the best, I look forward to trying it.
B
103
S
38
G
19
Posts: 962
Reputation: 17,996

Post » Sat May 24, 2014 12:11 pm

Has anyone tried turning off the icon cache and does it help avoid UI issues? Also does it slow down the editor too much?
Scirra Founder
B
402
S
238
G
89
Posts: 24,628
Reputation: 196,023

PreviousNext

Return to Closed bugs

Who is online

Users browsing this forum: No registered users and 0 guests