public static void addSpell(int castId, int casterY, int casterX, int offsetY, int offsetX, int angle, int speed, int movegfxID,int startHeight, int endHeight, int finishID, int enemyY, int enemyX, int MageAttackIndex) {
	for (int i = 0; i <= 150; i++) { 
		if(GFXspot[i] == 0) { 
			GFXspot[i] = castId;
			castID[i] = castId;
			moveID[i] = movegfxID;
			endID[i] = finishID;
			gfxX[i] = casterX;
			gfxY[i] = casterY;
			offX[i] = offsetX;
			offY[i] = offsetY;
			gfxA[i] = angle;
			gfxS[i] = speed;
			gfxSH[i] = startHeight;
			gfxFH[i] = endHeight;
			targetX[i] = enemyX;
			targetY[i] = enemyY;
			lockOn[i] = MageAttackIndex;
			if (GFXspot[i] != -1)
				createSpell(castID[i], gfxY[i], gfxX[i], offY[i], offX[i], gfxA[i], gfxS[i], moveID[i], gfxSH[i], gfxFH[i], endID[i], targetY[i], targetX[i], lockOn[i]);
		}
	}
}