public void calcScore(Frame [] frame, int [] accumScore, int frameNum) {
		while (thisIndex <= frameNum) {
			// Optimised by jwlee
			int basic = addFirstSecond(frame[thisIndex]);
			int bonus = 0;

			if (frame[thisIndex].isStrike())
				bonus = strikeBonus(frame, thisIndex, frameNum);
			if (frame[thisIndex].isSpare())
				bonus = spareBonus(frame, thisIndex, frameNum);

			if (bonus == -1)
				return;

			sum += basic + bonus;
			accumScore[thisIndex] = sum;
			thisIndex++;
		}
	}