Paradise icon indicating copy to clipboard operation
Paradise copied to clipboard

[TGUI] Loadout

Open AyIong opened this issue 4 months ago • 5 comments

What Does This PR Do

Loadout now use TGUI, finally. Removed the Loadout tab because it is now a separate UI Loadout now opens from Character Settings Tab, screenshot bellow. If you have some better idea when i can put this button, will be glad to hear it

ImageButton slightly tweaked, buttonsAlt now accept nodes instead only boolean value, that means, you can use buttons and buttonsAlt at the same time, which allow you to make more informative compact buttons

Dimmer and tooltip have increased z-index, so that they cover everything (Dimmer did not cover the ImageButton before, lol)

Loadout button

image

Loadout Tweaks (by @ROdenFL )

That's how you can add tweaks on item

/datum/gear/accessory/scarf/white
	display_name = "Scarf, white"
	path = /obj/item/clothing/accessory/scarf/white

/datum/gear/accessory/scarf/white/New()
	..()
	gear_tweaks |= new /datum/gear_tweak/rename
	gear_tweaks |= new /datum/gear_tweak/color

And that's how it will look in UI

UI

https://github.com/user-attachments/assets/9ccc8a95-c2d6-4d19-96d5-42537494a7e3

Why It's Good For The Game

Finally a user-friendly Loadout, with images Now you will not be rolled back to the beginning of the page when selecting an item All selected items are shown on the left, and you can quickly put them away to get something new, instead of looking for where you don't want or need it

Also, sorting features inspired by Mining Vendor UI. Search and Tweaks implementation by @ROdenFL (Not implemented to any item, but works now)

Standard sorting by Donor TIer

Images of changes

Images
Clean No free points Almost all points used Selected Items Donor Tab
image image image image image
Video

https://github.com/user-attachments/assets/e5c7cef0-e911-4d4c-87e9-572a0f79aa1e

Testing

Tested a lot on local server, also with DB connected (I had never used DB before) Loadouts won't break after old loadout, even with tweaks

Also TestMerged here - https://github.com/ss220club/Paradise-SS220/pull/1573 For a 7+ days and until it get merged :D (Or closed :c) Don't watch on failed tests in TM, thanks to translate branch


Declaration

  • [x] I confirm that I either do not require pre-approval for this PR, or I have obtained such approval and have included a screenshot to demonstrate this below.

Changelog

:cl: Aylong, ROdenFL add: Loadout transfered from tab to separate TGUI window. With images, searching, sorting and more info wip: Added support for loadout items tweaks, ain't used anywhere for now /:cl:

AyIong avatar Oct 08 '24 15:10 AyIong