card view from prompts
Post MTG Forge Related Programming Questions Here
Moderators: timmermac, Blacksmith, KrazyTheFox, Agetian, friarsol, CCGHQ Admins
card view from prompts
by pfps » 20 Jan 2017, 00:55
I made changes to the prompt code to show more information about the spell
or ability that caused a prompt. I also made changes to the gui interface
and the desktop gui to record this spell or ability (view) and to show its
card (view) when the mouse is over the prompt pane. This required more
changes to the code than I would have liked because the spell or ability has
to be dragged from the player code through the input code all the way to the
view code. I had to add new methods fairly high up in the class hierarchy
- for IGuiGame - showPromptMessage(playerView, message, sav)
- for InputBase - showMessage(message, sav)
or ability that caused a prompt. I also made changes to the gui interface
and the desktop gui to record this spell or ability (view) and to show its
card (view) when the mouse is over the prompt pane. This required more
changes to the code than I would have liked because the spell or ability has
to be dragged from the player code through the input code all the way to the
view code. I had to add new methods fairly high up in the class hierarchy
- for IGuiGame - showPromptMessage(playerView, message, sav)
- for InputBase - showMessage(message, sav)
Re: card view from prompts
by Agetian » 20 Jan 2017, 04:57
This is a very interesting and very nice feature to have! Thanks, I'll test it soon!
- Agetian
- Agetian
- Agetian
- Programmer
- Posts: 3472
- Joined: 14 Mar 2011, 05:58
- Has thanked: 677 times
- Been thanked: 561 times
Re: card view from prompts
by Xitax » 20 Jan 2017, 17:35
This is a very welcome addition to be sure. Not knowing the source of the prompt or what it's asking for is an all to frequent annoyance.pfps wrote:I made changes to the prompt code...
Re: card view from prompts
by pfps » 20 Jan 2017, 20:19
Thanks.
I'm not completely happy with the information showing up in the prompts, but at least all the relevant information should now show up.
I'm not completely happy with the information showing up in the prompts, but at least all the relevant information should now show up.
Re: card view from prompts
by pfps » 21 Jan 2017, 17:23
Some triggered abilities on some cards don't have a description, e.g., for Boros Garrison. This isn't ideal, but I guess is a flaw in the card description and shouldn't be papered over in the code. (Besides which, it's not very clear what should be shown - the stack description could be used, but it is not very clear - the trigger description would be nice to show but I don't know how to get ahold of that when the triggered ability is asking for input.)
Re: card view from prompts
by pfps » 25 Jan 2017, 02:17
Both the desktop and the mobile interface can show the card "responsible" for a prompt, if there is one. In the desktop interface this is via clicking on the prompt. In the mobile interface this is via a long press or a swipe.
6 posts
• Page 1 of 1
Who is online
Users browsing this forum: No registered users and 105 guests