def check_triggered(card):
    triggered = 0
    triggered_2 = 0
    for line in card.text_lines:
        if 'when ' + utils.this_marker + ' enters the battlefield' in line.text:
            triggered += 1
        if 'when ' + utils.this_marker + ' leaves the battlefield' in line.text:
            triggered += 1
        if 'when ' + utils.this_marker + ' dies' in line.text:
            triggered += 1
        elif 'at the beginning' == line.text[:16] or 'when' == line.text[:4]:
            if 'from your graveyard' in line.text:
                triggered_2 += 1
            elif 'in your graveyard' in line.text:
                triggered_2 += 1
            elif 'if ' + utils.this_marker + ' is suspended' in line.text:
                triggered_2 += 1
            elif 'if that card is exiled' in line.text or 'if ' + utils.this_marker + ' is exiled' in line.text:
                triggered_2 += 1
            elif 'when the creature ' + utils.this_marker + ' haunts' in line.text:
                triggered_2 += 1
            elif 'when you cycle ' + utils.this_marker in line.text or 'when you cast ' + utils.this_marker in line.text:
                triggered_2 += 1
            elif 'this turn' in line.text or 'this combat' in line.text or 'your next upkeep' in line.text:
                triggered_2 += 1
            elif 'from your library' in line.text:
                triggered_2 += 1
            elif 'you discard ' + utils.this_marker in line.text or 'you to discard ' + utils.this_marker in line.text:
                triggered_2 += 1
            else:
                triggered += 1
            
    if triggered > 0:
        return list_only(card.types, ['creature', 'land', 'artifact', 'enchantment', 'planeswalker', 'tribal'])
    elif triggered_2:
        return True
    else:
        return None
dataset/ETHPy150Open billzorn/mtgencode/scripts/mtg_validate.py/check_triggered/original