superhero 0.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +7 -0
- data/lib/superhero.rb +160 -0
- metadata +44 -0
checksums.yaml
ADDED
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
---
|
|
2
|
+
SHA1:
|
|
3
|
+
metadata.gz: bde466c5c47b1629b51edf2f3a29ce913eea3705
|
|
4
|
+
data.tar.gz: b6da4722c96fbd8a1c76fe714df1163d4e79edfe
|
|
5
|
+
SHA512:
|
|
6
|
+
metadata.gz: 678f4ecfcf9d833f3f9f664f0eacd30e05d6349e64e2d68ba0b07c3501925fa46301bfbd70a4d9273a615c4f585babed159edc3a7014727899d8500784734a5f
|
|
7
|
+
data.tar.gz: 688e58ae55d94bb345e744b93cd95a03bb6a6dbfb7bebc249bf9e494902844b5a32b72df3d638048a2d3e5c14106d301f043e29b19ed942e8940a2071e8ee096
|
data/lib/superhero.rb
ADDED
|
@@ -0,0 +1,160 @@
|
|
|
1
|
+
require 'faker'
|
|
2
|
+
class Superhero
|
|
3
|
+
@@adjectives = ["mega ","super ","epic ", "awesome ", "deadly ", "lethal ", "powerful ", "instantaneous ", "crazy cool ", "wonderous ", "spectacular ", "ingenious ", "mad skillful ", "extraordinary ", "simple ", "weird ", "instinctual ", "hypothetical ", "insurmountable ", "unavoidable ", "uncontrollable ", "killer ", "wicked-awesome ", "sick-nasty ", "janky ", "new-age ", "never before seen ", "special ", "amazing ", "terrible ", "horrible ", "classy ", "terrific ", "mind-bending ", "jaw-dropping ", "", "", "", ""]
|
|
4
|
+
@@superpowers = %{Adhesion
|
|
5
|
+
Amphibious
|
|
6
|
+
Animal control
|
|
7
|
+
Animate/control the dead
|
|
8
|
+
Autonomic function control
|
|
9
|
+
Body duplication
|
|
10
|
+
Body transformation
|
|
11
|
+
Bullet-proof
|
|
12
|
+
Chemical control
|
|
13
|
+
Clairvoyance
|
|
14
|
+
Cold generation
|
|
15
|
+
Computer hacking
|
|
16
|
+
Cosmic awareness
|
|
17
|
+
Danger sense
|
|
18
|
+
Dark generation/control
|
|
19
|
+
Density control
|
|
20
|
+
Deus ex machina
|
|
21
|
+
Direct computer interface
|
|
22
|
+
Earthquake generation
|
|
23
|
+
Earth/rock control
|
|
24
|
+
Elasticity
|
|
25
|
+
Electrical generation/control
|
|
26
|
+
Electromagnetism
|
|
27
|
+
Empathy
|
|
28
|
+
Encyclopedic knowledge
|
|
29
|
+
Energy absorption
|
|
30
|
+
Energy blasts
|
|
31
|
+
Energy manipulation
|
|
32
|
+
Enhanced agility
|
|
33
|
+
Enhanced common sense
|
|
34
|
+
Enhanced senses
|
|
35
|
+
Enhanced senses
|
|
36
|
+
Escape artist
|
|
37
|
+
Explodes
|
|
38
|
+
Extra appendage(s)
|
|
39
|
+
Extra-dimensional travel
|
|
40
|
+
Extreme popularity
|
|
41
|
+
Flame generation/control
|
|
42
|
+
Flight Flight Flight
|
|
43
|
+
Force blasts
|
|
44
|
+
Force field generation
|
|
45
|
+
Friction manipulation
|
|
46
|
+
Gadget creation
|
|
47
|
+
Glows in the dark
|
|
48
|
+
Growth
|
|
49
|
+
Gravity control
|
|
50
|
+
Heat generation
|
|
51
|
+
Heat vision
|
|
52
|
+
Hold breath indefinitely
|
|
53
|
+
Hypnosis
|
|
54
|
+
Ice generation
|
|
55
|
+
Illusion casting
|
|
56
|
+
Image projection
|
|
57
|
+
Immortality
|
|
58
|
+
Incomprehensibility
|
|
59
|
+
Incredible balance
|
|
60
|
+
Insect control
|
|
61
|
+
Instant language understanding
|
|
62
|
+
Intangibility
|
|
63
|
+
Intuition
|
|
64
|
+
Invisibility
|
|
65
|
+
Invulnerability
|
|
66
|
+
Juggling
|
|
67
|
+
Laser vision
|
|
68
|
+
Light generation/control
|
|
69
|
+
Luck
|
|
70
|
+
Lycanthrope
|
|
71
|
+
Machine control
|
|
72
|
+
Magic spell casting
|
|
73
|
+
Magnetism
|
|
74
|
+
Martial arts mastery
|
|
75
|
+
Matter consumption
|
|
76
|
+
Microscopic vision
|
|
77
|
+
Mind control
|
|
78
|
+
Mind-numbing beauty/ugliness
|
|
79
|
+
Molecular control
|
|
80
|
+
Odor generation
|
|
81
|
+
Omni directional sight
|
|
82
|
+
Omnipotence
|
|
83
|
+
Omniscience
|
|
84
|
+
Perfect pitch
|
|
85
|
+
Photographic memory
|
|
86
|
+
Plant control
|
|
87
|
+
Poison resistance
|
|
88
|
+
Power mimicry
|
|
89
|
+
Precognition
|
|
90
|
+
Prehensile tail
|
|
91
|
+
Psychic
|
|
92
|
+
Pyrokinesis
|
|
93
|
+
Radar sense
|
|
94
|
+
Radiation generation/control
|
|
95
|
+
Regeneration
|
|
96
|
+
Reinforced skeleton
|
|
97
|
+
Seventh sense
|
|
98
|
+
Shape-shifting
|
|
99
|
+
Sharp shooting
|
|
100
|
+
Shrinking
|
|
101
|
+
Smoke generation/control
|
|
102
|
+
Sound generation/control
|
|
103
|
+
Speed reading
|
|
104
|
+
Super breath
|
|
105
|
+
Super hearing
|
|
106
|
+
Super intelligence
|
|
107
|
+
Super jumping
|
|
108
|
+
Super loud voice
|
|
109
|
+
Super speed
|
|
110
|
+
Super spelling
|
|
111
|
+
Super strength Super strength Super strength
|
|
112
|
+
Super ventriloquism
|
|
113
|
+
Super-human hand-eye coordination
|
|
114
|
+
Super-human stamina
|
|
115
|
+
Super-human throwing accuracy
|
|
116
|
+
Super-human weight-guessing accuracy
|
|
117
|
+
Telekinesis
|
|
118
|
+
Telepathy
|
|
119
|
+
Teleportation
|
|
120
|
+
Telescopic vision
|
|
121
|
+
Time manipulation
|
|
122
|
+
Time travel
|
|
123
|
+
Water control
|
|
124
|
+
Weapon mastery
|
|
125
|
+
Weather control
|
|
126
|
+
Weather prediction
|
|
127
|
+
Unaided outer space travel
|
|
128
|
+
X-ray vision
|
|
129
|
+
}.lines
|
|
130
|
+
@@orientation = ['neutral', 'evil', 'good']
|
|
131
|
+
@@level = ['lawful','neutral','chaotic']
|
|
132
|
+
def self.power
|
|
133
|
+
"#{@@adjectives.sample}#{@@superpowers.sample.downcase.gsub(/\n/, '')}"
|
|
134
|
+
end
|
|
135
|
+
def self.alignment
|
|
136
|
+
"#{@@level.sample}-#{@@orientation.sample}"
|
|
137
|
+
end
|
|
138
|
+
def self.name
|
|
139
|
+
Faker::App.name
|
|
140
|
+
end
|
|
141
|
+
def self.alias
|
|
142
|
+
Faker::Name.name
|
|
143
|
+
end
|
|
144
|
+
def self.nemesis
|
|
145
|
+
title = ["Dr. ", "Mr. ", "The ", "Professor ", "He Whom They Call ", "The One Named ", "Super ", "Ultra ", "Mega ", "The Angry ", "The Last ", "Master ", "", "Cable Guy ", "Miss ", "Maestro ", "Misses ", "Madame ", "Sister ", "The Temptress ", "A Punk Named ", "Puny ", "Tiny ", "Babyface ", "Sinister ", "The Evilest ", "Murder Face ", "Bad ", "Bad Boy ", "Pretty Boy ", "A Girl Named ", "Squidface ", "", "Temper ", "Alien ", "The Skilled ", "Top Dog ", "T-Dawg ", "Tough Nut ", "The Irate ", "", "Ballerina ", "Mob Boss ", "Pretty Tony ", "Robot Model 688-", "Robot Model 42-", "A Poodle Named ", "The Secret Trigger Word ", "", "Mamy ", "The Body ", "Medusa ", "Gin and ", "Siracha Sauce ", "Slick Willy ", "Jennifer ", "Tamany ", "Pool Shark ", "Loan Shark ", "Mama ", "", "The Only ", "", "", "Tiny ", "", "Master ", "Dr. ", "Dr. ", "The ", "The ", "The ", "Miss ", "Misses ", "Mega ", "Ultra ", "Super ", "", "", "", "", Faker::Name.title + " ", Faker::Name.title + " ", Faker::Name.title + " ", Faker::Name.prefix + " ", Faker::Name.prefix + " ", Faker::Name.prefix + " ", Faker::Name.prefix + " ", Faker::Name.prefix, Faker::Name.prefix + " ", Faker::Hacker.adjective + " ", Faker::Hacker.adjective + " ", Faker::Hacker.adjective + " ", Faker::Hacker.abbreviation + " "]
|
|
146
|
+
name = [Faker::App.name, Faker::App.name, Faker::App.name, Faker::App.name, Faker::App.name, Faker::App.name, Faker::App.name, Faker::Name.title, Faker::Name.title, Faker::Name.name, Faker::Name.last_name, Faker::Name.last_name, Faker::Name.last_name, Faker::Name.last_name, Faker::Name.last_name, Faker::Name.first_name, Faker::Name.first_name, Faker::Name.first_name, Faker::Name.first_name, Faker::Name.first_name, Faker::Name.first_name, Faker::App.author, Faker::App.author]
|
|
147
|
+
title = (title + @@adjectives).flatten
|
|
148
|
+
title.sample + name.sample
|
|
149
|
+
end
|
|
150
|
+
def self.weakness
|
|
151
|
+
adjectives = ["shiney ", "sharp ", "slimey ", 'little ', 'angry ', 'frightened ', "painful ", "", "", "", "", "", "", "", "", "", "", "", "", "heavy ", "rusty ", "faded ", "a pack of ", "some ", "any type of ", "hairy ", "cute and cudly ", "burning ", "overhyped ", "loud ", "thick ", "overly attached ", "twin ", "simple ", "wet ", "red ", "blue ", "green ", "yellow ", "orange ", "brown ", "happy ", "sad ", "cool ", "hot ", "tattered ", "paper ", "plastic ", "a call from ", "sliced ", "too many ", "the last ", "too few ", "sticky ", "kisses from ", "lengthy ", "ketchup on ", "beautiful ", "perrywinkle ", "kind "]
|
|
152
|
+
nouns = ["animals", "tacks", "toy cars", "cigarrettes", "cereal", "muffins", "corn", "fish", "monkeys", "bears", "stuffed animals", "cartoons", "weddings", "movie scenes", "books", "people", "songs", "folders", "paper cuts", "kitchen sinks", "newspaper articles", "girls", "boys", "men", "women", "dogs", "cats", "trees", "balls", "liquids", "gasses", "solids", "bushes", "birds", "snakes" ,"wookies", "melodies", "apples", "teens", "gangsters", "reporters", "glasses", "hats", "pizzas", "canolis", "beans", "toddlers", "poodles", "octopi", "spleens", "sweats", "t-shirts", "pants", "hats", "love", "hate", "r&b singers", "royal weddings", "symphonies", "spyglasses", "terraformers", "water-dwellers", "land-walkers", "seedlings", "boulders", "airplanes", "seas", "mountains", "worlds", "pies", "cakes", "drinks", "fluids", "words", "phrases", "eyes", "chairs", "crystals", "gems", "rocks", "vegetables", "salt-water", "mummies", "wolves", "ghosts", "aliens", "rappers", "skeletons", "tissues", "lawyers", "politicians", "pansies", "roses", "trains", "particles", "dust mites", "mosquitos", "hippos"]
|
|
153
|
+
adjectives = (adjectives + @@adjectives).flatten
|
|
154
|
+
adjectives.sample + nouns.sample
|
|
155
|
+
end
|
|
156
|
+
def self.describe
|
|
157
|
+
name = self.name
|
|
158
|
+
"#{name} (alias: #{self.alias}) is #{self.alignment} and their power is #{self.power} #{@@superpowers.sample.downcase.gsub(/\n/, '')}. #{name}'s weakness is #{self.weakness} and their arch-nemesis is #{self.nemesis}"
|
|
159
|
+
end
|
|
160
|
+
end
|
metadata
ADDED
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
|
2
|
+
name: superhero
|
|
3
|
+
version: !ruby/object:Gem::Version
|
|
4
|
+
version: 0.3.0
|
|
5
|
+
platform: ruby
|
|
6
|
+
authors:
|
|
7
|
+
- Robert Wilkinson
|
|
8
|
+
- Keyan Bagheri
|
|
9
|
+
autorequire:
|
|
10
|
+
bindir: bin
|
|
11
|
+
cert_chain: []
|
|
12
|
+
date: 2015-05-28 00:00:00.000000000 Z
|
|
13
|
+
dependencies: []
|
|
14
|
+
description:
|
|
15
|
+
email:
|
|
16
|
+
executables: []
|
|
17
|
+
extensions: []
|
|
18
|
+
extra_rdoc_files: []
|
|
19
|
+
files:
|
|
20
|
+
- lib/superhero.rb
|
|
21
|
+
homepage:
|
|
22
|
+
licenses: []
|
|
23
|
+
metadata: {}
|
|
24
|
+
post_install_message:
|
|
25
|
+
rdoc_options: []
|
|
26
|
+
require_paths:
|
|
27
|
+
- lib
|
|
28
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
|
29
|
+
requirements:
|
|
30
|
+
- - '>='
|
|
31
|
+
- !ruby/object:Gem::Version
|
|
32
|
+
version: '0'
|
|
33
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
|
34
|
+
requirements:
|
|
35
|
+
- - '>='
|
|
36
|
+
- !ruby/object:Gem::Version
|
|
37
|
+
version: '0'
|
|
38
|
+
requirements: []
|
|
39
|
+
rubyforge_project:
|
|
40
|
+
rubygems_version: 2.0.14
|
|
41
|
+
signing_key:
|
|
42
|
+
specification_version: 4
|
|
43
|
+
summary: A gem to generate random superhero powers
|
|
44
|
+
test_files: []
|