Class: PfrpgClasses::Loremaster

Inherits:
Heroclass show all
Defined in:
lib/pfrpg_classes/heroclass/loremaster.rb

Instance Attribute Summary

Attributes inherited from Heroclass

#level_for_json

Instance Method Summary collapse

Methods inherited from Heroclass

#as_json, #bab, #bonus_choices_for_level, #bonus_features_for_level, by_name, class_list, class_list_json, #features, fetch, #initialize, #meets_prerequisites?, prestige_class_list, prestige_list_json, #pretty_choice_string, #pretty_feature_string, #saves, #spells, #spells_per_day, #starting_feats, #starting_wealth, #starting_wealth_avg, #starting_wealth_str

Constructor Details

This class inherits a constructor from PfrpgClasses::Heroclass

Instance Method Details

#alignmentObject



15
16
17
# File 'lib/pfrpg_classes/heroclass/loremaster.rb', line 15

def alignment
  PfrpgUtility::Alignment.any
end

#bonuses_for_level(level) ⇒ Object



52
53
54
# File 'lib/pfrpg_classes/heroclass/loremaster.rb', line 52

def bonuses_for_level(level)
  PfrpgTables::Tables::Heroclasses::Loremaster.level_bonus(level)
end

#descriptionObject



19
20
21
# File 'lib/pfrpg_classes/heroclass/loremaster.rb', line 19

def description
  "Loremasters' lives are spent in study, research, and fieldwork. While the first two lend themselves to the loremaster's reputation as a bookish recluse, the latter oftentimes forces a loremaster to seek out the aid of adventurers who, through a mutually beneficial arrangement, might provide a degree of protection to the scholar while he seeks whatever knowledge he is after. For his part, the loremaster provides a wealth of information and arcane firepower to a party. Some loremasters actively deride those of their kind who fear to leave the safety of the temple or library, pointing out that only old lore can be discovered in books—new lore must be sought out in the world. These more active loremasters might join up with an adventuring party for the benefit of the journey, content with whatever knowledge might be picked up along the way."
end

#feature_typeObject



76
77
78
# File 'lib/pfrpg_classes/heroclass/loremaster.rb', line 76

def feature_type
  'LoremasterFeature'
end

#get_spells_tableObject



56
57
58
59
# File 'lib/pfrpg_classes/heroclass/loremaster.rb', line 56

def get_spells_table
  # plus one of existing class
  return PfrpgTables::Tables::Spells::SpellsPerDay.empty
end

#hit_dieObject



11
12
13
# File 'lib/pfrpg_classes/heroclass/loremaster.rb', line 11

def hit_die
  PfrpgUtility::Dice.new(1,6)
end

#nameObject



3
4
5
# File 'lib/pfrpg_classes/heroclass/loremaster.rb', line 3

def name
  "Loremaster"
end

#prerequisitesObject



65
66
67
68
69
70
71
72
73
74
# File 'lib/pfrpg_classes/heroclass/loremaster.rb', line 65

def prerequisites
  metamagic = Proc.new do |character, attribute, value|
    character.feats.select { |x| x.type == 'Metamagic' || x.type == 'Item Creation' }.size >= 3
  end
  [
    PfrpgUtility::Prerequisite.new(nil, nil, metamagic),
    PfrpgUtility::Prerequisite::LanguagePrereq.new(nil, 'Draconic'),
    PfrpgUtility::Prerequisite::MiscPrereq.new('caster level', 3)
  ]
end

#prestigeObject



7
8
9
# File 'lib/pfrpg_classes/heroclass/loremaster.rb', line 7

def prestige
  true
end

#secrets_tableObject



80
81
82
83
84
85
86
87
88
89
90
91
92
93
# File 'lib/pfrpg_classes/heroclass/loremaster.rb', line 80

def secrets_table
  [
    ['Instant Mastery', '4 ranks of a new skill', 'special', 1],
    ['Secret Health', 'Granted the Toughness feat', 'bonus_feat:toughness', 2],
    ['Secrets of inner strength', '+2 Will Save', 'saves:will:2', 3],
    ['The lore of true stamina', '+2 Fortitude Save', 'saves:fortitude:2', 4],
    ['Secret knowledge of avoidance', '+2 Reflex Save', 'saves:reflex:2', 5],
    ['Weapon trick', '+1 to attack rolls', 'combat:attack:1', 6],
    ['Dodge trick', '+1 dodge bonus to AC', 'armor:dodge:1', 7],
    ['Applicable Knowledge', 'Choose an extra feat', 'bonus_feat', 8],
    ['Newfound Arcana', 'Bonus 1st-level spell', '1stlevelspell', 9],
    ['More newfound Arcana', 'Bonus 2nd-level spell', '2ndlevelspell', 10]
  ]
end

#skillsObject



23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
# File 'lib/pfrpg_classes/heroclass/loremaster.rb', line 23

def skills
  non_knowledge =
    [PfrpgSkills::Skill::Appraise.new,
     PfrpgSkills::Skill::Diplomacy.new,
     PfrpgSkills::Skill::HandleAnimal.new,
     PfrpgSkills::Skill::Heal.new,
     PfrpgSkills::Skill::Linguistics.new,
     PfrpgSkills::Skill::Perform.new,
     PfrpgSkills::Skill::Spellcraft.new,
     PfrpgSkills::Skill::UseMagicDevice.new,
    ]
  knowledge =
    [ 'Arcana',
      'Dungeoneering',
      'Engineering',
      'Geography',
      'History',
      'Local',
      'Nature',
      'Nobility',
      'Planes',
      'Religion'
    ]
  knowledge.each do |k|
    non_knowledge << PfrpgSkills::Skill::Knowledge.new(k)
  end
  return non_knowledge
end

#skills_per_levelObject



61
62
63
# File 'lib/pfrpg_classes/heroclass/loremaster.rb', line 61

def skills_per_level
  4
end