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

DIRECTOR : Fix physical energy game bar not filled in total distortion. #5438

Merged
merged 2 commits into from Nov 21, 2023

Conversation

kartiksharmakk
Copy link
Contributor

@kartiksharmakk kartiksharmakk commented Nov 16, 2023

It is partial revert of 3cb61c5

Steps to reproduce:

  1. Start Total Distortion
  2. Start a new game / load game
  3. Click on the "Options" button
  4. The physical energy bar is not visible

Trello card : https://trello.com/c/mpZTlPoZ/628-physical-energy-game-bar-not-filled

Copy link
Contributor

coderabbitai bot commented Nov 16, 2023

Walkthrough

Walkthrough

The changes across the files pertain to the handling of a blend property in the Director engine's rendering system. A new _blend member has been introduced to the Sprite class and is now being used in the Channel class methods to determine plot data and mask conditions. Additionally, the Frame class's function for formatting channel information has been updated to include the blend value in its output.

Changes

Files Change Summary
engines/director/sprite.h
engines/director/sprite.cpp
Added a new _blend member variable to the Sprite class and updated constructors and assignment operators to handle it.
engines/director/channel.cpp Modified Channel::getPlotData to use _blend instead of _blendAmount and updated Channel::getMask to check _sprite->_blend for blend condition.
engines/director/frame.cpp Updated Frame::formatChannelInfo to include the blend value in the output string.

Tips

Chat with CodeRabbit Bot (@coderabbitai)

  • If you reply to a review comment from CodeRabbit, the bot will automatically respond.
  • To engage with CodeRabbit bot directly around the specific lines of code in the PR, mention @coderabbitai in your review comment
  • Note: Review comments are made on code diffs or files, not on the PR overview.
  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.

CodeRabbit Commands (invoked as PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger a review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai help to get help.

Note: For conversation with the bot, please use the review comments on code diffs or files.

CodeRabbit Configration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • The JSON schema for the configuration file is available here.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/coderabbit-overrides.v2.json

@sev-
Copy link
Member

sev- commented Nov 18, 2023

As it was rightfully pointed out by @moralrecordings, this effectively breaks blending in the engine. Thus, switching this PR to draft until the problem is properly detected and addressed.

@sev- sev- marked this pull request as draft November 18, 2023 19:27
It is partial revert of 3cb61c5

Steps to reproduce:
1. Start Total Distortion
2. Start a new game / load game
3. Click on the "Options" button
4. The physical energy bar is not visible

Trello card : https://trello.com/c/mpZTlPoZ/628-physical-energy-game-bar-not-filled
1-bit sprites will not blend with kInkTypeCopy , whereas 8-bit will.

Trello card : https://trello.com/c/mpZTlPoZ/628-physical-energy-game-bar-not-filled
@sev-
Copy link
Member

sev- commented Nov 21, 2023

Thank you!

@sev- sev- marked this pull request as ready for review November 21, 2023 19:19
@sev- sev- merged commit 545073c into scummvm:master Nov 21, 2023
7 of 8 checks passed
@kartiksharmakk kartiksharmakk deleted the 1fc7794 branch November 21, 2023 19:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
3 participants