It is currently 08 Sep 2025, 01:53
   
Text Size

Adding counters

Post MTG Forge Related Programming Questions Here

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

Adding counters

Postby Kurai » 09 Oct 2010, 06:43

Ahoy people!

I'm not much of a programmer at all... But I want to add cards to the cards.txt. Many of the cards I want to add have abilities which add counters to other cards.

I used abPumpTgtC but that just lasts until the end of the turn and doesn't add counters...

These are my failed attempts:
The creature sacrifices itself in order to boost another, think the ability is called Reinforce 1, but that's not a keyword yet is it?
Code: Select all
abPumpTgtC W Sac-CARDNAME:+1/+1
Code: Select all
abPumpTgtC W Sac-CARDNAME:AddCounter<P1P1/1>
If anyone could help with this it would be a great help.

Thanks a lot in advance.
Kurai
 
Posts: 12
Joined: 08 Oct 2010, 10:44
Has thanked: 0 time
Been thanked: 0 time

Re: Adding counters

Postby Rob Cashwalker » 09 Oct 2010, 12:32

Hi, welcome to the forum!

I'm sure spells and abilities dealing with counters are on the horizon for our dev team. Possibly even a dedicated Reinforce ability, though it appears on a very limited group of cards. We tend to make keywords that apply to the largest range of cards first, then move down in scale.

Also, we are no longer using cards.txt. Now each card has its own text file under res/cardsfolder.
The Force will be with you, Always.
User avatar
Rob Cashwalker
Programmer
 
Posts: 2167
Joined: 09 Sep 2008, 15:09
Location: New York
Has thanked: 5 times
Been thanked: 40 times

Re: Adding counters

Postby friarsol » 09 Oct 2010, 13:43

Funny you should mention it. I have a abPutCounter mostly completed just needed a little bit of testing before it was submitted.
friarsol
Global Moderator
 
Posts: 7593
Joined: 15 May 2010, 04:20
Has thanked: 243 times
Been thanked: 965 times

Re: Adding counters

Postby Kurai » 10 Oct 2010, 08:12

Thanks. ^_^

Ah ok, so maybe by the next release? I'm using the Archenemy Green and White deck irl, managed to add a few simple cards to the game but certain ones like the Forgotten Ancient and a few others use a lot of counters.

Is it for the next release that each card will have it's own file? The 9-12 one I downloaded still has the cards.txt. That would be a great addition and would mean that users could upload cards which can just be downloaded and slotted straight into the game!

Looking forward to the addition of abPutCounter! I'm going through Java tutorials and stuff, hope I may be of use in the future. ^_^
Kurai
 
Posts: 12
Joined: 08 Oct 2010, 10:44
Has thanked: 0 time
Been thanked: 0 time

Re: Adding counters

Postby Sloth » 10 Oct 2010, 09:25

Kurai wrote:Is it for the next release that each card will have it's own file? The 9-12 one I downloaded still has the cards.txt.
This Version already has the new card structure: viewtopic.php?f=26&t=3264

Kurai wrote:That would be a great addition and would mean that users could upload cards which can just be downloaded and slotted straight into the game!
Yes. That would be welcome.
User avatar
Sloth
Programmer
 
Posts: 3498
Joined: 23 Jun 2009, 19:40
Has thanked: 125 times
Been thanked: 507 times

Re: Adding counters

Postby zerker2000 » 10 Oct 2010, 19:47

Kurai wrote:That would be a great addition and would mean that users could upload cards which can just be downloaded and slotted straight into the game!
Well, it wouldn't be quite that simple, since complicated cards would also involve swapping in updated classfiles into run-forge.jar.
That being said, "Vanilla" or "French vanilla"(anything using only the implemented keywords) cards can easily be added, and have been for a long time(pasting the same info into cards.txt and card-pictures.txt).
O forest, hold thy wand'ring son
Though fears assail the door.
O foliage, cloak thy ravaged one
In vestments cut for war.


--Eladamri, the Seed of Freyalise
zerker2000
Programmer
 
Posts: 569
Joined: 09 May 2009, 21:40
Location: South Pasadena, CA
Has thanked: 0 time
Been thanked: 0 time


Return to Developer's Corner

Who is online

Users browsing this forum: No registered users and 34 guests

Main Menu

User Menu

Our Partners


Who is online

In total there are 34 users online :: 0 registered, 0 hidden and 34 guests (based on users active over the past 10 minutes)
Most users ever online was 7303 on 15 Jul 2025, 20:46

Users browsing this forum: No registered users and 34 guests

Login Form