Commit Graph

164 Commits

Author SHA1 Message Date
Plykiya
c5ff647ca6 Replace obsolete EntityWhitelist IsValid usages part 2 (#28506) 2024-06-03 17:40:03 -04:00
Plykiya
d6ba166d3b Replace obsolete EntityWhitelist IsValid usages (#28465)
* Replace obsolete whitelist is valid with whitelist system

* Consistency

* Fix logic

* Bork

* I figured out how to get whitelists on the client lol

* test fail

* woops

* HELP ME FUNCTIONS

* Fix errors

* simplify

---------

Co-authored-by: plykiya <plykiya@protonmail.com>
2024-06-01 23:10:24 -04:00
Nemanja
a1a8f04036 Decouple interactions from hands, cleanup old events, add new fears (#28393)
* ok basic shit

* second part

* pretend it isn't real it can't hurt you.

* 👁️ 👁️

* shadowcommander review
2024-05-31 13:26:19 -07:00
DrSmugleaf
8619f241d4 Fix not networking whitelist and blacklist in storage component (#28238) 2024-05-25 16:07:37 -04:00
Leon Friedrich
76e13eed35 Improve InteractionSystem range & BUI checks (#27999)
* Improve InteractionSystem range & BUI checks

* Ghost fixes

* AAA

* Fix test

* fix nullable

* revert to broadcast event

* Fixes for eengine PR

* Ah buckle code

* )
2024-05-24 15:03:03 +10:00
DrSmugleaf
594a898260 Fix whatever the fuck is going on in storage system slightly (#28236)
* Fix whatever the fuck is going on in storage system slightly

* Fix inverted check

* h

* Add silent bool

* Silent
2024-05-23 18:23:55 -07:00
Leon Friedrich
0f6e1196d8 Use non-generic TryComp() for metadata & transform (#28133) 2024-05-20 22:40:35 -07:00
Kara
d6e2cc0a8b Open slot storage keybind can now also close the UI (#27962) 2024-05-12 20:03:07 -04:00
Kara
855234aa30 Resolve 'TransformComponent.MapPosition' is obsolete in content (#27939)
* Resolve `'TransformComponent.MapPosition' is obsolete: 'Use TransformSystem.GetMapCoordinates'` in content

* build?
2024-05-12 10:31:54 -04:00
ShadowCommander
1db48b86d1 Fix collection modified error when locking storage (#27913) 2024-05-11 02:25:40 -07:00
Sphiral
de729f9037 Make storage UI close upon being locked (#27810)
* make storage close on lock

* formatting and comments

* Update Content.Shared/Storage/EntitySystems/SharedStorageSystem.cs

Co-authored-by: ShadowCommander <shadowjjt@gmail.com>

* Apply suggestions from code review

Co-authored-by: ShadowCommander <shadowjjt@gmail.com>

* Swap to foreach instead of for

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

---------

Co-authored-by: ShadowCommander <shadowjjt@gmail.com>
Co-authored-by: Kara <lunarautomaton6@gmail.com>
2024-05-08 23:50:50 -07:00
Tayrtahn
236da1cd27 Make UseDelay SetLength do EnsureComp (#27601)
Make UseDelay.SetLength do EnsureComp
2024-05-02 22:16:16 +10:00
metalgearsloth
5896e68752 Content update for UI prediction (#27214)
* Content update for UI refactor

* Big update

* Sharing

* Remaining content updates

* First big update

* Prototype updates

* AUGH

* Fix UI comp ref

* Cleanup

- Fix predicted message, fix item slots, fix interaction range check.

* Fix regressions

* Make this predictive

idk why it wasn't.

* Fix slime merge

* Merge conflict

* Fix merge
2024-04-26 18:16:24 +10:00
Tayrtahn
b292905216 Expand UseDelay to support multiple delays per entity; fix bible healing and bag pickup (#27234)
* Upgraded UseDelay to support multiple delays per entity

* Implement secondary delay for bibles.
Also some improvements to make it work nicely.

* Documentation is good

* Reserve the previous change; now Storage uses the special ID and Bible uses the default.

* .0

* Added VV support to UseDelayInfo

* Serialize better

* No register, just setlength
2024-04-25 22:25:52 -04:00
Plykiya
6ad039d0f9 Fix for inventory and belt not opening (#27179)
Co-authored-by: Plykiya <plykiya@protonmail.com>
2024-04-20 20:24:52 +02:00
DrSmugleaf
3c6722bd6f Move storage binds and slot click handling to shared (#27135) 2024-04-20 16:23:45 +10:00
metalgearsloth
b2b1926ecc More storage tweaks (#25970)
- Fix some prediction stuff.
- Fix some jank.
- UseDelay.
- Cap.
2024-04-20 11:51:16 +10:00
DrSmugleaf
45df595c15 Fix storage fill giving no reason for failing (#27122) 2024-04-18 23:24:13 -04:00
Plykiya
5aadb17be7 Fix for items dropped being rotated to world north (#26662)
* Fix rotation of dropped items

* combined world position rotation function for dumpable

* scuffed implementation?

* less scuffed?

* even less scuffed... I guess

* capital D

---------

Co-authored-by: Plykiya <plykiya@protonmail.com>
2024-04-03 16:31:57 +11:00
brainfood1183
5f063d2d6d Toilet Upgrade (needs review) (#22133)
* Toilet Draft

* fixes

* toilets now have secret stash to place items in cistern.

* fixes

* plungers now unblock toilets.

* fix sprite

* new sprites and fix

* fixes

* improve seat sprites.

* fix

* removed visualisersystem changed to genericvisualizers

* flush sound for toilets and copyright for toilet sprites.

* fix atrributions

* fixes

* fix datafield flushtime

* sprite improvements

* fixes

* multiple changes

* fix

* fix

* fixes remove vv

* moved stash related functions to secret stash system from toilet.

* fix

* fix

* changes for recent review.

* fix

* fix
2024-03-31 14:21:18 +11:00
metalgearsloth
cdfee5aa0c Transform cleanups (#25963)
* Transform cleanups

* Fix build

* ascension
2024-03-29 17:26:30 +11:00
deltanedas
6863a7cc26 biggest gridinv update OF ALL TIME (#25834)
* add SaveItemLocation keybind

* make item direction public to avoid having to change between Angle for no reason

* add item location saving

* show

* Added a better save keybind, made it draw saved positions, and trying to save in a position it has already been saved in removes that position.

* w

* code style

* Make taken spots appear blue

* style

* !

---------

Co-authored-by: deltanedas <@deltanedas:kde.org>
Co-authored-by: notquitehadouken <tripwiregamer@gmail.com>
Co-authored-by: I.K <45953835+notquitehadouken@users.noreply.github.com>
2024-03-28 17:31:47 +11:00
Tayrtahn
4a83c36585 Code cleanup: Dirty(Comp) (#26238)
* Replaced uses of Dirty(Component) with Dirty(Uid, Component)
Modified some systems (notably pulling-related) to use uids.

* Missed a few

* Revert changes to pulling

* No
2024-03-19 23:27:02 -04:00
nikthechampiongr
362d56981f Simplify DoAfterArgs behavior for movement and distance checks (#25226)
* Merge BreakOnWeightlessMove and BreakOnMove. Provide different theshold for weightless movement.

* Adjust WeightlessMovementThresholds. Put a thing I forgot to put in the doafterargs.

* Make DoAfterArgs only use OnMove to determine whether to check for
movement and MoveThreshold to determine the threshold regardless of
weightlessness. Gave DistanceThreshold a default value which will always
be checked now.

* Fix issue introduced by merge.

* Use interaction system for determining whether a distance is within range

* Fix incorrect doafter args introduced by previous merge.
Forgor to commit these.

* Exorcise ghost.

The execution system should have been deleted when I merged previously.
For a reason I cannot comprehend it came back, but only the execution
system.

* Exorcise ghost Pt. 2

* Allow for movement check to be overriden in zero g and adjust doafter args where needed.

You can now override checking for movement in zero g with the BreakOnWeightlessMove bool. By default it will check.
The following doafters were made to ignore the movement check in zero g:
- Healing yourself with healing items,
- Removing embedded projectiles,
- Using tools like welders and crowbars

* Adjust distance for cuffing/uncuffing to work. Make injections not break on weightless movement.

* Fix evil incorrect and uneeded comments
2024-03-19 21:09:00 +11:00
SlamBamActionman
d7484ae9f5 Fix recycled containers deleting items inside them (#26045)
* Removes items from containers in reclaimers

* Made it into an event instead

* Sloth review comment

* Fix indentation and rename field
2024-03-19 13:36:21 +11:00
Krunklehorn
c775410370 Weight based AreaInsert and Dumpable delay, a janitor qol tweak (#24899)
Weight based delay, retuned average, fixed comments
2024-03-03 00:57:44 +11:00
metalgearsloth
a9502be29e Revert "Fix chat bubbles (#25643)" (#25645)
* Revert "Fix chat bubbles (#25643)"

This reverts commit 23d2c4d924.

* Revert "Fixes obsolete Transform warnings in Content. (#25256)"

This reverts commit f284b43ff6.
2024-02-28 00:51:20 +11:00
TemporalOroboros
f284b43ff6 Fixes obsolete Transform warnings in Content. (#25256)
* Fix TransformComponent.MapPosition warnings in Content.Client

* Fix TransformComponent.MapPosition warnings in Content.IntegrationTests

* Fix TransformComponent.MapPosition warnings in Content.Shared

* Fix TransformComponent.MapPosition warnings in Content.Server

* Fix TransformComponent.WorldPosition warnings in Content.Shared

* Fix TransformComponent.WorldPosition warnings in Content.Client
Excepts ClickableComponent b/c that needs to be ECS'd entirely later

* Fix TransformComponent.WorldPosition warnings in Content.Server

* Fix TransformComponent.WorldRotation warnings in Content.*

* Fix TransformComponent.MapPosition warnings I missed

* Fix TransformComponent.WorldMatrix warnings in Content.*

* Fix TransformComponent.InvWorldMatrix warnings in Content.*

* Fix TransformComponent.GetWorldPositionRotationMatrixWithInv warnings in Content.*

* Fix TransformComponent.GetWorldPositionRotationMatrix warnings in Content.*

* Fix TransformComponent.GetWorldPositionRotation warnings in Content.*

* Fix TransformComponent.Anchored.set warnings in Content.*

* Fix TransformComponent.Coordinates.set warnings in Content.*

* Fix TransformComponent.LocalPosition.set warnings in Content.*

* Fix TransformComponent.AttachToGridOrMap warnings in Content.*

* Fix TransformComponent.AttachParent warnings in Content.*

* Preempt TransformComponent.LocalRotation.set warnings in Content.Shared

* Preempt TransformComponent.LocalRotation.set warnings in Content.Client

* Preempt TransformComponent.LocalRotation.set warnings in Content.IntegrationTests

* Preempt TransformComponent.LocalRotation.set warnings in Content.Server

* Fix/Preempt the remaining obsolete TransformComponent properties/methods in Content.*

* ECS ClickableComponent

* Fix obsolete SharedTransformSystem methods in Content.*

* Fix ExplosionOverlay `SharedTransformSystem` dependency

* Maybe fix null eye position breaking tests

* MGS requested changes
2024-02-27 12:06:20 +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
Krunklehorn
902198d7e0 Fix candy bowls (#25514)
* Before SharedItemSystem

* Fixes mispredict, removed unused

* Fix physics
2024-02-26 00:08:14 +11:00
MilenVolf
c7870882f6 LockVisualizer (#25224)
* LockVisualizer

* Fix state

* Clean some code

* Make it component, fix tests fail

* Fix for StateUnlocked

Now it is possible to manually set the unlocked state and it will work!

* Optimize LockVisualizer, add check for unlocked state

* No todo I guess
2024-02-16 16:52:31 -07:00
Pieter-Jan Briers
68ce53ae17 Random spontaneous cleanup PR (#25131)
* Use new Subs.CVar helper

Removes manual config OnValueChanged calls, removes need to remember to manually unsubscribe.

This both reduces boilerplate and fixes many issues where subscriptions weren't removed on entity system shutdown.

* Fix a bunch of warnings

* More warning fixes

* Use new DateTime serializer to get rid of ISerializationHooks in changelog code.

* Get rid of some more ISerializationHooks for enums

* And a little more

* Apply suggestions from code review

Co-authored-by: 0x6273 <0x40@keemail.me>

---------

Co-authored-by: 0x6273 <0x40@keemail.me>
2024-02-13 16:48:39 -05:00
metalgearsloth
042feae2e9 Predicted movement opening lockers (#24937)
Relay wasn't really networked properly and this annoys me.

EntityStorage is still pretty skrunkly but this fixes the main issue I think.
2024-02-04 13:23:16 +11:00
Leon Friedrich
3ffa15ce34 Fix storage destruction/deletion bug (#24882) 2024-02-03 11:54:48 +11:00
Kara
cc24ba6a31 Roundstart variation game rules (#24397)
* Raise `StationPostInitEvent` broadcast

* Basic variation pass handling

* standardize names + rule entities

* why does it work like that?

* add to defaults

* light break variation pass

* ent spawn entry

* move some stationevent utility functions to gamerule + add one for finding random tile on specified station

* forgot how statistics works

* powered light variation pass is good now

* station tile count function

* public method to ensure all solutions (for procedural use before mapinit)

* move gamerulesystem utility funcs to partial

* ensure all solutions before spilling in puddlesystem. for use when spilling before mapinit

* trash & puddle variation passes!

* oh yeah

* ehh lets live a little

* std

* utility for game rule check based on comp

* entprotoid the trash spawner oops

* generalize trash variation

* use added instead of started for secret rule

* random cleanup

* generic replacement variation system

* Wall rusting variation rule

* account for modifying while enumerating

* use localaabb

* fix test

* minor tweaks

* reinforced wall replacer + puddletweaker
2024-01-30 21:52:35 -08:00
Arendian
e89be95d4c Prevent EntityStorages from being opened while inside another container (#24253)
* Prevent EntityStorages from being opened while inside a mech.

* compressed into few lines

* unneeded line

* Popup client

---------

Co-authored-by: metalgearsloth <comedian_vs_clown@hotmail.com>
2024-01-20 13:50:14 +11:00
metalgearsloth
24f8da8f0c Fix storage state (#23852)
slughands
2024-01-10 02:07:35 -07:00
metalgearsloth
b22c9aa5e2 Fix storagecomp serialization (#23780)
* Fix storagecomp serialization

* Fix state
2024-01-09 03:47:51 -07:00
Nemanja
a448e5fa56 Allow storage to specify a default orientation for stored items. (#23594)
Co-authored-by: metalgearsloth <comedian_vs_clown@hotmail.com>
2024-01-06 14:19:01 +11:00
TemporalOroboros
7a77d6d5dd Content ecs containers (#22484) 2023-12-28 01:30:03 -04:00
Leon Friedrich
364ecae94f Cache ItemSizePrototype in StorageSystem (#22611) 2023-12-28 09:50:49 +11:00
Leon Friedrich
0baffe3243 Fix closet skeletons spawning in nullspace (#22942) 2023-12-24 23:48:58 -07:00
Leon Friedrich
907b873145 Fix various errors/exceptions (#22841)
* Fix entity storage localization

* Fix HumanoidAppearanceComponent resolve

* Fix null reference exceptions

* Fix duplicate key error

* Fix artifact error spam

* actually maybe this is what its meant to do

* Fix entities playing sounds on deletion
2023-12-22 00:26:08 -07:00
LordCarve
cb6884e5bb DumpableComponent on an empty container no longer stops other interactions (#22831)
DumpableComponent does not block the entity from being disposed via InteractOn a DisposalUnit
2023-12-21 21:26:40 -07:00
deltanedas
a7e85fe446 open bag in combat mode (#22512)
* open bag in combat mode

* !!!!!

---------

Co-authored-by: deltanedas <@deltanedas:kde.org>
2023-12-14 18:54:27 -05:00
Nemanja
9de4c40c29 Miscellaneous inventory tweaks (#22371)
* pt 1

* Miscellaneous gridinv UX
2023-12-12 00:49:37 -07:00
deltanedas
e85ca6a4f6 make syndie bag and rigs explosion resistant (#22088)
* remove empty file real

* support explosion resistance for non-worn things

* remove redundant entitystorage resistance

* port entitystorage optimisation to apply for everything with 100% resistance

* add explosion resistance for bag contents

* make thing reusable

* add resistance to chest rig too

* medical chest rig too

---------

Co-authored-by: deltanedas <@deltanedas:kde.org>
2023-12-11 02:43:00 -07:00
Nemanja
1945ded919 fix small CanInsert bug (#22302) 2023-12-11 02:26:19 -07:00
Nemanja
09dbb24e7e Make items' default rotation orient them correctly (#22258) 2023-12-10 15:11:45 -08:00
Nemanja
736300d505 keybinds for opening bag/belt & context logic for opening storage window (#22238)
* keybinds for opening bag/belt & context logic for opening storage window

* no error por favor
2023-12-08 12:43:37 -06:00