MagicStack.add
Post MTG Forge Related Programming Questions Here
	Moderators: timmermac, Agetian, friarsol, Blacksmith, KrazyTheFox, CCGHQ Admins
			4 posts
			 • Page 1 of 1
		
	
MagicStack.add
 by Max mtg » 28 May 2013, 11:29
by Max mtg » 28 May 2013, 11:29 
There is such code at the end of MagicStack.add(SpellAbility sa)
			- Code: Select all
- if (!this.getSimultaneousStackEntryList().isEmpty()) {
 game.getPhaseHandler().passPriority();
 }
Single class for single responsibility.
		- Max mtg
- Programmer
- Posts: 1997
- Joined: 02 Jul 2011, 14:26
- Has thanked: 173 times
- Been thanked: 334 times
Re: MagicStack.add
 by friarsol » 28 May 2013, 12:03
by friarsol » 28 May 2013, 12:03 
I believe simultaneousStackEntryList is keeping track of what triggers are hitting the stack at the same time for ordering (or at least was many a moon ago). I'm not sure why you would be passing priority if that were empty.
			
		- friarsol
- Global Moderator
- Posts: 7593
- Joined: 15 May 2010, 04:20
- Has thanked: 243 times
- Been thanked: 965 times
Re: MagicStack.add
 by Max mtg » 28 May 2013, 13:10
by Max mtg » 28 May 2013, 13:10 
Well, there is no longer passPriority method... so I cannot sustain this code. 
If there's a repro when current code won't work, please write it here or file as a bugreport.
			If there's a repro when current code won't work, please write it here or file as a bugreport.
Single class for single responsibility.
		- Max mtg
- Programmer
- Posts: 1997
- Joined: 02 Jul 2011, 14:26
- Has thanked: 173 times
- Been thanked: 334 times
Re: MagicStack.add
 by Max mtg » 28 May 2013, 15:23
by Max mtg » 28 May 2013, 15:23 
Found a repro : cast Bloodbraid Elf.
But it should not pass priority in that case - when Cascade trigger is added to stack
I commited r21786, seems to work as it should
			But it should not pass priority in that case - when Cascade trigger is added to stack
I commited r21786, seems to work as it should
Single class for single responsibility.
		- Max mtg
- Programmer
- Posts: 1997
- Joined: 02 Jul 2011, 14:26
- Has thanked: 173 times
- Been thanked: 334 times
			4 posts
			 • Page 1 of 1
		
	
Who is online
Users browsing this forum: No registered users and 48 guests
