It is currently 19 Apr 2024, 17:51
   
Text Size

Upcoming Release: Forge version 1.5.58

Post MTG Forge Related Programming Questions Here

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

Re: Upcoming Release: Forge version 1.5.58

Postby friarsol » 03 Jan 2017, 14:16

Agetian wrote:I noticed rather recently that the AI sometimes "forgets" to use the + ability on a planeswalker even though there is no drawback to doing so, and will instead do nothing at all. For example, a common place to see it is AI casting Saheeli Rai and not doing anything at all with it on the first turn (though there is no drawback to +1'ing her). I've seen the same happen with at least several other planeswalkers that are all marked AI playable. Does anyone know what's going on?

- Agetian
Are you sure that's new? I know the AI should do those things but I'm not sure if enough AI code was setup to make sure M2 wasn't passed if +Loyalty abilities were still available.
friarsol
Global Moderator
 
Posts: 7593
Joined: 15 May 2010, 04:20
Has thanked: 243 times
Been thanked: 965 times

Re: Upcoming Release: Forge version 1.5.58

Postby Agetian » 03 Jan 2017, 15:19

Hmm I seem to recall that I haven't seen so many missed opportunities in the past, though maybe I was just playing with different planeswalkers back then, who knows :D At any rate, I'll see if I can somehow improve that later. :)

- Agetian
Agetian
Programmer
 
Posts: 3471
Joined: 14 Mar 2011, 05:58
Has thanked: 676 times
Been thanked: 561 times

Re: Upcoming Release: Forge version 1.5.58

Postby Hanmac » 03 Jan 2017, 15:24

@Agetian you might checkout the Parts with has Random. Probably isn't it just not happen often enough? Might add the part to scryAI that treat the PW Ability different.

(Maybe some general case for PW (+) abilitites? )
Hanmac
 
Posts: 954
Joined: 06 May 2013, 18:44
Has thanked: 229 times
Been thanked: 158 times

Re: Upcoming Release: Forge version 1.5.58

Postby Hanmac » 05 Jan 2017, 08:15

Did some more fixes with damage Replacement. Add new option for DamageTarget should be used with damage redirection or split damage.
The logic behind that is that damage can only be redirected or split if the other target is a creature or planeswalker in play or a Player in play.

My non commited tests does pass for my non commited card changes. I hope i got it finish until weekend.
Hanmac
 
Posts: 954
Joined: 06 May 2013, 18:44
Has thanked: 229 times
Been thanked: 158 times

Re: Upcoming Release: Forge version 1.5.58

Postby Hanmac » 05 Jan 2017, 18:12

@Agetian: i did see your changes about Donate and Illusions of Grandeur
we might think about doing a DonateMe variable like for SacMe and DiscardMe? to make it better for the AI?
Hanmac
 
Posts: 954
Joined: 06 May 2013, 18:44
Has thanked: 229 times
Been thanked: 158 times

Re: Upcoming Release: Forge version 1.5.58

Postby Agetian » 05 Jan 2017, 18:30

Hanmac wrote:@Agetian: i did see your changes about Donate and Illusions of Grandeur
we might think about doing a DonateMe variable like for SacMe and DiscardMe? to make it better for the AI?
Yep, sounds like a plan! :) I'll go ahead and do that :)

EDIT: Done. :) Thanks for the suggestion, Hanmac! As a side note, sadly, haven't found a way to get a list of valid cards as CardCollection other than calling .threadSafeIterable() inside a call to CardsList.filter, is there a better way of handling that? :/
I mean this call:

Code: Select all
Card donateTarget = ComputerUtil.getCardPreference(ai, sa.getHostCard(), "DonateMe", CardLists.filter(ai.getCardsIn(ZoneType.Battlefield).threadSafeIterable(), CardPredicates.hasSVar("DonateMe")));
- Agetian
Agetian
Programmer
 
Posts: 3471
Joined: 14 Mar 2011, 05:58
Has thanked: 676 times
Been thanked: 561 times

Re: Upcoming Release: Forge version 1.5.58

Postby Hanmac » 05 Jan 2017, 19:57

@Agetian hm i need to check, but i don't know if there is a better way to get a CardCollection other than creating one.

i committed some changes for PumpAI. it does improve your changes for DonateAI more. now working with multiple opponents.

i also commited my changes for MoveCounter AI ... but i didnt commited the cards yet which should use that because its not finish yet. (guys feel free to extend it)
Hanmac
 
Posts: 954
Joined: 06 May 2013, 18:44
Has thanked: 229 times
Been thanked: 158 times

Re: Upcoming Release: Forge version 1.5.58

Postby Agetian » 05 Jan 2017, 20:07

Thanks a lot for your contribution, Hanmac! :) Much appreciated!

- Agetian
Agetian
Programmer
 
Posts: 3471
Joined: 14 Mar 2011, 05:58
Has thanked: 676 times
Been thanked: 561 times

Re: Upcoming Release: Forge version 1.5.58

Postby Hanmac » 06 Jan 2017, 17:50

While working though the damage modification cards i noticed Ajani Steadfast (it uses replace prevention)

And that I need to overwork PreventDamage too. (With moving parts to GameEntity if able)

While that I will add a DamagePrevented Trigger for Selfless Squire.
Hanmac
 
Posts: 954
Joined: 06 May 2013, 18:44
Has thanked: 229 times
Been thanked: 158 times

Re: Upcoming Release: Forge version 1.5.58

Postby Xitax » 07 Jan 2017, 03:55

Here are Masters Editions edition files and booster pics. Please let me know if I goofed anything up!
Attachments
masters_edition_defs.zip
(273.45 KiB) Downloaded 227 times
Xitax
 
Posts: 918
Joined: 16 May 2010, 17:19
Has thanked: 183 times
Been thanked: 133 times

Re: Upcoming Release: Forge version 1.5.58

Postby Agetian » 07 Jan 2017, 04:47

Xitax wrote:Here are Masters Editions edition files and booster pics. Please let me know if I goofed anything up!
These look really good, Xitax! Should we maybe set their type to Online though (instead of Reprint) since they are MTGO only? (both Vintage Masters and Tempest Remastered are Type=Online)

I'll commit them unless there are objections from anyone else and once this is discussed. :)

- Agetian
Agetian
Programmer
 
Posts: 3471
Joined: 14 Mar 2011, 05:58
Has thanked: 676 times
Been thanked: 561 times

Re: Upcoming Release: Forge version 1.5.58

Postby Hanmac » 07 Jan 2017, 10:30

I commited the best patch of my damage changes.
moved preventDamage to GameEntity and refactor it a bit.
no need to have the same code in Card and Player.

i added TriggerDamagePrevented, with that Selfless Squire can be coded.

currently i didn't updated the cards yet on that place like i need to for Ajani Steadfast, but the tests does all pass and the cards should work like before.

PS: i did changed the order in preventDamage how the different parts are applied. i thought it now makes more sense (ShieldEffect after Static and ReplacementEffects)
Hanmac
 
Posts: 954
Joined: 06 May 2013, 18:44
Has thanked: 229 times
Been thanked: 158 times

Re: Upcoming Release: Forge version 1.5.58

Postby disferente » 09 Jan 2017, 01:39

AI pays 0 mana to unmanifest.
Attachments
Unmanifest.png
disferente
 
Posts: 11
Joined: 21 Dec 2016, 11:50
Has thanked: 0 time
Been thanked: 1 time

Re: Upcoming Release: Forge version 1.5.58

Postby Agetian » 09 Jan 2017, 05:03

A little question: does anyone know what exactly is preventing Plague of Vermin from being scripted? Looks like Forge already supports effects like "Starting with you, each player..." and "Repeat this process until no one" (e.g. Hypergenesis), as well as token creation. Is there anything in particular that is not possible at the moment? (just curious)

- Agetian
Agetian
Programmer
 
Posts: 3471
Joined: 14 Mar 2011, 05:58
Has thanked: 676 times
Been thanked: 561 times

Re: Upcoming Release: Forge version 1.5.58

Postby Hanmac » 09 Jan 2017, 05:52

@Agetian the problem was the counting how many each player did pay. I don't think we have the right fuctions yet.
Hanmac
 
Posts: 954
Joined: 06 May 2013, 18:44
Has thanked: 229 times
Been thanked: 158 times

PreviousNext

Return to Developer's Corner

Who is online

Users browsing this forum: Baidu [Spider] and 67 guests


Who is online

In total there are 68 users online :: 1 registered, 0 hidden and 67 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: Baidu [Spider] and 67 guests

Login Form