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

Game under control doesn’t work (Emrakul, the Promised End and other) #12878

Closed
siyiye opened this issue Sep 15, 2024 · 13 comments
Closed

Game under control doesn’t work (Emrakul, the Promised End and other) #12878

siyiye opened this issue Sep 15, 2024 · 13 comments
Assignees
Labels
bug Bugs and errors

Comments

@siyiye
Copy link

siyiye commented Sep 15, 2024

After casting Emrakul, the Promised End, I can‘t control my opponent's turn.(It doesn't work after I switch)

This is a bug,Hope you can fix it perfectly.THX!

@jeffwadsworth jeffwadsworth added the bug Bugs and errors label Sep 20, 2024
@jeffwadsworth
Copy link
Contributor

[[Emrakul, the Promised End]]

Copy link

Emrakul, the Promised End - (Gatherer) (Scryfall) (EDHREC)

{13}
Legendary Creature — Eldrazi
13/13
This spell costs {1} less to cast for each card type among cards in your graveyard.
When you cast this spell, you gain control of target opponent during that player's next turn. After that turn, that player takes an extra turn.
Flying, trample, protection from instants

@JayDi85
Copy link
Member

JayDi85 commented Sep 20, 2024

It’s can be related to wrong usage of user’s skip settings in HumanPlayer.java

@jeffwadsworth
Copy link
Contributor

Hmm. I tested it with default settings and still no go. I will check earlier builds.
settings

@JayDi85
Copy link
Member

JayDi85 commented Sep 20, 2024

I mean the game can use pressed skip button and skip user settings from wrong player (not from real controller of the player). I added some todos about it somewhere in HumanPlayer long ago. Same bugs with miss priority can be appear after rollback with active skip buttons (maybe).

@JayDi85
Copy link
Member

JayDi85 commented Sep 20, 2024

Also AI code can be bugged with under control effects (related to same problems with wrong usage of real controller).

@jeffwadsworth
Copy link
Contributor

Sen Triplets is screwed up as well. May be related or not. #12918

@JayDi85 JayDi85 self-assigned this Jan 6, 2025
@JayDi85
Copy link
Member

JayDi85 commented Jan 6, 2025

I can confirm: turn control effects doesn’t work at all in human games. And your opponent must press skip button to continue without any actions (or you will lose by timeout). There are impossible to play/activate anything. And it’s not related to any settings.

@JayDi85
Copy link
Member

JayDi85 commented Jan 6, 2025

AI games also affected -- you can't do anything and can only pass priority.

JayDi85 added a commit that referenced this issue Jan 7, 2025
 - game: added support for human games (cards like Emrakul, the Promised End, #12878);
 - game: added support of 720.1. to reset control in the turn beginning instead cleanup step (related to #12115);
 - game: added game logs for priorities in cleanup step;
 - game: fixed game freezes and wrong skip settings usages (related to #12878);
 - gui: added playable and choose-able marks for controlling player's cards and permanents, including switched hands;
 - gui: added controlling player name in all choice dialogs;
 - info: control of computer players is it not yet supported;
@JayDi85
Copy link
Member

JayDi85 commented Jan 7, 2025

Added support of under control effects for human games in c076f49, cards like Emrakul, the Promised End are fully playable without game freeze. Also it contains some other game freeze fixes and gui improves.

Computer players doesn't support it yet. Maybe I'll add it later (still under investigation -- is it possible to support or not yes, it’s possible).

JayDi85 added a commit that referenced this issue Jan 7, 2025
@JayDi85
Copy link
Member

JayDi85 commented Jan 7, 2025

JayDi85 added a commit that referenced this issue Jan 10, 2025
 - game: added support when a human is take control over a computer player (related to #12878);
 - game: fixed game freezes while controlling player leaves/disconnect on active priority/choose of another player;
@JayDi85
Copy link
Member

JayDi85 commented Jan 10, 2025

Take control over computer player added by 0505f51. Now you can fully control computer's actions.

It can be useful for test mode too (use cheats menu to take control over computer and setup attack/defend/casts/etc instead using two client apps).

P.S. There's one last feature left to develop: computer take control over another computer or human. It will use pass and default choice logic due too complicated use cases.

JayDi85 added a commit that referenced this issue Jan 11, 2025
 - game: fixed game freezes when computer try to take control over another computer or human (added game logs, related to #12878);
 - cheats: improved take and give control commands, now you can give control under yourself to another player;
 - cheats: improved take and give control commands, now you can return control to computer in the same priority;
 - cheats: deleted useless and unused command to activate opponent's ability;
@JayDi85
Copy link
Member

JayDi85 commented Jan 11, 2025

Added more stability and improved cheats in 1f1d108. Now you can take control over computer, add cards/lands by another cheats and return control. So AI will play activate priority as itself.

Emrakul, the Promised End is playable, so issue will be closed. For better AI support see #13220

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

No branches or pull requests

3 participants