class Faker::Games::DnD

Public Class Methods

alignment() click to toggle source

Produces the name of an alignment from Dungeons and Dragons.

@return [String]

@example

Faker::Games::DnD.alignment #=> "Lawful Neutral"

@faker.version 2.13.0

# File lib/faker/games/dnd.rb, line 16
def alignment
  fetch('dnd.alignments')
end
background() click to toggle source

Produces the name of a background from Dungeons and Dragons (PHB).

@return [String]

@example

Faker::Games::DnD.background #=> "Urchin"

@faker.version 2.13.0

# File lib/faker/games/dnd.rb, line 29
def background
  fetch('dnd.backgrounds')
end
city() click to toggle source

Produces the name of a city from Dungeons and Dragons.

@return [String]

@example

Faker::Games::DnD.city #=> "Earthfast"

@faker.version 2.14.0

# File lib/faker/games/dnd.rb, line 42
def city
  fetch('dnd.cities')
end
klass() click to toggle source

Produces the name of a class from Dungeons and Dragons (PHB).

@return [String]

@example

Faker::Games::DnD.klass #=> "Warlock"

@faker.version 2.13.0

# File lib/faker/games/dnd.rb, line 55
def klass
  fetch('dnd.klasses')
end
language() click to toggle source

Produces the name of a language from Dungeons and Dragons.

@return [String]

@example

Faker::Games::DnD.language #=> "Gnomish"

@faker.version 2.14.0

# File lib/faker/games/dnd.rb, line 68
def language
  fetch('dnd.languages')
end
melee_weapon() click to toggle source

Produces the name of a melee weapon from Dungeons and Dragons.

@return [String]

@example

Faker::Games::DnD.melee_weapon #=> "Handaxe"

@faker.version 2.14.0

# File lib/faker/games/dnd.rb, line 81
def melee_weapon
  fetch('dnd.melee_weapons')
end
monster() click to toggle source

Produces the name of a monster from Dungeons and Dragons.

@return [String]

@example

Faker::Games::DnD.monster #=> "Manticore"

@faker.version 2.14.0

# File lib/faker/games/dnd.rb, line 94
def monster
  fetch('dnd.monsters')
end
race() click to toggle source

Produces the name of a race from Dungeons and Dragons (PHB).

@return [String]

@example

Faker::Games::DnD.races #=> "Dwarf"

@faker.version 2.14.0

# File lib/faker/games/dnd.rb, line 107
def race
  fetch('dnd.races')
end
ranged_weapon() click to toggle source

Produces the name of a ranged weapon from Dungeons and Dragons.

@return [String]

@example

Faker::Games::DnD.ranged_weapon #=> "Shortbow"

@faker.version 2.14.0

# File lib/faker/games/dnd.rb, line 120
def ranged_weapon
  fetch('dnd.ranged_weapons')
end
species() click to toggle source

This method is deprecated. The implementation will be removed in a near future release. Use ‘DnD.race` instead.

@deprecated Use {#race} instead.

Calls superclass method
# File lib/faker/games/dnd.rb, line 128
def species
  warn '`DnD.species` is deprecated. Use `DnD.race` instead.'

  super
end