-
Notifications
You must be signed in to change notification settings - Fork 4.2k
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
Prevent gaining non-intelligence stats from reading with Stats Through Skills #39387
Prevent gaining non-intelligence stats from reading with Stats Through Skills #39387
Conversation
c165945
to
0642bf7
Compare
0642bf7
to
990c854
Compare
So, 2 situations:
Does it mean, that if I read I'm never getting the STR I could've gotten without reading? |
Yes. |
|
Because you're reading, you're not doing anything that would actually make you stronger. |
I understand the point you're trying to make about reading, but I'm specifically talking about the same amount of practice with and without reading
Situation 3 should actually take less practicing, because you now know the theory
Why should practicing after the cataclysm matter more than practicing before the cataclysm? |
I'm sorry, I don't understand what you're trying to say about those scenarios. What I'm demonstrating in that particular case is is that the practice ratio is set to |
Sorry, I might have chosen my words poorly Just trying to understand the reasoning and logic behind this system:
For me, it seems logical that taking a skill during a character gen should actually give higher practice ratio (
Yes, I agree with that proposal, but practice should not be a ratio. Let's take your example: |
I'd actually be more tempted to give it a lower ratio, with the justification that the stat gains from that skill are incorporated into the stats taken at chargen. Practice isn't really a ratio, I'm just storing it in a ratio because experience is wiped out on each level up. When multiplied by skill or an amount of experience, it gives how much of that skill, or how much experience has been gained through practicing. Okay, I see what you mean. I'll look into how to resolve that. |
Alternatively you could also play with stats through kills. Should the two mods be merged? |
No. |
I have no interest in merging my mod (StK) with stats through skills, nor do i think it is a balanced and good idea. |
990c854
to
8defbf0
Compare
Okay: Updated it! Now, Stats Through Skills cares about the experience of each type, not the levels. This way, training your skills through reading, while it will still not give you as many stat boosts as doing it through practice, will not mean you are locked out of gaining stat boost by practicing after this. Stat boosts are completely divorced from level ups, and can occur any time you have the appropriate amount of experience in the relevant skills. These changes mean it is more useful to have higher levels in fewer skills than lower levels in more skills, because those level levels carry less experience than the higher ones. |
928b532
to
62a4a94
Compare
407a35f
to
823983b
Compare
This pull request fixes 1 alert when merging 823983b into 32e6aab - view on LGTM.com fixed alerts:
|
c8ae293
to
2d0aa17
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I need to think about this, the main issue I have is that this is pretty invasive to the skill class, which is not justified for a peripheral feature like STS.
OTOH, this might feed into the way skills will work in the future.
2d0aa17
to
91c4ace
Compare
91c4ace
to
b14e2b1
Compare
b14e2b1
to
ef2bf4a
Compare
ef2bf4a
to
b211551
Compare
6ccf4b8
to
3ef2e1c
Compare
ed093c0
to
d7236d9
Compare
This allows differentiating between skills learned from reading books, and skills learned from practicing them. This is important for things such as Stats Through Skills, where you should be able to gain stats from doing activities, but not by sitting in a basement and reading. This will cause some differences in how skill is lost due to skill rust, but skill rust is generally unused, so I figured it was not worth the time to make it perfect. This also changes how savegames are loaded, and as such the savegame version has been bumped. Skills taken in character generation are treated as 50% practice and 50% knowledge. There's no strong reason for this ratio, it's just what worked.
For all the skills but intelligence, it doesn't make much sense to learn skills by reading. It probably doesn't make some sense for a bit of the intelligence skills, but someone else can easily change that in the future. Because stat bonuses are now based on skill experience, as opposed to number of skills, Stats Through Skills now emphasizes fewer, higher skills, as opposed to more, lower skills. The new formula: cbrt( 0.9 * experience - 0.5 ) Roughly matches the old formula sqrt( skills - 3 ) ^ 0.4 in the amount of experience required to get each stat bonus. It does, however gain slightly faster than the old one. Because I basically reinvented Stats Through Skills, I put my name in authors.
d7236d9
to
db33ce6
Compare
Talked a bit with Kevin, this is indeed too invasive. If I can think of something less invasive, I may come back to this in future. |
it is quite disappointing that this PR is closed. I expected pretty much on this. |
Summary
SUMMARY: Mods "Stats Through Skills: Prevent raising strength, dexterity, or perception through reading"
Purpose of change
For all the skills but intelligence, it doesn't make much sense to learn skills by reading. It probably doesn't make some sense for a bit of the intelligence skills, but someone else can perform the analysis for that.
Describe the solution
Split
SkillLevel::_exercise
into two variables -_practice
, and_knowledge
.Create enum
skill_exercise_type
, which tellsSkillLevel::train
whether to train_practice
or_knowledge
.Plumb the
skill_exercise_type
through all instances ofplayer::practice
andSkillLevel::train
Training from NPCs and reading books gives
KNOWLEDGE
, all other training givesPRACTICE
.Adjust skill rust to subtract equally from each of these experience pools.
Add
practice_ratio
toSkillLevel
This tracks the ratio of practice experience to knowledge experience that was used to learn this skill.
On level up, determine this with the formula
Adjust savegame loading code to load the previous
experience
value intopractice
experience.Similarly, if there is no
practice_ratio
, set it to1.0f
.Along with these changes, bump the savegame version.
Adjust
skill_boost
to contain skills that will give stats through practice and skills that will give stats through knowledge separately.When calculating skill boost, use the experience of each type where appropriate, over 1000.
Add
skill_boost::_coefficient
andskill_boost::_max_stat
, and use them in the calculation to cap and multiply the experience.Change the calculation for stats through skills from
to
This roughly tracks the previous min/average experience to gain each stat level, but is a little accelerated.
The stat cap is set to 5, tracking with the previous effective stat cap.
Stats through skills now emphasizes higher levels, as opposed to more levels, because stat gains are based off of experience, not number of skills.
Add
character::set_skill_practice_ratio
andSkillLevel::set_practice_ratio
, to set the practice ratio for skills.Using this, when taking skills in character creation, give then a practice ratio of 50%.
I'm not tied to this number, it's just the arbitrary one I chose.
Testing
BEFORE applying this change, create a world with stats through skills, and a default character, and go out and forage in the woods a bit, until you have some experience in the survival skill.
Remember the amount of experience you have in survival.
Load the save with this applied, and your experience in survival will be the same.
Set skill learning rate to
100
in the options before performing the next steps:Spawn in the books
Under the Hood
andMechanical Mastery
, and read them until your mechanics is level 6. Your strength stat will not increase.Spawn in the books that come up when you search
first
in the debug menu, and read them until your first aid is level 6. Your intelligence will increase.Create a new default character in the same world.
Spawn in appropriate tools, use the debug menu to level your mechanics to 1, and then repair or otherwise interact with vehicles until your mechanics is 6. Your strength stat will increase.
Spawn in several bandages, and bandage your character till your first aid skill is 6. Your intelligence will increase.
Create a new character in the same world, but this time take 10 levels of swimming.
You will get a strength boost of 2.
Create a new default character in this world, and swim until your swimming is level 10.
You will have a strength boost of 3.