Commit Graph
55 Commits
Author SHA1 Message Date
WhatstoneandGitHub 5749d7a6e5 Revert UI queueing (#6789, #6829, #6840) (#6900)
* Revert "Hotfix: pass last state in SharedUserInterfaceSystem.EnsureClientBui (#6840)"

This reverts commit 08b3257ece.

* Revert "Bugfix: SharedUserInterfaceSystem stores and applies BUI states in order. (#6829)"

This reverts commit c766e79ef4.

* Revert "Defer UI operations until UI system runs frame update (#6789)"

This reverts commit f44d7e00c3.
2026-08-04 01:14:17 +00:00
08b3257ece Hotfix: pass last state in SharedUserInterfaceSystem.EnsureClientBui (#6840)
* sins

* New AddQueuedState function, comment both

* I like this name better actually

---------

Co-authored-by: Princess Cheeseballs <66055347+Princess-Cheeseballs@users.noreply.github.com>
2026-07-23 20:03:30 -07:00
WhatstoneandGitHub c766e79ef4 Bugfix: SharedUserInterfaceSystem stores and applies BUI states in order. (#6829)
* store intermediate bui states

* exception printout, remove redundant check

* Set state on Open

* trygetvalue defaults, you dingus

* fix string interpolation bug

* queue in SetUiState

* queue in SetUiState regardless

* TryGetValue->GetValueOrDefault
2026-07-23 14:01:16 -07:00
ab4db16d08 Fix calling Dirty+DiryField on same tick (#6685)
Co-authored-by: slarticodefast <161409025+slarticodefast@users.noreply.github.com>
Co-authored-by: metalgearsloth <31366439+metalgearsloth@users.noreply.github.com>
2026-07-16 19:32:20 +10:00
eoineoineoinandGitHub f44d7e00c3 Defer UI operations until UI system runs frame update (#6789) 2026-07-16 17:22:55 +10:00
WhatstoneandGitHub dfe1d4ef8a Cleanup: ProtoMan Part 3 - remove redundant EntitySystem IPrototypeManager, IComponentFactory instances (#6693) 2026-06-30 17:12:55 +10:00
metalgearsloth cb768d2aa5 Raise a BUI message on any input
The bound wrapper is internal only and I don't want these filtered out by UI validation.
2026-06-18 17:21:47 +10:00
83c2a1be11 [Dependency] source generator part 2 (#6550)
* [Dependency] source generator

No more reflection, no more codegen at runtime

Also various changes to Roslyn helpers to make this easier to write.

Requires all types with dependencies to be partial and not have readonly dependency fields. An analyzer enforces this at warning level, the previous injection strategies have remained in the code *for now* as a fallback.

No fallback is available for [field: Dependency] properties, due to a Roslyn bug.

Code Fixes exist. We love Roslyn

* Apply dependencies generator changes to all code

* Release notes

* Preprocessor got hands

* Handle nullable dependencies

These are bad but gotta deal with it.

* Apply suggestions from code review

Co-authored-by: Moony <moony@hellomouse.net>

* Fine, let's not use collection expressions

---------

Co-authored-by: Moony <moony@hellomouse.net>
2026-05-08 12:38:33 +02:00
TayrtahnandGitHub 1666a3a704 Fix BUI EntitySystem injection (#6515)
* Disable injection when creating BUI instances (the constructor will take care of it)

* Comment

* Release note
2026-04-07 12:51:03 -04:00
ArtisticRoombaandGitHub 077ad1929e Expand SharedUserInterfaceSystem API (#6342)
* Expand SharedUserInterfaceSystem API

* addr reviews
2025-12-18 22:05:33 +01:00
Leon FriedrichandGitHub 10e4766809 Try fix UI state debug assert (#6191)
* Try fix UI state debug assert

* comment
2025-09-18 00:31:57 +02:00
TayrtahnandGitHub 196e59b7e4 Clean up all missing EntitySystem proxy method uses (#6027)
* Clean up all missing EntitySystem proxy method uses

* Restore comment

* Fix bad change that caused closure allocation

* tuple

* Revert "tuple"

This reverts commit 14581a40aa.

* Revert "Fix bad change that caused closure allocation"

This reverts commit 215b2559ed.

* Revert "Restore comment"

This reverts commit 4a47a36557.

* Revert "Clean up all missing EntitySystem proxy method uses"

This reverts commit 3b1fe4ce7f.

* Redo with improved code fixer.
Let's see how it fares this time
2025-06-21 00:05:09 +02:00
Leon FriedrichandGitHub 5756d15333 Make BoundUserInterfaceMessageAttempt broadcast again (#5821) 2025-04-12 18:22:13 +10:00
MilonandGitHub e128338f9d hi (#5811) 2025-04-12 01:29:41 +10:00
WhatstoneandGitHub 3dda8d9e93 Try/catch blocks around BUI open/dispose calls (#5730) 2025-03-08 15:16:11 +11:00
metalgearslothandGitHub ffa3bb7202 Fix savedpos caching on UI shutdown (#5729)
Don't need this as it gets handled already.
2025-03-08 13:28:29 +11:00
Leon FriedrichandGitHub 7016facb9a Tweak UserInterfaceComponent shutdown to prevent bugs (#5678) 2025-02-14 18:16:24 +11:00
metalgearslothandGitHub bb9517fd19 Check equatable on client-predicted BUI states (#5671) 2025-02-12 13:29:19 +11:00
metalgearslothandGitHub a734bc50fa Avoid unnecessary UpdateState calls for BUIs (#5670) 2025-02-12 12:50:33 +11:00
metalgearslothandGitHub fc55c8e0d3 Add saved BUI positions (#5650) 2025-02-04 00:19:22 +11:00
metalgearslothandGitHub d9bf1d1afb BUI deferral tweaks (#5503) 2025-01-27 21:04:27 +11:00
Leon FriedrichandGitHub 32d8a1cba9 Misc grid state changes (#5597) 2025-01-17 17:07:09 +01:00
9837c33de7 Add sourcegenned field deltas (#5155)
* Remove full "delta" states

* Update MapGridComponentState

* abstract ComponentState

* Release notes

* Fix tests

* Fix nullable errors

* A

* Sourcegen component deltas

* Audio deltas + methids

* Also eye

* Optimise out the dictionary

* Minor fixes

* Physics deltas

* Also this

* Fix field deltas

* remove old release notes

* Make IComponentDelta implement IComponent

* add sourcegen launch settings

* make silent error loud

* Review

* UI deltas

* Slimmer

* Sourcegen bandaid

---------

Co-authored-by: ElectroJr <leonsfriedrich@gmail.com>
2024-12-21 15:48:33 +11:00
metalgearslothandGitHub 649378e59a BUI helpers (#5558)
* BUI helpers

- Some virtual methods for BUI to make it slightly easier. Haven't though of a good way to do it via sourcegen yet.
- TryGetUiState which is occasionally useful.

* Also this one
2024-12-13 01:33:17 +01:00
Leon FriedrichandGitHub 1621d25a92 Fix UserInterfaceSystem debug assert (#5546) 2024-11-30 13:09:51 +01:00
Pieter-Jan Briers 18a17da8fa .NET 9 forward compatibility changes
This doesn't switch the projects over to .NET 9, but it does make them work on .NET 9 when we decide to switch in the future.
2024-11-19 19:54:01 +01:00
Pieter-Jan BriersandGitHub f0ed3537ee Duplicate dependency field analyzer (#5463)
* Duplicate dependency field analyzer

Detects cases of duplicate [Dependency] fields in a type. We apparently have 27 of these across RT + SS14.

* Fix duplicate dependencies in Robust
2024-09-28 15:35:18 +10:00
metalgearslothandGitHub b1e13f5b13 Fix BUI interfaces not deep copying (#5410)
* Fix BUI interfaces not deep copying

Didn't think I'd need to on a getstate but client state moment.

* less shitcodey
2024-08-29 12:47:32 +10:00
metalgearslothandGitHub 903041dfd1 Add storage BUI bandaid (#5401) 2024-08-27 17:36:54 +02:00
metalgearslothandGitHub e3819f8245 Network interfacedata (#5399)
If UIs are dynamically changed this fixes it.
2024-08-26 18:48:15 +10:00
metalgearslothandGitHub ff056552fe Don't spam BUI closing in state handling (#5382)
We just do what content does and defer it until update. Saves performance + we don't have some BUIs that do special logic on open re-running it constantly (e.g. open on mouse position).
2024-08-25 20:08:19 +10:00
metalgearslothandGitHub 176ca6c578 Add window helper for BUIs (#5183)
* Add window helper for BUIs

Automatically does OnClose and just makes content slightly nicer.

* more

* Add prototype reload helper

* Add Box2i Center

* weh
2024-07-20 14:50:15 +10:00
Leon FriedrichandGitHub 1eb874f4c3 Fix storage key-not-found exception (#5213) 2024-06-05 22:56:50 +10:00
deltanedasGitHubdeltanedas <@deltanedas:kde.org>
a3a90154a4 add SetUi to shared ui system (#5092)
* re-add AddUi

* rename to SetUi, add if missing

---------

Co-authored-by: deltanedas <@deltanedas:kde.org>
2024-06-05 15:25:49 +10:00
Leon FriedrichandGitHub 074a4faa92 Try fix client-side BUI error spam (#5208) 2024-06-05 15:21:27 +10:00
metalgearslothandGitHub 6b4d74f46e Maybe fix bad resolve logging (#5207)
I'm not entirely sure what happens, I couldn't repro it locally even when I tried to force it to use threadpool threads. The only info I have is it happens and no other info has been provided so.
2024-06-05 09:00:41 +10:00
Leon FriedrichandGitHub d8f2b917b4 Fix buis not closing properly on entity deletion (#5198) 2024-06-02 22:12:39 +10:00
Leon FriedrichandGitHub 15a2f6702c Add try-catch to EnsureClientBui() (#5189)
* Add `try-catch` to `EnsureClientBui()`

* Better comment

* Uneccesary !

* a
2024-05-31 18:01:29 +10:00
Leon FriedrichandGitHub c5c2c2022a Ignore invalid entityuids in bui system update method. (#5187) 2024-05-31 10:47:55 +10:00
metalgearslothandGitHub fe8d1d9422 Fix BUI state getting stuck (#5180) 2024-05-30 11:02:44 +10:00
Leon FriedrichandGitHub 6cc2083b09 Move some EntityCoordinates methods to TransformSystem (#5136)
* Move `EntityCoordinate` methods to `TransformSystem`

* TryGetInterfaceData

* Update IsInSameOrParentContainer

* Don't broadcast BoundUserInterfaceCheckRangeEvent

* Changelog

* Defer fetching component

* Re-add obsoleted methods

* Add obsolete container methods

* update release notes

* Add InRange()

* Make error logging optional
2024-05-24 16:44:17 +10:00
metalgearslothandGitHub b056caeed7 Fix cross-map BUIs (#5115)
Even the ignore range bit is going to break with pvs but uhh not sure on that one unless we do overrides or something.
2024-05-16 19:00:11 +02:00
metalgearslothandGitHub a9ed53f47b Run BUI range checks in parallel (#5118)
These still take almost half-ms in server tick time on live as it has to do a raycast for everyone that has storage or their PDA open or whatever. Haven't benchmarked with a lot of clients but easiest way to tell is just check grafanaTM and I'm not sure how to check this locally.
2024-05-14 09:03:26 +10:00
metalgearslothandGitHub fe051a3577 Minor bui thing (#5114) 2024-05-08 19:59:13 +10:00
DrSmugleafandGitHub a0c1ad246f Fix never setting BoundUserInterface.State (#5111)
* Fix never setting BoundUserInterface.State

* Make setter internal
2024-05-07 20:51:26 -07:00
metalgearslothandGitHub 7e331eaa75 Defer clientside BUI opens (#5073)
* Defer clientside BUI opens

Needs content fix first as storage UI breaks.

* tweaks

* Re-revert this because it seems needed
2024-05-03 12:58:19 +10:00
Leon FriedrichandGitHub 25211e3781 Improve transform & state handling exception tolerance (#5081)
* Improve transform & state exception tolerance

* release notes

* Fix pvs assert

* Fix velocity conservation
2024-04-29 18:42:05 +10:00
metalgearslothandGitHub 16bab1bc03 Close UIs on disconnect (#5071)
Engine handles it fine but content does not as the state gets handled before all comps are initialized.
2024-04-27 12:21:46 +10:00
metalgearslothandGitHub d72de032fa Predicted BUIs (#5059)
* Add TryGetOpenBUI

Avoids having to get the component and openinterfaces separately.

* Couple more helpers

* entityquery

* reviews

* Shared BUIs

* zawehdo

* More boilerplate

* Bunch more work

* Building

* Stuff

* More state handling

* API cleanup

* Slight tweak

* Tweaks

* gabriel

* Disposies

* Active UI support

* Lots of fixes

- Fix states not applying properly, fix predicted messages, remove redundant message type, add RaiseUiMessage for an easy way to do it from shared, add the old BUI state change events back.

* Fix test failures

* weh

* Remove unncessary closes.

* release note
2024-04-26 18:12:55 +10:00
deltanedasGitHubdeltanedas <@deltanedas:kde.org>
9ef7f7cb37 add AddUi to shared ui system (#4984)
Co-authored-by: deltanedas <@deltanedas:kde.org>
2024-03-27 14:36:11 +11:00