It is currently 22 May 2024, 16:26
   
Text Size

Bug Reports (snapshot builds)

Post MTG Forge Related Programming Questions Here

Moderators: timmermac, Blacksmith, KrazyTheFox, Agetian, friarsol, CCGHQ Admins

Re: Bug Reports (snapshot builds)

Postby excessum » 26 Jan 2016, 04:52

friarsol wrote:I think OP isn't talking about auto-payment. This sounds similar to a problem I was having with Whisperer of the Wilds, but since I was just messing around with mana to get Colorless all fixed up I think I may know how to fix this. Not sure it's related to: Temple of the False God issue also listed.

Edit: Definitely not related to False God
I thought that paying costs manually by selecting stuff selected mana abilities using the auto-payment logic (ie. payManaCosts())?
excessum
 
Posts: 177
Joined: 21 Oct 2013, 02:30
Has thanked: 0 time
Been thanked: 19 times

Re: Bug Reports (snapshot builds)

Postby Agetian » 26 Jan 2016, 06:39

Midori wrote:SNAPSHOT-30720
Jori En, Ruin Diver's ability seems broken.
It won't trigger for a spell with buyback if it was cast previously this turn (probably thinking that spell is still the first spell).
It will also trigger multiple times for a spell with buyback, if that spell was previously cast as the second spell this turn (probably thinking that spell is still the second spell).
Ok, this was a little bit of a "deeper" issue. The problem was that functions like getSpellsCastThisTurn / getSpellsCastLastTurn processed spells in terms of cards they were cast from, and filtering functions that normally deal with card objects (read: unique objects) discarded duplicates. This actually probably affected many things outside this scenario, it's just that these possible scenarios are not very common, which is why they're not very obvious.

In r30723 I implemented an experimental fix such that functions that count spells cast this turn/last turn allow duplicate card objects during iteration and filtering. This allows, for example, spells cast with Buyback to be counted properly (fixes Jori En, Ruin Diver triggering on a second spell that was previously cast that same turn with Buyback, and other similar scenarios). This fix required an expansion to CardLists that adds versions of a couple validity test and filtering functions that return the result as a List<Card> instead of as a CardCollection. I'm not sure how desirable that is. I tried to do it in a couple other ways (initially I wanted to process spells cast this turn/last turn in terms of spell abilities that were cast instead of cards they were cast from), but that proved to be rather difficult because all of the underlying code implies the use of a CardCollection... If you feel like you know a better way to work around this limitation and implement a better fix, please feel free to tweak/update. :)

My fix assumes that the functions mentioned above should always care for duplicates if any. Please report any weird behavior you may encounter from this.

- Agetian
Agetian
Programmer
 
Posts: 3474
Joined: 14 Mar 2011, 05:58
Has thanked: 677 times
Been thanked: 563 times

Re: Bug Reports (snapshot builds)

Postby Agetian » 26 Jan 2016, 06:43

tjtillman wrote:r30720

After CPU casts and resolves Kozilek, the Great Distortion, CPU is able to counter any spell. CPU was able to counter a 5 CMC spell without having a 5 CMC card of its own and did not discard. Also, it did have a 2 CMC card and countered a 2 CMC spell I cast, but did not discard.
I tried looking into this but couldn't understand what's going wrong... Can our current AI properly understand limitations for costs like <Discard/cmcEQX> and pay them? If it should be able to, probably there should be a fix for this, but I'm not sure how to implement it, someone else's help is very welcome. If it simply can't do it at the moment, should we mark the card as RemAIDeck?..

- Agetian
Agetian
Programmer
 
Posts: 3474
Joined: 14 Mar 2011, 05:58
Has thanked: 677 times
Been thanked: 563 times

Re: Bug Reports (snapshot builds)

Postby tjtillman » 26 Jan 2016, 07:50

Agetian wrote:
tjtillman wrote:r30720

After CPU casts and resolves Kozilek, the Great Distortion, CPU is able to counter any spell. CPU was able to counter a 5 CMC spell without having a 5 CMC card of its own and did not discard. Also, it did have a 2 CMC card and countered a 2 CMC spell I cast, but did not discard.
I tried looking into this but couldn't understand what's going wrong... Can our current AI properly understand limitations for costs like <Discard/cmcEQX> and pay them? If it should be able to, probably there should be a fix for this, but I'm not sure how to implement it, someone else's help is very welcome. If it simply can't do it at the moment, should we mark the card as RemAIDeck?..

- Agetian
When it occurred I noticed in the stack box description it said "(X=0)" even though I was casting a non-zero CMC spell. Maybe it's not related to the cost exactly, but how it's calculating X? Then again it still wouldn't explain why it's still not discarding the card.
tjtillman
 
Posts: 202
Joined: 16 Sep 2013, 17:47
Has thanked: 0 time
Been thanked: 2 times

Re: Bug Reports (snapshot builds)

Postby Agetian » 26 Jan 2016, 13:38

tjtillman wrote:
Agetian wrote:
tjtillman wrote:r30720

After CPU casts and resolves Kozilek, the Great Distortion, CPU is able to counter any spell. CPU was able to counter a 5 CMC spell without having a 5 CMC card of its own and did not discard. Also, it did have a 2 CMC card and countered a 2 CMC spell I cast, but did not discard.
I tried looking into this but couldn't understand what's going wrong... Can our current AI properly understand limitations for costs like <Discard/cmcEQX> and pay them? If it should be able to, probably there should be a fix for this, but I'm not sure how to implement it, someone else's help is very welcome. If it simply can't do it at the moment, should we mark the card as RemAIDeck?..

- Agetian
When it occurred I noticed in the stack box description it said "(X=0)" even though I was casting a non-zero CMC spell. Maybe it's not related to the cost exactly, but how it's calculating X? Then again it still wouldn't explain why it's still not discarding the card.
I added RemAIDeck to Kozilek, the Great Distortion for now - it looks like the AI can't handle costs like that after all. The only other card with a somewhat similar effect (cost-wise) is Knollspine Invocation, which is marked RemAIDeck. I tried giving it into AI's virtual hands and observed a similar effect - that is, the AI pays the X mana cost correctly but it completely ignores the fact that it needs to possess a card with CMC X and it also needs to discard it as a part of cost payment. That being said, it would be nice if someone could enhance the AI to handle this correctly some day. :)

- Agetian
Agetian
Programmer
 
Posts: 3474
Joined: 14 Mar 2011, 05:58
Has thanked: 677 times
Been thanked: 563 times

Re: Bug Reports (snapshot builds)

Postby friarsol » 26 Jan 2016, 13:42

tjtillman wrote:When it occurred I noticed in the stack box description it said "(X=0)" even though I was casting a non-zero CMC spell. Maybe it's not related to the cost exactly, but how it's calculating X? Then again it still wouldn't explain why it's still not discarding the card.
Yea I'm not convinced the AI is doing things correctly. Kozilek is probably Knollspine Invocation + Spell Blast, and both of those spells are SVar:RemAIDeck:True. There's certainly a timing issue with setting X and applying X for the costs.
friarsol
Global Moderator
 
Posts: 7593
Joined: 15 May 2010, 04:20
Has thanked: 243 times
Been thanked: 965 times

Re: Bug Reports (snapshot builds)

Postby friarsol » 26 Jan 2016, 13:53

excessum wrote:
friarsol wrote:I think OP isn't talking about auto-payment. This sounds similar to a problem I was having with Whisperer of the Wilds, but since I was just messing around with mana to get Colorless all fixed up I think I may know how to fix this. Not sure it's related to: Temple of the False God issue also listed.

Edit: Definitely not related to False God
I thought that paying costs manually by selecting stuff selected mana abilities using the auto-payment logic (ie. payManaCosts())?
Well, the auto-payment logic goes through the PlayerControllerAi, that's when you actually click on the "auto" button. But when you actually activate a mana ability with the "InputPayMana" dialog active it goes through the Input logic. Before Autopayment existed, that's how everything was routed that was activated by the player.

In general, the InputPayMana dialog should be more robust. There is some "express" payment involved to reduce the amount of times the user has to actually make a decision, but here it isn't choosing the "right" ability, and should probably just let the user select.
friarsol
Global Moderator
 
Posts: 7593
Joined: 15 May 2010, 04:20
Has thanked: 243 times
Been thanked: 965 times

Re: Bug Reports (snapshot builds)

Postby rigged » 28 Jan 2016, 19:18

Auto-pay for Tolarian Academy doesn't appear to be working properly.

I have to manually tap it.

build 30737.
rigged
 
Posts: 56
Joined: 16 Feb 2010, 10:26
Has thanked: 3 times
Been thanked: 2 times

Re: Bug Reports (snapshot builds)

Postby Hanmac » 29 Jan 2016, 13:38

Havengul Lich has two problems:
first: if i target a card in my graveyard and then if i want to play my creature i get TWO cast ways, only one should appear.
second: if i summon my creature, and then the creature dies again, i can still summon it, but that shouldn’t be possible.

Phyrexian Swarmlord: still has the wrong token image, i think something like TokenImage is missing.


ManaPaying: sometimes when i press Cancel for paying mana, it does uptap the wrong lands ... or i get mana i should not get like i get more mana than before.
Hanmac
 
Posts: 954
Joined: 06 May 2013, 18:44
Has thanked: 229 times
Been thanked: 158 times

Re: Bug Reports (snapshot builds)

Postby Agetian » 30 Jan 2016, 20:08

Hanmac wrote:Phyrexian Swarmlord: still has the wrong token image, i think something like TokenImage is missing.
This issue is fixed (r30754).

- Agetian
Agetian
Programmer
 
Posts: 3474
Joined: 14 Mar 2011, 05:58
Has thanked: 677 times
Been thanked: 563 times

Re: Bug Reports (snapshot builds)

Postby tjtillman » 31 Jan 2016, 05:26

r30749

Cinder Hellion doesnt have trample (missing the "K:" in the script)
tjtillman
 
Posts: 202
Joined: 16 Sep 2013, 17:47
Has thanked: 0 time
Been thanked: 2 times

Re: Bug Reports (snapshot builds)

Postby Agetian » 31 Jan 2016, 06:29

tjtillman wrote:r30749
Cinder Hellion doesnt have trample (missing the "K:" in the script)
Fixed (r30765).

- Agetian
Agetian
Programmer
 
Posts: 3474
Joined: 14 Mar 2011, 05:58
Has thanked: 677 times
Been thanked: 563 times

Re: Bug Reports (snapshot builds)

Postby fiend123 » 31 Jan 2016, 07:15

After drafting a few times in tournament mode, I tried to build a quest deck with the added cards, then Forge crashed. When I try to start up forge again, the same crash occurs immediately. Anyway to delete quest data?

RuntimeException | Open
Code: Select all
Forge Version:    1.5.49-SNAPSHOT-r30765
Operating System: Windows 10 10.0 x86
Java Version:     1.8.0_71 Oracle Corporation

java.lang.RuntimeException: java.io.EOFException: Unexpected end of ZLIB input stream
   at forge.quest.io.QuestDataIO.loadData(QuestDataIO.java:138)
   at forge.control.FControl.initialize(FControl.java:233)
   at forge.view.Main.main(Main.java:51)
Caused by: java.io.EOFException: Unexpected end of ZLIB input stream
   at java.util.zip.InflaterInputStream.fill(Unknown Source)
   at java.util.zip.InflaterInputStream.read(Unknown Source)
   at java.util.zip.GZIPInputStream.read(Unknown Source)
   at sun.nio.cs.StreamDecoder.readBytes(Unknown Source)
   at sun.nio.cs.StreamDecoder.implRead(Unknown Source)
   at sun.nio.cs.StreamDecoder.read(Unknown Source)
   at java.io.InputStreamReader.read(Unknown Source)
   at java.io.Reader.read(Unknown Source)
   at forge.quest.io.QuestDataIO.loadData(QuestDataIO.java:112)
   ... 2 more
fiend123
 
Posts: 70
Joined: 05 Mar 2012, 17:26
Has thanked: 2 times
Been thanked: 1 time

Re: Bug Reports (snapshot builds)

Postby Agetian » 31 Jan 2016, 09:00

fiend123 wrote:After drafting a few times in tournament mode, I tried to build a quest deck with the added cards, then Forge crashed. When I try to start up forge again, the same crash occurs immediately. Anyway to delete quest data?

RuntimeException | Open
Code: Select all
Forge Version:    1.5.49-SNAPSHOT-r30765
Operating System: Windows 10 10.0 x86
Java Version:     1.8.0_71 Oracle Corporation

java.lang.RuntimeException: java.io.EOFException: Unexpected end of ZLIB input stream
   at forge.quest.io.QuestDataIO.loadData(QuestDataIO.java:138)
   at forge.control.FControl.initialize(FControl.java:233)
   at forge.view.Main.main(Main.java:51)
Caused by: java.io.EOFException: Unexpected end of ZLIB input stream
   at java.util.zip.InflaterInputStream.fill(Unknown Source)
   at java.util.zip.InflaterInputStream.read(Unknown Source)
   at java.util.zip.GZIPInputStream.read(Unknown Source)
   at sun.nio.cs.StreamDecoder.readBytes(Unknown Source)
   at sun.nio.cs.StreamDecoder.implRead(Unknown Source)
   at sun.nio.cs.StreamDecoder.read(Unknown Source)
   at java.io.InputStreamReader.read(Unknown Source)
   at java.io.Reader.read(Unknown Source)
   at forge.quest.io.QuestDataIO.loadData(QuestDataIO.java:112)
   ... 2 more
Yes, you can delete the saved game file from the "quest/saves" subfolder in your profile folder (you can find out where that is by looking in the game settings - click the "Open User Folder" button in preferences).

- Agetian
Agetian
Programmer
 
Posts: 3474
Joined: 14 Mar 2011, 05:58
Has thanked: 677 times
Been thanked: 563 times

Re: Bug Reports (snapshot builds)

Postby fiend123 » 31 Jan 2016, 12:25

Agetian wrote:
fiend123 wrote:After drafting a few times in tournament mode, I tried to build a quest deck with the added cards, then Forge crashed. When I try to start up forge again, the same crash occurs immediately. Anyway to delete quest data?

RuntimeException | Open
Code: Select all
Forge Version:    1.5.49-SNAPSHOT-r30765
Operating System: Windows 10 10.0 x86
Java Version:     1.8.0_71 Oracle Corporation

java.lang.RuntimeException: java.io.EOFException: Unexpected end of ZLIB input stream
   at forge.quest.io.QuestDataIO.loadData(QuestDataIO.java:138)
   at forge.control.FControl.initialize(FControl.java:233)
   at forge.view.Main.main(Main.java:51)
Caused by: java.io.EOFException: Unexpected end of ZLIB input stream
   at java.util.zip.InflaterInputStream.fill(Unknown Source)
   at java.util.zip.InflaterInputStream.read(Unknown Source)
   at java.util.zip.GZIPInputStream.read(Unknown Source)
   at sun.nio.cs.StreamDecoder.readBytes(Unknown Source)
   at sun.nio.cs.StreamDecoder.implRead(Unknown Source)
   at sun.nio.cs.StreamDecoder.read(Unknown Source)
   at java.io.InputStreamReader.read(Unknown Source)
   at java.io.Reader.read(Unknown Source)
   at forge.quest.io.QuestDataIO.loadData(QuestDataIO.java:112)
   ... 2 more
Yes, you can delete the saved game file from the "quest/saves" subfolder in your profile folder (you can find out where that is by looking in the game settings - click the "Open User Folder" button in preferences).

- Agetian
Thanks for the tip, however, as Forge crashes on start-up, I am unable to access the game settings. Is there any default locations I can manually search?
fiend123
 
Posts: 70
Joined: 05 Mar 2012, 17:26
Has thanked: 2 times
Been thanked: 1 time

PreviousNext

Return to Developer's Corner

Who is online

Users browsing this forum: No registered users and 19 guests


Who is online

In total there are 19 users online :: 0 registered, 0 hidden and 19 guests (based on users active over the past 10 minutes)
Most users ever online was 4143 on 23 Jan 2024, 08:21

Users browsing this forum: No registered users and 19 guests

Login Form