It is currently 12 Nov 2025, 04:56
   
Text Size

Bug Reports (snapshot builds)

Post MTG Forge Related Programming Questions Here

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

Re: Bug Reports (snapshot builds)

Postby Hanmac » 26 Sep 2016, 20:49

@onderzeeboot: currently there is no extra logic for Vehicle/Crew and AI does treat it like every other Animate Ability.

hm to add more logic into it, can you explain more about the situations, and how the AI should react to it?

If i understand you correctly it seems that AI does not use the Crew Ability? (or use it wrong?)
Hanmac
 
Posts: 954
Joined: 06 May 2013, 18:44
Has thanked: 229 times
Been thanked: 158 times

Re: Bug Reports (snapshot builds)

Postby Twainer » 27 Sep 2016, 02:06

Hanmac wrote:If i understand you correctly it seems that AI does not use the Crew Ability? (or use it wrong?)
The main problem is when the defending player has a vehicle the AI will not attack into it even if it can't be crewed.

Also in r32193
Padeem, Consul of Innovation - Ability only seems to trigger on expensive artifacts, if i have a Prophetic Prism and my opponent has no artifacts it wont trigger.
Twainer
 
Posts: 44
Joined: 03 Jan 2010, 23:42
Has thanked: 0 time
Been thanked: 0 time

Re: Bug Reports (snapshot builds)

Postby Agetian » 27 Sep 2016, 05:49

I tried to improve the AI for Crew a bit when it comes to considering an attack while the opponent has a vehicle out (see r32210).

- Agetian
Agetian
Programmer
 
Posts: 3490
Joined: 14 Mar 2011, 05:58
Has thanked: 684 times
Been thanked: 572 times

Re: Bug Reports (snapshot builds)

Postby excessum » 27 Sep 2016, 12:58

NullPointerException | Open
Code: Select all
Forge Version:    SVN
Operating System: Windows 8.1 6.3 amd64
Java Version:     1.8.0_25 Oracle Corporation

java.lang.NullPointerException
   at forge.game.spellability.SpellAbility.canTarget(SpellAbility.java:784)
   at forge.game.ability.effects.ChangeTargetsEffect.resolve(ChangeTargetsEffect.java:103)
   at forge.game.spellability.AbilitySub.resolve(AbilitySub.java:119)
   at forge.game.ability.AbilityUtils.resolveApiAbility(AbilityUtils.java:1296)
   at forge.game.ability.AbilityUtils.resolve(AbilityUtils.java:1277)
   at forge.ai.ComputerUtil.playNoStack(ComputerUtil.java:288)
   at forge.ai.PlayerControllerAi.playSpellAbilityNoStack(PlayerControllerAi.java:314)
   at forge.game.trigger.WrappedAbility.resolve(WrappedAbility.java:444)
   at forge.game.ability.AbilityUtils.resolveApiAbility(AbilityUtils.java:1296)
   at forge.game.ability.AbilityUtils.resolve(AbilityUtils.java:1277)
   at forge.game.zone.MagicStack.resolveStack(MagicStack.java:521)
   at forge.game.phase.PhaseHandler.startFirstTurn(PhaseHandler.java:978)
   at forge.game.GameAction.startGame(GameAction.java:1463)
   at forge.game.Match.startGame(Match.java:95)
   at forge.match.HostedMatch$2.run(HostedMatch.java:220)
   at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
   at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
   at java.lang.Thread.run(Unknown Source)
r32213
AI's Captured by the Consulate effect is triggered in response to my Disappearing Act. I guess the crash is due to an illegal target change?
excessum
 
Posts: 177
Joined: 21 Oct 2013, 02:30
Has thanked: 0 time
Been thanked: 19 times

Re: Bug Reports (snapshot builds)

Postby akuolum » 27 Sep 2016, 13:47

r: 32213

Hi. When i'm playing against AI in phase: "declare blockers" there's no option for crew a vehicle to block clicking on vehicle card. Is it correct? can I only crew a vehicle in my main phase?

Sorry my bad english :P
Attachments
2016-09-27.png
akuolum
 
Posts: 4
Joined: 27 Sep 2016, 13:35
Has thanked: 2 times
Been thanked: 1 time

Re: Bug Reports (snapshot builds)

Postby friarsol » 27 Sep 2016, 14:33

akuolum wrote:r: 32213

Hi. When i'm playing against AI in phase: "declare blockers" there's no option for crew a vehicle to block clicking on vehicle card. Is it correct? can I only crew a vehicle in my main phase?

Sorry my bad english :P
Once you are in your Declare Blockers step it is too late. The last time you are able to Crew (and block) is in the Declare Attackers step.
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 onderzeeboot » 28 Sep 2016, 06:01

Twainer wrote:
Hanmac wrote:If i understand you correctly it seems that AI does not use the Crew Ability? (or use it wrong?)
The main problem is when the defending player has a vehicle the AI will not attack into it even if it can't be crewed.
That is indeed the main problem. I'll go test if Agetian's fix makes it better tonight :)

Another problem with vehicles I encountered was that my opponent played Fleetwheel Cruiser post-combat, but I see that has been fixed in the meantime with an "SVar:PlayMain1:TRUE" :D
onderzeeboot
 
Posts: 31
Joined: 29 Nov 2014, 19:37
Has thanked: 5 times
Been thanked: 0 time

Re: Bug Reports (snapshot builds)

Postby tjtillman » 28 Sep 2016, 08:32

r32223
Not really a bug, but maybe a possible AI improvement. CPU attacked a 3/1 flyer and a 2/2 flyer into my board. I didn't have a flyer, but I had a Dukhara Peafowl who could gain flying for U and I had one blue mana open.

If this is difficult to implement it mightn't be worth it, but not sure how easy it is.
tjtillman
 
Posts: 202
Joined: 16 Sep 2013, 17:47
Has thanked: 0 time
Been thanked: 2 times

Re: Bug Reports (snapshot builds)

Postby tjtillman » 28 Sep 2016, 08:59

r32223

Something weird is going on with the token (that was a copy of a creature) that is created by Saheeli's Artistry, several times in combat it should have died but did not.

Screenshot attached shows the token copied by Saheeli's Artistry took 1 damage but isn't dead.
Attachments
Creature Not Dead.png
tjtillman
 
Posts: 202
Joined: 16 Sep 2013, 17:47
Has thanked: 0 time
Been thanked: 2 times

Re: Bug Reports (snapshot builds)

Postby Hanmac » 28 Sep 2016, 10:48

@tjtillman that looks suspicious!
Can you test it if it happens at r32216 too? (Before some "fixes"?)
Hanmac
 
Posts: 954
Joined: 06 May 2013, 18:44
Has thanked: 229 times
Been thanked: 158 times

Re: Bug Reports (snapshot builds)

Postby akuolum » 28 Sep 2016, 11:35

r32221:
AI problem: AI is attacking me with thriving turtle without energy counters (so he can't put +1/+1, the damage is 0 and he can't block later)
Attachments
2016-09-28.png
akuolum
 
Posts: 4
Joined: 27 Sep 2016, 13:35
Has thanked: 2 times
Been thanked: 1 time

Re: Bug Reports (snapshot builds)

Postby friarsol » 28 Sep 2016, 14:05

tjtillman wrote:r32223

Something weird is going on with the token (that was a copy of a creature) that is created by Saheeli's Artistry, several times in combat it should have died but did not.

Screenshot attached shows the token copied by Saheeli's Artistry took 1 damage but isn't dead.
Hanmac wrote:@tjtillman that looks suspicious!
Can you test it if it happens at r32216 too? (Before some "fixes"?)
Looks like it has more to do with AIs Fabricate code than anything else, an important part of the screenshot is missing and that's how much combat damage was dealt:

I quickly ran a scenario, and my Servo took 4 damage from the Maulfist Squad (meaning the UI thinks it's a 3/1 but the engine AND the AI think it's a 4/2), even though it also spawned a Servo of it's own...


I'm guessing the issue is related to the following code block --

Code: Select all
final Card copy = CardUtil.getLKICopy(host);
copy.setCounters(CounterType.P1P1, copy.getCounters(CounterType.P1P1) + n);
copy.setZone(host.getZone());
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 Hanmac » 28 Sep 2016, 14:40

hmmm i did use that copy Card to get a copy which does have counters so i an compare it with a card without (and tokens)
the copy should not be added to the real battlefield, and the SetZone stuff should only be apply to the CheckAbilities below.

hm i will test it out if it works if the SetZone line is removed.
Hanmac
 
Posts: 954
Joined: 06 May 2013, 18:44
Has thanked: 229 times
Been thanked: 158 times

Re: Bug Reports (snapshot builds)

Postby tjtillman » 28 Sep 2016, 15:15

friarsol wrote:Looks like it has more to do with AIs Fabricate code than anything else, an important part of the screenshot is missing and that's how much combat damage was dealt:

I quickly ran a scenario, and my Servo took 4 damage from the Maulfist Squad (meaning the UI thinks it's a 3/1 but the engine AND the AI think it's a 4/2), even though it also spawned a Servo of it's own...
In this case I attacked with a 4/2 Maulfist Squad, and the CPU blocked with the copied Maulfist Squad and another creature (I don't recall what, but it wasn't a copy of something). I ordered the blockers to deal damage first to the CPU's copied Maulfist Squad. It dealt 1 damage to it, and the rest to the other creature. After damage step my creature and the 2nd creature died, the copied Maulfist squad did not.

When I have a chance I can try this with r32216 as well.
tjtillman
 
Posts: 202
Joined: 16 Sep 2013, 17:47
Has thanked: 0 time
Been thanked: 2 times

Re: Bug Reports (snapshot builds)

Postby friarsol » 28 Sep 2016, 15:19

tjtillman wrote:In this case I attacked with a 4/2 Maulfist Squad, and the CPU blocked with the copied Maulfist Squad and another creature (I don't recall what, but it wasn't a copy of something). I ordered the blockers to deal damage first to the CPU's copied Maulfist Squad. It dealt 1 damage to it, and the rest to the other creature. After damage step my creature and the 2nd creature died, the copied Maulfist squad did not.

When I have a chance I can try this with r32216 as well.
The copy aspect is a red herring. It happens with a normal (AI controlled on ETB) Maulfist Squad too. But that description isn't any different than what I was describing. The UI thinks it's toughness is one, so when the UI spawns the window to distribute blocking damage it only says you need 1 damage.

I quickly commented out the Fabricate AI code, and it only deal 3 damage as expected. So there's definitely something in that part that's causing the issue.
friarsol
Global Moderator
 
Posts: 7593
Joined: 15 May 2010, 04:20
Has thanked: 243 times
Been thanked: 965 times

PreviousNext

Return to Developer's Corner

Who is online

Users browsing this forum: Bing [Bot] and 59 guests

Main Menu

User Menu

Our Partners


Who is online

In total there are 60 users online :: 1 registered, 0 hidden and 59 guests (based on users active over the past 10 minutes)
Most users ever online was 9824 on 10 Nov 2025, 04:33

Users browsing this forum: Bing [Bot] and 59 guests

Login Form