tModLoader
55 lượt đánh giá
Pegasus Lib
   
Giải thưởng
Yêu thích
Đã yêu thích
Bỏ thích
Mod Features: Library
Mod Side: NoSync
tModLoader Version: 1.4.4
Language: English
Kích cỡ file
Đã đăng
Đã cập nhật
387.949 KB
20 Thg10, 2024 @ 4:48pm
21 Thg08 @ 7:19pm
28 ghi chú thay đổi ( xem )

Đăng ký để tải xuống
Pegasus Lib

Mô tả
A collection of code I found myself repeating and recommending to other modders

Includes:
A system to easily apply shaders to things drawn in multiple parts, and/or apply multiple shaders to one thing (ShaderLayerTargetHandler)
A strikethrough font which matches the character spacing of the MouseText font
A faster alternative to accessing fields through reflection (FastFieldInfo and FastStaticFieldInfo)
Automatic asset loading (AutoLoadingAsset)
Custom drawing while using or holding an item (ICustomDrawItem)
Various collision methods (CollisionExt)

To use (as a player):
Install and enable alongside a mod which uses it.

To use (as a modder):
Perform the normal setup to use a library mod.
During loading, call PegasusLib.PegasusLib.Require() with any PegasusLib.LibFeatures your mod needs, to ensure that features relying on them do not fail silently.
Alternatively, you can use PegasusLib.PegasusLib.IsFeatureErrored or PegasusLib.PegasusLib.OnFeatureError to handle any issues that may arise in whatever way suits your mod best.
These methods exist to ensure that tModLoader updates or mod incompatibilities only interfere with mods that actually use the features they cause errors with, so that players can continue using your mod without having to wait for features it doesn't use to be fixed.
Nguyên văn bởi tModLoader PegasusLib:
Developed By Moonlight Glint
8 bình luận
Moonlight Glint  [tác giả] 21 Thg08 @ 11:16pm 
This is no longer an entirely pure library mod as one of the features I wanted it to make available to multiple mods would apply to vanilla, but you can change 2 settings to disable the feature and make it only change 2 inaccurate item tooltips on its own.
Fluffy Moff 31 Thg07 @ 4:12pm 
It worked! You really are fricken amazing!
Moonlight Glint  [tác giả] 31 Thg07 @ 12:24pm 
Fixed
Moonlight Glint  [tác giả] 29 Thg07 @ 9:50pm 
That's an interesting error, I'll try to fix it, but for the time being there's a workaround, if you disable the automatic reload after changing mods you can just exit and re-enter the game; Given that bypasses the unloading process it shouldn't even be much slower.
Fluffy Moff 29 Thg07 @ 7:59pm 
Mod is now broken. Trying to unload it at all makes it so the game has to close with the Error of "PegasusLib was unable to unload properly" Where something called PegasusLib.ExtraDyeSlots "threw an exception"
wurt 22 Thg07 @ 8:44pm 
k :SBpenguin:
Moonlight Glint  [tác giả] 22 Thg07 @ 8:41pm 
I try to ensure that it always does.
wurt 22 Thg07 @ 8:39pm 
does it work
:steamthumbsup::steamthumbsdown: