///<reference path="../ContentAtom.ts"/>
///<reference path="../ContentNounSimple.ts"/>
/**
 * This atom should be used in place of the default atom when handling Fucking.
 */
class ContentAtomFucking extends ContentAtom {
    /**
     * Only one of the following markers appears at once. They mean the style of what is going on.
     */
    public static GENTLE = new ContentNounSimple("GENTLE");
    public static ROUGH = new ContentNounSimple("ROUGH");

    /**
     * These signify a state. If Pentrating and Removing appear together he probably insta-cummed and is already retreating in shame.
     */
    public static PENETRATING = new ContentNounSimple("PENETRATING");
    public static REMOVING = new ContentNounSimple("REMOVING");

    /**
     * These signify a state. They'll usually appear all at once, but on rare cases some NPCs will have prolonged CUM_START before CUMMING, or last multiple turns on CUMMING, etc.
     */
    public static CUM_START = new ContentNounSimple("CUM_START");
    public static CUMMING = new ContentNounSimple("CUMMING");
    public static CUM_END = new ContentNounSimple("CUM_END");

    /**
     * These signify the style if any of the above CUMMING is happening. Probably never going to show both at once, since atoms deal with a single stick/hole combo, but I guess it's technically possible for some rare enemies?
     */
    public static CUM_INSIDE = new ContentNounSimple("CUM_INSIDE");
    public static CUM_OUTSIDE = new ContentNounSimple("CUM_OUTSIDE");

    /**
     * These signify the current stance of the Fucked. In general you can assume that if standing, Vagina/Mouth = Fucker is in front, otherwise is behind, etc. We don't handle the fucker position separatedly. Maybe we should? No idea.
     */
    public static STANDING = new ContentNounSimple("STANDING");
    public static ALLFOURS = new ContentNounSimple("ALLFOURS");

    public fucked : any;
    public fucker : any;
    public hole : any;
    public stick : any;
    public markers : ContentAtom = new ContentAtom();

    constructor () {
        super();
    }

    public setFucked (fucked : any) {
        this.fucked = fucked;
        return this;
    }

    public setFucker (fucker : any) {
        this.fucker = fucker;
        return this;
    }

    public setHole (hole : any) {
        this.hole = hole;
        return this;
    }

    public setStick (stick : any) {
        this.stick = stick;
        return this;
    }

    public addMarker (...markers : Array<any>) {
        this.markers.addNoun(...markers);
        return this;
    }

    public compareAgainst (other : ContentAtom) {
        if (other instanceof ContentAtomFucking) {
            return (
                ContentAtom.compareNoun(this.fucked, other.fucked) &&
                ContentAtom.compareNoun(this.fucker, other.fucker) &&
                ContentAtom.compareNoun(this.hole, other.hole) &&
                ContentAtom.compareNoun(this.stick, other.stick) &&
                this.markers.compareAgainst(other.markers)
            );
        }
        return false;
    }

    public getAtomPriority () {
        return (
            ContentAtom.weightNoun(this.fucked) +
            ContentAtom.weightNoun(this.fucker) +
            ContentAtom.weightNoun(this.hole) +
            ContentAtom.weightNoun(this.stick) +
            this.markers.getAtomPriority()
        );
    }
}