package com.ghost.technic.server.card.effect.impl;

import com.ghost.technic.server.Player;
import com.ghost.technic.server.card.effect.ConstantAbility;
import com.ghost.technic.server.game.GameState;
import lombok.RequiredArgsConstructor;
import lombok.extern.slf4j.Slf4j;

@Slf4j
@RequiredArgsConstructor
public class MurmookEffect implements ConstantAbility {

    private final Player controller;

    @Override
    public void apply() {
        log.info("Murmook effect active: opponent's keys cost +1");
    }

    @Override
    public void remove() {
        log.info("Murmook effect removed.");
    }

    @Override
    public int keyCostModifier(Player forPlayer, GameState state) {
        Player opponent = state.getOpponentOf(controller);
        return forPlayer.equals(opponent) ? 1 : 0;
    }
}
