Commit graph

190 commits

Author SHA1 Message Date
nebel
7a52cb85db
Fix ShowStructInternal ImGui crash (#2127) 2024-11-27 21:30:24 +01:00
ItsBexy
c950b15a22
Minor interface adjustments (#2121)
- Further ImRaii safety in UiDebug2
- Set some mistakenly internal methods in ImGuiComponents to public
- Added SpanFullWidth flag to trees in Util.ShowStruct
2024-11-24 21:37:39 +01:00
ItsBexy
192dc9c3c3
Update Util.ShowStruct() (#2104)
- Now prints field offsets, if/when they are defined.
- Fixed a bug wherein Boolean fields were being printed with incorrect values (now tries reading the value as a byte, which seems to do the trick)
2024-11-18 17:30:12 -08:00
Kaz Wolfe
6052469976
bumpy da cs 2024-11-13 08:23:57 -08:00
Kaz Wolfe
720b1676e5
Merge branch 'master' into api11
# Conflicts:
#	Dalamud/Game/ClientState/Fates/Fate.cs
#	Dalamud/Game/Gui/NamePlate/NamePlateUpdateContext.cs
#	Dalamud/Interface/Internal/DalamudInterface.cs
#	Dalamud/Interface/Windowing/Window.cs
#	Dalamud/Utility/StringExtensions.cs
#	lib/FFXIVClientStructs
2024-11-11 08:38:20 -08:00
wolfcomp
30d56e4d11
fix all warnings and breaking changes for CS (#2061) 2024-11-04 21:14:51 -08:00
goat
8956bd54a9 fix some warnings 2024-11-04 15:01:09 +01:00
Asriel Camora
0b9af0e3f4
Update to Lumina 5 (new Excel parsing) (#2022)
* Refactor and upgrade to new excel design

* Obsolete ExcelResolver<T> and use only RowRef<T>

* Better benchmarking for Lumina

* Add custom game-supported RSV provider

* Refactor and move Lazy<T> and nullable/cached row objects to RowRefs

* Convert IRSVProvider to delegate, resolve strings by default

* Split IExcelRow into IExcelSubrow

* Extra lumina documentation

* Minor RSV CS fixes

* Fix UIGlowPayload warning

* Fix rebase

* Update to Lumina 5
2024-10-20 19:59:03 -07:00
Kaz Wolfe
4d6b8e59ef
apply low-hanging fruit for api11todos 2024-09-29 10:51:00 -07:00
srkizer
1f74293de4
Update Lumina and use MacroStringParser (#2033)
No longer requires hook and main thread requirements on compiling macro
strings.

Needs lookup table fixing on Lumina; using reflection to fix for the
time being.
2024-09-14 10:23:24 -07:00
KazWolfe
0fb7585973
feat: Use Debug Command Handler for Dalamud Commands (#2018)
* feat: new command handler that works off a hook

* cr comment

* Use ClientStructs for sig
2024-08-28 13:23:39 -07:00
Soreepeong
27ef053252 Update docs 2024-08-25 22:23:58 +09:00
Soreepeong
0a8f9b73fb Make ServiceScope IAsyncDisposable
ServiceScope.Dispose was not waiting for scoped services to complete
disposing. This had an effect of letting a new plugin instance register
a DtrBar entry before previous plugin instance's entry got unregistered.

This change also cleans up unloading procedure in LocalPlugin.
2024-08-18 07:58:45 +09:00
srkizer
b6eb18d550
SeString renderer: fix colors, add link support (#1983)
* Add coloring options

* Add link support

* simplify

* fixes

* Prevent EncodeString from causing crashes

* Fix link range application and add link example

* Fix test widget

* Make DalamudLinkPayload backward compatible

* make it better to use

* make it better to use

* Mark SeString rendering functions experimental via comments

* rename

* Simplify

* Make sestring draw functions take in draw params

* Improvements
2024-08-01 10:36:11 -07:00
srkizer
c25f13261d
Make DtrBar more threadsafe (#1978)
* Changed DtrBar to use ReaderWriterLockSlim so that there exists only one storage of entries, preventing possible desync.
* DtrBarEntry will now hold a reference to the LocalPlugin that created the entry, so that DtrBarPluginScoped can defer plugin related handling to the main service.
* Marked DtrBarEntry class itself to be turned internal in API 11.
* Made IDtrBar.Entries return an immutable copy of underlying list of DtrBar entries, that will be freshly created whenever the list changes.
2024-07-28 14:14:37 +02:00
goat
bd170ee74a
Merge pull request #1945 from KazWolfe/fixed-versioning
feat: Use new versioning strategy
2024-07-25 01:01:50 +02:00
Soreepeong
6c8ec0ab4d Fix random typo 2024-07-22 20:34:43 +09:00
Soreepeong
1be5cd452d Make all TCS RunContinuationsAsynchronously 2024-07-21 20:49:41 +09:00
goat
3584f2cf3d fix warning 2024-07-20 02:17:04 +02:00
srkizer
7707da079c
Add separate handler for process modules (#1947) 2024-07-19 00:03:53 -07:00
Kaz Wolfe
2b96f2187c
feat: Use new versioning strategy
- Rename BuildHash to SCMVersion
- Expose the actual commit hash as a new `commit_hash.txt`
- Update GetGitHash() to actually return the git hash
2024-07-18 14:51:03 -07:00
srkizer
1109e64552
Describe address for debugging, change PresentDetour viewport handling (#1943)
* Describe memory address when printed in log/debug utilities

* PresentDetour: Compare against game's internal copy of IDXGISwapChain

* Handle ReShade on_present function signature properly
2024-07-18 21:28:25 +02:00
Sabine Lim
c57cc5c41f
Fix incorrect GetMapCoordinates() within housing ward subdivisions (#1917)
Co-authored-by: Sabine Lim <thesabinelim@gmail.com>
2024-07-16 19:00:08 +00:00
goat
577f17eb1b add solution-wide code analysis config
Disabled for now, since it'll be a bit of a refactor to enable them
2024-07-11 00:14:15 +02:00
goat
7e397bef17 actually just move the language types, don't use the one from the common assembly 2024-06-29 01:26:29 +02:00
goat
b212b4e00a Revert "api10 todo: only use ClientLanguage from Dalamud.Common, move ToLumina() extension into Dalamud.Util"
This reverts commit 2e731b1eab.
2024-06-29 01:23:29 +02:00
goat
2e731b1eab api10 todo: only use ClientLanguage from Dalamud.Common, move ToLumina() extension into Dalamud.Util 2024-06-29 00:29:51 +02:00
Blair
7947b896ea
Add interfaces to non public/sealed classes referenced in public interfaces (#1808)
* Add interfaces to non public/sealed classes referenced in public interfaces

* Fixed inheritdocs + made most classes internal

* Add missing properties to IFate and Fate, fix documentation

---------

Co-authored-by: goat <16760685+goaaats@users.noreply.github.com>
2024-06-28 23:05:34 +02:00
Kaz Wolfe
cce11a82be
Merge branch 'refs/heads/master' into apiX 2024-06-21 16:04:39 -07:00
Anna
50dc3d44c2
Add /xlcopylog command (#1850)
* feat: add /xlcopylog command

Add a command to copy the dalamud.log file to the user's
clipboard, behaving the same as copying the file in an
Explorer window.

* chore: fix clientstructs submodule

* fix: dispose hGlobal if it's unused

* refactor: move file copier to util class
2024-06-21 15:36:18 -07:00
kal
a35ae5fdf3
refactor: use client struct for character name check (#1840) 2024-06-16 10:38:58 -07:00
github-actions[bot]
4e331b1d85 Merge remote-tracking branch 'origin/master' into apiX-rollup 2024-06-08 23:34:08 +00:00
goat
31e541fae5 deps: upgrade StyleCop, fix warnings
...fixes new array initializer expression
2024-06-07 21:19:16 +02:00
Soreepeong
729795ff9e Move temp file gen for File.Replace to separate file 2024-06-05 00:29:15 +09:00
Soreepeong
0d7c0a0375 Merge remote-tracking branch 'upstream/apiX' into feature/itextureprovider-updates 2024-06-04 23:54:38 +09:00
Kaz Wolfe
8d5f2bdf51
Disambiguate ObjectId to GameObjectId and EntityId 2024-06-03 11:19:39 -07:00
Soreepeong
20717cce3d more 2024-05-21 09:27:51 +09:00
Soreepeong
8c7771bf7d Merge branch 'apiX' into feature/itextureprovider-updates 2024-05-12 22:17:32 +09:00
Infi
44a3c3a1ee
Fix RGB returning wrong color and change it to RGBA (#1793)
* FIx RGB returning wrong color and change it to RGBA

* Don't use the old RGB variable

* Fix UIGlowPayload too

* Add RGBA to ABGR helper and new method for glow/foreground to expose it directly

* Move from Utils to ColorHelpers

* Rename the function
2024-05-03 21:22:53 -07:00
Kaz Wolfe
b32ed39826
Merge branch 'refs/heads/master' into apiX
# Conflicts:
#	Dalamud/Game/Libc/LibcFunction.cs
#	Dalamud/Game/Libc/LibcFunctionAddressResolver.cs
#	Dalamud/Game/Libc/OwnedStdString.cs
#	Dalamud/Game/Libc/StdString.cs
#	Dalamud/Interface/UiBuilder.cs
2024-04-28 11:54:54 -07:00
goat
448b0d16ea
Add "loading dialog" for service init, unify blocking logic (#1779)
* wip

* hacky fix for overlapping event text in profiler

* move IsResumeGameAfterPluginLoad logic to PluginManager

* fix some warnings

* handle exceptions properly

* remove ability to cancel, rename button to "hide" instead

* undo Dalamud.Service refactor for now

* warnings

* add explainer, show which plugins are still loading

* add some text if loading takes more than 3 minutes

* undo wrong CS merge
2024-04-21 17:28:37 +02:00
Kaz Wolfe
3b8ef2c8e8
chore: Remove static PluginLog
- API 10 deprecation
2024-04-20 10:57:59 -07:00
goat
12efd9e679 flush log on Util.Fatal() 2024-04-15 00:43:06 +02:00
KazWolfe
de6dcb8b53
Add some small map helpers (#1756)
* feat: Add new `.GetMapCoordinates` extension method

- Used to easily resolve player-friendly map coordinates for any GameObject.

* feat: Add MapID to ClientState

- Provides easy access to the player's current map ID
2024-04-10 00:49:37 +02:00
srkizer
eb5fa24101
Use CultureInfo.GetCultureInfo for DateTimeSpanExtensions.LocAbsolute instead (#1742)
* MMmm

* Use regional culture infos instead
2024-03-25 12:07:41 +01:00
srkizer
95defa200f
Add Reduced Motion for Notifications (#1732)
When Reduced Motion configuration is on, the expiry progressbar is
removed, and instead a pie on top right is shown, and relative time
update interval increases to 15 seconds. Progress wave animation also is
suppressed.
2024-03-20 21:53:20 +01:00
goaaats
ec122c85d5 fix warnings 2024-03-19 23:24:23 +01:00
github-actions[bot]
4abb3535fa Merge remote-tracking branch 'origin/master' into net8-rollup 2024-03-16 16:02:57 +00:00
srkizer
87b9edb448
Add IInternal/PublicDisposableService (#1696)
* Add IInternal/PublicDisposableService

Plugins are exposed interfaces that are not inherited from
`IDisposable`, but services implementing plugin interfaces often
implement `IDisposable`. Some plugins may try to call
`IDisposable.Dispose` on everything provided, and it also is possible to
use `using` clause too eagerly while working on Dalamud itself, such as
writing `using var smth = await Service<SomeService>.GetAsync();`. Such
behaviors often lead to a difficult-to-debug errors, and making those
services either not an `IDisposable` or making `IDisposable.Dispose` do
nothing if the object has been loaded would prevent such errors. As
`ServiceManager` must be the only class dealing with construction and
disposal of services, `IInternalDisposableService` has been added to
limit who can dispose the object. `IPublicDisposableService` also has
been added to classes that can be constructed and accessed directly by
plugins; for those, `Dispose` will be ignored if the instance is a
service instance, and only `DisposeService` will respond.

In addition, `DalamudPluginInterface` and `UiBuilder` also have been
changed so that their `IDisposable.Dispose` no longer respond, and
instead, internal functions have been added to only allow disposal from
Dalamud.

* Cleanup

* Postmerge fixes

* More explanation on RunOnFrameworkThread(ClearHooks)

* Mark ReliableFileStorage public ctor obsolete

---------

Co-authored-by: goat <16760685+goaaats@users.noreply.github.com>
2024-03-16 15:58:05 +00:00
github-actions[bot]
458e48c088 Merge remote-tracking branch 'origin/master' into net8-rollup 2024-03-14 04:35:37 +00:00