Page 1 of 1

Interaction of deathtouch and trample

PostPosted: 15 Dec 2009, 17:56
by Incantus
Hey rules lawyers, I'm a bit stuck implementing the new combat damage rules. How do deathtouch and trample interact when you are checking the damage assignment of one attqcker with several blockers. For example, imagine an 8/8 with deathtouch and trample attacking, and being blocked by a 3/3 (call it A), 2/2 (B), and a 1/1(C). You order them in that way: A, B, C. Which of the following are valid damage assignments (and i it is invalid, why)?

A: 3, B: 2, C: 1
A: 3, B: 3, C: 0
A: 1, B: 2, C: 3
A: 1, B: 1, C: 1

Re: Interaction of deathtouch and trample

PostPosted: 15 Dec 2009, 18:36
by Arch
You did mean a 6/6 dt,trample right?

A: 3, B: 2, C: 1
Yes.

A: 3, B: 3, C: 0
Yes.

A: 1, B: 2, C: 3
Yes.

A: 1, B: 1, C: 1
No. You must assign damage equal to your power. Deathtouch only allows you to "divided that damage as he or she chooses". It doesn't allow you to deal less damage.

Re: Interaction of deathtouch and trample

PostPosted: 15 Dec 2009, 18:38
by Marek14
Incantus wrote:Hey rules lawyers, I'm a bit stuck implementing the new combat damage rules. How do deathtouch and trample interact when you are checking the damage assignment of one attqcker with several blockers. For example, imagine an 8/8 with deathtouch and trample attacking, and being blocked by a 3/3 (call it A), 2/2 (B), and a 1/1(C). You order them in that way: A, B, C. Which of the following are valid damage assignments (and i it is invalid, why)?

A: 3, B: 2, C: 1
A: 3, B: 3, C: 0
A: 1, B: 2, C: 3
A: 1, B: 1, C: 1
Well, if I assume that you assign the 2 leftover damage to player, only the first line is valid.

Deathtouch allows you to divide the damage as you want, BUT that doesn't override rule for trample damage, which says that ALL blockers must be assigned at least lethal damage before any of it can be assigned to the defending player or planeswalker.

Re: Interaction of deathtouch and trample

PostPosted: 16 Dec 2009, 03:21
by Incantus
OK, I think I understand. Going back to my example (8/8 with trample and deathtouch blocked by a 3/3 (A), 2/2 (B), and 1/1 (C), blocked in that order), the following assignment is valid:

A: 1
B: 1
C: 6

although no damage will be trampled. One way to get trample damage is to assign damage as follows (with 2 damage assigned to defending player):

A: 3
B: 2
1: 1

Is this correct? If so, then I believe I have a succinct function to determine whether a multiple creature damage assignment is correct (taking into account deathtouch and trample).

Code: Select all
def check_assignment(attacker, blockers, assignment, trample=False, deathtouch=False):
    total = attacker.combatDamage()
    valid_lethal = True
    for blocker in blockers:
        dmg = assignment[blocker]
        total -= dmg
        if (dmg < blocker.lethalDamage() and total > 0):
            valid_lethal = False
    return ((deathtouch or valid_lethal) and
            ((trample and valid_lethal and total > 0) or (total == 0))
(where blockers is the list of blockers ordered by the attacking player, and assignment is a dictionary mapping each blocker to the amount of damage it is assigned)

This seems to handle all possible cases that I can think of.

Re: Interaction of deathtouch and trample

PostPosted: 16 Dec 2009, 07:18
by Marek14
Incantus wrote:OK, I think I understand. Going back to my example (8/8 with trample and deathtouch blocked by a 3/3 (A), 2/2 (B), and 1/1 (C), blocked in that order), the following assignment is valid:

A: 1
B: 1
C: 6

although no damage will be trampled. One way to get trample damage is to assign damage as follows (with 2 damage assigned to defending player):

A: 3
B: 2
1: 1

Is this correct? If so, then I believe I have a succinct function to determine whether a multiple creature damage assignment is correct (taking into account deathtouch and trample).

Code: Select all
def check_assignment(attacker, blockers, assignment, trample=False, deathtouch=False):
    total = attacker.combatDamage()
    valid_lethal = True
    for blocker in blockers:
        dmg = assignment[blocker]
        total -= dmg
        if (dmg < blocker.lethalDamage() and total > 0):
            valid_lethal = False
    return ((deathtouch or valid_lethal) and
            ((trample and valid_lethal and total > 0) or (total == 0))
This seems to handle all possible cases that I can think of.
Hmm, seems to.

Re: Interaction of deathtouch and trample

PostPosted: 24 Dec 2009, 08:52
by rocketnia
Have you considered the case when a blocker is being assigned damage from multiple attackers? Unless lethalDamage() is really clever, I think your algorithm fails there; it'll call a trampler's damage assignment illegal even though some other attacker is contributing the missing damage. It's probably a bit more accurate to check every attacker's damage assignments all at once.

Re: Interaction of deathtouch and trample

PostPosted: 09 Jan 2010, 14:21
by Incantus
Hi Rocketnia,

You are correct that this doesn't account for a blocker blocking multiple attackers. That isn't really supported by incantus yet, but it will definitely complicate this algorithm. If you have any insight I'd definitely like to hear it. Thanks!