-
Notifications
You must be signed in to change notification settings - Fork 4.7k
Remove dependency of DoorComponent from PryingSystem, add PryableComponent #37689
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
base: master
Are you sure you want to change the base?
Conversation
…e, not just a locstring. Take the random default BaseTime out of the GetPryTimeModifierEvent, this default was never used. BaseTime is set at construction of the event from PryableComponent instead of an event on PryableComponent. Use `Entity<T>` for OnDoorAltVerb, OnDoAfter Use `Resolve` on nullable component arguments in public functions. Use `Entity<T>` pattern in private functions Add some comments and change some variable names in `PryingSystem for clarity.`
fix high sec door not being pryable fix blast door being pryable
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.
every day ToolSystem creeps closer to death
|
Drafting this a moment -- checking something |
|
@EmoGarbage404 I'm so sorry.... but I added in tons of changes to remove It all ties into how things get pried... so....... |
|
this is the final extent of the scope creep I promise |
|
Do tests count as scope creep? I added ~30 tests using a generic prying test function. |
|
This pull request has conflicts, please resolve those before we can evaluate the pull request. |
123aff3 to
7e144e8
Compare
|
@EmoGarbage404 I've un-scope creeped this, I'll add the work to the bolt system in another PR. |
|
actually nevermind I'm not labelling this as part of the turnstile improvements :| |
…pen, pry closed, powered, unpowered, welded, unwelded, hand pry, crowbar, jaws of life.
|
This pull request has conflicts, please resolve those before we can evaluate the pull request. |
About the PR
I want turnstiles to exhibit unique behavior on prying with a tool, and instead of bringing
TurnstileComponentintoPryingSystem, I saw the light yesterday and am doing the reverse.I remove common prying datafields from
DoorComponentand bring them into a new componentPryableComponent. TheCanPrydatafield is removed and replaced by the existence ofPryableComponenton an entity.All of the
PryingSystemevents are largely unchanged:All the weird pry tool flags are now just
PryStrength. I can't imagine a tool that can pry a bolted door but not a powered door, so it's just a scale.The prying door tests have been generalized and every combination is tested.
Why / Balance
Clean up, refactor, allow cleaner integration of planned features in #37350.
Technical details
See
Aboutsection, not much more complicated than that.Basically just lets me slap
PryableComponenton something like turnstiles and add in unique checks for if it can be pried and unique time modifiers without having to duplicate checks forDoorComponentwithTurnstileComponentMedia
none
Requirements
Breaking changes
The following properties have been remove from
DoorComponent:PryableComponenthas been added withPryingQualityandPryTime.CanPryhas been "replaced" with the existence ofPryableComponenton an entity.Prototypes with
CanPry: Falseshould have that datafield removed.PryableComponenthas been added to:Abstract prototype
BaseShutterPryableis parented fromBaseShutter, all shutters are parented toBaseShutterPryableexceptBlastDoorwhich shouldn't be pryable.Handlers of
BeforePryEventshould put a fully localized message in theMessagefield instead of just theloc-stringas before.GetPryTimeModifierEventrequires the base pry time as an argument. Normally this will be thePryTimefield of thePryableComponentPryingComponentno longer has:PryingComponentnow has:enum PryStrengthStrengthWhich can take on the values:
WeakStrongPoweredForcePrototypes with
PryingComponenthave been changed appropriately.