Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Experience revamp #1470

Merged
merged 1 commit into from
Dec 9, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
97 changes: 96 additions & 1 deletion config.lua
Original file line number Diff line number Diff line change
Expand Up @@ -471,7 +471,102 @@ storage.config = {
},
admin_panel = {
enabled = true,
}
},
experience = {
enabled = false,
-- controls the formula for calculating level up costs in stone sent to surface
difficulty_scale = 20, -- Diggy default 20. Higher increases experience requirement climb
first_lvl_xp = 350, -- Diggy default 350. This sets the price for the first level.
xp_fine_tune = 400, -- Diggy default 400. This value is used to fine tune the overall requirement climb without affecting the speed
cost_precision = 3, -- Diggy default 3. This sets the precision of the required experience to level up. E.g. 1234 becomes 1200 with precision 2 and 1230 with precision 3.
-- percentage * mining productivity level gets added to mining speed
mining_speed_productivity_multiplier = 5,
XP = {
['big-rock'] = 5,
['huge-rock'] = 10,
['rocket_launch'] = 0.05, -- XP reward in percentage of total experience when a rocket launches (Diggy default: 0.05 which equals 5%)
['rocket_launch_max'] = 500000, -- Max XP reward from rocket launches (Diggy default: 500000)
['automation-science-pack'] = 4,
['logistic-science-pack'] = 8,
['chemical-science-pack'] = 15,
['military-science-pack'] = 12,
['production-science-pack'] = 25,
['utility-science-pack'] = 50,
['space-science-pack'] = 10,
['enemy_killed'] = 10, -- Base XP for killing biters and spitters.
['death-penalty'] = 0.0035, -- XP deduct in percentage of total experience when a player dies (Diggy default: 0.0035 which equals 0.35%)
--['cave-in-penalty'] = 100 -- XP lost every cave in.
['infinity-research'] = 0.60 -- XP reward in percentage of the required experience from current level to next level (Diggy default: 0.60 which equals 60%)
},
buffs = {
-- define new buffs here, they are handed out for each level
mining_speed = { value = 5, max = 10 },
inventory_slot = { value = 1, max = 100 },
-- double_level is the level interval for receiving a double bonus (Diggy default: 5 which equals every 5th level)
health_bonus = { value = 2.5, double_level = 5, max = 500 }
},
-- add or remove a table entry to add or remove an unlockable item from the market.
unlockables = {
{ level = 2, price = 4, name = 'wood' },
{ level = 3, price = 5, name = 'stone-wall' },
{ level = 4, price = 20, name = 'pistol' },
{ level = 4, price = 5, name = 'firearm-magazine' },
{ level = 5, price = 100, name = 'light-armor' },
{ level = 6, price = 6, name = 'small-lamp' },
{ level = 6, price = 5, name = 'raw-fish' },
{ level = 8, price = 1, name = 'stone-brick' },
{ level = 10, price = 85, name = 'shotgun' },
{ level = 10, price = 4, name = 'shotgun-shell' },
{ level = 12, price = 200, name = 'heavy-armor' },
{ level = 14, price = 25, name = 'landfill' },
{ level = 15, price = 85, name = 'submachine-gun' },
{ level = 18, price = 10, name = 'piercing-rounds-magazine' },
{ level = 18, price = 8, name = 'piercing-shotgun-shell' },
{ level = 19, price = 2, name = 'rail' },
{ level = 19, price = 1, name = 'iron-stick' },
{ level = 20, price = 50, name = 'locomotive' },
{ level = 20, price = 350, name = 'modular-armor' },
{ level = 21, price = 5, name = 'rail-signal' },
{ level = 22, price = 5, name = 'rail-chain-signal' },
{ level = 23, price = 15, name = 'train-stop' },
{ level = 24, price = 35, name = 'cargo-wagon' },
{ level = 24, price = 35, name = 'fluid-wagon' },
{ level = 26, price = 150, name = 'tank' },
{ level = 29, price = 750, name = 'power-armor' },
{ level = 30, price = 30, name = 'logistic-robot' },
{ level = 31, price = 200, name = 'personal-roboport-equipment' },
{ level = 32, price = 20, name = 'construction-robot' },
{ level = 34, price = 750, name = 'fission-reactor-equipment' },
{ level = 35, price = 150, name = 'battery-equipment' },
{ level = 38, price = 250, name = 'exoskeleton-equipment' },
{ level = 40, price = 125, name = 'energy-shield-equipment' },
{ level = 42, price = 500, name = 'personal-laser-defense-equipment' },
{ level = 44, price = 1250, name = 'power-armor-mk2' },
{ level = 46, price = 750, name = 'battery-mk2-equipment' },
{ level = 48, price = 550, name = 'combat-shotgun' },
{ level = 51, price = 25, name = 'uranium-rounds-magazine' },
{ level = 63, price = 250, name = 'rocket-launcher' },
{ level = 63, price = 40, name = 'rocket' },
{ level = 71, price = 80, name = 'explosive-rocket' },
{ level = 78, price = 1000, name = 'satellite' },
{ level = 100, price = 2500, name = 'spidertron' },
},
-- modifies the experience per alien type, higher is more xp
alien_experience_modifiers = {
['small-biter'] = 2,
['small-spitter'] = 2,
['small-worm-turret'] = 2,
['medium-biter'] = 3,
['medium-spitter'] = 3,
['medium-worm-turret'] = 3,
['big-biter'] = 5,
['big-spitter'] = 5,
['big-worm-turret'] = 5,
['behemoth-biter'] = 7,
['behemoth-spitter'] = 7,
['behemoth-worm-turret'] = 7
}
},
}

return storage.config
3 changes: 3 additions & 0 deletions control.lua
Original file line number Diff line number Diff line change
Expand Up @@ -176,6 +176,9 @@ end
if config.player_shortcuts.enabled then
require 'features.gui.shortcuts'
end
if config.experience.enabled then
require 'features.gui.experience'
end
if config.score.enabled then
require 'features.gui.score'
end
Expand Down
Loading
Loading