Skip to content

Commit

Permalink
Lets you de-select a ship outfit preview (#2779)
Browse files Browse the repository at this point in the history
<!-- Write **BELOW** The Headers and **ABOVE** The comments else it may
not be viewable. -->
<!-- You can view Contributing.MD for a detailed description of the pull
request process. -->

## About The Pull Request

![image](https://github.com/shiptest-ss13/Shiptest/assets/47290811/e93c2ee0-9c32-4639-b630-d7c0f162cb0c)
<!-- Describe The Pull Request. Please be sure every change is
documented or this can delay review and even discourage maintainers from
merging your PR! -->

## Why It's Good For The Game
Currently, once you select an outfit through this menu you can't go back
to not having an outfit on your character. This fixes that (so you can
compare just your loadout gear to your loadout gear + job gear, things
like that).
<!-- Please add a short description of why you think these changes would
benefit the game. If you can't justify it in words, it might not be
worth adding. -->

## Changelog

:cl:
tweak: You can now go back to having no ship outfit after selecting one
/🆑
<!-- Both :cl:'s are required for the changelog to work! You can put
your name to the right of the first :cl: if you want to overwrite your
GitHub username as author ingame. -->
<!-- You can use multiple of the same prefix (they're only used for the
icon ingame) and delete the unneeded ones. Despite some of the tags,
changelogs should generally represent how a player might be affected by
the changes rather than a summary of the PR's contents. -->
  • Loading branch information
JimKil3 authored Feb 29, 2024
1 parent 15dbb87 commit abc3475
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion code/modules/client/preferences.dm
Original file line number Diff line number Diff line change
Expand Up @@ -1240,7 +1240,11 @@ GLOBAL_LIST_EMPTY(preferences_datums)
if(!SSmapping)
return

var/datum/map_template/shuttle/ship = SSmapping.ship_purchase_list[tgui_input_list(user, "Please select which ship to preview outfits for.", "Outfit selection", SSmapping.ship_purchase_list)]
var/ship_selection = tgui_input_list(user, "Please select which ship to preview outfits for.", "Outfit selection", (list("None") + SSmapping.ship_purchase_list))
if(ship_selection == "None")
selected_outfit = new /datum/outfit //The base type outfit is nude

var/datum/map_template/shuttle/ship = SSmapping.ship_purchase_list[ship_selection]
if(!ship)
return

Expand Down

0 comments on commit abc3475

Please sign in to comment.