Card card = game.getCard(source.getSourceId());
if (card != null) {
Permanent hauntedCreature = game.getPermanent(targetPointer.getFirst(game, source));
// haunting card will only be moved to exile, if
if (hauntedCreature != null) {
if (card.moveToExile(source.getSourceId(), "Haunting", source.getSourceId(), game)) {
// remember the haunted creature
String key = new StringBuilder("Haunting_").append(source.getSourceId().toString()).append("_").append(card.getZoneChangeCounter()).toString();
game.getState().setValue(key, new FixedTarget(targetPointer.getFirst(game, source)));
card.addInfo("hauntinfo", new StringBuilder("Haunting ").append(hauntedCreature.getLogName()).toString());
hauntedCreature.addInfo("hauntinfo", new StringBuilder("Haunted by ").append(card.getLogName()).toString());