UI Improvements, Round 2: Match UI
Post MTG Forge Related Programming Questions Here
Moderators: timmermac, Agetian, friarsol, Blacksmith, KrazyTheFox, CCGHQ Admins
Re: UI Improvements, Round 2: Match UI
by Doublestrike » 17 Dec 2011, 07:42
Me three.
Battlefield click bug should be fixed now.
Battlefield click bug should be fixed now.
---
A joke is a very serious thing.
A joke is a very serious thing.
-

Doublestrike - UI Programmer
- Posts: 715
- Joined: 08 Aug 2011, 09:07
- Location: Bali
- Has thanked: 183 times
- Been thanked: 161 times
Re: UI Improvements, Round 2: Match UI
by friarsol » 17 Dec 2011, 13:41
Ah stupid thing. Will have it up in a few.
Edit: Oh yes, this is one complex file that got missed. Should be fixed now.
Edit: Oh yes, this is one complex file that got missed. Should be fixed now.
- friarsol
- Global Moderator
- Posts: 7593
- Joined: 15 May 2010, 04:20
- Has thanked: 243 times
- Been thanked: 965 times
Re: UI Improvements, Round 2: Match UI
by moomarc » 17 Dec 2011, 16:32
I've noticed that the mana isn't always cleared properly when paying for a spell. It seems to happen when more than one mana of a particular type is spent. Also, if you cancel spells after paying part of the cost, you end up with negative mana. In both these cases the erroneous mana will then be carried across to following phases. I don't think it can be used to cast spells (in the case that there's too much mana) but it is counted when checking the amount of mana in your pool (Omnath, Locus of Mana and Glissa Sunseeker). You can also add the following code to any script (or create a new test card with it) although it'll only count white and blue mana at the momentfriarsol wrote:The first checkin for actually paying mana from the Player Panel is now in. Lemme know if there's any issues with it. I haven't removed the ManaPool card just in case it doesn't quite work as expected. It seems to be working for the most part, but for sure can use some fine-tuning and extra eyes on it.
- Code: Select all
A:AB$ GainLife | Cost$ 0 | ValidTgts$ Player | TgtPrompt$ Select target player | LifeAmount$ X | SpellDescription$ Target player gains X life.
SVar:A:Count$ManaPool:white
SVar:B:Count$ManaPool:blue
SVar:C:Count$ManaPool:black
SVar:D:Count$ManaPool:red
SVar:E:Count$ManaPool:green
SVar:X:SVar$A/Plus.B/Plus.C/Plus.D/Plus.E
Edit: Further testing shows that any mana added to your pool will persist for counting mana pool contents, but not for spell casting.
Edit 2: Just added Doubling Cube which also helps demonstrate the irregularities. It will double any persisted mana which can then be used to pay for mana. So its quite broken at the moment.
-Marc
-

moomarc - Pixel Commander
- Posts: 2091
- Joined: 04 Jun 2010, 15:22
- Location: Johannesburg, South Africa
- Has thanked: 371 times
- Been thanked: 372 times
Re: UI Improvements, Round 2: Match UI
by friarsol » 17 Dec 2011, 19:51
Sounds like the observer isn't being called on an undo/in between turns+phases. I'll try to see what's going on, but I didn't write any of that part. I was mostly just hooking up the button actions with a paying mana in certain cases.
Edit: Oh nevermind, just needed a few more updateObservers from the stuff I wrote last week.
Edit: Oh nevermind, just needed a few more updateObservers from the stuff I wrote last week.
- friarsol
- Global Moderator
- Posts: 7593
- Joined: 15 May 2010, 04:20
- Has thanked: 243 times
- Been thanked: 965 times
Re: UI Improvements, Round 2: Match UI
by friarsol » 17 Dec 2011, 20:11
Nope. That wasn't it. It looks like the FloatingTotals math isn't correct in relation to Unpaying, and it seems that those Count$ManaPool functions try to use that same function. I should be able to fix this up. Once everything is working smoothly enough, I'll probably trash the whole thing to not be a Card anymore along with cleaning up all the oddities like this.friarsol wrote:Sounds like the observer isn't being called on an undo/in between turns+phases. I'll try to see what's going on, but I didn't write any of that part. I was mostly just hooking up the button actions with a paying mana in certain cases.
Edit: Oh nevermind, just needed a few more updateObservers from the stuff I wrote last week.
- friarsol
- Global Moderator
- Posts: 7593
- Joined: 15 May 2010, 04:20
- Has thanked: 243 times
- Been thanked: 965 times
Re: UI Improvements, Round 2: Match UI
by Rob Cashwalker » 17 Dec 2011, 21:00
I just quit between two games, but the battlefield stayed up and I could cycle through the human phases. Couldn't close the window, had to use the stop button in eclipse to terminate the app.
The Force will be with you, Always.
-

Rob Cashwalker - Programmer
- Posts: 2167
- Joined: 09 Sep 2008, 15:09
- Location: New York
- Has thanked: 5 times
- Been thanked: 40 times
Re: UI Improvements, Round 2: Match UI
by Sloth » 17 Dec 2011, 21:15
When i tried getting moomarc's Birthing Pod to work (which was a piece of cake by the way), i noticed that phyrexian mana is not displayed on cards on the battlefield. Furthermore i can't pay phyrexian mana with life points (if i remember correctly clicking on my own lifepoints should do the trick). Or was there another way?
-

Sloth - Programmer
- Posts: 3498
- Joined: 23 Jun 2009, 19:40
- Has thanked: 125 times
- Been thanked: 507 times
Re: UI Improvements, Round 2: Match UI
by friarsol » 17 Dec 2011, 21:27
It works, the Phyrexian Mana needs to be first.Sloth wrote:When i tried getting moomarc's Birthing Pod to work (which was a piece of cake by the way), i noticed that phyrexian mana is not displayed on cards on the battlefield. Furthermore i can't pay phyrexian mana with life points (if i remember correctly clicking on my own lifepoints should do the trick). Or was there another way?
ManaCost:3 PG
- friarsol
- Global Moderator
- Posts: 7593
- Joined: 15 May 2010, 04:20
- Has thanked: 243 times
- Been thanked: 965 times
Re: UI Improvements, Round 2: Match UI
by friarsol » 17 Dec 2011, 21:51
Just played my first Quest Challenge in the new UI. And uhh.. Well, the AI started with a Bird Pet and Plant Wall instead of whatever he was supposed to start with. I'm playing vs. the first Black challenge dude.
Edit: In game 2, Infernal Genesis started on the field.
Edit: In game 2, Infernal Genesis started on the field.
- friarsol
- Global Moderator
- Posts: 7593
- Joined: 15 May 2010, 04:20
- Has thanked: 243 times
- Been thanked: 965 times
Re: UI Improvements, Round 2: Match UI
by moomarc » 18 Dec 2011, 10:56
Working perfectly now. Thanks.friarsol wrote:Nope. That wasn't it. It looks like the FloatingTotals math isn't correct in relation to Unpaying, and it seems that those Count$ManaPool functions try to use that same function. I should be able to fix this up. Once everything is working smoothly enough, I'll probably trash the whole thing to not be a Card anymore along with cleaning up all the oddities like this.friarsol wrote:Sounds like the observer isn't being called on an undo/in between turns+phases. I'll try to see what's going on, but I didn't write any of that part. I was mostly just hooking up the button actions with a paying mana in certain cases.
Edit: Oh nevermind, just needed a few more updateObservers from the stuff I wrote last week.
On a side note, while testing with Glissa Sunseeker, Omnath, Locus of mana an two Doubling Cubes, Omnath gets broken quickly.
Glissa still doesn't add more than the first two colors in her calculations though (but I know that's not what you were trying to fix so is neither here nor there)
-Marc
-

moomarc - Pixel Commander
- Posts: 2091
- Joined: 04 Jun 2010, 15:22
- Location: Johannesburg, South Africa
- Has thanked: 371 times
- Been thanked: 372 times
Re: UI Improvements, Round 2: Match UI
by friarsol » 22 Dec 2011, 16:40
I have some code that will be ready soon that removes the Mana Pool from being a Card (and appearing on the battlefield). Is the old battlefield UI accessible at all anymore? If it isn't I'll check this in, as I won't need to worry about it being functional (since the ManaPool not being a card would make the game unplayable in the old UI). It's nice to actually have that space not taken up by the Mana Pool anymore.
- friarsol
- Global Moderator
- Posts: 7593
- Joined: 15 May 2010, 04:20
- Has thanked: 243 times
- Been thanked: 965 times
Re: UI Improvements, Round 2: Match UI
by Chris H. » 22 Dec 2011, 23:55
`friarsol wrote:I have some code that will be ready soon that removes the Mana Pool from being a Card (and appearing on the battlefield). Is the old battlefield UI accessible at all anymore? If it isn't I'll check this in, as I won't need to worry about it being functional (since the ManaPool not being a card would make the game unplayable in the old UI). It's nice to actually have that space not taken up by the Mana Pool anymore.
Settings has an option to turn on the old UI and I tested it. I still get the new UI though so I guess that it is not an active setting with the proper hook ups.
I can only speak for myself, I would not mind loosing both the old LAFs and the old UI. I do suspect that a few people might not agree with me on this matter.
-

Chris H. - Forge Moderator
- Posts: 6320
- Joined: 04 Nov 2008, 12:11
- Location: Mac OS X Yosemite
- Has thanked: 644 times
- Been thanked: 643 times
Re: UI Improvements, Round 2: Match UI
by goonjamin » 23 Dec 2011, 01:07
+1Chris H. wrote:I can only speak for myself, I would not mind loosing both the old LAFs and the old UI.
I can't wait to not have to see the mana pool card
Re: UI Improvements, Round 2: Match UI
by slapshot5 » 23 Dec 2011, 02:51
My feeling is that as long as we're making big changes, let's make them. Remove the setting and state v1.1.8 is the last release that supports the old UI.
I know some users aren't and won't be crazy about the new UI, but we've got much better things to do than support 2 UIs. And I don't think anyone was really crazy about doing fixes for the old UI anyway.
-slapshot5
I know some users aren't and won't be crazy about the new UI, but we've got much better things to do than support 2 UIs. And I don't think anyone was really crazy about doing fixes for the old UI anyway.
-slapshot5
- slapshot5
- Programmer
- Posts: 1391
- Joined: 03 Jan 2010, 17:47
- Location: Mac OS X
- Has thanked: 25 times
- Been thanked: 68 times
Re: UI Improvements, Round 2: Match UI
by friarsol » 23 Dec 2011, 02:57
Yea I think that's the main issue. We're the ones that need to support it, and we barely were supporting it to begin with. If we're going to make strides forward with the UI, some sacrifices need to be made. I think the new UI looks much better, and the several new features corresponding to it aren't available in the old UI; this makes retiring the old UI necessary.
- friarsol
- Global Moderator
- Posts: 7593
- Joined: 15 May 2010, 04:20
- Has thanked: 243 times
- Been thanked: 965 times
Who is online
Users browsing this forum: No registered users and 16 guests