A new build of Leadwerks Game Engine is available on Steam, on the "beta" branch.
It's pretty clear that constructive solid geometry modeling is a high priority for our community. I like being able to easily sketch out my ideas. In fact, when this feature went away in Leadwerks 2, that was when I just stopped making game levels. It's not that I don't know how to use 3ds Max and other programs, it's just that they're not fun. The upcoming release of Steam Workshop also fulfills my long-held dream of building a shared repository of textures and models scaled correctly to work with CSG mapping.
Today I began some preparatory work, starting with some texture templates:
These are important because they give us a standard template we can line solids up against:
Why does this matter? Well, when we have a standard template for common features, we can design textures that match the geometry, like this plaster wall below:
This is one of the tricks that makes maps look great, and it's easy to set up once you have a standard template.
However, I ran into one big problem. Leadwerks 2 started using a scale of 1 unit space = 1 meter. This makes a lot of sense, because it is easy to measure physics and large distances, as Leadwerks 2 was mostly an outdoors engine. When it comes to texture mapping, however, this scale is not ideal at all! A human being is roughly 1.8 meters tall. That means that 2 meters is just a little over their head, and is too short to place a wall texture on. We can scale the texture up on the surface, as I did in the example AI map, but this will cause problems. The grid in Leadwerks is based on powers of two, and if we scale the texture up to 2.5 meters in size, it's going to be hard to line brushes up precisely against the texture pixels! What to do?!
On the other hand, using a centimeter grid gives a perfect scale. 256 cm is roughly the height of a one-story building's wall, so mapping textures on that scale makes a lot of sense. I realized I could just display a grid in centimeters instead of meters, and it would totally solve this problem, without requiring any rescaling. So I added that setting in the Viewport options and it works perfectly. The door on the left was modeled with the centimeter grid while the one on the right was modeled with the grid measures in meters. Because the grid is power-of-two, the centimeter grid had major grid lines at 2.56 meters, while the meter grid had it at 2.0 meters:
This will not affect your existing maps, but I recommend you start using the centimeter grid for new maps. This preliminary work will allow me to unleash our artists to produce more texture packs for you to use in your maps, and will allow the community to work together more effectively.
A pick material mouse tool has been added. This is like a color/eye dropper that lets you click something in the scene, and the picked object's material will be shown and highlighted in the asset browser. This is just a nice tool for convenience, and I found I really wanted something like this as I was working.
A global sky setting has been added. To set this, select the scene root in the scene browser, then select a texture or material for the skybox in the properties editor. The sky will be stored in the map file and reloaded when the map is opened in the editor or game. The new command [url]Camera::SetSkybox[/url] can be used to do this in code.
Finally, support for exporting VMF (Valve Map Format) files has been added. Texture coordinates are perfectly retained, which makes Leadwerks Editor perfectly suitable for making maps for Source games, for those who are so inclined.
To access this build, right-click on Leadwerks Game Engine in your library list and select the Properties menu. Go to the "Betas" tab and select the beta branch. Note that this is potentially less stable than the default branch, but gets access to new features first. Note that the map file format has been incremented, and you will need to update your project to run new maps. Go to File > Project Manager to do this.