Skip to content

Conversation

@vgskye
Copy link
Member

@vgskye vgskye commented Aug 23, 2024

fixes #638

@vgskye vgskye force-pushed the circle-player-inv branch from 0cea91b to 2f56641 Compare August 23, 2024 06:04
@SamsTheNerd
Copy link
Member

this code looks basically copy pasted from the player casting env, maybe it should just be abstracted into a shared method somewhere?

@vgskye
Copy link
Member Author

vgskye commented Aug 24, 2024

it is based off of that, but there are some behavioural changes(e.g. pull mainhand first then offhand, rather than other-hand-first or other-hand-only since spell circles are hands-free) that I'm not sure makes sense to unify into one set of methods

@vgskye vgskye force-pushed the circle-player-inv branch 2 times, most recently from 923e92c to 2111328 Compare November 2, 2024 06:03
Copy link
Member

@SamsTheNerd SamsTheNerd left a comment

Choose a reason for hiding this comment

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

i think pulling it out and unifying still makes the most sense. can have it just take a list of hands or something and that should handle that behavior? That seemed like the main thing, was there another issue with unifying it ?

@vgskye vgskye force-pushed the circle-player-inv branch from 2111328 to 544c570 Compare November 6, 2024 08:21
@vgskye vgskye requested a review from SamsTheNerd November 6, 2024 08:21
Copy link
Member

@SamsTheNerd SamsTheNerd left a comment

Choose a reason for hiding this comment

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

other than comment I left (which I'm not sure about), code looks fine. Should probably be tested a bit more before merging but I'm not doing that rn

if (!offhand.isEmpty()) {
out.add(offhand);
}
} else {
Copy link
Member

Choose a reason for hiding this comment

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

shouldn't this case check both hands, just prioritizing otherhand. for stuff like self refilling artifacts and whatnot.

Copy link
Member

Choose a reason for hiding this comment

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

i think having this method take a list of hands to check may be better? that way callers can prioritize whichever hand they want while also being able to decide if they want the other hand used also. then just loop over that list, would probably be neater too.

Copy link
Member

Choose a reason for hiding this comment

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

not sure that this would ever actually be used in a case like that though

Copy link
Member Author

Choose a reason for hiding this comment

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

iiuc this is used for Place Block&co, not Recharge&co? I was just retaining previous behaviour when provided with a casting hand though

@SamsTheNerd SamsTheNerd merged commit 8b3e267 into FallingColors:main Nov 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: ✅ Done

Development

Successfully merging this pull request may close these issues.

Spell Circle Unable to use Recharge

2 participants