It is currently 29 Mar 2017, 17:00
   
Text Size

Bug Reports (snapshot builds)

Post MTG Forge Related Programming Questions Here

Moderators: timmermac, moomarc, Chris H., friarsol, DennisBergkamp, Rob Cashwalker, CCGHQ Admins

Re: Bug Reports (snapshot builds)

Postby pfps » 07 Jan 2017, 03:29

OK, here's the proposal for auto yield.

The key for auto yield for wrapped abilities is the host card string (i.e., incluidng number) plus the trigger description (i.e., not including targets or triggering information). So the key for an Amulet of Vigor would be something like "Amulet of Vigor (9): Whenever ... untap it.".

I think that this does the right thing. I'll code it up and see how it works locally and then do a commit of it and the change to ordering. (Assuming that I can figure out how to commit.)
pfps
 
Posts: 48
Joined: 09 Jan 2015, 14:34
Has thanked: 0 time
Been thanked: 6 times

Re: Bug Reports (snapshot builds)

Postby Agetian » 07 Jan 2017, 04:23

Sounds great! If you have trouble committing, let me know and I'll help you out. You can commit right from NetBeans (if you're using NetBeans to code), probably Eclipse and IntelliJ have similar facilities, but I've never tried those IDEs, so I can't say for sure. At least in NetBeans you right-click the project (select multiple projects if your commit affects several, e.g. both Game and Gui) and choose "Subversion -> Commit"

- Agetian
Agetian
Programmer
 
Posts: 2499
Joined: 14 Mar 2011, 05:58
Has thanked: 489 times
Been thanked: 297 times

Re: Bug Reports (snapshot builds)

Postby pfps » 07 Jan 2017, 15:58

OK, I implemented and committed changes (r33021) to make autoyield work at a card level. The code assumes that there always is a host card available. If that's not true, there will have to be a couple of fixes made.

This is just for autoyield, not for effort ordering. I've separated the changes so that they can be reverted more easily.

By the way, is there a better place for these kind of messages/discussions?
pfps
 
Posts: 48
Joined: 09 Jan 2015, 14:34
Has thanked: 0 time
Been thanked: 6 times

Re: Bug Reports (snapshot builds)

Postby friarsol » 07 Jan 2017, 16:07

pfps wrote:
By the way, is there a better place for these kind of messages/discussions?
We don't have a slack/ irc channel if that's what you mean. If there's enough interest we can create one.

Otherwise, I'd recommend spawning a new thread just so it's not all chatter in the bug reports thread.
friarsol
Global Moderator
 
Posts: 6991
Joined: 15 May 2010, 04:20
Has thanked: 219 times
Been thanked: 820 times

Re: Bug Reports (snapshot builds)

Postby pfps » 07 Jan 2017, 16:22

OK, I'll do that in future, but here's an issue with autoyield.

Autoyields are not removed at the end of the game. However, card numbers don't persist between games. This causes a problem with my change to autoyield.

If autoyields are supposed to be removed at the end of the game then that can be fixed and no further change is needed. Otherwise I'm going to have to do a further fix to autoyields, either making them cardname specific or finding out a persistent number for a card, but that number isn't going to be the one that users see. Suggestions?
pfps
 
Posts: 48
Joined: 09 Jan 2015, 14:34
Has thanked: 0 time
Been thanked: 6 times

Re: Bug Reports (snapshot builds)

Postby Agetian » 07 Jan 2017, 16:25

pfps wrote:OK, I'll do that in future, but here's an issue with autoyield.

Autoyields are not removed at the end of the game. However, card numbers don't persist between games. This causes a problem with my change to autoyield.

If autoyields are supposed to be removed at the end of the game then that can be fixed and no further change is needed. Otherwise I'm going to have to do a further fix to autoyields, either making them cardname specific or finding out a persistent number for a card, but that number isn't going to be the one that users see. Suggestions?
I'm pretty sure auto-yields are meant to be cleared up after the game is over.

- Agetian
Agetian
Programmer
 
Posts: 2499
Joined: 14 Mar 2011, 05:58
Has thanked: 489 times
Been thanked: 297 times

Re: Bug Reports (snapshot builds)

Postby friarsol » 07 Jan 2017, 16:34

Agetian wrote:
I'm pretty sure auto-yields are meant to be cleared up after the game is over.

- Agetian
I believe they are cleared at the end of the match. We can probably move that to the game without a major loss
friarsol
Global Moderator
 
Posts: 6991
Joined: 15 May 2010, 04:20
Has thanked: 219 times
Been thanked: 820 times

Re: Bug Reports (snapshot builds)

Postby pfps » 07 Jan 2017, 18:55

friarsol wrote:
Agetian wrote:
I'm pretty sure auto-yields are meant to be cleared up after the game is over.

- Agetian
I believe they are cleared at the end of the match. We can probably move that to the game without a major loss
Right now they aren't even cleared when a new match is started from the end-game dialog. There isn't even a good way to clear them aout all at once. If someone could point me to the place where autoyields would have to be set before starting a new game, I'll add the necessary code.
pfps
 
Posts: 48
Joined: 09 Jan 2015, 14:34
Has thanked: 0 time
Been thanked: 6 times

Re: Bug Reports (snapshot builds)

Postby Marek14 » 08 Jan 2017, 17:03

AI can use the same mode of Demonic Pact multiple times.
Marek14
Tester
 
Posts: 2455
Joined: 07 Jun 2008, 07:54
Has thanked: 0 time
Been thanked: 211 times

Re: Bug Reports (snapshot builds)

Postby Agetian » 08 Jan 2017, 17:05

Marek14 wrote:AI can use the same mode of Demonic Pact multiple times.
Umm most likely the AI is not fully coded for it, yeah, it's currently marked as RemAIDeck...
EDIT: Nevermind, actually even the human player can do it. :) Looking into it now.
EDIT 2: For some reason, choice restriction could not match the SAs (remembered one and the ones in the choice list), I made the game temporarily compare SAs by their description, which is clunky but works, please update if necessary/possible. :)

- Agetian
Agetian
Programmer
 
Posts: 2499
Joined: 14 Mar 2011, 05:58
Has thanked: 489 times
Been thanked: 297 times

Re: Bug Reports (snapshot builds)

Postby Hanmac » 08 Jan 2017, 18:23

Agetian wrote:
Marek14 wrote:AI can use the same mode of Demonic Pact multiple times.
Umm most likely the AI is not fully coded for it, yeah, it's currently marked as RemAIDeck...
EDIT: Nevermind, actually even the human player can do it. :) Looking into it now.
EDIT 2: For some reason, choice restriction could not match the SAs (remembered one and the ones in the choice list), I made the game temporarily compare SAs by their description, which is clunky but works, please update if necessary/possible. :)

- Agetian
probably the reason why is because the spellAbility got copied. thats why the remembered does not fit the copy anymore ...
another way would be to store the SVarName if accessible/possible which might be better than description.

but i think your way is okay for now
Hanmac
 
Posts: 906
Joined: 06 May 2013, 18:44
Has thanked: 223 times
Been thanked: 148 times

Re: Bug Reports (snapshot builds)

Postby Agetian » 09 Jan 2017, 07:39

r33069: It is possible to cast Qasali Ambusher from graveyard under the conditions "if you control a Plains and a Forest and a creature is attacking you". I have noticed the presence of EffectZone$ All on this card, changing it to Hand fixes this issue, but I have seen that other similar cards have "EffectZone$ All" as well (but they do not have the "...and a creature is attacking you" clause, so they don't have to worry about being castable while an attack is happening). Is it OK to switch Qasali Ambusher to "Hand"? (I'm worried that it might interfere with things like "you can cast cards from your graveyard" and stuff - actually, I tested it with Yawgmoth's Will and indeed it does not work with Qasali Ambusher if it's switched to EffectZone=Hand). Or what should we do here?

- Agetian
Agetian
Programmer
 
Posts: 2499
Joined: 14 Mar 2011, 05:58
Has thanked: 489 times
Been thanked: 297 times

Re: Bug Reports (snapshot builds)

Postby Hanmac » 09 Jan 2017, 08:47

@Agetian: mayPlay need some reworking because they are Cumulative.

Quasli should support playing it with flash. Other MayPlay should allow it to play from other Zones.
Hanmac
 
Posts: 906
Joined: 06 May 2013, 18:44
Has thanked: 223 times
Been thanked: 148 times

Re: Bug Reports (snapshot builds)

Postby fmartel » 09 Jan 2017, 18:45

I can't seem to cast Necroplasm (1BB) it always ask me for 1 more. I have Opal Palace, Underground Sea, Tropical Island OTB (thank you Forge !! :D)
My commander is Atraxa, Praetors' Voice
fmartel
 
Posts: 187
Joined: 31 Dec 2013, 19:27
Location: Québec City
Has thanked: 8 times
Been thanked: 1 time

Re: Bug Reports (snapshot builds)

Postby Agetian » 09 Jan 2017, 19:31

fmartel wrote:I can't seem to cast Necroplasm (1BB) it always ask me for 1 more. I have Opal Palace, Underground Sea, Tropical Island OTB (thank you Forge !! :D)
My commander is Atraxa, Praetors' Voice
Hmm I'm not sure if you can actually cast it - I mean, you tap Opal Palace, you pay {1} (so you tap one more land) to actually get black mana from it, then you only have one open land left, so yeah, you're one short...

- Agetian
Agetian
Programmer
 
Posts: 2499
Joined: 14 Mar 2011, 05:58
Has thanked: 489 times
Been thanked: 297 times

PreviousNext

Return to Developer's Corner

Who is online

Users browsing this forum: No registered users and 2 guests


Who is online

In total there are 2 users online :: 0 registered, 0 hidden and 2 guests (based on users active over the past 10 minutes)
Most users ever online was 279 on 11 Jul 2013, 22:03

Users browsing this forum: No registered users and 2 guests

Login Form