The security rating can be a mystery sometimes: rising and falling throughout the scenario and sometimes getting stuck on zero. So how does the rating work exactly?
If there are no crimes in the city, your security rating will rise with one point per week, which comes down to four points per month. Without any walls around the city, the maximum attainable security rating is 50.
For a rating higher than 50, you have to surround at least part of your city with walls. How high your rating will rise after completing the wall depends on how many of your important buildings are now protected by walls.
So, which buildings are considered "important" and need protecting by walls? It might be easier to give a list of unimportant buildings, since that list is quite short:
- Aesthetics: decorative items such as trees, hedges and statues
- Raw materials: farms, fields and pastures, and gathering camps for raw materials
- Water facilities: pump houses, aqueducts, fountains, wells, bridges
- Military buildings: forts, mess hall, recuitment post, drill yard
Any of the buildings mentioned above can be left outside the city walls without affecting the security rating, but any building not on that list (including prefect and engineer offices, warehouses and granaries) will have to be protected if you want a high security rating.
One odd thing about this is that any towers attached to the city wall are also counted as important buildings. This is most likely a bug in the game. If you are attempting to get a security rating of 100, you'd better not have too many towers.
If you want to get a security rating of 100, you can have at maximum 1/6th of your important buildings outside the city walls. If you have more unprotected important buildings, your rating will drop below 100.
The exact formula for calculating the maximum security rating is the following:
maximum security rating = 50 + 60 * [protected important buildings] / [total important buildings]
With regard to the tower "bug" explained above: if all of your important buildings are protected by walls, the number of towers you can have depends on the number of buildings in your city. For smaller cities (less than 3000 people), you can have about 5-10 towers without affecting the security rating. For larger cities of 8000-10,000 people, you may be able to have 30 or more towers while still maintaining a security rating of 100.
A city is considered "protected" when it is completely surrounded by walls and impassable terrain. Only water bodies (lakes, rivers, sea) count as impassable terrain; rocks and hills don't: you will have to build your walls around rocks and over mountains. Bridges are considered a hole in your fortification and will need to be fortified on one of the sides.
|This small city is not protected because of the bridge...||... you have to wall off the other side of the bridge as well.|
Crime and your security rating
Even one single crime in a year can bring your security rating down in no time. A crime is defined as either actions caused by angry citizens such as mugging or burglary, or enemies torching or destroying buildings. Even if the buildings are not completely destroyed but saved by prefects or engineers later, it still counts as a crime.
If a crime has occurred, your security rating will gradually drop to zero with 2 points per week, or 8 points per month. It only starts to rise again when there have been no crimes for 6 months.
Having lots of prefects won't completely prevent crimes from occurring. To reduce any crime, make sure your citizens are satisfied with their life in the city; you can use the Happiness overlay (under Risks) to check which people are dissatisfied. The most common causes for unhappiness are high unemployment and no food.