forked from External/mage
xenodron mentionned that one of the use of setSourceId is to more easily find the Event that use non-standard sourceId. So reverting the change made in a previous commit. It was a non-functional change meant to ease new BatchEvent sharing sourceId, but I'll use setSourceId instead there.
18 lines
502 B
Java
18 lines
502 B
Java
package mage.game.events;
|
|
|
|
import mage.abilities.Ability;
|
|
import mage.game.permanent.Permanent;
|
|
|
|
import java.util.UUID;
|
|
|
|
/**
|
|
* @author JayDi85
|
|
*/
|
|
public class AttachEvent extends GameEvent {
|
|
|
|
// TODO: investigate why source is provided but not used at all?
|
|
public AttachEvent(UUID targetPermanentId, Permanent attachment, Ability source) {
|
|
super(GameEvent.EventType.ATTACH, targetPermanentId, null, attachment.getControllerId());
|
|
this.setSourceId(attachment.getId());
|
|
}
|
|
}
|