14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
..
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
...
108
109
110
111
112
113
114
115
116
117
118
119
120
121
...
160
161
162
163
164
165
166
167
168
169
170
171
172
173
|
-- constants
local animationFrameRate = 60
local species = {
human = {
name = 'Human';
desc = 'The weeds of the galactic flowerbed. Humans are one of the Lesser Races, excluded from the ranks of the Greatest Races by souls that lack, in normal circumstances, external psionic channels. Their mastery of the universe cut unexpectedly short, forever locked out of FTL travel, short-lived without augments, and alternately pitied or scorned by the lowest of the low, humans flourish nonetheless due to a capacity for adaptation unmatched among the Thinking Few, terrifyingly rapid reproductive cycles -- and a keen facility for bribery. While the lack of human psions remains a sensitive topic, humans (unlike the bitter and emotional Kruthandi) are practical enough to hire the talent they cannot possess, and have even built a small number of symbiotic civilizations with the more indulging of the Powers. In a galaxy where nearly all sophont life is specialized to a fault, humans have found the unique niche of occupying no particular niche.';
scale = 1.0;
params = {
{'eyeColor', 'Eye Color', 'tone', {hue=327, sat=0, lum=0}};
{'hairColor', 'Hair Color', 'tone', {hue=100, sat=0, lum=0}};
{'skinTone', 'Skin Tone', 'tone', {hue= 0, sat=0, lum=0}};
};
tempRange = {
................................................................................
morale = 0.8; -- you are not She-Bear Grylls
};
traits = {
health = 400;
lungCapacity = .6;
irradiation = 0.8; -- you are smaller, so it takes less rads to kill ya
sturdiness = 0; -- women are more fragile and thus susceptible to blunt force trauma
metabolism = 1800; --Cal
painTolerance = 0.4;
};
};
male = {
name = 'Human Male';
eyeHeight = 1.6;
stats = {
psiRegen = 1.0;
psiPower = 1.0;
psi = 1.0;
hunger = 1.0;
staminaRegen = .7; -- men are strong but have inferior endurance
};
traits = {
health = 500;
painTolerance = 1.0;
lungCapacity = 1.0;
sturdiness = 0.3;
metabolism = 2200; --Cal
};
};
};
traits = {};
};
}
starlit.world.species = {
index = species;
paramTypes = paramTypes;
}
function starlit.world.species.mkDefaultParamsTable(pSpecies, pVariant)
local sp = species[pSpecies]
local var = sp.variants[pVariant]
local vpd = var.defaults or {}
local tbl = {}
for _, p in pairs(sp.params) do
................................................................................
return {
species = pSpecies;
speciesVariant = pVariant;
bodyParams = starlit.world.species.paramsFromTable(pSpecies,
starlit.world.species.mkDefaultParamsTable(pSpecies, pVariant)
);
statDeltas = {};
}
end
local function spLookup(pSpecies, pVariant)
local sp = species[pSpecies]
local var = sp.variants[pVariant or next(sp.variants)]
return sp, var
................................................................................
local delta = max - min
return min + delta*p
end
local ps = starlit.world.species.mkPersonaFor(pSpecies,pVariant)
local startingHP = pct('health', 1.0)
if circumstances.injured then startingHP = pct('health', circumstances.injured) end
if circumstances.psiCharged then ps.statDeltas.psi = pct('psi', circumstances.psiCharged) end
ps.statDeltas.warmth = 20 -- don't instantly start dying of frostbite
entity:set_properties{hp_max = var.traits.health or sp.traits.health}
entity:set_hp(startingHP, 'initial hp')
return ps
end
|
|
|
>
>
|
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
|
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
..
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
...
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
...
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
|
-- constants
local animationFrameRate = 60
local species = {
human = {
name = 'Human';
desc = 'The weeds of the galactic flowerbed. Humans are one of the Lesser Races, excluded from the ranks of the Starlit by souls that lack, in normal circumstances, external psionic channels. Their mastery of the universe cut unexpectedly short, forever locked out of FTL travel, short-lived without augments, and alternately pitied or scorned by the lowest of the low, humans flourish nonetheless due to a capacity for adaptation unmatched among the Thinking Few, terrifyingly rapid reproductive cycles -- and a keen facility for bribery. While the lack of human psions remains a sensitive topic, humans (unlike the bitter and emotional Kruthandi) are practical enough to hire the talent they cannot possess, and have even built a small number of symbiotic civilizations with the more indulging of the Powers. In a galaxy where nearly all sophont life is specialized to a fault, humans have found the unique niche of occupying no particular niche.';
scale = 1.0;
params = {
{'eyeColor', 'Eye Color', 'tone', {hue=327, sat=0, lum=0}};
{'hairColor', 'Hair Color', 'tone', {hue=100, sat=0, lum=0}};
{'skinTone', 'Skin Tone', 'tone', {hue= 0, sat=0, lum=0}};
};
tempRange = {
................................................................................
morale = 0.8; -- you are not She-Bear Grylls
};
traits = {
health = 400;
lungCapacity = .6;
irradiation = 0.8; -- you are smaller, so it takes less rads to kill ya
sturdiness = 0; -- women are more fragile and thus susceptible to blunt force trauma
metabolism = 1800e3 / 24 / 60 / 60; --kCal/s
painTolerance = 0.4;
dehydration = 3; -- mL/s
};
};
male = {
name = 'Human Male';
eyeHeight = 1.6;
stats = {
psiRegen = 1.0;
psiPower = 1.0;
psi = 1.0;
hunger = 1.0;
thirst = 1.0;
staminaRegen = .7; -- men are strong but have inferior endurance
};
traits = {
health = 500;
painTolerance = 1.0;
lungCapacity = 1.0;
sturdiness = 0.3;
metabolism = 2200e3 / 24 / 60 / 60; --Cal/s
dehydration = 5; -- mL/s
};
};
};
traits = {};
};
}
starlit.world.species = {
index = species;
paramTypes = paramTypes;
}
starlit.world.species.pheno = lib.class {
name = 'starlit:species.pheno';
construct = function(pSp, pVar)
local sp, var = starlit.world.species.lookup(pSp, pVar)
return {
species = sp, variant = var;
pSpecies = pSp, pVariant = pVar;
};
end;
__index = {
trait = function(me, st, dflt)
local v = me.variant.traits[st] or me.species.traits[st]
return v or dflt
end;
};
}
function starlit.world.species.mkDefaultParamsTable(pSpecies, pVariant)
local sp = species[pSpecies]
local var = sp.variants[pVariant]
local vpd = var.defaults or {}
local tbl = {}
for _, p in pairs(sp.params) do
................................................................................
return {
species = pSpecies;
speciesVariant = pVariant;
bodyParams = starlit.world.species.paramsFromTable(pSpecies,
starlit.world.species.mkDefaultParamsTable(pSpecies, pVariant)
);
statDeltas = {};
facts = {};
}
end
local function spLookup(pSpecies, pVariant)
local sp = species[pSpecies]
local var = sp.variants[pVariant or next(sp.variants)]
return sp, var
................................................................................
local delta = max - min
return min + delta*p
end
local ps = starlit.world.species.mkPersonaFor(pSpecies,pVariant)
local startingHP = pct('health', 1.0)
if circumstances.injured then startingHP = pct('health', circumstances.injured) end
if circumstances.psiCharged then ps.statDeltas.psi = pct('psi', circumstances.psiCharged) end
for k,v in pairs(starlit.world.stats) do ps.statDeltas[k] = 0 end
ps.statDeltas.warmth = 20 -- don't instantly start dying of frostbite
entity:set_properties{hp_max = var.traits.health or sp.traits.health}
entity:set_hp(startingHP, 'initial hp')
return ps
end
|