In Clash of Clans setting up your base or town is crucial in order to defend against attacks and protect your valuable gold and elixir. A well thought out and structured base layout can mean the difference between winning and losing an attack.
This guide will cover the basics in order to protect your resources and key buildings from being destroyed. There are more specialist set ups depending on whether or not you are trying to protect your resources, or if you are trying to win trophies and work your way up the Clash of Clans league tables. I will cover these in later player guides.
The object of most defense layouts is twofold; firstly to protect your valuable resources and secondly to protect your trophies (but not necessarily in that order!)
50% of your uncollected elixir and gold can be stolen from your Gold Mines and Elixir Collectors. 20% of your elixir and gold can be stolen from your stores. However, your stores are more likely to contain the vast majority of your resources. The object is to protect as much as you can from being stolen.
An attacker is awarded trophies for a successful attack and a defender loses trophies for a defeat. A player has a successful attack if they are awarded 1, 2 or 3 stars. Stars are awarded if your Town Hall is destroyed, if 50% of your buildings are destroyed and finally when 100% of your buildings are destroyed. The object is therefore to avoid any either of the first two happening and certainly the last!
The first thing you need to understand is that a player can attack from all four edges of the map. Even if you place your buildings and walls right up against the edge of the map, you cannot stop a player from deploying troops just outside the boundaries. With this in mind there is no real benefit (and actually a lot of downsides) in building your town along an edge, or in a far corner of the map.
The important thing to remember is a player cannot deploy a troop on top of a structure, or within a 1 tile perimeter of a structure. If you tap on any building and attempt to move it you will notice a light green border surrounding all of your structures, this area is a no go for enemy deployment.
In the picture to the right you can see the light green area surrounding the walls and buildings.
This means you can actually use buildings on the outside of your walls to act as a barrier. The advantage of this is that it stops ranged units such as Archers and Wizards from spawning right next to your walls and shooting at your defenses.
Your Walls are one of your key lines of defense against an attack. You need to make sure that whatever buildings you decide to place inside your walls are completely sealed in a solid wall perimeter. If you have a gap in your wall then troops will head straight for it and into your base.
You should try not to put all your buildings inside your walls. To start with you will probably want your Town Hall, resource stores such as your Elixir Storage and Gold Storage, and most of your defenses inside your walls. The rest of your buildings can be placed outside your perimiter.
As you increase Town Hall levels and the number of wall tiles available to you increases, you should start to surround individual buildings (or groups of buildings) inside your base with their own wall perimeters. This is a much better setup than just surrounding your entire base with one wall, because as soon as melee ground troops break through they will be able to attack all of your buildings.By enclosing buildings inside your walls individually, melee troops will have to break through at least one wall tile for every building they attack. This dramatically slows down an attack allowing your defenses more time to take out the troops.
Assuming you are going for Trophies your Town Hall should be somewhere near the center of your base. This is because losing your Town Hall means a defeat no matter what other buildings are destroyed. I would also suggest enclosing the Town Hall in its own wall perimeter for an extra layer of protection.
In Clash of Clans your Gold Storage and Elixir Storage buildings should also be protected inside your walls. If you regularly transfer your elixir and gold from your collector/mine to your stores, this is where most of your resources will be kept. Remember an attacking player can steal 20% of your elixir and gold from these buildings, which at higher levels equates to a lot of resources.
Finally defenses should be placed inside your base and close together so they overlap as many buildings as possible. You should aim to put your Mortar and Wizard Towers near the center of your base, again surrounded by their own mini wall perimeter. This is because they have a large range and do serious area effect damage to attacking hoards of troops.
You should also try and keep some air defenses at the center of you base to cover as much of your inner buildings and ground defenses as possible, protecting them from air attacks.
The rest of your defenses should be scattered throughout your base, but still inside your walls.
Everything else should be outside your walls. However, do not just spread them out randomly around the map! You will want to build up a second perimeter surrounding your walls in order to keep attacking troops out of range of your defenses.
The majority (but not all) attacking troops will automatically target the nearest building, which means if there are buildings between your walls and the deployment area they will target these first. This allows your defenses to target these troops whilst the attacking force targets useless buildings that offer no rewards.
Some players do like to keep their Elixir Collectors and Gold Mines inside their walls as well. The problem is this can mean sacrificing a decent defense layout protecting your core buildings. Remember whilst an attacking player can steal 50% of any elixir or gold from your collectors and mines, this will only going to include resources generated since you last logged in.
This covers the basic base layout for beginners which should dramatically increase your survival rates. The biggest hurdle is remembering not to try and protect every building. Concentrate on the key buildings outlined in this guide, which in turn will go a long way to protecting your resources and trophies.