-
Couldn't load subscription status.
- Fork 206
Allow GM chat dialog to switch to scripted comms #2559
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
Open
oznogon
wants to merge
10
commits into
daid:master
Choose a base branch
from
oznogon:2551-gm-chat-script-switch
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
…arams Rather than relying on Boolean values consistently across GuiLabel and GuiAutoSizeLabel, and instead of manipulating the font flags inconsistently across them, refactor GuiLabel to manipulate font flags more directly instead of using a Boolean value to determine whether to apply sp::Font::FlagVertical. - Add a bitwise font_flag parameter to GuiLabel and default it to 0x01 (FlagLineWrap only, same as existing label behavior) - Simplify renderer.drawText logic in onDraw to use font_flag instead of conditionally applying some or no sp::Font flags during every draw - Refactor setVertical() to set font_flag to sp::Font::FlagVertical instead of flipping the vertical Bool and applying the flag conditionally at onDraw() - Add setUnwrapped() and setClipped() functions to unset FlagLineWrap and set FlagClip, respectively, in font_flag - Remove unused Boolean parameters for vertical (removed) and bold (never implemented) - Remove redundant GuiAutoSizeLabel::onDraw() to inherit GuiLabel::onDraw instead
bf60a69 to
589e3bf
Compare
…2555) When a comms entity is being hailed by or has an open channel with a GM that isn't created via the GM screen "Hail ship" button, it can be created via GameMasterScreen::getChatDialog with an uninitialized position and size. This can result in an unusuable dialog and infinite GUI layout loop. Assign a default position (0, 0) and size (300, 300) to any dialog created via getChatDialog.
* Support Center alignment of button icons * Support rotated sprites on GuiToggleButton
Defaulting to LineWrap breaks existing label behavior when a label has a small width, typically 0, as on the main menu's credits and in the autoconnect screen. Revert to no default flag.
- Use rotating icon for minimize GuiToggleButton - Use layout properties instead of absolute positioning - Use GuiAutoSizeLabel for title bar and clip overflow title text
Add a Script button to GM chat dialogs for entities with comms scripts or callbacks. When clicked, the button closes the GM chat and opens a standard chat channel from the player ship to the entity with no hailing delay. This either launches any configured scripted chat on the receiving entity or closes the channel.
589e3bf to
81f20a3
Compare
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Add a button to the GM chat dialog that switches an active impersonation chat to scripted comms, if the impersonated entity supports it.
Depends on #2556, #2557, and #2558. Resolves #2551.
Demo:
Screencast_20251021_142915.webm