LUA - sure. But I wouldn't even try to approach this in XML. If it is possible (and perhaps it is, I am just too lazy and insufficiently inventive to slam my head at that wall) in XML, it is certain to be particularly cumbersome. The problem is, resources are not placed on the map using XML. The map generation is done through LUA before the game begins. Once the game is set, there are very few options for changing core terrain aspects using XML. However, in Lua, there are plenty of useful WorldBuilder and other related functions.