-
Notifications
You must be signed in to change notification settings - Fork 591
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
Dependency Layers Meta Issue #5642
Comments
This is important for Lifecraft Engine
For this to work correct, Animate Effects would need to use StaticAbility Layers @tool4ever @tehdiplomat @Northmoc I might need some input there |
Places that use addChangedCardTypes to be changed for Layer 4 using this as LinkedHashMap:
|
Imo one of the better ressources (not too outdated and lots of examples) is: Like the link suggests we might consider implementing it as directed graph, which when visualized might help players and our debugging too. Here's my rough pseudocode:
I couldn't really think of any better approach with heuristics but I think we can still do it! |
@tool4ever checkout this Repo: the problem there is that it can't do dependency loop yet some cases from this blog wasn't even on my radar yet Our Main Problem is the checking "if Applying A first, would that change what B applies to" would require to make a Copy of the Game State first |
@tool4ever |
It would certainly be faster if we can do it on the existing game objects:
I think the engine could handle it like that, the View would be frozen anyway and the rest is just Tables/Maps being modified. |
I don't think the frozen is applied strong enough |
That might be because Could investigate if that's still needed for netplay (?) otherwise we can still implement I also have a branch where players get handled in better order: |
For your code, i would made a separate
Wouldn't that mean these should NOT use Layers? my first attempt for this issue would be something like this:
until i noticed that this wouldn't work unless all effects use Static Abilties |
Layer6: addChangedCardTraits
addChangedCardKeywords
|
I'm also gunning for AnimateSubAbility #6816 |
@tool4ever did you comment to the wrong issue? |
Well I guess I can move the details to a sub-issue |
I don't understand this case:
Doesn't Xenograft depend on Kormus Bell depending on Urborg, Tomb of Yawgmoth? I think I need to ask a Judge to explain it to me better |
You're thinking "too far" into the future... This is what I tried to express with: "it's noteworthy that this should be a flat loop instead of recursion after each static"
Now you only check like this:
+
Also important here:
➡ If A had the latest you would get the 1/1 Zombie.
➡ Or if you already control a Swamp at the start of L4 (via intrinsic / L1 copy / L2 control change) then yes, a dependency would exist because A would "directly" depend on C Hope that made sense :) Footnotes
|
@tool4ever yeah i was asking them directly on twitter too, i just didn't link the post there yet in my opinion, a much deeper check would make more sense, but so it is easier for us, i think |
@tool4ever I was thinking about LinkedHashMap But we need to change the other effects fir this too |
Collection of issues related to "Layer Dependency"
Which Layers should be affected?
A token Metamorphic Alteration and Brudiclad, Telchor Engineer (copiable values are handled differently by us)
Confiscate enchanting a Mind Control
Exchange of Words targeting Volrath's Shapeshifter (Volrath's Shapeshifter is a special case entirely)
Cards like Blood Moon
or Graaz, Unstoppable Juggernaut applying to previous non-creatures that got animated
Like Cavalry Master that refers to other creatures with abilities
or stuff that makes the card loose all abilities
Andrios, Roaming Explorer for example, the pump ability otherwise wouldn't make the static ability apply for these cards
for which Layer 4 and unlikely Layer 6 could have ways to cause a dependency Loop
Main Dependency Rule:
For this, it would be good to first separate the characteristic-defining ones.
I haven't seen an example for a dependency between two CharacteristicDefining abilities (in the same layer?)
Related Issues:
Animate and Pump Effects should use StaticLayer #144
The text was updated successfully, but these errors were encountered: