The striker ran onto a through-ball from Chris Lines to confidently shoot past Phil Smith after seven minutes and Jo Kuffour capitalised on a defensive mix-up to fire the second on just after the break.
Jon-Paul McGovern gave Swindon hope with a superbly struck 66th-minute volley after a mistake by the otherwise reliable David McCracken.
But Jeff Hughes stole in at the near post to head home a Hoskins cross after 74 minutes to settle the outcome.
Rovers deserved the points, although Swindon were enjoying a good spell when Hughes struck the decisive third goal.
Home goalkeeper Luke Daniels played his part, doing well to save a 49th-minute header from Charlie Austin.
Source: PA
Source: PA