Pardon me for neglecting you oscar.

You would use an event monitor something like this in your script:

Code:
monitor_event FactionTurnStart FactionType greek_cities
              and I_TurnNumber = 31
              and I_SettlementOwner Sparta = greek_cities
    console_command create_building Sparta "army_barracks"
end_monitor
This would create an army_barracks building in Sparta on the 31st turn of the game if Sparta were controlled by the greek cities.