Jess Current production of oil is 6 x Scotland's needs and it is estimated that there is more oil still under the sea than has already been extracted. At current production rates the oil is predicted to last for another 40 years [or 240 years if only used within Scotland!] Granted that some of it will be more expensive to extract but the same is true across all the OPEC countries and so the market price of oil will continue to rise making investment in hard to reach oil fields financially worthwhile. The plan is to slow production rates to conserve stocks and thereby spin out the oil for a longer period. Once Scotland's share of the National Debt has been cleared there would be scope to save money annually into an OIL Fund like Norway's.
Fortunately, for Scotland there is another bonanza round the corner in the form of wind and wave power. Developments are mainly still at the experimental stage but the expertise in working offshore, plus an extensive coastline and plenty wind mean that Scotland is set to become a world leader in green energy.
Also still lots of coal underground, (vast new opencast mine given planning permission at Penicuik this month), which with carbon capture technology could be used safely to fuel power stations if necessary and potential for fracking, shale oil, etc. if the SG decides to allow it. Of course, the Scottish Economy is not entirely dependent on oil/gas revenues, also having profitable Food and Drink, farming, fishing, Media production, and Tourism sectors contributing to the GDP.
NB: As things stand ATM, crediting Scotland with a 9.6% share of oil revenue, the Scottish economy runs a 1-2% deficit on GDP compared with 3-4% deficit for the whole UK.