Commit Graph

79 Commits

Author SHA1 Message Date
metalgearsloth
8ab0e59db6 Refactor disarms (#36546)
* Refactor disarms

- Move client stuff to shared
- Cleanup a bunch of stuff
- Ref events
- Fix the swing sound mispredict (I noticed it on target dummies).

* Revert this change

* minor review

* Rebiew

---------

Co-authored-by: Milon <milonpl.git@proton.me>
2025-04-19 11:38:22 +10:00
metalgearsloth
0ff70fdb40 Implement field-deltas for melee (#33977)
* Implement field-deltas for melee

* Review
2025-03-30 16:02:45 +11:00
SlamBamActionman
3200ba88a5 Add ability for +VVEDIT users to scale damage/healing in the game (#35255)
* Initial commit

* Add universal modifier for all damage/heals, make guidebooks work.

* help text
2025-02-18 08:28:42 +01:00
SlamBamActionman
f25720124a Fix hitting through directional windows (and more!) (#34793) 2025-02-02 23:03:31 +01:00
Calecute
b7bd7c1d68 Blunt damage will do stamina damage on wide attacks (#32422)
Fix: blunt damage will now do stamina damage on wide attacks.
2024-10-20 14:41:44 +11:00
Джексон Миссиссиппи
9b71757c07 cleanup melee (#32486)
* it removes warns ig

* Quick fix

---------

Co-authored-by: metalgearsloth <comedian_vs_clown@hotmail.com>
2024-10-14 16:40:59 +11:00
Scribbles0
220aff21eb Melee Executions (#30104)
* melee executions

* fix damage bug

* cleanup

* address reviews hopefully

* resistance bypass mechanic

* component changes

* self executions (not finished yet)

* self execs part two

* ok i fixed things (still not finished)

* finish everything

* review stuff

* nuke if (kind = special)

* more review stuffs

* Make suicide system much less hardcoded and make much more use of events

* Fix a dumb bug I introduced

* self execution popups

* Integration tests

* Why did they even take 0.5 blunt damage?

* More consistent integration tests

* Destructive equals true

* Allow it to dirty-dispose

* IS THIS WHAT YOU WANT?

* FRESH AND CLEAN

* modifier to multiplier

* don't jinx the integration tests

* no file-scoped namespace

* Move the rest of execution to shared, create SuicideGhostEvent

* handled

* Get rid of unused code and add a comment

* ghost before suicide

* stop cat suicides

* popup fix + small suicide change

* make it a bit better

---------

Co-authored-by: Plykiya <58439124+Plykiya@users.noreply.github.com>
2024-08-11 13:05:54 +10:00
DrSmugleaf
84a9253b10 Fix falsely showing damage color effect to entities that aren't allowed to be attacked (#30661) 2024-08-05 13:14:01 +10:00
themias
648f94f4bb Fix fingerprint transfer on weapon attack (#30257)
* Fix fingerprint transfer on weapon attack

* Switch to just not raising the event

* one more
2024-07-30 18:35:30 +10:00
ShadowCommander
4d4f67132c Allow attack while pulling (#29703)
* Make VirtualItem not block attacking

* Remove unneeded usings
2024-07-11 14:48:00 +10:00
eoineoineoin
b44b159431 Replace Matrix3 with System.Numerics.Matrix3x2 (#27443)
Replace Matrix3 with Matrix3x2
2024-06-02 14:07:41 +10:00
Leon Friedrich
54337911d3 Only auto-enable internals when necessary (#28248)
* Only auto-enable internals when necessary

* Add toxic gas check

* Rename Any -> AnyPositive
2024-05-31 12:28:11 +10:00
Leon Friedrich
d0cf620a85 Fix weapon error logs (#28264) 2024-05-25 13:13:24 +10:00
Leon Friedrich
0f6e1196d8 Use non-generic TryComp() for metadata & transform (#28133) 2024-05-20 22:40:35 -07:00
beck-thompson
afcdc8b866 Fixed gloved weapons being able to attack when not equipped. (#26762)
* Initial commit. No evil hidden files this time :)

* Added newline because I forgot :(

* We <3 tags :)

* Fixed! Works now

* Update Content.Shared/Weapons/Melee/MeleeWeaponComponent.cs

---------

Co-authored-by: metalgearsloth <31366439+metalgearsloth@users.noreply.github.com>
2024-04-17 20:10:03 +10:00
Bixkitts
ae8a68b7cd MeleeHitSoundSystem (#25005)
* Began work to unscrew melee noises

* finished

* cleanup

* cleanup

* Update Content.Server/Weapons/Melee/MeleeWeaponSystem.cs

Co-authored-by: Ed <96445749+TheShuEd@users.noreply.github.com>

* _Style

* Fix merge

---------

Co-authored-by: Ed <96445749+TheShuEd@users.noreply.github.com>
Co-authored-by: metalgearsloth <comedian_vs_clown@hotmail.com>
2024-03-31 16:21:01 +11:00
Pieter-Jan Briers
e00f74505c Use new ComponentPauseGenerator (#25183)
Also includes some (non critical) changes to the solution file to re-organize the Roslyn components.
2024-02-26 14:36:19 +11:00
Bixkitts
b98dc66974 MeleeSoundComponent Working With 0 Damage (#24872)
* made hit sound logic potentially better

* Function already tries all fallbacks, no reason to return bool

* NoDamageSound execution path
2024-02-03 12:00:14 +11:00
LordCarve
c77eb8691d DamageSpecifier Total => GetTotal (#24160)
* DamageSpecifier [Obsolete] Total => GetTotal()

* Remove obsolete Total member from DamageSpecifier.
2024-01-21 18:59:14 -07:00
Kara
818b07ecf8 Destruction & impact sound rework pass 1 (#24282)
* Various sounds ported

* Replace wall_bonk.ogg

* Metal/metalglass break sound pass

* Replace metalbreak.ogg

* Replace woodhit

* Replcae tap.ogg n some smack uses

* Fix lint

* Replace bang.ogg and some instances of hit_kick.ogg

* couple more

* fix wood sound

* i may be stupid

* le attributing

* bro what

* standardize more destruction sounds

* fix melee hit sound cutting off

* window threshold sounds and remove `destroySound` it literally doesnt exist
2024-01-19 10:33:07 -05:00
Veritius
2e83f5a0ec Executions (#24150)
* Execution (you monster)
not done

* woops

* more stuff

* Melee executions

* Prevent executing those who can interact

* Better checks for if you can execute

* Scale the execution time of a knife with its attack speed

* Translations for fucking up an execution

* rename some functions

* Properly scale execution speed of melee weapons

* Fix checks in CanExecuteWithAny

* Allow executing yourself (funny)

* More versatile localisation

* Suicide with guns

* Popups for successful gun executions

* whoops

* Stop flare guns crashing the game on executions

* Various tweaks

* Remove some old usings

* Pacifists can no longer execute

* Remove unnecessary check

* Use CanShoot in gunsystem

* Capitalisation in ftl string

* Fix melee executions not playing a sound

* localisation tweaks
2024-01-17 01:45:45 -07:00
metalgearsloth
2166958bd0 AutoCompState + ItemToggle fixes (#23422)
* AutoCompState + ItemToggle fixes

Fix a lot of the comp states that are never actually networked and also cleaned up ItemToggle events a bunch. ItemToggle will still need some future work for lights and sounds.

* Also catch these
2024-01-03 17:24:02 +11:00
Nemanja
9bd03824ac GORILLA Gauntlets (#23012)
* GORILLA gauntlets

* oh shit this too
2023-12-27 20:11:13 -07:00
Kara
faca1d7043 Pacifism rework (#23037)
* Pacifism rework

* grammar
2023-12-27 02:55:48 -07:00
Darkie
a3fbab84e6 ItemToggle system expansion (#22369)
* Fixed EnergySword and variants having incorrect sound on attacking when in their Off state.

* Removed the unused ItemToggle from the serverside and created a new shared ItemToggleComponent and System, now used for the e-blade family of items. Also added e-blade hum and swing sounds. Thanks Sloth for the initial code!

* Changing Stunbaton system to include the itemToggle system.

* Adapted changes that have come up in the meantime.

* Changed damagespecifier to be serializable and autoNetworked in melee weapon components. Fixes a bug that makes it so client-side, damage values are not updated on toggle.

* Made the ItemToggleSystem have both a shared and a server component. Ported the Stun Baton and Stun Prod to the new toggleable system. Added a failure to activate noise component.

* Ported the welders to the new item toggle system. Set it so deactivated damage and item size default to the item's regular options.

* Removed unnecessary usings.

* Small modification to the stun prod.

* Made the integration test use the new method to turn the welders on.

* Fixed a few testing issues, applied a few changes requested by Delta.

* Updated Stunbaton code for consistentcy when it comes to calling the itemToggle component.

* Removed a redundant return; as per Delta.
Made examining the stun baton for charge rely on the battery component instead.

* Removed the welder visualizer system, now using the generic one. Removed some unused usings. Removed the welder visuals and layers.
Ported lighters to the new system.
Added zippi (sic) lighters.

* Renamed variables used to make them less generic.

* Simplified the light update code.

* Fixed the unit test to use the itemToggle system for welders now.

* Made the name shorter. I can't tell if the welding damage when interacted with actually does anything though. I can't figure out how to trigger it.

* Fixed some YML issues.

* Added a client side item toggle system just to make the shared code run on local UID's too.

* Fixed some more Yaml.

* Made the Zippi lighter have its own parent item, so it doesnt' conflict with the random pattern on the regular lighter.

* Made the zippi lighter its own in-hand sprites.

* Added a summary for the activated property in itemtoggle component.

* Fixed a typo in the itemToggle Component.

* Fixed a typo.

* Added to the remarks for the ItemToggleComponent.

* Fixed up the lighter yaml to make it use a generic term instead of a toggle layer enum for the random skin.

* Fixed a bug I introduced accidentally with the humming sound.

* Removed 2 unnecessary events from the ItemToggleSystem and component.

* Fixed a bug by only making the server run the item activation code, since the client cannot predict whether or not the activation will be cancelled.

* Cleaned up some names and functions getting called.

* Renamed a couple of variables and removed the explicit datafields from the component. Removed "activated: false" from yml since they're already deactivated by default.

* Added an IsActivated function, used it in the welder and stun baton systems code.
Refactored welder code to remove the WelderToggle event, now using the ItemToggleActivatedEvent instead for eye protection check.

* Fixed a typo. Added some comments.

* Split the ItemToggle into smaller components.
Changed the items that used the toggle system to work with the smaller components.
Made the mirror shield reflect energy shots with a 95% chance.

* Fixed the namespaces for the server components and whatnot.

* Fixed a doubled deactivation sound from using activated wieldable items (like the double Esword).
Fixed wrong yml with the e-dagger.
Fixed the disarm malus code.

* Added the zippo lighter to the detective's trench coat.

* Removed the default hit sound for the double e-sword since it was unnecessary.

* Changed e-sword damage numbers to be in line with the changes made by Emisse.

* Made no damage sounds be autoNetworked, so it changes can be changed on activation/deactivation of items.
Made Welders and Eswords sound like themselves but quieter if they hit for 0 damage, instead of taps.
You can choose what sound to play when a weapon does 0 damage when activated now.
Fixed a bug with swing sounds.

* Typo.

* Fixed a bug where the welder would blind you if you used it while it was off.

* Created a single abstract method called when an item has completed its toggle.

* Update Content.Server/Eye/Blinding/EyeProtection/EyeProtectionSystem.cs

Co-authored-by: metalgearsloth <31366439+metalgearsloth@users.noreply.github.com>

* Fixed a comment.

* Made most component variables readOnly for ItemToggle. There is no need to be able to change them from within the variable viewer.

* Removed trailing white spaces.

* Made the Use a field instead of a property in the itemToggleActivation/Deactivation attempt events.

* Small fixes.

* Removed ForceToggle, just use the toggle method instead.

* Fixed a bug with item sharpness staying even after getting deactivated, if the item gained sharpness that way (esword).

* Used ProtoId in the welder component.

* Made damage NetSerializable as well.

* Added networking and data fields to a couple of components.

* Made component variables autonetworked. Added some comments.

* Moved the events that modify item components on toggle to events, handled (where possible) in the systems linked to said components.

* Made all the component variables readWrite again.

* Added the component get to the WelderStatus.

* Added a predictable bool to the item toggle component.

* Replaced the Activated/Deactivated events with ToggleDone, with an Activated argument. Used that to simplify some systems.

* Added a reflect update raise event.

* Removed the Zippo changes. To add in a later PR.

* Removed the zippo from meta.json too.

* Small fix.

* Another small fix.

* Fixed the wieldable system thing in ItemToggle.

---------

Co-authored-by: metalgearsloth <31366439+metalgearsloth@users.noreply.github.com>
2023-12-24 17:11:05 +11:00
metalgearsloth
269c93245d Unrevert audio (#21330)
Co-authored-by: Pieter-Jan Briers <pieterjan.briers@gmail.com>
2023-11-27 22:12:34 +11:00
metalgearsloth
5b8f3c48c4 Revert "Update submodule to 175.0.0 (#21318)" (#21319) 2023-10-29 15:29:30 +11:00
metalgearsloth
9b1b3e03ed Content audio (#20862) 2023-10-29 14:58:23 +11:00
Leon Friedrich
e685cb626b Un-revert IPlayerManager refactor (#21244) 2023-10-28 09:59:53 +11:00
metalgearsloth
a2bbda43cc Revert "Update submodule to 172.0.0 (#21222)" (#21225) 2023-10-24 21:55:20 +11:00
Leon Friedrich
7ba0ea2926 IPlayerManager refactor (#21215) 2023-10-24 20:19:08 +11:00
I.K
df81532469 Change wide swing sprites to be that of the weapon used (#21050)
Co-authored-by: notquitehadouken <1isthisameme>
2023-10-18 12:12:00 +11:00
deltanedas
6db534ef86 uncloak ninja after attacking (#20892)
* raise MeleeAttackEvent on the user after swinging

* add disable bool to RevealNinja

* uncloak ninja after attacking

---------

Co-authored-by: deltanedas <@deltanedas:kde.org>
2023-10-10 22:55:53 -04:00
Leon Friedrich
364c9b7f0a DamageableSystem cleanup & performance improvements (#20820) 2023-10-09 03:27:41 +11:00
DrSmugleaf
a44fa86b68 Update trivial components to use auto comp states (#20539) 2023-09-28 16:20:29 -07:00
metalgearsloth
5a0fc68be2 Content update for NetEntities (#18935) 2023-09-11 09:42:41 +10:00
metalgearsloth
b25862365e Revert click damage mod (#19860)
Maybe swings should be default and we make the animation not shit and the prediction slightly better.
2023-09-06 03:30:23 -05:00
metalgearsloth
0f917d22d7 Color flash effect fixes (#18952) 2023-08-10 10:44:52 -07:00
Errant
eb8c7dcc6c Melee rebalancing rebalancing, high damage single-target attacks (#18766) 2023-08-07 02:01:44 +10:00
metalgearsloth
aa8efc9a26 Melee rebalancing (#17520) 2023-08-06 12:55:38 +10:00
Chief-Engineer
cca2f52a30 add melee miss logs (#18671) 2023-08-05 12:17:13 +10:00
metalgearsloth
68480af109 Update content vectors to numerics (#17759) 2023-07-08 14:08:32 +10:00
metalgearsloth
ee2a3216d6 Self-attack nerfs (#17845) 2023-07-07 18:45:37 +10:00
metalgearsloth
876beb9369 Stop NPC smashing if it fails (#17847) 2023-07-06 14:42:17 +10:00
metalgearsloth
90110183be Fix a bunch of logger warnings (#17691) 2023-06-27 23:56:52 +10:00
Justin Trotter
12a44bf4e0 uranium spears make damage sounds (#17575) 2023-06-23 22:23:08 +10:00
deltanedas
25763e4ace add an event to prevent gun shooting (#17104)
Co-authored-by: deltanedas <@deltanedas:kde.org>
2023-06-08 12:15:39 +10:00
Nemanja
37d3056809 Events all over melee (#16997) 2023-06-07 13:26:45 -07:00
Nemanja
dd044f4a91 Make melee damage not go through MeleeHitEvent.cs (#16881)
Co-authored-by: metalgearsloth <31366439+metalgearsloth@users.noreply.github.com>
2023-05-28 17:03:25 +10:00
metalgearsloth
6417bb4fa0 Proto-kinetic crusher (#16277)
Co-authored-by: AJCM-git <60196617+AJCM-git@users.noreply.github.com>
2023-05-14 13:15:18 +10:00