Every RTS I've ever played shows whether a potential building site is allowed by making the transparent building red if it can't be built there. In Glest the worker has to walk all the way to the building site before the player is told "Building can't be placed there".
This simple change will make it so that if a building site is illegal (on top of a rock for example) the transparent building will be red.
* Open "renderer.cpp"
* Find the following routine: Renderer::renderMouse3d
* Find the "if(gui->isPlacingBuilding()){" clause
* Replace "color= Vec4f(1.f, 1.f, 1.f, 0.5f);"
with:
if(map->isFreeCells(pos, building->getSize(), fLand)){
color= Vec4f(1.f, 1.f, 1.f, 0.5f);
} else color= Vec4f(1.f, 0.f, 0.f, 0.5f);
That's it. Note that although this will let the player know if the building is allowed or not, it won't stop him attempting to place a building there like any other RTS would: that's a slightly bigger problem.