Unfinished, but laptop is dying
This commit is contained in:
parent
8f59c28565
commit
a66fa490a7
52
lib/OSRIC/Races.pm
Normal file
52
lib/OSRIC/Races.pm
Normal file
@ -0,0 +1,52 @@
|
||||
package OSRIC::Races;
|
||||
|
||||
# The stat buffs/nerfs a race gives:
|
||||
sub stats_boosts
|
||||
{
|
||||
{
|
||||
str => 0,
|
||||
dex => 0,
|
||||
con => 0,
|
||||
int => 0,
|
||||
wis => 0,
|
||||
cha => 0,
|
||||
}
|
||||
}
|
||||
|
||||
# The permitted classes:
|
||||
sub permitted_classes
|
||||
{
|
||||
[ "Assassin", "Cleric", "Druid", "Fighter", "Illusionist", "MagicUser",
|
||||
"Paladin", "Ranger", "Thief" ]
|
||||
}
|
||||
|
||||
# A hash of subs to generate the starting age based on class:
|
||||
sub ages
|
||||
{
|
||||
{
|
||||
assassin => sub { },
|
||||
cleric => sub { },
|
||||
druid => sub { },
|
||||
fighter => sub { },
|
||||
illusionist => sub { },
|
||||
magicuser => sub { },
|
||||
paladin => sub { },
|
||||
ranger => sub { },
|
||||
theif => sub { },
|
||||
}
|
||||
}
|
||||
|
||||
# The racial limitations:
|
||||
sub racial_limitations
|
||||
{
|
||||
{
|
||||
str => { min => 0, max => 0 },
|
||||
dex => { min => 0, max => 0 },
|
||||
con => { min => 0, max => 0 },
|
||||
int => { min => 0, max => 0 },
|
||||
wis => { min => 0, max => 0 },
|
||||
cha => { min => 0, max => 0 },
|
||||
}
|
||||
}
|
||||
|
||||
1;
|
53
lib/OSRIC/Races/Dwarf.pm
Normal file
53
lib/OSRIC/Races/Dwarf.pm
Normal file
@ -0,0 +1,53 @@
|
||||
package OSRIC::Races::Dwarf
|
||||
use parent qw(OSRIC::Races);
|
||||
use OSRIC::Util qw/d/;
|
||||
|
||||
# The stat buffs/nerfs a race gives:
|
||||
sub stats_boosts
|
||||
{
|
||||
{
|
||||
str => 0,
|
||||
dex => 0,
|
||||
con => 1,
|
||||
int => 0,
|
||||
wis => 0,
|
||||
cha => -1,
|
||||
}
|
||||
}
|
||||
|
||||
# The permitted classes:
|
||||
sub permitted_classes
|
||||
{
|
||||
[ "Assassin", "Cleric", "Fighter", "Thief", [ "Fighter", "Thief" ] ]
|
||||
}
|
||||
|
||||
# A hash of subs to generate the starting age based on class:
|
||||
sub ages
|
||||
{
|
||||
{
|
||||
assassin => sub { (75 + (d(6) + d(6) + d(6))) },
|
||||
cleric => sub { (250 + (d(20) + d(20))) },
|
||||
druid => sub { 0 },
|
||||
fighter => sub { (40 + (d(4) + d(4) + d(4) + d(4) + d(4))) },
|
||||
illusionist => sub { 0 },
|
||||
magicuser => sub { 0 },
|
||||
paladin => sub { 0 },
|
||||
ranger => sub { 0 },
|
||||
theif => sub { (75 + (d(6) + d(6) + d(6))) },
|
||||
}
|
||||
}
|
||||
|
||||
# The racial limitations:
|
||||
sub racial_limitations
|
||||
{
|
||||
{
|
||||
str => { min => 8, max => 18 },
|
||||
dex => { min => 3, max => 17 },
|
||||
con => { min => 12, max => 19 },
|
||||
int => { min => 3, max => 18 },
|
||||
wis => { min => 3, max => 18 },
|
||||
cha => { min => 3, max => 16 },
|
||||
}
|
||||
}
|
||||
|
||||
1;
|
55
lib/OSRIC/Races/Elf.pm
Normal file
55
lib/OSRIC/Races/Elf.pm
Normal file
@ -0,0 +1,55 @@
|
||||
package OSRIC::Races::Elf;
|
||||
use parent qw(OSRIC::Races);
|
||||
use OSRIC::Util qw/d/;
|
||||
|
||||
# The stat buffs/nerfs a race gives:
|
||||
sub stats_boosts
|
||||
{
|
||||
{
|
||||
str => 0,
|
||||
dex => 1,
|
||||
con => -1,
|
||||
int => 0,
|
||||
wis => 0,
|
||||
cha => 0,
|
||||
}
|
||||
}
|
||||
|
||||
# The permitted classes:
|
||||
sub permitted_classes
|
||||
{
|
||||
[ "Assassin", "Cleric", "Fighter", "MagicUser", "Thief",
|
||||
[ "Fighter", "MagicUser" ], [ "Fighter", "Thief" ],
|
||||
[ "MagicUser", "Thief" ], [ "Fighter", "MagicUser", "Thief" ] ]
|
||||
}
|
||||
|
||||
# A hash of subs to generate the starting age based on class:
|
||||
sub ages
|
||||
{
|
||||
{
|
||||
assassin => sub { 0 },
|
||||
cleric => sub { my $i = 0; $i += d(10) for(1..10); $i += 500; },
|
||||
druid => sub { 0 },
|
||||
fighter => sub { my $i = 0; $i += d(6) for(1..5); $i += 130; },
|
||||
illusionist => sub { 0 },
|
||||
magicuser => sub { my $i = 0; $i += d(6) for(1..5); $i += 150; },
|
||||
paladin => sub { 0 },
|
||||
ranger => sub { 0 },
|
||||
theif => sub { my $i = 0; $i += d(6) for(1..5); $i += 100; },
|
||||
}
|
||||
}
|
||||
|
||||
# The racial limitations:
|
||||
sub racial_limitations
|
||||
{
|
||||
{
|
||||
str => { min => 3, max => 18 },
|
||||
dex => { min => 7, max => 19 },
|
||||
con => { min => 8, max => 17 },
|
||||
int => { min => 8, max => 18 },
|
||||
wis => { min => 3, max => 18 },
|
||||
cha => { min => 3, max => 18 },
|
||||
}
|
||||
}
|
||||
|
||||
1;
|
55
lib/OSRIC/Races/Gnome.pm
Normal file
55
lib/OSRIC/Races/Gnome.pm
Normal file
@ -0,0 +1,55 @@
|
||||
package OSRIC::Races::Gnome;
|
||||
use parent qw(OSRIC::Races);
|
||||
use OSRIC::Util qw/d/;
|
||||
|
||||
# The stat buffs/nerfs a race gives:
|
||||
sub stats_boosts
|
||||
{
|
||||
{
|
||||
str => 0,
|
||||
dex => 0,
|
||||
con => 0,
|
||||
int => 0,
|
||||
wis => 0,
|
||||
cha => 0,
|
||||
}
|
||||
}
|
||||
|
||||
# The permitted classes:
|
||||
sub permitted_classes
|
||||
{
|
||||
[ "Assassin", "Cleric", "Fighter", "Illusionist", "Thief",
|
||||
[ "Fighter", "Illusionist" ], [ "Fighter", "Thief" ],
|
||||
[ "Illusionist", "Thief" ] ]
|
||||
}
|
||||
|
||||
# A hash of subs to generate the starting age based on class:
|
||||
sub ages
|
||||
{
|
||||
{
|
||||
assassin => sub { my $i = 0; $i += d(4) for(1..5); $i += 80; },
|
||||
cleric => sub { my $i = 0; $i += d(12) for(1..3); $i += 300; },
|
||||
druid => sub { 0 },
|
||||
fighter => sub { my $i = 0; $i += d(4) for(1..5); $i += 60; },
|
||||
illusionist => sub { my $i = 0; $i += d(12) for(1..2); $i += 100; }
|
||||
magicuser => sub { 0 },
|
||||
paladin => sub { 0 },
|
||||
ranger => sub { 0 },
|
||||
theif => sub { my $i = 0; $i += d(4) for(1..5); $i += 80; },
|
||||
}
|
||||
}
|
||||
|
||||
# The racial limitations:
|
||||
sub racial_limitations
|
||||
{
|
||||
{
|
||||
str => { min => 6, max => 18 },
|
||||
dex => { min => 3, max => 19 },
|
||||
con => { min => 8, max => 17 },
|
||||
int => { min => 7, max => 18 },
|
||||
wis => { min => 3, max => 18 },
|
||||
cha => { min => 3, max => 18 },
|
||||
}
|
||||
}
|
||||
|
||||
1;
|
55
lib/OSRIC/Races/HalfElf.pm
Normal file
55
lib/OSRIC/Races/HalfElf.pm
Normal file
@ -0,0 +1,55 @@
|
||||
package OSRIC::Races::HalfElf;
|
||||
use parent qw(OSRIC::Races);
|
||||
use OSRIC::Util qw/d/;
|
||||
|
||||
# The stat buffs/nerfs a race gives:
|
||||
sub stats_boosts
|
||||
{
|
||||
{
|
||||
str => 0,
|
||||
dex => 0,
|
||||
con => 0,
|
||||
int => 0,
|
||||
wis => 0,
|
||||
cha => 0,
|
||||
}
|
||||
}
|
||||
|
||||
# The permitted classes:
|
||||
sub permitted_classes
|
||||
{
|
||||
[ "Assassin", "Cleric", "Fighter", "MagicUser", "Ranger", "Thief",
|
||||
[ "Cleric", "Fighter" ], [ "Cleric", "Ranger" ],
|
||||
[ "Illusionist", "Thief" ] ]
|
||||
}
|
||||
|
||||
# A hash of subs to generate the starting age based on class:
|
||||
sub ages
|
||||
{
|
||||
{
|
||||
assassin => sub { my $i = 0; $i += d(4) for(1..5); $i += 80; },
|
||||
cleric => sub { my $i = 0; $i += d(12) for(1..3); $i += 300; },
|
||||
druid => sub { 0 },
|
||||
fighter => sub { my $i = 0; $i += d(4) for(1..5); $i += 60; },
|
||||
illusionist => sub { my $i = 0; $i += d(12) for(1..2); $i += 100; }
|
||||
magicuser => sub { 0 },
|
||||
paladin => sub { 0 },
|
||||
ranger => sub { 0 },
|
||||
theif => sub { my $i = 0; $i += d(4) for(1..5); $i += 80; },
|
||||
}
|
||||
}
|
||||
|
||||
# The racial limitations:
|
||||
sub racial_limitations
|
||||
{
|
||||
{
|
||||
str => { min => 6, max => 18 },
|
||||
dex => { min => 3, max => 19 },
|
||||
con => { min => 8, max => 17 },
|
||||
int => { min => 7, max => 18 },
|
||||
wis => { min => 3, max => 18 },
|
||||
cha => { min => 3, max => 18 },
|
||||
}
|
||||
}
|
||||
|
||||
1;
|
5
lib/OSRIC/Races/HalfOrc.pm
Normal file
5
lib/OSRIC/Races/HalfOrc.pm
Normal file
@ -0,0 +1,5 @@
|
||||
package OSRIC::Races::
|
||||
use parent qw(OSRIC::Races);
|
||||
use OSRIC::Util qw/d/;
|
||||
|
||||
1;
|
5
lib/OSRIC/Races/Halfling.pm
Normal file
5
lib/OSRIC/Races/Halfling.pm
Normal file
@ -0,0 +1,5 @@
|
||||
package OSRIC::Races::
|
||||
use parent qw(OSRIC::Races);
|
||||
use OSRIC::Util qw/d/;
|
||||
|
||||
1;
|
5
lib/OSRIC/Races/Human.pm
Normal file
5
lib/OSRIC/Races/Human.pm
Normal file
@ -0,0 +1,5 @@
|
||||
package OSRIC::Races::
|
||||
use parent qw(OSRIC::Races);
|
||||
use OSRIC::Util qw/d/;
|
||||
|
||||
1;
|
Loading…
Reference in New Issue
Block a user