Non-repeating textures and decals not working?

Hi I’m trying to do a simple tile based strategy game where all the tiles have the same size. The texturing in BGE is working fine for the landscape tiles that must fill out the entire tile. I’m trying to make unit tiles that go on top of the landscape tiles, but this is where I’m having trouble. The unit textures should be slightly smaller than the tile size, so I tried scaling the UV-map, but that makes the texture repeat, which I don’t want. I just want them to be applied like a decal.

I’ve also tried under Image Mapping to set Extension to Clip which works fine when using the blender render. But I don’t get the same result when using BGE. Any ideas how to scale textures and make them non-repeating for decals?

It might be that in game mode blender wont apply a texture that is smaller than a face. You could create another face on the tile by bevelling or vertex editing, or else apply the texture to a plane and attach that plane just above the surface of the tile.

Or else in Gimp or whatever add a transparent border around the edge of the image.

If you want the decal to apply only on an area smaller than the tile, then make a new face that is above the landscape tile, set the UV-map to be the decal image (which I assume, for instance, is the same size as all of the other tiles, just transparent on the outside, like a bullet hole would be), and then scale the new tile down. You can then place the decals wherever you wish.

Thanks for the work-around. That will be good enough for moving on.

I think the behavior is a bug, but I can’t find it in the Blender bug tracker. I’ll go there and open a bug report.

I have opened a bug report and written a hack that works when starting blenderplayer directly. See