AshuraDX Posted May 11, 2016 Author Posted May 11, 2016 You should probably try to reduce the polycount some more, your main mesh is quite high.that's starting to get fairly difficult without destroying the UVsI could delete the sides of the knee and ellbow pad straps probably, maybe remove a few more edges at the helmet EDIT: 500 tris down, still crashes
DEVISS Posted May 11, 2016 Posted May 11, 2016 its amazing Ashura!! will you make the others helmet?? (like Neyo, airborne....)
AshuraDX Posted May 11, 2016 Author Posted May 11, 2016 @@DEVISS before I can think about that this one has to work properly without crashing the game (an issue thats allready fixed for those using openjk) I seem to be close to fixing the crash though - 755 tris down leaving me with 7794 tris in total and a single clone no longer crashes the game, as soon as you spawn a second and shoot one of them while the other is still alive it crashes.Strangely I can have 20 ragdolling dead clones lieing around and still spawn&shoot another clone without problems occuring. I als succesfully tested 10 solaires fighting that single clone, Solaires tricount is 7355 so I assume the treshold for the ghoul2 error to be at around 7.5k tris Edit: down to 7514 tris and it still crashes Edit2: 7490 tris and it crashes with 3 clones on screen while 6 7355 tri Solaire models work fine - there must be another trigger for this error than just the tri count @@eezstreet, @@Xycaleth any ideas what else could be related? the clone is split into many sub objects could that be part of the problem?
Xycaleth Posted May 11, 2016 Posted May 11, 2016 I can't remember exactly when the vert transform error comes up. I'll take a look when I'm back from work.
AshuraDX Posted May 11, 2016 Author Posted May 11, 2016 @@Archangel35757 if caps are included in that count I have 49EDIT: caps do not count towards the limit. I also tried leaving a piece out to get to the 32 surface mark and it still crashes - now with a lower tricount than solaire
Kualan Posted May 11, 2016 Posted May 11, 2016 Damn that is looking sweet, shame about the crashes. I'm sure you'll sort it out in time.Excellent work on the model though - never thought we'd see the new clone model we've been wanting so many years for.
AshuraDX Posted May 11, 2016 Author Posted May 11, 2016 this is ridiculous! compare these 2 models, I can spawn 13 solaires without lag or a crash at once, might be even more since I stopped spawning more after the 13th... while 2 clones onscreen at once crash the game
AshuraDX Posted May 11, 2016 Author Posted May 11, 2016 and they both are using the _humanoid.gla?yes, they are here's a list of differences that you can't take from the linked pics: Solaire:-4 Materials (2k for the whole body, 1k for accesoires and 2 sided alphamapped variants for both)-slightly different hierarch (bolts for LODs are not linked correctly, hips_x are not linked to the coresponding stupidtriangle_off) Clone:-7 materials (6x 1k for the test version (have higher res 2k versions available) and a shader based at textures/common/black with an env stage)-everything in the hierarchy is linked to the proper LOD variant Similiarities between both:-all materials have 2 shaderstages (just diffuse and spec)-LODs seem to work fine for both ingame and in Modview time fore more extreme tests... EDIT:I'm done.I'm fucking done - now a single scalped, beltless clone crashed the game it's official @@neomarz1's clones have a protective curse the crash can't be related to vertex, tri and surface count alone EDIT2: a hierarchy change didn't do the trick either
Rayce Posted May 11, 2016 Posted May 11, 2016 I'm done. I'm fucking done - now a single scalped, beltless clone crashed the game it's official @@neomarz1's clones have a protective curse the crash can't be related to vertex, tri and surface count alone EDIT2: a hierarchy change didn't do the trick eitherhttp://www.nooooooooooooooo.com/
Archangel35757 Posted May 11, 2016 Posted May 11, 2016 @@AshuraDX -- maybe it's renderer related? @@Xycaleth, @@eezstreet -- is there any way to trap the error and get some error message from the console?
eezstreet Posted May 11, 2016 Posted May 11, 2016 The exact error can happen in two different places (in MP, couldn't find the error in SP): TransformedVerts = (float *)G2VertSpace->MiniHeapAlloc(surface->numVerts * 5 * 4); g.mTransformedVertsArray = (size_t*)G2VertSpace->MiniHeapAlloc(g.currentModel->mdxm->numSurfaces * sizeof (size_t)); It's either the number of vertices in a single surface, or it's the total number of surfaces. AshuraDX likes this
AshuraDX Posted May 11, 2016 Author Posted May 11, 2016 the number of vertices in each surface is below 500I guess I'll try to merge a few objects to reduce the surface count... EDIT: strangely enough the error only occurs in singleplayer
eezstreet Posted May 11, 2016 Posted May 11, 2016 the number of vertices in each surface is below 500I guess I'll try to merge a few objects to reduce the surface count... EDIT: strangely enough the error only occurs in singleplayerYeah, that's because singleplayer JKA has half the miniheapsize of multiplayer. Don't ask me why it's like that, but either way it's correctly set as the MP size in OpenJK.If you're getting errors in singleplayer while using jamp.exe, it's not even worth it to sacrifice quality imo.
AshuraDX Posted May 11, 2016 Author Posted May 11, 2016 Yeah, that's because singleplayer JKA has half the miniheapsize of multiplayer. Don't ask me why it's like that, but either way it's correctly set as the MP size in OpenJK.If you're getting errors in singleplayer while using jamp.exe, it's not even worth it to sacrifice quality imo.people still complainI have 2 versions for now, a high res model with 2k textures and the lowres which is the model I'm butchering atm with 1k textures eezstreet likes this
Xycaleth Posted May 11, 2016 Posted May 11, 2016 Okay, just looked at the code. In OpenJK, SP and MP both have the same amount of 'transform space', which is 262144 bytes. JASP seems to have roughly half the amount of transform space compared to JAMP; JASP has 132096 bytes of transform space, JAMP has 262144 bytes. The equation you're trying to satisfy is: number of surfaces * 4 + total number of vertices in an LOD * 20 <= transform spaceIn other words, both the number of surfaces and the total number of vertices can trigger the error, but total number of vertices more-so. I don't know which LOD gets used, but assuming you're hitting the error, I'm guessing it's using LOD0. For JASP, you can have around 6600 verts maximum before you hit the error. In JAMP and OpenJK, you can have around 13100 verts before hitting the error. Both cases assuming you have 32 surfaces. EDIT: The 'transform space', in case anyone is curious, is used for transforming the model vertices for collision detection. Archangel35757 and eezstreet like this
AshuraDX Posted May 11, 2016 Author Posted May 11, 2016 Okay, just looked at the code. In OpenJK, SP and MP both have the same amount of 'transform space', which is 262144 bytes. JASP seems to have roughly half the amount of transform space compared to JAMP; JASP has 132096 bytes of transform space, JAMP has 262144 bytes. The equation you're trying to satisfy is: number of surfaces * 4 + total number of vertices in an LOD * 20 <= transform spaceIn other words, both the number of surfaces and the total number of vertices can trigger the error, but total number of vertices more-so. I don't know which LOD gets used, but assuming you're hitting the error, I'm guessing it's using LOD0. For JASP, you can have around 6600 verts maximum before you hit the error.In JAMP and OpenJK, you can have around 13100 verts before hitting the error. Both cases assuming you have 32 surfaces. EDIT: The 'transform space', in case anyone is curious, is used for transforming the model vertices for collision detection. happens with any LOD actuallyand the current clone model has 6246 verts, 7490 tris on 27 surfaces doing the math (132096-(27*4))/20=6599.4 max verts, which I should not reachbut that's for a single model I guess? atm I'm only crashing with 2 or more clones rendered at once
Xycaleth Posted May 11, 2016 Posted May 11, 2016 That's strange :/ I can't see anything in the code that would cause this to happen. Do you ever get the transform space error when you only have one player on screen? My only explanation is that the collision detection isn't happening unless there's more than one player. I don't believe this is a problem caused by rendering models. Instead, it's when collision detection needs to be done.
AshuraDX Posted May 11, 2016 Author Posted May 11, 2016 @@Xycaleth the error occurs when you shoot/attack one of the 2, running into them doesn't do anything
Xycaleth Posted May 11, 2016 Posted May 11, 2016 Ok, that makes sense. Blaster fire/saber collision detection is done against the G2 model. I'll look at why you're still getting errors even when you should be within the transform space limit.
AshuraDX Posted May 11, 2016 Author Posted May 11, 2016 @@Xycaleth it's even more random!If I use the clone model as my character model instead of spawning the npc version in, me being hit instantly crashes - while a single clone npc I shoot won't crash the game EDIT: the circumstances for the crash to occur are very varied - now I could have 2 at once without problems but a third caused the crash again
Archangel35757 Posted May 11, 2016 Posted May 11, 2016 @@Xycaleth - so this is the vanilla game limit? Since you say OpenJK 13100 verts? can we increase this transform limit so that in SP we can have same number of vertices?
AshuraDX Posted May 11, 2016 Author Posted May 11, 2016 @@Xycaleth - so this os the vanilla game limit? Since you say OpenJK 13100 verts? can we increase this transform limit so that in SP we can have same number of vertices?we have that for OpenJK SP the crash only occurs with the base JASP @@Xycaleth did some more systematic testing and noticed something:https://docs.google.com/spreadsheets/d/1OLTu9MrDbIFFQkcKWgDCxUjtbXt5ietF4Wqu1k1Tjr8/edit?usp=sharing green is fine, red crashes Xycaleth and Archangel35757 like this
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now