score:2
The three months don't count. According to the Schengen borders code:
Periods of stay authorised under a residence permit or a long-stay visa shall not be taken into account in the calculation of the duration of stay on the territory of the Member States.
Source: http://eur-lex.europa.eu/legal-content/EN/AUTO/?uri=celex:32016R0399.