Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Gun action (and equip) buttons refactor #5750

Merged
merged 4 commits into from
Feb 21, 2024

Conversation

SabreML
Copy link
Member

@SabreML SabreML commented Feb 18, 2024

About the pull request

Refactors the 'gun action' buttons and the 'equip' button to have each have their own /atom/movable/screen subtype, rather than all of their functionality being done through if() checks in /atom/movable/screen/clicked().

The 'gun action' buttons being these:
image

And the 'equip' button being this:
image

Explain why it's good for the game

Cleaner code, and the gun buttons now show their names in the status bar when hovered over thanks to this:

SHOW_ON_STATUSBAR(/atom/movable/screen/gun)

(That line has been there for a couple of years, but /atom/movable/screen/gun didn't exist until now.)

Testing Photographs and Procedure

Screenshots & Videos

Put screenshots and videos here with an empty line between the screenshots and the <details> tags.

Changelog

🆑
refactor: Refactored the 'gun action' buttons, making them show their names in the status bar when hovered over.
/:cl:

I removed the `if("Reset Machine")` part rather than refactoring it because, as far as I can tell, nothing actually uses it.
@github-actions github-actions bot added the Refactor Make the code harder to read label Feb 18, 2024
code/_onclick/hud/screen_objects.dm Outdated Show resolved Hide resolved
@harryob harryob marked this pull request as draft February 21, 2024 03:46
Co-Authored-By: harryob <[email protected]>
@cm13-github
Copy link
Contributor

This pull request has conflicts, please resolve those before we can evaluate the pull request.

@cm13-github cm13-github added the Merge Conflict PR can't be merged because it touched too much code label Feb 21, 2024
@cm13-github cm13-github removed the Merge Conflict PR can't be merged because it touched too much code label Feb 21, 2024
@cm13-github
Copy link
Contributor

Conflicts have been resolved. A maintainer will review the pull request shortly.

@SabreML SabreML marked this pull request as ready for review February 21, 2024 11:02
@harryob harryob added this pull request to the merge queue Feb 21, 2024
Merged via the queue into cmss13-devs:master with commit 06eebf0 Feb 21, 2024
27 checks passed
cm13-github added a commit that referenced this pull request Feb 21, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Refactor Make the code harder to read
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants