Spells per Day
Level BAB Fort Ref Will Special 0th 1st 2nd 3rd 4th 5th 6th
1st +0 +0 +2 +2 Arcane focus, rune bullet, enhanced perception 3 1
2nd +1 +0 +3 +3   4 2
3rd +2 +1 +3 +3 Spell channel (Ranged touch attack) 4 3
4th +3 +1 +4 +4   4 3 1
5th +3 +1 +4 +4 Bonus Feat, spell channel (touch attack) 4 4 2
6th +4 +2 +5 +5   5 4 3
7th +5 +2 +5 +5   5 4 3 1
8th +6/+1 +2 +6 +6   5 4 4 2
9th +6/+1 +3 +6 +6   5 5 4 3
10th +7/+2 +3 +7 +7 Bonus feat 5 5 4 3 1
11th +8/+3 +3 +7 +7   5 5 4 4 2
12th +9/+4 +4 +8 +8   5 5 5 4 3
13th +9/+4 +4 +8 +8   5 5 5 4 3 1
14th +10/+5 +4 +9 +9   5 5 5 4 4 2
15th +11/+6/+1 +5 +9 +9 Bonus Feat 5 5 5 5 4 3
16th +12/+7/+2 +5 +10 +10   5 5 5 5 4 3 1
17th +12/+7/+2 +5 +10 +10   5 5 5 5 4 4 2
18th +13/+8/+3 +6 +11 +11   5 5 5 5 5 4 3
19th +14/+9/+4 +6 +11 +11   5 5 5 5 5 5 4
20th +15/+10/+5 +6 +12 +12 Bonus Feat 5 5 5 5 5 5 5
D6
Int + 2
4d4 x 10 (100 gp)

All of the following are class features of the gun mage.

Weapon and Armor Proficiency: A gun mage is proficient with all simple weapons. Guns are treated equivalent to crossbows. Gun mages are proficient with light armor, but not with shields. A gun mage can cast gun mage spells while wearing light armor without incurring the normal arcane spell failure chance. Like any other arcane spellcaster, a gun mage wearing medium or heavy armor incurs a chance of arcane spell failure if the spell in question has a somatic component. A multiclass gun mage still incurs the normal arcane spell failure chance for arcane spells received from other classes.

Table: Gun Mage Spells Known
Level 0th 1st 2nd 3rd 4th 5th 6th
1st 4 2
2nd 5 3
3rd 6 4
4th 6 4 2
5th 6 4 3
6th 6 4 4
7th 6 5 4 2
8th 6 5 4 3
9th 6 5 4 4
10th 6 5 5 4 2
11th 6 6 5 4 3
12th 6 6 5 4 4
13th 6 6 5 5 4 2
14th 6 6 6 5 4 3
15th 6 6 6 5 4 4
16th 6 6 6 5 5 4 2
17th 6 6 6 6 5 4 3
18th 6 6 6 6 5 4 4
19th 6 6 6 6 5 5 4
20th 6 6 6 6 6 5 5

Spells: A gun mage casts arcane spells, but draws them from a spell list that begins empty. He can add new spells to it from the wizard spell list; any wizard spells that he has not personally learned are not on his spell list for the purposes of using items. He can cast any spell he knows without preparing it ahead of time. To learn or cast a spell, a gun mage must have a Charisma score equal to at least 10 + the spell level. The Difficulty Class (DC) for a saving throw against a gun mage's spell is 10 + the spell level + the gun mage's Charisma modifier.

Like other spellcasters, a gun mage can cast only a certain number of spells of each spell level per day. His base daily spell allotment is given on the table. In addition, he receives bonus spells per day if he has a high Charisma score.

The gun mage's selection of spells is extremely limited. A gun mage begins play knowing four 0-level spells and two 1st-level spells from the wizard spell list. At each new gun mage level, he gains one or more new spells, as indicated on Table: Gun Mage Spells Known. (Unlike spells per day, the number of spells a gun mage knows is not affected by his Charisma score (See Table: Ability Modifiers and Bonus Spells).

Upon reaching 5th level, and at every third gun mage level after that (8th, 11th, and so on), a gun mage can choose to learn a new spell in place of one he already knows. In effect, the gun mage “loses” the old spell in exchange for the new one. The new spell’s level must be the same as that of the spell being exchanged, and it must be at least one level lower than the highest-level gun mage spell the gun mage can cast. A gun mage may swap only a single spell at any given level, and must choose whether or not to swap the spell at the same time that he gains new spells known for the level.

A gun mage need not prepare his spells in advance. He can cast any spell he knows at any time, assuming he has not yet used up his allotment of spells per day for the spell’s level.

Arcane Focus: A gun mage is capable of channeling arcane magic through a pistol. With a functioning pistol, the gun mage always has the focus necessary to cast his spells. 

Additionally, any ray spells cast by the gun mage are focused through the barrel of his pistol, allowing him to use his pistol ranged attack bonus (and any ensuing bonuses from Weapon Focus or other feats) to determine the ranged touch attack bonuses for resolving the ray spell.

Rune Bullet: A gun mage knows how to craft special bullets that channel spell energy. A rune-cast bullet deals an additional +1d6 force damage per level of the highest spell slot the gun mage is able to cast.

In addition, upon reaching 6th level, the gun mage's rune-cast bullets do additional +1 damage, and is treated as a magical weapon for purposes of penetrating damage reduction. This bonus is increased by +1 for every 6 levels in the gun mage class; +2 at 12th level, +3 at 18th level.

Casting and maintaining rune bullets is an intensive process. A gun mage can only have a number of rune cast bullets up to one-half his class levels plus his Charisma bonus at any time. Casting rune bullets requires 15 minutes, Artisan’s Tools, 1 gold piece worth amount of raw materials per bullet, and at least 1 rank in Craft (Alchemy).

Enhanced Perception: A gun mage receives +2 to Perception checks.

Spell Channel (Ex): Starting from 3rd level, a gun mage can use her pistol to deliver ranged touch spells. She must use a rune bullet for this ability to work. She casts a ranged touch spell, but holds the charge - the bullet is designated as the "toucher" for a ranged touch spell. At a later time, the ranged touch spell can be then delivered as a ranged attack. If she casts another touch spell, then this touch spell dissipates.

If a rune bullet is used to deliver a spell, then it does not deal its usual bonus damage.

Starting from 5th level, a gun mage can do this for melee touch spells.

Bonus Feat: Every five levels, a gun mage gains a bonus feat. These must be chosen from the following list: any Metamagic feat, Combat Casting, Dodge, Improved Initiative, Point Blank Shot, Quick Draw, Skill Focus (Craft (any)), Spell Focus, Weapon Focus (Pistol), or any feat that has any of these feats as a requirement.