In order to analyse the behaviour of pedestrians at the very fine scale, while moving along the streets, in open spaces or inside a building, simulation modelling becomes an essential tool. In these spatial environments, in the presence of unusual demand flows, simulation requires the ability to model the local dynamics of individual decision making and behaviour, which is strongly affected by the geometry, randomness, social preferences, local and collective behaviour of other individuals. The dynamics of people visiting and evacuating a museum offers an excellent case study along this line. In this paper we realize an agent-based simulation of the Castello Ursino museum in Catania (Italy), evaluating its carrying capacity in terms of both satisfaction of the visitors in regime of normal fruition and their safety under alarm conditions.