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

Update to Linking Book Mod share function #335

Open
wants to merge 5 commits into
base: master
Choose a base branch
from

Conversation

DoobesURU
Copy link
Contributor

Sets the default of the share function to false along with an extra check before creating a default share region. This ensures extra, unneeded share regions will not be added as is happening with the current setup (per Ehren's examination of the Chiso files).

Deledrius
Deledrius previously approved these changes Jun 25, 2022
@@ -482,7 +482,7 @@ def pre_export(self, exporter, bo):
else:
rgn_obj = self.clickable_region

if self.shareable:
if self.shareable and self.link_type == "kOriginalBook":
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

To reduce the amount of potentially duplicated logic, Korman usually has Python properties for this. Eg, in the class:

    @property
    def export_share_region(self) -> bool:
        return self.shareable and self.link_type == "kOriginalBook"

Then this line becomes:

Suggested change
if self.shareable and self.link_type == "kOriginalBook":
if self.export_share_region:

@Hoikas Hoikas added the defect label Jun 26, 2022
Comment on lines +691 to +700
# Odds and Ends
stamped = nodes.new("PlasmaAttribBoolNode")
stamped.link_output(linkingnode, "pfm", "IsDRCStamped")
if not self.drc_stamp:
stamped.value = False
forcecam = nodes.new("PlasmaAttribBoolNode")
forcecam.link_output(linkingnode, "pfm", "ForceThirdPerson")
if self.third_person:
forcecam.value = True

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm thinking we should defer these changes to another PR.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I agree.

Sets the default of the share to false as the default along with an extra check before making a share region. This keeps extra, unneeded share regions from being added.
Adds bool values for the stamp and third person cam portions of the xLinkingBookGUIPopup.py parts of the script (MOUL only)
Make the new bool nodes actually work when selected
Updated the stamped property to better reflect its purpose (it's for any stamp on the left page, not just the DRC)
Add new @Property per Hoikas' suggestion
@Hoikas Hoikas dismissed Deledrius’s stale review March 7, 2023 02:00

Approval overruled by BDFL

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants