It is currently 29 Apr 2024, 17:42
   
Text Size

Card Development Questions

Post MTG Forge Related Programming Questions Here

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

Re: Card Development Questions

Postby Marek14 » 22 Nov 2013, 08:30

Marc: It's this article:

https://www.wizards.com/magic/magazine/ ... arcana/612

When I was implementing these things in BotArena, I encountered another problem, and that is Zombie tokens in Innistrad (there are 3 pictures). Unlike Eldrazi Spawns, there's no simple way to assign them to cards. In the end I resolved it by making the cards create the three types randomly, which seems to fit Innistrad well. Is there a better way?
Marek14
Tester
 
Posts: 2762
Joined: 07 Jun 2008, 07:54
Has thanked: 0 time
Been thanked: 297 times

Re: Card Development Questions

Postby Xitax » 23 Nov 2013, 01:18

Sure, I will make the tokens all set specific as they can be as well as make sure the Eldrazi tokens are associated with the right cards. I will upload a set of edited scripts and also the complete tokens picture directory for LQ size when I finish. I think this makes it as easy as possible for somebody to put it in.

I never asked to join the devs group because I don't have an ongoing contribution plan. Once I get the tokens sorted out I don't think there's any more for me to do.
Xitax
 
Posts: 918
Joined: 16 May 2010, 17:19
Has thanked: 183 times
Been thanked: 133 times

Re: Card Development Questions

Postby Marek14 » 23 Nov 2013, 08:03

If you could upload a HQ compilation of tokens somewhere, it would be good as well - getting HQ tokens would otherwise involve large amount of renaming.
Marek14
Tester
 
Posts: 2762
Joined: 07 Jun 2008, 07:54
Has thanked: 0 time
Been thanked: 297 times

Re: Card Development Questions

Postby friarsol » 23 Nov 2013, 13:16

drdev,

I'm curious why you decided to just create CostDesc's for all of the cards that didn't parse properly with your regex instead of just having the Mana be wrapepd in {} when coming out of Cost.java as I originally suggested. The way you did it means that people will need to do this in the future, instead of just creating the cards they had been, and letting the underlying framework generate the cost formatting like it was doing before.
friarsol
Global Moderator
 
Posts: 7593
Joined: 15 May 2010, 04:20
Has thanked: 243 times
Been thanked: 965 times

Re: Card Development Questions

Postby drdev » 23 Nov 2013, 15:52

friarsol wrote:drdev,

I'm curious why you decided to just create CostDesc's for all of the cards that didn't parse properly with your regex instead of just having the Mana be wrapepd in {} when coming out of Cost.java as I originally suggested. The way you did it means that people will need to do this in the future, instead of just creating the cards they had been, and letting the underlying framework generate the cost formatting like it was doing before.
CostDesc$ often includes more than just mana costs, so it seemed the best way to do it efficiently. This way, the syntax for mana costs is consistent for all description pieces in the script, whether it be SpellDescription, TriggerDescription, or CostDesc.
drdev
Programmer
 
Posts: 1958
Joined: 27 Jul 2013, 02:07
Has thanked: 189 times
Been thanked: 565 times

Re: Card Development Questions

Postby friarsol » 23 Nov 2013, 17:42

drdev wrote:CostDesc$ often includes more than just mana costs, so it seemed the best way to do it efficiently. This way, the syntax for mana costs is consistent for all description pieces in the script, whether it be SpellDescription, TriggerDescription, or CostDesc.
But this is exactly what's generated by Cost. It spits out a full Cost in words, ordered in specific way. Updating 100s of scripts definitely seems less efficient to me than just fixing it one spot (for many of these cases). We can't do anything about SpellDescriptions or TriggerDescriptions because it's just text. But the Cost for abilities is parsed, so we should be able to handle that.
friarsol
Global Moderator
 
Posts: 7593
Joined: 15 May 2010, 04:20
Has thanked: 243 times
Been thanked: 965 times

Re: Card Development Questions

Postby drdev » 23 Nov 2013, 18:20

friarsol wrote:
drdev wrote:CostDesc$ often includes more than just mana costs, so it seemed the best way to do it efficiently. This way, the syntax for mana costs is consistent for all description pieces in the script, whether it be SpellDescription, TriggerDescription, or CostDesc.
But this is exactly what's generated by Cost. It spits out a full Cost in words, ordered in specific way. Updating 100s of scripts definitely seems less efficient to me than just fixing it one spot (for many of these cases). We can't do anything about SpellDescriptions or TriggerDescriptions because it's just text. But the Cost for abilities is parsed, so we should be able to handle that.
What you're missing is I already did update the Cost logic to format it, however, for cards where it's specified, CostDesc$ is used in place of the parsed cost, meaning the only way to have it display right was to update the scripts.
drdev
Programmer
 
Posts: 1958
Joined: 27 Jul 2013, 02:07
Has thanked: 189 times
Been thanked: 565 times

Re: Card Development Questions

Postby friarsol » 23 Nov 2013, 18:30

drdev wrote:What you're missing is I already did update the Cost logic to format it, however, for cards where it's specified, CostDesc$ is used in place of the parsed cost, meaning the only way to have it display right was to update the scripts.
Ah. That makes more sense. Sorry about that. I don't know why so many of those cards have CostDesc. I just saw a ton of card script changes and it had me worried.
friarsol
Global Moderator
 
Posts: 7593
Joined: 15 May 2010, 04:20
Has thanked: 243 times
Been thanked: 965 times

Re: Card Development Questions

Postby drdev » 23 Nov 2013, 18:38

friarsol wrote:
drdev wrote:What you're missing is I already did update the Cost logic to format it, however, for cards where it's specified, CostDesc$ is used in place of the parsed cost, meaning the only way to have it display right was to update the scripts.
Ah. That makes more sense. Sorry about that. I don't know why so many of those cards have CostDesc. I just saw a ton of card script changes and it had me worried.
No worries.
drdev
Programmer
 
Posts: 1958
Joined: 27 Jul 2013, 02:07
Has thanked: 189 times
Been thanked: 565 times

Re: Card Development Questions

Postby Xitax » 23 Nov 2013, 20:32

Marek14 wrote:If you could upload a HQ compilation of tokens somewhere, it would be good as well - getting HQ tokens would otherwise involve large amount of renaming.
I'll try, but the problem is going to be finding HQ versions of the card art I need for tokens that have no official art. I've spent a lot of time finding versions of the art that I personally prefer for those but since I use 282x400 pics for Forge I don't have them in HQ. I mean, has anyone ever seen a black 3/3 kavu token pic in HQ that doesn't look like total crap?
Xitax
 
Posts: 918
Joined: 16 May 2010, 17:19
Has thanked: 183 times
Been thanked: 133 times

Re: Card Development Questions

Postby Marek14 » 24 Nov 2013, 08:51

There was a compilation here at one time. I put my current version up...

http://uloz.to/xstCTNeW/tokens-compilation-zip
Marek14
Tester
 
Posts: 2762
Joined: 07 Jun 2008, 07:54
Has thanked: 0 time
Been thanked: 297 times

Re: Card Development Questions

Postby swordshine » 07 Jan 2014, 14:16

I'm trying to implement the last card which affects cards during the untap step, Storage Matrix. AI logic is quite complicated (forge.ai.ComputerUtil.chooseSomeType(Player, String, String, List<String>)). Any suggestions?
swordshine
 
Posts: 682
Joined: 11 Jul 2010, 02:37
Has thanked: 116 times
Been thanked: 87 times

Re: Card Development Questions

Postby Sloth » 07 Jan 2014, 17:23

swordshine wrote:I'm trying to implement the last card which affects cards during the untap step, Storage Matrix. AI logic is quite complicated (forge.ai.ComputerUtil.chooseSomeType(Player, String, String, List<String>)). Any suggestions?
Maybe just choose the type with the most tapped permanents. Maybe value creatures with factor 1,5.
User avatar
Sloth
Programmer
 
Posts: 3498
Joined: 23 Jun 2009, 19:40
Has thanked: 125 times
Been thanked: 507 times

Re: Card Development Questions

Postby torridus » 11 Jan 2014, 04:28

I've been coding a number of unofficial cards and I'm not entirely sure how to proceed for one. I want it to be a creature which gets +1/+1 for each card in the exile zone (through suspend or other abilities), but I haven't found a way to make that work yet.

I figure it should look similar to Omnath:
Code: Select all
S:Mode$ Continuous | Affected$ Card.Self | AddPower$ X | AddToughness$ X | References$ X | Description$ CARDNAME gets +1/+1 for each green mana in your mana pool.
SVar:X:Count$ManaPool:green
There are existing cards buffed by all sorts of things - lands, cards in graveyards, auras, etc - but nothing similar enough to this. Trench Gorger is the closest card, probably, but I want to have something without remembered cards.
torridus
 
Posts: 56
Joined: 03 Jul 2012, 12:58
Has thanked: 4 times
Been thanked: 9 times

Re: Card Development Questions

Postby friarsol » 11 Jan 2014, 05:12

I didn't test it, but I believe this should do the trick:

Code: Select all
S:Mode$ Continuous | Affected$ Card.Self | AddPower$ X | AddToughness$ X | References$ X | Description$ CARDNAME gets +1/+1 for each exiled card.
SVar:X:Count$Valid Card.inZoneExile
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: No registered users and 100 guests


Who is online

In total there are 100 users online :: 0 registered, 0 hidden and 100 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 100 guests

Login Form