• 🏆 Texturing Contest #33 is OPEN! Contestants must re-texture a SD unit model found in-game (Warcraft 3 Classic), recreating the unit into a peaceful NPC version. 🔗Click here to enter!
  • It's time for the first HD Modeling Contest of 2024. Join the theme discussion for Hive's HD Modeling Contest #6! Click here to post your idea!

Mdx sanity tester

Level 20
Joined
Apr 12, 2018
Messages
494
I seem to get errors with Footprints where the Tester wants me to have a Footprint at the start of a Walk track sequence even if that is inappropriate for the model. I don't think having one at the start is strictly required...?

Most of the time I 'solved' this problem by removing the footprints entirely, but I also figured that there wasn't any particular reason why I couldn't just leave them.
 
Level 29
Joined
Jul 29, 2007
Messages
5,174
It doesn't want you to have a footprint at any point, it only wants you to form a proper timeline with a start and an end, the value at the start is irrelevant.
In other words, if your animation starts at frame 333 and ends at frame 1333, you are expected to have keyframes at frame 333 and at frame 1333, unless you have 0 or 1 keyframes.
With that being said, as mentioned many times in the past, warnings are lenient and you can usually ignore them - it's actually right there in the first post :p

Just for the sake of future comments, I am attaching a map that shows the issue in WE.
All of the boxes in the map are supposed to animate the same, some don't. If you make the units fly, or hide the terrain, you might see something interesting with the animation.
You can check the models themselves if you are interested, they are already in MDL so it's quite simple.
Technically now that Retera figured the logic of this weird animation behavior, I could test better for it and only warn when missing keyframes will actually cause an issue, but I don't have time to do this for the time being.
 

Attachments

  • MissingKeyframes.w3m
    21.5 KB · Views: 32
Last edited:
Level 20
Joined
Apr 12, 2018
Messages
494
It doesn't want you to have a footprint at any point, it only wants you to form a proper timeline with a start and an end, the value at the start is irrelevant.
In other words, if your animation starts at frame 333 and ends at frame 1333, you are expected to have keyframes at frame 333 and at frame 1333, unless you have 0 or 1 keyframes.

Event Tracks aren't done like that since the only thing they list is which keyframe to generate the event at.
 
Level 29
Joined
Jul 29, 2007
Messages
5,174
Event Tracks aren't done like that since the only thing they list is which keyframe to generate the event at.
I agree that event object tracks should be checked separately than other animation tracks.
Looking back at it, I am not quite sure why I merged the code to work with both. Probably just to share the other stuff like keyframes being in the wrong order etc.
Hopefully I'll have some time to change it soon-ish.

If you have other complaints I would like to hear them as well. This tool is for the community after all.
 
Level 29
Joined
Jul 29, 2007
Messages
5,174
  • Missing the Origin Ref attachment is now a warning, since it stops effects from attaching to the model (source). This is likely irrelevant if the tested model is an effect itself, but only the user can know how the model is going to be used.
  • SD models no longer show the useless warning saying there aren't enough matrices, which are only used by HD models.
  • The missing opening/closing tracks spam warnings are gone. Instead the proper check is done now, and reported as a severe warning, thanks to Retera's research. This needs more testing. If you think it's reporting something it shouldn't, please look closely at the beginning of the animation of whatever you are looking at.
 
Level 29
Joined
Jul 29, 2007
Messages
5,174
I removed some warnings from HD models that are not relevant to them.

In addition, there are now some experimental tooltips for some of the issues, if you hover over them.
I am wondering if it will be worthwhile to make them more personalized.
For example, if there is a missing keyframe at the beginning of an animation when one is required, perhaps the tooltip should show a small snapshot of the timeline as MDL with a pointer as to where the keyframe is missing?
It could be cool, but it will take some effort.
 
Level 29
Joined
Jul 29, 2007
Messages
5,174
  • Emitted objects (particles, ribbons, splats, models) are no longer removed every time an animation repeats. That was annoying as heck.
  • Fixed the data type of layer fresnel animations, which might affect the viewer in the future (thanks @BogdanW3 for reporting).
  • Emitters don't have any filter mode called "Add alpha" as was "known", rather, like the MDL token says it's AlphaKey, which seems to use normal blending with alpha keying similar to the layer Transparent filter mode. In other words, there's blending, but also pixels with alpha < 0.75 are not visible (thanks @Mythic for both reporting and supplying the attached test model).
 

Attachments

  • AA_XYs_0.mdl
    3.4 KB · Views: 23
Level 29
Joined
Jul 29, 2007
Messages
5,174
Added very basic and hardcoded support for DDS textures with extended headers used for normal maps. This should let some normal maps that would previously not load or load garbage data load properly instead (the normal maps used in this model for example).

With that being said, DDS is a complex format that supports about 10 gazillion combinations of image formats and relies on many duplicated flags and other data to determine the formats to begin with, so if the sanity test fails to parse any DDS that works elsewhere (e.g. ingame), I would like having it.
 
Level 29
Joined
Jul 29, 2007
Messages
5,174
Added also DXT1/3/5 detection from the extended header for DDS images after seeing some on the Hive.

The shading option was replaced with a selection of debug render modes, in a similar way of how the client used to work years ago for SC2 models.
So far this only affects HD models. Maybe I'll add support for SD, although naturally there's less to really see there.
Still considering what modes exactly I want.
Thinking about adding normals (as opposed to the normals map), and perhaps splitting the ORM to its 4 channels in grayscale.
Suggestions?

Also fixed the position of emitted event objects, thanks to @Taylor Mouse for pointing me in the right way.

/Edit
Split the ORM to its 4 channels drawn in grayscale, and added normals and tangents.
SD models only have diffuse, texcoords, and normals, since nothing else is relevant. Maybe add shading? :peasant-thinking:
 
Last edited:
Dear GhostWolf, if I delete a bone with a warning then my Particle Emitter will fall off. I guess, this warning shouldn't appear when the bone is being used and is used this way?
Sanity.png
 
Level 29
Joined
Jul 29, 2007
Messages
5,174
I should add a tooltip to that warning like some others do if you leave your mouse on them.

The warning isn't that the bone exists, but rather that it is a bone and not a helper.

Bones are used when rendering things as opposed to helpers (e.g. sent to shaders in modern wc3, who knows what old wc3 does), so it's probably more efficient to set bones with no vertices to helpers.
 
Level 29
Joined
Jul 29, 2007
Messages
5,174
Some updates that I added along the way since the last update:
  • When adding multiple tests (drag & drop, maps, Hive API) only the first test will be shown, rather than swapping to every new test as they are loaded. This makes the loading much less noisy and also speeds it up.
  • BLP/DDS/TGA all got a small header that shows basic information in the test results (size, compression, etc.)
  • BLPs with alphaBits>8 now load with alphaBits=8. Should make some weird BLPs load correctly.
  • DDS image mipmaps are now also shown in the test results (might be a bit laggy for big 2k textures).
  • TGA images are now also shown in the test results.
  • The DXT1 decoder now decodes 8-8-8-8 RGBA pixels rather than 5-6-5 RGB pixels, meaning it will support alpha correctly as the DXT spec defines it, and the DXT3 decoder was fixed (thanks @NightKnight for helping with testing and giving the motivation).
  • A bunch of other smaller fixes.
 
Hi, a suggestion for your sanity test add a check:
  • to see if two nodes are referencing each other as parents. MAgos war3 editor ignores them both in such case, including any transformations that they have. (hides them) - ERROR
  • to check if there are 2 or more nodes with the same id - magos war3 editor opens it but who knows what bugs can this can cause - WARNING
  • the error "invalid parent -1" does not cause a map crash becasue ive seen it in some blizz models. It's probably ignored because -1 is considered none.
  • since event object without track causes crash i think you shoudl change it to error not warning

EDIT: Also checks for nodes, cameras and sequences with the same names

EDIT 25/01/24:
Maybe you should add warning of type "Number of geoset animations does nto match the numebr of geosets" or "not all geosets use a geoset animation". Since we know that geoset animations are imporatnat to ensure that a model is visible ingame.

add warning is a visibility ,static or animated, contains values that are no 0 or 1.
 
Last edited:
Top