Commit Graph

51 Commits

Author SHA1 Message Date
Hannah Giovanna Dawson
cdbe92d37d Update DamageableSystem to modern standards (#39417)
* Update DamageableSystem to modern standards

* DamageContainerId -> DamageContainerID with lint flag

* Replace strings with protoids

* Make CVar subscription declarations all consistently whitespaced

* ChangeDamage -> TryChangeDamage, cope with C# jank

* Revert event signature changes

* Restore a comment

* Re-add two queries

* Init the queries

* Use appearanceQuery in DamageChanged

* Use damageableQuery in TryChangeDamage

* Use damageableQuery in SetDamageModifierSetId

* Final cleanup, fix sandboxing

* Rectify ExplosionSystem:::ProcessEntity's call to TryChangeDamage

* Re-organize DamageableSystem

* first big fuck you breaking change.

* THATS A LOT OF DAMAGE!!!

* Fix test fails

* test fixes 2

* push it

---------

Co-authored-by: Princess Cheeseballs <66055347+Pronana@users.noreply.github.com>
2025-10-27 19:53:04 +00:00
Princess Cheeseballs
c7f5545a46 Vulpkanin Admin Smite (#40360)
* Cheeborger

* Vulp smite

* validate those ProtoIds

---------

Co-authored-by: Princess Cheeseballs <66055347+Pronana@users.noreply.github.com>
2025-09-21 23:22:25 -07:00
Pieter-Jan Briers
0c97520276 Fix usages of TryIndex() (#39124)
* Fix usages of TryIndex()

Most usages of TryIndex() were using it incorrectly. Checking whether prototype IDs specified in prototypes actually existed before using them. This is not appropriate as it's just hiding bugs that should be getting caught by the YAML linter and other tools. (#39115)

This then resulted in TryIndex() getting modified to log errors (94f98073b0), which is incorrect as it causes false-positive errors in proper uses of the API: external data validation. (#39098)

This commit goes through and checks every call site of TryIndex() to see whether they were correct. Most call sites were replaced with the new Resolve(), which is suitable for these "defensive programming" use cases.

Fixes #39115

Breaking change: while doing this I noticed IdCardComponent and related systems were erroneously using ProtoId<AccessLevelPrototype> for job prototypes. This has been corrected.

* fix tests

---------

Co-authored-by: slarticodefast <161409025+slarticodefast@users.noreply.github.com>
2025-09-09 18:17:56 +02:00
Princess Cheeseballs
3ea9321d25 [Hotfix] Wizard Rod doesn't gib the wizard. (#40041)
* Title

* Tired

* That shit did nothing goddamn

* Fix for real

* Use og code

* Hmmm borgaer

---------

Co-authored-by: Princess Cheeseballs <66055347+Pronana@users.noreply.github.com>
2025-09-06 02:19:20 -07:00
Princess Cheeseballs
91a4cee6e1 [Bugfix] Lizard smite fix (#39842)
Fix

Co-authored-by: Princess Cheeseballs <66055347+Pronana@users.noreply.github.com>
2025-08-24 09:34:56 -04:00
Tayrtahn
95b0df9a89 Fix nuke disk getting lost when polymorphed holder is deleted (#36058)
* Delete original entity when polymorph is deleted

* Switch to EntityTerminatingEvent

* Add RevertOnDelete option to PolymorphPrototype

* Fix error on server shutdown while polymorphed

* Set RevertOnDelete to false by default

* AsNullable

* Revert "Set RevertOnDelete to false by default"

This reverts commit 087c43fbb923c9369c61c9d001e18814b3de3aca.

* Use pattern matching instead of .Value
2025-08-20 00:02:41 -07:00
Princess Cheeseballs
91854e0776 Debody Food and Drink Systems, Combine Food and Drink into One System. (#39031)
* Shelve

* 22 file diff

* What if it was just better

* Hold that thought

* Near final Commit, then YAML hell

* 95% done with cs

* Working Commit

* Final Commit (Before reviews tear it apart and kill me)

* Add a really stupid comment.

* KILL

* EXPLODE TEST FAILS WITH MY MIND

* I hate it here

* TACTICAL NUCLEAR STRIKE

* Wait what the fuck was I doing?

* Comments

* Me when I'm stupid

* Food doesn't need solutions

* API improvements with some API weirdness

* Move non-API out of API

* Better comment

* Fixes and spelling mistakes

* Final fixes

* Final fixes for real...

* Kill food and drink localization files because I hate them.

* Water droplet fix

* Utensil fixes

* Fix verb priority (It should've been 2)

* A few minor localization fixes

* merge conflict and stuff

* MERGE CONFLICT NUCLEAR WAR!!!

* Cleanup

---------

Co-authored-by: Princess Cheeseballs <66055347+Pronana@users.noreply.github.com>
2025-08-06 12:53:38 -04:00
Perry Fraser
2a4f36422b fix: properly respect AllowRepeatedMorphs (#39411)
* fix: properly respect AllowRepeatedMorphs

* feat: add IgnoreAllowRepeatedMorphs
2025-08-06 02:02:52 +02:00
slarticodefast
2c40a950f7 Trigger Refactor (#39034) 2025-08-03 21:20:37 +02:00
Kyle Tyo
83b3e9e15a Localize makesentient command. Move makesentient method to mind system. (#38565)
* praying pjb doesn't smite me for this 🙏

* requested changes

* Update makesentient-command.ftl

* verin commith and verin taketh away
2025-07-23 14:29:46 +02:00
Kyle Tyo
546bfd0a30 MapManager warnings cleanup Server Edition 2003 (#36781)
* now you see me

* unused depen

* test fail fix attempt 1

* test fail fix attempt 2

* fix test fail attempt 3

* shot in the dark.

* Does this work?

* import cleanup

* taking a shot at this.

* Convert PersistenceSaveCommand to LocalizedEntityCommands.

* requested changes

* requested changes. also dealt with improperly named private const

* Update Content.Server/GameTicking/GameTicker.Spawning.cs

Co-authored-by: slarticodefast <161409025+slarticodefast@users.noreply.github.com>

* Update Content.Server/GameTicking/GameTicker.Spawning.cs

Co-authored-by: slarticodefast <161409025+slarticodefast@users.noreply.github.com>

* Convert PlanetCommand to LocalizedEntityCommand

* Update BiomeSystem.cs

* Update Content.Server/Salvage/SalvageSystem.Runner.cs

Co-authored-by: slarticodefast <161409025+slarticodefast@users.noreply.github.com>

* Update Content.Server/Procedural/DungeonSystem.Rooms.cs

Co-authored-by: slarticodefast <161409025+slarticodefast@users.noreply.github.com>

* Update Content.Server/Salvage/SpawnSalvageMissionJob.cs

Co-authored-by: slarticodefast <161409025+slarticodefast@users.noreply.github.com>

* Update Content.Server/Station/Systems/StationBiomeSystem.cs

Co-authored-by: slarticodefast <161409025+slarticodefast@users.noreply.github.com>

* revert to latest master.

* slartis suggestion.

* Update SetMapAtmosCommand.cs

* cleanup

* Update PersistenceSaveCommand.cs

* finish localizing persistencesavecommand

* this is icky, I change.

* :sigh:

* revert whatever I did here?

* oh I see, some inconsistencies.

* revert this

* Update PlanetCommand.cs

* move this ftl to the commands folder

---------

Co-authored-by: slarticodefast <161409025+slarticodefast@users.noreply.github.com>
2025-06-09 02:09:42 +02:00
deltanedas
b3825dce97 action refactor proper ecs edition (#27422) 2025-05-28 15:52:11 -04:00
metalgearsloth
0d4f9640b5 CompFactory updates (#37559) 2025-05-20 01:08:55 -04:00
B_Kirill
b3c4c7c32b Cleanup warnings: CS8321, CS0105, CS0168 (#36949)
* Clean up

* CS0168
2025-05-07 20:01:02 -04:00
beck-thompson
186cef25ca Put items inside cakes! (#31015)
* First commit

* I'm silly

* Please be it

* Some more fixes

* Cleanup

* fine!

* removed = false

* review

---------

Co-authored-by: Milon <milonpl.git@proton.me>
2025-04-24 05:00:50 +02:00
Tayrtahn
02814e1e8d Cleanup warnings in PolymorphSystem.Map (#36869)
Fix warnings in PolymorphSystem.Map
2025-04-24 00:25:13 +02:00
Flareguy
92b0f62500 New Experimental Science T3: Desynchronizer (#35752)
* desynchronizer real

* yaml stuff from slarti branch

* C# stuff

* oops

* review

* improve

---------

Co-authored-by: slarticodefast <161409025+slarticodefast@users.noreply.github.com>
2025-04-16 11:33:39 +10:00
slarticodefast
d8ac1524ef polymorph popup fixes (#35796)
polymorph fixes
2025-03-12 19:48:45 +01:00
slarticodefast
175f5e6c2f TriggerSystem improvements (#35762)
* desynchronizer real

* yaml stuff from slarti branch

* C# stuff

* oops

* fix triggers

* atomize PR

---------

Co-authored-by: Flareguy <woaj9999@outlook.com>
2025-03-11 22:31:33 -07:00
Tayrtahn
46b19291ea Fix followers getting sent to nullspace when target is polymorphed (#33878)
* Add an event for polymorph actions

* Subscribe FollowerSystem to the event

* Add check that unfollow target is actually current target.

* Make followers try to follow on state update; Dirty follower on follow.
2025-02-11 22:34:24 +01:00
Baa
1f42413416 Fix udder wooly reagent creation V2 (#32905)
* Changed comments to be more clear and uniform.
EggLayer uses NextGrowth instead of frame accumulation.
Egglayer uses much less energy to make eggs, and lay time is randomized for player and AI chicken.

* UdderComponent ReagentId can be changed now
UdderSystem and WoolySystem use SharedSolutionContainerSystem now

* Entities with udders can be examined to see a rough hunger level
udders and wooly stop reagent generation/extra nutrient usage once the solution container is full

* Moved stuff to Shared
AutoPausedField now

* Cleanup moving stuff to Shared

* Oops. Make UdderSystem sealed instead of abstract.

* Switch PopupEntity for PopupClient

* Didn't mean to delete Access

* new() instead of default! prototype
revert egglayer balance change
NextGrowth += timespan   in egglayer

* forgot [Datafield] for NextGrowth

* forgot NetworkedComponent again...

* Renaming Shared Animal to Shared Animals to match Server
Hopefully also resolve merge conflicts.

* Fix incorrect filename

* Update with requested changes
Put UdderSystem dependencies in alphabetical order.
Initialise NextGrowth for Udder and Wooly components on MapInitEvent.
Clean-up EggLayerSystem a little.
Re-write OnExamine function for UdderSystem, improving clarity.
Add full stops to end of udder examine locales.
And more :)

* Add some additional descriptions for cow hunger levels.

* Add Udder and Wooly quantity to AutoNetworkedField

* Account for less than starving threshold.

---------

Co-authored-by: sirionaut <sirionaut@gmail.com>
Co-authored-by: Sirionaut <148076704+Sirionaut@users.noreply.github.com>
Co-authored-by: Tayrtahn <tayrtahn@gmail.com>
2024-12-16 13:53:21 +01:00
keronshb
fa3a04a527 Ethereal Jaunt Spell for Wizard & Jaunt ECS (#33201)
* Act

* Adds Jaunt ECS and related prototypes

* Adds jaunt sounds

* Adds enter and exit sound support to polymorphs

* Updates jaunt description

* Adds jaunt action sprite and changes jaunt polymorph to use it

* Adds Jaunt and upgrade to the wizard grimoire

* Makes base mob jaunt parent off of incorporeal and basemob, adds blue ghost sprite for ethereal jaunt

* Update Resources/Locale/en-US/store/spellbook-catalog.ftl

Co-authored-by: slarticodefast <161409025+slarticodefast@users.noreply.github.com>

* Update Resources/Prototypes/Entities/Mobs/Player/jaunt_mobs.yml

Co-authored-by: slarticodefast <161409025+slarticodefast@users.noreply.github.com>

* Update Resources/Prototypes/Entities/Mobs/Player/jaunt_mobs.yml

Co-authored-by: slarticodefast <161409025+slarticodefast@users.noreply.github.com>

* Update Resources/Prototypes/Entities/Mobs/Player/jaunt_mobs.yml

Co-authored-by: slarticodefast <161409025+slarticodefast@users.noreply.github.com>

* Update Content.Shared/Polymorph/PolymorphPrototype.cs

Co-authored-by: slarticodefast <161409025+slarticodefast@users.noreply.github.com>

* Update Content.Shared/Polymorph/PolymorphPrototype.cs

Co-authored-by: slarticodefast <161409025+slarticodefast@users.noreply.github.com>

* removes meta changes

* removes other meta changes

* adds context menu and a description to basemobjaunt

* comments for jaunt component and adds on component shutdown method

* Update Content.Shared/Jaunt/JauntComponent.cs

* Update Content.Shared/Jaunt/JauntComponent.cs

* Update Content.Shared/Jaunt/JauntComponent.cs

* Update Resources/Prototypes/Catalog/spellbook_catalog.yml

---------

Co-authored-by: lzk <124214523+lzk228@users.noreply.github.com>
Co-authored-by: slarticodefast <161409025+slarticodefast@users.noreply.github.com>
2024-11-14 00:36:37 +01:00
slarticodefast
bb2981400c replace all uses of TryGetContainingContainer with non-obsolete overload (#30583)
* replace all uses of TryGetContainerContainer with non-obsolete overload

* rerun
2024-08-04 15:38:53 +10:00
Leon Friedrich
0f6e1196d8 Use non-generic TryComp() for metadata & transform (#28133) 2024-05-20 22:40:35 -07:00
keronshb
210e6f6444 Polymorphs spawn using the parents world rotation (#27223)
changes polymorph spawn to use angle
2024-04-22 01:39:07 -07:00
keronshb
d4b7bc5aa3 Fixes polymorph cooldowns (#26914)
fixes polymorph cooldowns
2024-04-13 11:26:51 -04:00
keronshb
06b14f30cd Change Polymorph Actions to use Polymorph Proto Id (#26419)
* polymorph changes

Adds poly proto ids to polymorph action event and checks for proto id when performing

* nullable proto id

* Replaces instances of Polymorph prototype with a proto id and tryindex

* birdup

---------

Co-authored-by: metalgearsloth <comedian_vs_clown@hotmail.com>
2024-03-29 17:41:09 +11:00
Jake Huxell
59e46aab93 Reduced Warning Count By 130 For Full Rebuilds (#26518)
* remove deprecated entity coordinate extension functions. Reduces warning count by approximately 50

* final toCoords Removed

* Remove all unused variables and dead code paths

* remove always true variable, should be a cvar or something instead

* remove superfluous variables from tests
2024-03-29 16:28:16 +11:00
AJCM-git
b8f0ed3975 Cleanups PolymorphSystem/Components/Prototypes (#23721)
* Cleanups PolymorphSystem

* forgot this

* Nah

* Fix test

---------

Co-authored-by: metalgearsloth <31366439+metalgearsloth@users.noreply.github.com>
2024-02-01 23:17:02 +11:00
Bakke
a9b797a091 Fix robusted dionas not being recoverable (#21636)
* Fix robusted dionas not being recoverable

* Implement a polymorph cooldown field, used for TreeMorph

Allows the polymorphed Diona some time to work off robust harvest
without immediately polymorphing again.

* Minor adjustment to polymorph cooldown timing

* Apply suggestions from code review

Co-authored-by: Kara <lunarautomaton6@gmail.com>

* fix: trigger polymorph revert on destruction

As suggested by mirrorcult, DamageThresholdReached is not the ideal
candidate for reverting a polymorph on destruction, as there exists a
DestructionEventArgs to listen for instead.

---------

Co-authored-by: Kara <lunarautomaton6@gmail.com>
2024-01-04 06:10:04 -07:00
TemporalOroboros
7a77d6d5dd Content ecs containers (#22484) 2023-12-28 01:30:03 -04: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
DrSmugleaf
f560f88eb5 Remove 700 usages of Component.Owner (#21100) 2023-10-19 12:34:31 -07:00
Leon Friedrich
684b334806 Action container rejig (#20260)
Co-authored-by: metalgearsloth <31366439+metalgearsloth@users.noreply.github.com>
2023-09-23 18:49:39 +10:00
DrSmugleaf
c71f97e3a2 Refactor actions to be entities with components (#19900) 2023-09-08 18:16:05 -07:00
metalgearsloth
4cfc578011 Revert "Remove most usages of obsolete TransformComponent methods (#1… (#19714) 2023-09-01 12:30:29 +10:00
DrSmugleaf
3f3ba6ac62 Move minds, roles, jobs and objectives to shared (#19679) 2023-08-30 21:46:11 -07:00
Visne
1416942bea Remove most usages of obsolete TransformComponent methods (#19571) 2023-08-30 12:05:19 +10:00
DrSmugleaf
15c0211fb2 Refactor minds to be entities with components, make roles components (#19591)
Co-authored-by: ShadowCommander <10494922+ShadowCommander@users.noreply.github.com>
Co-authored-by: DrSmugleaf <DrSmugleaf@users.noreply.github.com>
2023-08-28 16:53:24 -07:00
Visne
b88c2cbb49 Remove usages of obsolete MetaDataComponent setters (#19582) 2023-08-28 19:20:31 +10:00
Moony
3d3c9e3348 Toolshed part 2 (#18997)
* fixe

* Save work.

* Rune-aware parser.

* oogh

* pass tests pass tests pass tests pass tests pass tests pass tests pass tests pass tests pass tests pass tests pass tests pass tests pass tests pass tests pass tests pass tests pass tests pass tests pass tests pass tests pass tests pass tests pass tests pass tests pass tests pass tests pass tests pass tests pass tests pass tests pass tests pass tests pass tests pass tests pass tests pass tests pass tests pass tests pass tests pass tests pass tests pass tests pass tests pass tests pass tests pass tests pass tests pass tests pass tests pass tests pass tests pass tests pass tests pass tests pass tests pass tests pass tests pass tests pass tests pass tests pass tests pass tests pass tests pass tests pass tests pass tests

* Publicizes a lot of common generic commands, so custom toolshed envs can include them.

* i think i might implode

* Tests.

* a

* b

* awa

---------

Co-authored-by: moonheart08 <moonheart08@users.noreply.github.com>
2023-08-23 16:03:41 -05:00
DrSmugleaf
a88e747a0b Refactor serialization copying to use source generators (#19412) 2023-08-22 18:14:33 -07:00
ShadowCommander
dd7032a860 Mind ECS (#16826) 2023-06-19 04:33:19 +10:00
deltanedas
2bef7bfa38 magic bread wand (#17044)
Co-authored-by: deltanedas <@deltanedas:kde.org>
2023-06-03 12:08:52 -07:00
AJCM-git
878c7c0b85 Moves buckling and vehicles to shared, some cleanup (#15923) 2023-05-01 17:04:23 +10:00
Leon Friedrich
4d71b1b81e Revert "Mind ecs" (#14881) 2023-03-27 08:24:00 +11:00
ShadowCommander
bfc4da9377 Mind ecs (#14412) 2023-03-26 14:31:13 -04:00
metalgearsloth
49c7c0f9a7 Remove stamina + damageable .Owner (#14602)
* Remove stamina + damageable .Owner

* More
2023-03-12 09:19:05 -04:00