TheGameCreators / GameGuruRepo

The GameGuru Repository For Community Collaboration
http://www.game-guru.com
137 stars 56 forks source link

BUG GGMAX VERY LONG DELAY before objects become active in level. #5247

Closed imothep85 closed 7 months ago

imothep85 commented 7 months ago

There is a LONG delay between clicking on a 3D object and the software's reaction to making the object active and selected. The problem is that you have to wait 5sec PER CLICK before the object can be positioned in the level, and you waste an ENORMOUS amount of time waiting for the object to be selected and active once you've clicked on it, and if you click in the wrong place.....it's back to work... I waste a CRUCIAL amount of time, not to say a HUGE amount of time, waiting for objects to be selectable in real time and for them to be able to be moved in real time, without waiting a monstrous amount of time....it's horrible to have to wait and waste time, not to mention the fact that in the long run, it's extremely hard on the nerves... This problem needs to be corrected as a matter of urgency, as it causes major development problems, especially when levels are filled with objects of all kinds, and certain modifications need to be made.

Thanks to all

synchromesh62 commented 7 months ago

What's it like to select and move stuff on an default map ? Things will slow down in the editor if there is a huge amount of content and your level seems HUGE with caves, terrain mesh's and content.

Blood-Moon-Interactive commented 7 months ago

Also might be helpful to provide machine specs, a video of the issue, maybe a sample model for Lee to examine. Are these all custom models or did they come with Max? Details like that rather than dramatic statements and hyperbole will lead to a resolution faster.

imothep85 commented 7 months ago

my PC is an intel I7700k cpu, Nvidia 1080ti 11gb, and 32gb ram, win10. My models are all custom only the trees and grass are from max.

Now we can make infinite maps, huge levels in ggmax, imagine if i only use LESS than 1km square, for my whole game where i put all my props....the problem is not my props, it's the the game engine. In Unreal we don't have LAGS when selecting objects, even with millions of polys.... But i'm working with GGMAX, and i know we can do something very good with this game engine.

imothep85 commented 7 months ago

A short video showing HOW slow ggmax is with customs objects, when clicked they are very very slow to become active. (this video works for only 2days) https://streamable.com/id81b4

synchromesh62 commented 7 months ago

A short video showing HOW slow ggmax is with customs objects, when clicked they are very very slow to become active. (this video works for only 2days) https://streamable.com/id81b4

Well that was not what i was expecting granted. I was expecting a juddery performance so not sure what would cause that delay except a huge amount of assets .. Even so you avoided the crucial question .. What's it like to select and move stuff on an default map ? This will confirm if its map related ( as in size and content ) or Max itself. Easier to sort if you know the most likely cause.

imothep85 commented 7 months ago

as you can see here, this is a default map from ggmax, it takes some time before the object once clicked become active and the user can interact with it... its the same for every elements in default maps....and same on my game....so as i explained, if we miss the right object when clicked we have to re-click on the right object then wait for the object to be active "selected" & then do the change, for example a rotation, BUT if we have to move the object we have to do another operation again...it's waiting 5sec +5sec+5sec..... etc etc etc as explained in the beginning of this post. SELECTIONABLE objects and interactivity has to be in real-time NOT with HUGE delays. I took the example of Unreal but, with smaller game engine,s selection & modifications of objects properties are in real-time...no delay...

https://github.com/TheGameCreators/GameGuruRepo/assets/8946215/68c93d6f-8c0c-4e69-8f3a-9f695871db0c

synchromesh62 commented 7 months ago

SELECTIONABLE objects and interactivity has to be in real-time NOT with HUGE delays. They are .. what your seeing is weird. This is what i see.

https://github.com/TheGameCreators/GameGuruRepo/assets/35708217/419f605c-245d-486a-b82c-154cf15248d4

imothep85 commented 7 months ago

well as i explained and show in the videos is completely different. i have HUGE delays before the objects become active. it pushes me to long waiting times, and mentally it tires me, I have to wait each time for the object to be selectable, I use the latest EXPERIMENTAL version of ggmax

LeeBamberTGC commented 7 months ago

@imothep85 Thanks for the videos, the zombie escape level is the real indicator as that level is quite small with just a few objects and you can clearly see the object being clicked, then a long delay before it is highlighted. Your system specs look fine, and I am pretty sure this has not been reported elsewhere, so it is likely something systemic, we just need to figure out what is causing it. The behaviour that is frustrating you is NOT normal, and is a bug for sure.

Can you create an empty project with one carboard box dropped in, and then click that and move it in the video, I just want to make sure it is related to something during the click and not the number of objects in the scene or some kind of level complexity issue. We can then add some debug info to find out where the slow part is.

Are you okay with me sending you a debug build and some instructions on how to use OPTICK, as that performance profiler will tell me pretty much what I need to know?

imothep85 commented 7 months ago

i'm afraid to fail with optick i saw a video where you was explaining it on YouTube, it's too technical for me to understand. I'm going to try with an empty project and cardboard objects and make a short video.

But YES of course i will accept a debug build, i want that problem to be quickly solved to continue the development of my game in good conditions.

imothep85 commented 7 months ago

hare its a recorded short video, i created LOT of boxes in the default map and i can select them in real time and modify them without delay.

https://github.com/TheGameCreators/GameGuruRepo/assets/8946215/13f914ce-69d8-4fb1-8a50-ca013c21eb15

imothep85 commented 7 months ago

and here some technical info when i run my own game. info

imothep85 commented 7 months ago

here another test with lot of coffins... i can select them in realtime

https://github.com/TheGameCreators/GameGuruRepo/assets/8946215/47e1bf20-fa0d-4fe3-bb15-2ff4b9a0e204

imothep85 commented 7 months ago

and here another test with my custom 3d dunes, i make it giant to test and put lot of massive columns, and coffins everywhere, but no lags... i can select the objects in realtime. https://streamable.com/zbeodj

imothep85 commented 7 months ago

I'm removing the lights, but it's not lights the problem... If i remove all the lights from my game...it doesn't make sense of course...and the problem is still there. cave with lights

imothep85 commented 7 months ago

I FOUND SOMETHING........ but i can't explain it because i'm not a developer, i did two video in this video i will show you something, when i CLICK on my cave massive stones i can click in real-time because they are LOCKED not editable, i locked them to prevent the object to be moved.

but ONCE i UNLOCK the objects, it become extremely slow to edit the objects properties

https://github.com/TheGameCreators/GameGuruRepo/assets/8946215/0b066a1a-ab0d-48f9-b420-e17f7c705a2d

SO... LOCKED objects can be clicked in real-time, but not editable... UNLOCKED objects are very SLOW to edit

imothep85 commented 7 months ago

and HERE the same cave with the UNLOCKED rocks, you can see that it's extremely slow when i click on the objects .... https://github.com/TheGameCreators/GameGuruRepo/assets/8946215/f0f4d6e7-4001-425c-8b2b-734c2ffb7d29

LeeBamberTGC commented 7 months ago

@imothep85 Congrats, you are approaching the problem like a developer :) The LOCK UNLOCK is a nice clue. I tried reproducing but to no avail: image

I think the next thing is for me to get my hands on your level and custom content. Can you make a standalone executable of your level and email it to me at lee@thegamecreators.com

I can then deep dive into the level and see why clicking an UNLOCKED object causes the delay - hopefully it will happen on my PC too!

Melburnian70 commented 7 months ago

@LeeBamberTGC I just saw this ticket now and wanted to let you know the same thing is happening to me on some of my levels.

I only noticed this happening in the last week or two, so I wonder whether this has something to do with a recent update to the EXP build (which I'm on).

Another thing I noticed is that the delay doesn't happen when you drag-to-select objects - only when you click on them. See the video for a demonstration.

https://youtu.be/Bc3pG4sFZRw

Cheers, Roberto

PS. my specs are : Acer Nitro 5 Gaming Laptop, 12th Gen Intel(R) Core(TM) i7-12700H 2.70 GHz, 16GB RAM, NVIDIA GeForce RTX 3050 Laptop GPU, Windows 11 Home

Melburnian70 commented 7 months ago

Ok, I think I fixed this by changing a OneDrive setting.

OneDrive was syncing everything in the ... Documents > GameGuruApps > GameGuruMAX > Files folder to the cloud and only leaving a shortcut to them on my hard drive to save space.

I right-clicked the Files folder and chose 'Always keep on this device' and after a couple of hours of it copying the files back to my computer, I can now select objects without any delay.

@imothep85 could you try this to see if it helps?

imothep85 commented 7 months ago

what ??? can you explain in details, i don't use any cloud services from Google, where are those options, in Steam in gameguru max ??? I don't use any cloud services from Google or Microsoft....ggmax takes 23.45gb in my C: ALL my game project, 3d files are custom, hand made, stored on my C:

Melburnian70 commented 7 months ago

OneDrive is built into Windows. I think it's turned on by default - although I have a Microsoft 365 subscription, so I don't know if that makes a difference.

Here's some more information about it https://www.computerworld.com/article/3256907/microsoft-onedrive-cheat-sheet-backup-sync-share-files.html

If you right-click on the Files folder inside Documents > GameGuruApps > GameGuruMAX do you have the option to 'Always keep on this device'?

always keep on device

imothep85 commented 7 months ago

as i said i dont use any cloud services, one drive is deactivated on my windows

Melburnian70 commented 7 months ago

Ok. I thought this might be the reason, as I can't think of anything else that's changed with my system.

imothep85 commented 7 months ago

@LeeBamberTGC I tried, to remove every BIG objects in my level, the pyramid, the labyrinth, the bridge, the rocks --> that changed nothing I tried, to remove every Tree & Grass objects in my level --> that changed nothing

So i'm stuck & wait... for some good news i hope.

LeeBamberTGC commented 7 months ago

@imothep85 Having trouble downloading your 1.5GB+ file from ONE.COM. Can you try uploading again, or choosing something like Google Drive which provides free upload/download will work with my system no worries.

imothep85 commented 7 months ago

How is that possible ?? everyone can download the file, even the technical team of one.com tried & checked the file download is no technical problem with that, have you tried with OTHER browser than Chrome ?

LeeBamberTGC commented 7 months ago

@imothep85 I sent you an email on this earlier. Tried on Chrome and Microsoft Explorer, but both terminated before the download was completed. Maybe spl;it the file into two zips and upload those, that might do it.

imothep85 commented 7 months ago

i sent you a new url now using wetransfer service

Melburnian70 commented 7 months ago

This started happening to me again.

Could this have something to do with creating groups? When I group objects and then drag them into the scene to create duplicates, I get the delay.

After I click all the groups in the scene one-by-one and ungroup them, the delay goes away.

imothep85 commented 7 months ago

yes witg the groups its always a delay but in my game i have no groups

LeeBamberTGC commented 7 months ago

@imothep85 I have the file now and was able to reconstruct the loading of the level and navigate through it. Now the next step is for me to reproduce exactly what you are seeing.

  1. When I load THE CAVE.FPM level, I see this: image
  2. As you can see, I have activated the FPS score and level editor details so I can see the resources used. image
  3. The takeaway is the GPU score should be around 16, but is in fact 126, the general reason is the amount of content in the level, with the largest user being the shadows being rendered.
  4. That aside for the moment, the first thing I tried was to follow the original issue bug report "LONG delay between clicking on a 3D object and the software's reaction to making the object active and selected". The view I have is the same as that stored in the level file so we can match our steps exactly. I clicked the 5 coffins in turn and they selected right away: image image image image
  5. There was no long delay between clicking and the object highlighting. Now there IS A DELAY due to the high GPU framerate usage (126ms vs 16ms) which causes a click to be missed if you do it quickly.
  6. When I switched shadows to minimum, the GPU score improves to 11ms: image
  7. When I do that, the clicking and the object highlighting is super instant.

Can you go through the steps I did above [4] through [7] and confirm without moving the camera, that after following the above steps to reduce the shadows you could click all 5 coffins instantly with ZERO LAG. From this test we can proceed further.

imothep85 commented 7 months ago

The delay is still there, i tried that too before, no lights, no shadows etc all to the minimum it changes nothing

https://github.com/TheGameCreators/GameGuruRepo/assets/8946215/3d50f3a1-d324-40ac-870d-a2327eefa4e1

LeeBamberTGC commented 7 months ago

@imothep85 Can you switch on your FPS and level editor stats and present them similar to how I have them here so I can see what is taking the time: image

Also, I noticed your camera angle was different to mine. Mine was from loading your THE CAVE.FPM level you sent me with no changes once loaded. It looks like you moved your camera to face the Coffins in your video. Can you load your level and leave the camera position and angle without moving it, so you can show an exact screen as the one I see, from there we can align your steps to reproduce, thanks!

LeeBamberTGC commented 7 months ago

image

imothep85 commented 7 months ago

and my view, same as the file i sent you fps-view

imothep85 commented 7 months ago

i have this fps-view02

LeeBamberTGC commented 7 months ago

@imothep85 Thanks for the stats, interesting stuff. Looks like you have a decent GPU to render a high resolution and lots of shadows, much faster than my AMD card so I think we can discount that as the reason. I did notice something that COULD be a clue which is our CPU scores. Mine is better. Can you take a shot in the camera pose when the level first starts similar to mine so I can see it with no shadows and nothing highlighted: image

LeeBamberTGC commented 7 months ago

@imothep85 And maybe zoom into the stats so I can read the values. As you can see, I can process the level editor in this state at 2.7ms per cycle.

imothep85 commented 7 months ago

fps-view02

imothep85 commented 7 months ago

the only stats i have are those i was showing you stats

imothep85 commented 7 months ago

My screen resolution is in 4k native. stats 02

LeeBamberTGC commented 7 months ago

@imothep85 Indeed, looks like your CPU is about 4-5 times slower than mine, which might explain why I cannot reproduce if this is a CPU-bound issue. If the clicking of an object is a CPU-intensive task (most likely), then you would see a 4-5 (even 10-20) times slower response than on my PC, which might explain things a little.

First up, I like your level, very creative! I also see it's very polygon-intensive, with single meshes at 30K triangles, high geometry static objects scattered across the horizon and sky, and most angles require 10 million polygons to be rendered, and that's just for the visible geometry, not counting the repeats from shadows and reflections. The bottom line is that you have presented one of the most intense levels I have seen created in MAX to date.

I am going to run some deeper OPTICK performance profiling with your level, and see if I can see some CPU wastage. Even a small detection on my PC that gets fixed will mean a big gain on your PC (my guess).

P.S. Remind me what your CPU Make and Model is again, thanks!

imothep85 commented 7 months ago

my PC windows 10 CPU I7-7700k ram 32gb corsair Graphic card Nvidia 1080TI 11gb SSD 500gb nvme2 and other storages 2tb

i tried to remove the lights in my level, to reduce shadow and light quantity but it doesn't change anything. can you tell me which object has 30.000k polygon?

i removed lot of lights and now i have those stats: fps-view03

LeeBamberTGC commented 7 months ago

@imothep85 Some good news, I can certainly see a spike in CPU activity when selecting objects via OPTICK: image

Bodes well for a solution if we can somehow spread the load of this work when selecting objects...

LeeBamberTGC commented 7 months ago

@imothep85 New EXP build uploaded with optimization to the object select and release code. Turns out it was updating the collection list each time you released, and if you have a LOT of objects, this could cause a small delay on my PC, and I imagine a larger one on yours. No more spikes, but let me know how the new build feels, thanks!

imothep85 commented 7 months ago

THANKS LEE i saw the update now i can select the objects again in real-time ! you can put this on SOLVED . TESTED & WORKING perfectly. fixed

621ba8e24f74c9cd5bc66495

LeeBamberTGC commented 7 months ago

AWESOME, thanks for the image ;)