ficool2 / HammerPlusPlus-Website

The website for Hammer++
88 stars 8 forks source link

Detail props don't obey to texture's aspect ratio. #81

Open jean-knapp opened 5 months ago

jean-knapp commented 5 months ago

When a detail sprite sheet has an aspect ratio different than one (i.e. 1024x512), the engine uses both the texture's width and height as reference for setting the UV of each sprite. In Hammer++ 8865, it has a behavior similar to stretching the example texture to 1024x1024, and using the detail.vbsp parameters to crop the sprites.

Easier than explaining by text is showing images. For example, this is what a sprite should look like (according to the VDC documentation): image

This is what it looks like in-game (it's inverted in the U axis, but that is a normal behavior of the game, not Hammer++ related): image

And this is what it looks like in Hammer++: image