[TF2] Allow weapons with penetrating bullets to penetrate Medigun shield #1539
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
This change makes it so that weapons with penetrating bullets can go through the Medigun shield depending on the penetration and shield levels. This gives much more control for custom MvM mission creators over the usage of shield and penetrating heavy robots and the corresponding upgrades on the defenders.
There are two different kinds of penetration:
projectile penetration heavy
will count shield just like players but take into account the shield level (generate rage on heal
) and subtract that from the penetration limit.projectile penetration
andsniper penetrate players when charged
will penetrate the shield up to level 3 without any side effects but get blocked by shield level 4 and higher. The limit is chosen because max upgradedprojectile penetration heavy
will also be stopped by level 4.Currently no official mission uses shield Medics nor Heavies with penetration upgrade so this will have no effect on them.