Added CanBuild() resource cost checking logic to BuildManager.