code:
package classes.Scenes.Seasonal {

	import classes.*;
	import classes.GlobalFlags.*;
	import classes.display.SpriteDb;
	import classes.internals.*;

	public class XmasElf extends BaseContent
	{
		public function XmasElf() {}

		public function xmasBitchEncounter():void
		{
			clearOutput();
			spriteSelect(SpriteDb.s_christmas_elf);
			outputText("Your sleep is disturbed by something repeatedly smacking into your side.  Groggily at first, you grumble and throw back your blanket.  Then you remember where you are, and snap to full wakefulness.  You launch onto your feet, bring up your fists, and stare bewildered at the sight in front of you.\n\n");

			outputText("Standing there, innocent as can be, ");
			if (flags[kFLAGS.PC_ENCOUNTERED_CHRISTMAS_ELF_BEFORE] == 0) outputText("is an elf.  She can't be more than four and a half feet tall, and though she has fairly womanly hips, her chest is nothing to speak of.  Her clothing is strange – a red two piece lined with some kind of white fur.  She has typically pointed ears, blond hair, and a red fur-lined cap topped with a white puffball. She's holding a large box in front of her and looking at you expectantly as you stare, dumbfounded.\n\n");
			else outputText("is the same elf you met last year.  She can't be more than four and a half feet tall, and though she has fairly womanly hips, her chest is nothing to speak of.  Her clothing is strange – a red two piece lined with some kind of white fur.  She has typically pointed ears, blond hair, and a red fur-lined cap topped with a white puffball. She's holding a large box in front of her and looking at you expectantly as you stare, dumbfounded.\n\n");

			outputText("The elf says, \"Hiya " + player.short + "!  I brought you a");
			if (flags[kFLAGS.PC_ENCOUNTERED_CHRISTMAS_ELF_BEFORE] > 0) outputText("nother");
			outputText(" present, straight from the big man himself!\"\n\n");

			if (flags[kFLAGS.PC_ENCOUNTERED_CHRISTMAS_ELF_BEFORE] > 0)
			{
				outputText("Confused by her sudden re-appearance, you dumbly ask if you'll be getting the same thing as last year.\n\n");

				outputText("She giggles, \"Oh silly, that would spoil the surprise, wouldn't it?  We've got EVERYONE on our list, even ");
				if (flags[kFLAGS.KELT_BREAK_LEVEL] < 4) outputText("Kelt, though he's getting coal AGAIN");
				else outputText("Kelly, though I think she's getting another big fat dildo");
				outputText(".  You'll get what you're supposed to get!\"\n\n");
			}
			else
			{
				outputText("Confused by her appearance and the fact that she already knows you by name, you dumbly ask how she can possibly know who you are.\n\n");

				outputText("She giggles, \"Oh silly, don't you know what time of year it is?  We've got EVERYONE on our list, even ");
				if (flags[kFLAGS.KELT_BREAK_LEVEL] < 4) outputText("Kelt, though he's getting coal this year");
				else outputText("Kelly, though I think she's getting a big fat dildo this year");
				outputText(".\"\n\n");
			}
			awardAchievement("Naughty or Nice", kACHIEVEMENTS.HOLIDAY_CHRISTMAS_I);
			outputText("You wonder out loud, \"So this... present is mine?\"\n\n");
			menu();
			addButton(0, "OpenPresent", openXmasPresent);
			addDisabledButton(1, "Unwrap Elf");
			addButton(4, "Decline", declineXmasPresent);

			if (!player.isPureEnough(90) || game.jojoScene.isJojoCorrupted() || player.hasStatusEffect(StatusEffects.Exgartuan) || game.amilyScene.amilyCorrupt() || flags[kFLAGS.SOPHIE_DISABLED_FOREVER] > 0 || flags[kFLAGS.SOPHIE_BIMBO] > 0 || flags[kFLAGS.NIAMH_STATUS] > 0)
			{
				outputText("She nods, bouncing up and down in excitement and flushing slightly, \"Yup, just tear the lid off and get your gift!\"\n\n");
				if (flags[kFLAGS.PC_ENCOUNTERED_CHRISTMAS_ELF_BEFORE] > 0) outputText("Here we go again...\n\n");
				//[Open Present] [Decline]
				addDisabledButton(1, "Unwrap Elf", "This scene is not available for naughty kids.");
				return;
			}
			if (player.isGenderless())
			{
				outputText("She nods, bouncing up in down in excitement, \"Yup!  Just open it up!  Are you ready?\"\n\n");
				//[Open Present] [Decline]
				addDisabledButton(1, "Unwrap Elf", "This scene requires you to have genitals.");
				return;
			}
			outputText("She nods, bouncing up in down in excitement, \"Yup!  You can unwrap it or unwrap me.  What'll it be?\"\n\n");
			//[Open Present] [Unwrap Elf] [Decline]
			addButton(1, "Unwrap Elf", unwrapElfyPresent);
		}

		//[Decline]
		public function declineXmasPresent():void {
			spriteSelect(SpriteDb.s_christmas_elf);
			clearOutput();
			outputText("You shake your head 'no', and inform the elf that you'll have nothing to do with her 'gifts' or 'surprises'.  She looks on the verge of tears as she whines, \"I'm going to get reamed for this!\"\n\n");

			outputText("Before you can react, she sprints off into the darkness.");
			flags[kFLAGS.PC_ENCOUNTERED_CHRISTMAS_ELF_BEFORE] = date.fullYear;
			doNext(playerMenu);
		}
		//[Open Present]
		public function openXmasPresent():void {
			spriteSelect(SpriteDb.s_christmas_elf);
			clearOutput();
			outputText("You easily rip through the ribbons holding the box together and pull off the top.   You gasp in ");
			if (!player.isPureEnough(90) || game.jojoScene.isJojoCorrupted() || player.hasStatusEffect(StatusEffects.Exgartuan) || game.amilyScene.amilyCorrupt() || flags[kFLAGS.SOPHIE_DISABLED_FOREVER] > 0 || flags[kFLAGS.SOPHIE_BIMBO] > 0 || flags[kFLAGS.NIAMH_STATUS] > 0) {
				//[Bad Present]
				outputText("shock at the box's contents – a nine inch cock with damn near a dozen buzzing, elliptical devices taped to it.  A pair of coal lumps rattles around underneath it, positioned as if they were the dick's testicles.\n\n");

				outputText("Before you can utter a single word of confusion or protest, the elf moans and the cock erupts, spurting a rope of cum into your hair.  The next blast takes you across the nose, then on your lips, then your chin, and finally onto your " + player.allBreastsDescript() + ".  Shocked and dripping, you stand dumbfounded as the elf plants a kiss on your lips, tears off the box, and runs away with her cock flopping and buzzing in time with each step.  There's no way to catch her in this darkness.\n\n");

				outputText("The empty 'present' is on the ground with the coal still inside.  You wonder if the coal has any special effect. Everything else in this place does.  In the distance you can hear sleigh bells, and you know it's going to be hard to sleep with all that racket on top of the threat of more intruders...\n\n");
				inventory.takeItem(consumables.COAL___, playerMenu);
				flags[kFLAGS.PC_ENCOUNTERED_CHRISTMAS_ELF_BEFORE] = date.fullYear;
			}
			else if (player.cor <= 33) {
				//Great present!
				outputText("surprise at the box's contents - there's a careful arranged set of equipment here, made from woven spider-silk!  Somebody must think you're pretty good.\n\n");
				if (player.inte > player.str) inventory.takeItem(armors.SS_ROBE, playerMenu);
				else inventory.takeItem(armors.SSARMOR, playerMenu);
				flags[kFLAGS.PC_ENCOUNTERED_CHRISTMAS_ELF_BEFORE] = date.fullYear;
			}
			else if (player.cor < 60) {
				//[Good present]
				outputText("surprise at the box's contents – there's a vial labeled gro+.  It looks like it's going to be a 'big' Christmas this year...\n\n");
				inventory.takeItem(consumables.GROPLUS, playerMenu);
				flags[kFLAGS.PC_ENCOUNTERED_CHRISTMAS_ELF_BEFORE] = date.fullYear;
			}
			else {
				//[Mediocre Present]
				outputText("surprise at the box's contents – there is a single vial of untainted succubi's delight packed inside.  It's going to be a white Christmas after all...\n\n");
				inventory.takeItem(consumables.PSDELIT, playerMenu);
				flags[kFLAGS.PC_ENCOUNTERED_CHRISTMAS_ELF_BEFORE] = date.fullYear;
			}
		}

		//[Unwrap the elf]
		public function unwrapElfyPresent():void {
			spriteSelect(SpriteDb.s_christmas_elf);
			clearOutput();
			outputText("The elf tosses the present to the side and saunters up to you, her hips swaying sensually.  She ");
			if (player.tallness > 60) outputText("reaches up and presses herself against you seductively, caressing your body.");
			else outputText("cuddles up alongside, happy to have someone of similar stature to seduce.");
			outputText("  You find yourself getting more and more aroused as she teases you, sliding around your body as she feels every nook and cranny of your form.  She teases, \"If you don't unwrap a present soon enough I hear it gets taken away, and we don't want that.\"\n\n");

			outputText("You ");
			if (player.spe < 25) outputText("clumsily ");
			else outputText("easily ");
			outputText("reach around and grab hold of her fur-lined tube-top, yanking it up over her head in a smooth motion.  Her now exposed breasts are small but well formed.  Her skin is very pale, practically white, and it provides a stark contrast for her hard, cherry-red nipples.   She wiggles happily when you grab her short red skirt and undo the clasp, yanking it off to fully expose her.  The elf's sex is rosy pink in color, and her outer lips are puffy with arousal.   Her slit is completely hairless, and an intricate tattoo of a snowflake sits just above it.  You glance up at her hat and down at her stocking-clad legs and think, 'those can stay.'\n\n");

			menu();
			if (player.hasCock()) {
				addButton(0, "Male", dickXmasElfGo);
			} else {
				addDisabledButton(0, "Male", "This scene requires you to have cock.");
			}
			if (player.hasVagina()) {
				addButton(1, "Female", vagFuckXmasElf);
			} else {
				addDisabledButton(1, "Female", "This scene requires you to have vagina.");
			}
		}

		public function dickXmasElfGo():void {
			clearOutput();
			//(Dickfuck)
			if (player.cockArea(0) < 80) {
				outputText("She pushes you down onto your bedroll and whispers, \"Time to enjoy your present.\"\n\n");

				outputText("She mounts you without pretense, straddling and inserting your " + player.cockDescript(0) + " in one smooth motion.  The sudden change from cool, night air to hot, tight pussy sends shockwaves of pleasure into your skull.  You master yourself before your eyes roll the whole way back and close your mouth before you start drooling.   Her vise-like tightness is inhuman, but somehow not so tight as to be uncomfortable.   The internal muscles clench and squeeze around you with an uncommon degree of control.  She's so hot, wet, and tight that you shiver.  You start rocking underneath her, giving in completely to the pleasure of her hole.\n\n");

				outputText("You grunt, pistoning into her over and over.  She clears her throat as she's bouncing atop of you, and you look back up, suddenly reminded that there's more to the world than the cunt milking your " + player.cockDescript(0) + ".  The elf explains, \"Don't be ashamed.  We elves have magical cunts.  Once something is inside it'll feel so good that it never wants to leave.  Judging from the look on your face I don't think you ever want to leave, do you?  I'm the best present you've ever had, aren't I?  Go ahead, cum for me, show me what a great gift I am.\"\n\n");

				outputText("She's absolutely right – there's some indescribably pleasurable thing about the heat radiating into your dick that makes it feel like it's about to melt and pass into heaven.  The elf giggles and the vibrations of her laugh somehow radiate into you, and it's just too much.  You cum for your present, submitting to her pleasure as your spooge boils up into her.   It squelches wetly as it pumps into her, sounding absolutely perverse.");
				if (player.cumQ() >= 250) outputText("  The spunk quickly fills her womb and flows back out her entrance, frothing and bubbling as it drips over your " + player.hipDescript() + ".  ");
				if (player.cumQ() >= 1000) outputText("  It begins to splatter everywhere as you pour out more and more, the elf looking on with amusement as her cunt turns into a cum-spraying fountain.  ");
				outputText("\n\n");

				outputText("Once your orgasm ends the elf begins gyrating her hips again, her pussy frothing and dripping a mixed batch of creamy cum.   You don't go soft.  If anything you get even harder and more sensitive.  Brain blasting pressure squeezes up your rod from the elf's cunt as she starts bouncing again, fucking you in earnest, \"I told you my cunt was magical.  You'll never go soft inside me – your cum fuels my magic and makes you feel even better.\"\n\n");

				outputText("Aside from your " + player.cockDescript(0) + ", your body has gone completely numb from the waist down.  You glance down and see your " + player.legs() + " twitching and convulsing under the elf's assault.   She's so hot inside, it's like her pussy's candy-coated in liquid pleasure.   You fuck her harder and harder, squeezing her hips tightly and roughly fucking her magical pussy.   Somehow you're on the edge again, about to unload.  You start counting in your head, trying to resist another orgasm.  You know if you do you'll never be able stop.  You doubt you'll even be able to think.\n\n");

				outputText("Your effort at holding out totally fails – you start counting in time with each thrust, tying the numbers into the feel of the velvet cock-sleeve as it massages your " + player.cockDescript(0) + ".   The elf smiles condescendingly and taunts, \"I can see you've already lost the ability to resist the pleasure.  Just give in, and enjoy the night.  I'll be riding you 'til morning.\"\n\n");

				outputText("It's too hot, oh gods it's too hot.  You cum again, splattering her womb with more seed.  The elf's skin flushes as you pump more into her, squirting more and more into her overfull entrance.  Miraculously, you cum just as much as before, ");
				if (player.cumQ() >= 250) outputText("dumping out more and more waves of jizm until you're lying in a deep puddle of it, ");
				outputText("and somehow the orgasm lasts on even after you've emptied.   Your eyes roll back for a moment as you nearly lose consciousness.\n\n");

				outputText("You snap out of it and the elf is smirking down at you, stationary.  You feel totally numb – your " + player.cockDescript(0) + " has all of your sensation, all of your sense of touch.   On their own, your " + player.hipDescript() + " continually rise and fall, pumping into her with noisy explosions of pleasure that leave you gasping and writhing.  Every time you start to think something, the vise-like tunnel slides down you and squeezes your " + player.cockDescript(0) + ", interrupting any attempt at thought.  You give up on thinking and start drooling all over yourself, your world fading into a heaven of constant pleasure and repeated orgasms.\n\n");

				outputText("The elf fucks you relentlessly for hours, forcing you to cum over and over.  Somehow you never go dry, and each time feels better than the last.  Your bedroll is soaked with cum, your body is exhausted, and the elf FINALLY cums with a high-pitched cry of orgasmic pleasure.  Her body quakes, and you cum again, squirting messily inside her again.  The vise of pleasure on you quivers and squeezes, growing hotter by the second as the elf's orgasm drags on and on, milking you of every drop and setting you in a feedback loop of infinite pleasure.  You black out.");
			}
			else {
				//(TOO BIG)
				outputText("She pushes you down onto your bedroll and whispers, \"Time to enjoy your present.\"\n\n");
				outputText("The elf grabs ahold of your " + player.cockDescript(0) + " with both hands and cuddles against it as if it were a person, planting kisses along the edge of its " + player.cockHead() + ".  She laughs, \"Oh my, you're so big!  I almost wish I was big enough to take this bad boy.  Believe me, you haven't lived until you've been milked by an elf's cunt.\"\n\n");

				outputText("She wraps her arms around it and begins licking it, squatting down and standing up, jerking you off with her whole body.  Each time her cute bottom bumps your " + player.allBreastsDescript() + " ");
				if (player.biggestTitSize() >= 2) outputText("making them jiggle");
				else outputText("making her tight butt give a tiny jiggle");
				outputText(".  She hums happily as she works at the task, slathering it in spit, pressing her moist cunt against you.   Her warm body sliding along you feels fantastic, and feeling a bit daring, you give her a light slap on the ass-cheek.\n\n");

				outputText("The elf looks over her shoulder and laughs, \"Someone is feeling a bit naughty.  Well, I guess I'll have to help you drain out all that naughty energy.\"\n\n");

				outputText("Before you can puzzle out her meaning, she takes a big gulp of air, grabs your " + player.cockHead() + " with both hands, and presses her lips into your urethra.  She blows into it with a look of intense concentration.  You can feel your urethra filling, expanding with something, but it feels more like liquid than air, tingling as it slides deep into your shaft towards your ");
				if (player.balls > 0) outputText("balls");
				else if (player.hasSheath()) outputText("sheath");
				else outputText("body");
				outputText(".   She blows and blows, seemingly filling you with an inexhaustible supply of whatever magical substance she's forcing inside you. The tingling grows stronger and stronger, and then changes to warmth as a pleasurable heat centers itself in your midsection.\n\n");

				outputText("The magic-using elf pulls back with a knowing grin and resumes stroking you, ignoring a dribble of pink fluid that squirts from your tip.   The warmth inside builds higher and you start sweating, even in the cool night air. The uncomfortable heat churns inside you");
				if (player.balls > 0) outputText("r " + player.ballsDescriptLight());
				outputText(", a gentle pressure that builds higher and higher until you feel about to explode.  You need to cum, and you squirm in the elf's grasp, trembling and shuddering as one of her hands slips over a particularly sensitive spot. A bead of pre-cum rolls out of your " + player.cockHead() + " and starts sliding down the shaft, followed by another, and another, and another.\n\n");

				outputText("Your 'present' asks with gradually rising authority, \"Do you feel the naughtiness leaking out?  It feels good doesn't it?  Yes it does, but that's just the start.  You've got a lot of pent up naughty that needs to come out so you'll be good and see me next year.  So be a good boy and cum out all those bad thoughts for me please.\"\n\n");

				outputText("She flips around to the far side of your dick and hugs it tightly, squeezing it from base to tip in a fluid motion makes your abdominals clench with unexpected orgasm.   The first 'squirt' of cum is more like a geyser going off.  ");
				if (player.cumQ() < 500) outputText("You recoil from shooting out so much – it's far and away more than you're normally capable of.  ");
				outputText("The elf hugs it and squeezes tightly while whispering, \"Naughty naughty.\"\n\n");

				outputText("Thick ropes of your orgasmic goop splatter into her hair, and each successive blast comes out with less and less force, until you're leaking a steady stream of cum that rolls down your " + player.cockDescript(0) + " and soaks the pointy-eared woman completely.   As you release your prodigious load the scent of cinnamon fills the air, and you dumbly wonder if it's some side effect of the magic she used on you.  Regardless, cum keeps leaking out over the elf and onto you, and you eventually lose consciousness from perpetual orgasm.");
			}
			//(Go to followup for fucking scene)
			//[Next]
			doNext(xmasFuckFollowup);
			player.orgasm('Dick',true,20);
		}

		//[FEMALE SCENE]
		public function vagFuckXmasElf():void {
			clearOutput();
			outputText("She pushes you down onto your bedroll and whispers, \"Time to enjoy your present.\"\n\n");
			outputText("The elf winks and spreads her legs, revealing her obviously aroused sex to you.  She winks and you see her muscles clench.  The moist lips of her vagina slowly spread apart, and a blunt white object begins to squeeze out.  Is she laying an egg?  Wait- no, more of the object slides out and you can see now that it's tubular in shape, like some sort of sex-toy, and it's covered in a spiraling red pattern.  The object continues its slow journey downwards, roughly six inches hanging free as the elf grunts and moans, her face flushed.   She grips it with both hands and pulls it slowly.  It reminds you the soldiers in training back home the first time they tried to draw a sword – a mix of awkwardness and excitement.\n\n");

			outputText("In seconds the elf has her hands around a red-striped double-sided dildo.  It wiggles back and forth obscenely, and now that you have a good look at it, you realize the red sections are slightly raised, to better stimulate the user.  She pants and runs her hand over its pussy-slicked surface, shivering in remembered pleasure until her attention returns to you.  Her lips curl into a knowing smile and she kneels between your " + player.legs() + ", spreading them apart for better access to your " + player.vaginaDescript(0) + ".\n\n");

			outputText("The diminutive elf rubs the tip over your lower lips and " + player.clitDescript() + " a few times, getting you nice and hot before she slides it up your " + player.vaginaDescript(0) + ".  The dildo feels wonderful inside, each curved ridge sending shivers up your spine as it enters you, then stroking along your walls as you take it deeper and deeper.  The motion is interrupted once your 'present' has decided she's lodged her candy-cane-like toy deep enough inside you.  She lies back and scoots forwards, taking the rest of the striped dildo into her hairless snatch until your mounds are locked together, feminine fluids mixing on an artificial cock.");
			player.cuntChange(15,true,true,false);
			outputText("\n\n");

			outputText("The elf giggles, \"Merry Christmas,\" as she starts rocking against you.  The dildo slides through your passage, massaging your inner walls and bumping against your " + player.clitDescript() + "'s underside with each stroke.   She's got such great muscle control that she's clamped down on the double-sided dildo and started using it as a cock to fuck you!  She smirks and pounds your vulnerable " + player.vaginaDescript(0) + ", raping it with increasingly forceful strokes.  You grunt and moan as each stroke loudly smacks into your hips.  You feel yourself closing in on an orgasm, but the elf-girl relaxes her grip and simply grinds against you, taking the stimulation down a notch.\n\n");

			outputText("Determined to get off, you wiggle against her, mashing your " + player.clitDescript() + " into her own.  She squirms and cries out, actually getting off before you!  You muse that elves must have extraordinarily sensitive clitorises, but before you can act on it, you feel a sudden stirring in your loins.   The dildo is starting to spin!  You prop yourself up and watch, unbelieving as the elf's orgasmic contractions visibly contort her belly, moving more and more quickly as the spinning speeds up.  In seconds the twirling assault has placed you back on the edge of orgasm, and you're groaning and rubbing against your insensate lover for more.\n\n");

			outputText("You cum, ");
			if (player.vaginas[0].vaginalWetness == Vagina.WETNESS_SLAVERING) outputText("gushing fluids");
			else if (player.vaginas[0].vaginalWetness >= Vagina.WETNESS_SLICK) outputText("dripping fluids");
			else outputText("squishing wetly");
			outputText(" as your " + player.vaginaDescript(0) + " is drilled by the elf's double-ended dong.   It feels beyond good, like having a cock inside you that rubs against each part of your pussy over and over and over without the barest hint of mercy.  Your gasp and pant, glancing back up at the elf.  She's already recovered from her orgasm, though she has an intense look of concentration on her face while she focuses on twisting the dildo inside you.\n\n");

			outputText("\"You don't think I'd let you cum just once did you?  I'm going to drill all the naughty, sinful little thoughts from your slut-hole!\"\n\n");

			outputText("You throw your head back and let out a low shuddering moan as she spins the dildo even faster, forcing your convulsing cunt to stay locked in a mind-shattering orgasm.  Eyes crossed, you collapse onto your back and twitch, body wriggling and flopping about nervelessly as it caves in to pleasure it was never meant to handle.\n\n");

			outputText("You black out to the following words: \"Good girl.  Keep cumming, let out all those naughty thoughts.  I can't wait to see you next year!\"");
			doNext(xmasFuckFollowupFems);
			player.orgasm('Vaginal',true,10);
		}

		//MANTASTIC FOLLOWUP:
		public function xmasFuckFollowup():void {
			hideUpDown();
			clearOutput();
			outputText("You awaken in the morning, sore and exhausted, but more satisfied than you've ever felt before.  Your body feels INCREDIBLY sensitive from head to toe, but particularly on your well-used " + player.cockDescript(0) + ".  In spite of the traumatic lovemaking, you feel remarkably clear-headed.\n\n");
			outputText("Did you enjoy being able to cum so much");
			if (player.findPerk(PerkLib.ElvenBounty) >= 0) outputText(" again");
			outputText("?\n\n");
			//[Yes][No] – yes awards (+250 mls cum volume), no awards +15 intellect
			doYesNo(xmasPerkM,xmasSmart);
			//(-5 corruption)
			dynStats("cor", -5);
			//(+20 sens unless it would bring you over 80 sens, then +5 sens)
			if (player.sens + 20 > 80) dynStats("sen", 5);
			else dynStats("sen", 15);
			temp = 1001;
			flags[kFLAGS.PC_ENCOUNTERED_CHRISTMAS_ELF_BEFORE] = date.fullYear;
		}
		//FEMTASTIC FOLLOWUP:
		public function xmasFuckFollowupFems():void {
			hideUpDown();
			clearOutput();
			outputText("You awaken in the morning, sore and exhausted, but more satisfied than you've ever felt before.  Your body feels INCREDIBLY sensitive from head to toe, but particularly in your well-used " + player.vaginaDescript(0) + ".  In spite of the traumatic lovemaking, you feel remarkably clear-headed.  The dildo appears to have completely dissolved inside you, leaving behind a pinkish fluid that drips from your lips.\n\n");

			outputText("Do you think it might have done anything to you");
			if (player.findPerk(PerkLib.ElvenBounty) >= 0) outputText(" again");
			outputText("?\n\n");
			//[Yes][No] – yes awards (+15 fertility!), no awards +15 intellect
			doYesNo(xmasPerkM,xmasSmart);
			//(-5 corruption)
			dynStats("cor", -5);
			//(+20 sens unless it would bring you over 80 sens, then +5 sens)
			if (player.sens + 20 > 80) dynStats("sen", 5);
			else dynStats("sen", 15);
			temp = 2002;
			flags[kFLAGS.PC_ENCOUNTERED_CHRISTMAS_ELF_BEFORE] = date.fullYear;
		}

		public function xmasPerkM():void {
			if (player.findPerk(PerkLib.ElvenBounty) < 0) {
				if (temp == 1001) player.createPerk(PerkLib.ElvenBounty,250,0,0,0);
				else player.createPerk(PerkLib.ElvenBounty,0,15,0,0);
				outputText("New Perk Acquired - Elven Bounty!");
			}
			else {
				clearOutput();
				outputText("Perk Enhanced - Elven Bounty!");
				if (temp == 1001) {
					player.addPerkValue(PerkLib.ElvenBounty,1,250);
					outputText(" - +250mL cum production!");
				}
				else {
					player.addPerkValue(PerkLib.ElvenBounty,2,15);
					outputText(" - +15 bonus fertility!");
				}

			}
			doNext(playerMenu);
		}
		public function xmasSmart():void {
			hideUpDown();
			outputText("You nod to yourself, feeling pretty smart about your decision.");
			doNext(playerMenu);
			dynStats("int", 15);
		}
	}
}


code:
package classes.Scenes
{
	import classes.Creature;
	/**
	 * Interface for vaginal pregnancy.
	 * The class must at least implement a birth scene.
	 */
	public interface VaginalPregnancy
	{
		/**
		 * Progresses a active pregnancy. Updates should eventually lead to birth.
		 * @return true if the display output needs to be updated.
		 */
		function updateVaginalPregnancy(): Boolean;

		/**
		 * Give birth. Should output a birth scene and clean up the pregnancy.
		 */
		function vaginalBirth(): void;
	}
}

license: unknown


code:
package classes
{
import classes.GlobalFlags.kGAMECLASS;
import classes.internals.Utils;

	public class StatusEffect extends Utils
	{
		//constructor
		public function StatusEffect(stype:StatusEffectType)
		{
			this._stype = stype;
		}
		//data
		private var _stype:StatusEffectType;
		private var _host:Creature;
		public var value1:Number = 0;
		public var value2:Number = 0;
		public var value3:Number = 0;
		public var value4:Number = 0;
		public var dataStore:Object = null;
		//MEMBER FUNCTIONS
		public function get stype():StatusEffectType
		{
			return _stype;
		}
		public function get host():Creature
		{
			return _host;
		}
		/**
		 * Returns null if host is not a Player
		 */
		public function get playerHost():Player {
			return _host as Player;
		}

		public function toString():String
		{
			return "["+_stype+","+value1+","+value2+","+value3+","+value4+"]";
		}
		// ==============================
		// EVENTS - to be overridden in subclasses
		// ===============================

		/**
		 * Called when the effect is applied to the creature, after adding to its list of effects.
		 */
		public function onAttach():void {
			// do nothing
		}
		/**
		 * Called when the effect is removed from the creature, after removing from its list of effects.
		 */
		public function onRemove():void {
			// do nothing
		}
		/**
		 * Called after combat in player.clearStatuses()
		 */
		public function onCombatEnd():void {
			// do nothing
		}
		/**
		 * Called during combat in combatStatusesUpdate() for player, then for monster
		 */
		public function onCombatRound():void {
			// do nothing
		}

        /**
         * Called immediately after all characters take their turns.
         */
        public function onTurnEnd():void{}

        public function remove(/*fireEvent:Boolean = true*/):void {
			if (_host == null) return;
			_host.removeStatusEffectInstance(this/*,fireEvent*/);
			_host = null;
		}
		public function removedFromHostList(fireEvent:Boolean):void {
			if (fireEvent) onRemove();
			_host = null;
		}
		public function addedToHostList(host:Creature,fireEvent:Boolean):void {
			_host = host;
			if (fireEvent) onAttach();
		}
		public function attach(host:Creature/*,fireEvent:Boolean = true*/):void {
			if (_host == host) return;
			if (_host != null) remove();
			_host = host;
			host.addStatusEffect(this/*,fireEvent*/);
		}
        public var bonusStats:BonusDerivedStats = new BonusDerivedStats();

        public function boostsCriticalChance(id:String,value:*, mult:Boolean = false):void{
            bonusStats.boostStat(BonusDerivedStats.critC,value,mult,id);
        }

        public function boostsMaxHP(id:String,value:*, mult:Boolean = false):void{
            bonusStats.boostStat(BonusDerivedStats.maxHealth,value,mult,id);
        }

        public function boostsAccuracy(id:String,value:*, mult:Boolean = false):void{
            bonusStats.boostStat(BonusDerivedStats.accuracy,value,mult,id);
        }

        public function boostsPhysicalDamage(id:String,value:*, mult:Boolean = false):void{
            bonusStats.boostStat(BonusDerivedStats.physDmg,value,mult,id);
        }
        public function boostsDamageTaken(id:String,value:*, mult:Boolean = false):void{
            bonusStats.boostStat(BonusDerivedStats.damageMulti,value,mult,id);
        }

		protected static function register(id:String,statusEffectClass:Class,arity:int=0):StatusEffectType {
			return new StatusEffectType(id,statusEffectClass || StatusEffect,arity);
		}
		protected static function get game():CoC {
			return kGAMECLASS;
		}
	}
}


code:
/**
 * Created by aimozg on 31.01.14.
 */
package classes
{
	import flash.utils.Dictionary;

	public class StatusEffectType
	{
			private static var STATUSAFFECT_LIBRARY:Dictionary = new Dictionary();
		private var arity:int;

			public static function lookupStatusEffect(id:String):StatusEffectType{
				return STATUSAFFECT_LIBRARY[id];
			}

			public static function getStatusEffectLibrary():Dictionary
			{
				return STATUSAFFECT_LIBRARY;
			}

			private var _id:String;

			/**
			 * Unique perk id, should be kept in future game versions
			 */
			public function get id():String
			{
				return _id;
			}

		private var _secClazz:Class;

		/**
		 * @param id Unique status effect id; should persist between game version
		 * @param clazz Class to create instances of
		 * @param arity Class constructor arity: 0: new clazz(), 1: new clazz(thiz:StatusEffectType)
		 */
			public function StatusEffectType(id:String,clazz:Class,arity:int)
			{
				this._id = id;
				this.arity = arity;
				this._secClazz = clazz;
				if (STATUSAFFECT_LIBRARY[id] != null) {
					CoC_Settings.error("Duplicate status affect "+id);
				}
				STATUSAFFECT_LIBRARY[id] = this;
				if (!(arity >=0 && arity <= 1)) throw new Error("Unsupported status effect '"+id+"' constructor arity "+arity);
			}

		public function create(value1:Number, value2:Number, value3:Number, value4:Number):StatusEffect {
			var sec:StatusEffect;
			if (arity == 0) sec = new _secClazz();
			else if (arity == 1) sec = new _secClazz(this);
			sec.value1 = value1;
			sec.value2 = value2;
			sec.value3 = value3;
			sec.value4 = value4;
			return sec;
		}

			public function toString():String
			{
				return "\""+_id+"\"";
			}
		}
}


code:
package classes
{
import classes.StatusEffects.Combat.*;
import classes.StatusEffects.*;

	/**
	 * IMPORTANT NOTE:
	 * You can rename the constants BUT NOT the string ids (they are stored in saves).
	 */
	public class StatusEffects
	{
		// Non-combat player perks
		public static const AllNaturalOnaholeUsed:StatusEffectType = mk("all-natural onahole used");
		public static const AndysSmoke:StatusEffectType = mk("Andy's Smoke"); //v1: Hours; v2: Speed; v3: Intelligence
		public static const AteEgg:StatusEffectType = mk("ateEgg");
		public static const AnemoneArousal:StatusEffectType = mk("Anemone Arousal");
		public static const BimboChampagne:StatusEffectType = mk("Bimbo Champagne");
		public static const Birthed:StatusEffectType = mk("Birthed");
		public static const BirthedImps:StatusEffectType = mk("Birthed Imps");
		public static const BlackCatBeer:StatusEffectType = mk("Black Cat Beer");
		public static const BlackNipples:StatusEffectType = mk("Black Nipples");
		public static const BlowjobOn:StatusEffectType = mk("BlowjobOn");
		public static const BoatDiscovery:StatusEffectType = mk("Boat Discovery");
		public static const BonusACapacity:StatusEffectType = mk("Bonus aCapacity");
		public static const BonusVCapacity:StatusEffectType = mk("Bonus vCapacity");
		public static const BottledMilk:StatusEffectType = mk("Bottled Milk");
		public static const BreastsMilked:StatusEffectType = mk("Breasts Milked");
		public static const BSwordBroken:StatusEffectType = mk("BSwordBroken");
		public static const BuiltMilker:StatusEffectType = mk("BUILT: Milker");
		public static const BurpChanged:StatusEffectType = mk("Burp Changed");
		public static const ButtStretched:StatusEffectType = mk("ButtStretched");
		public static const CampAnemoneTrigger:StatusEffectType = mk("Camp Anemone Trigger");
		public static const CampMarble:StatusEffectType = mk("Camp Marble");
		public static const CampRathazul:StatusEffectType = mk("Camp Rathazul");
		public static const ClaraCombatRounds:StatusEffectType = mk("Clara Combat Rounds");
		public static const ClaraFoughtInCamp:StatusEffectType = mk("Clara Fought In Camp");
		public static const CockPumped:StatusEffectType = mk("Cock Pumped");
		public static const Contraceptives:StatusEffectType = mk("Contraceptives");
		public static const CuntStretched:StatusEffectType = mk("CuntStretched"); //Used only for compatibility with old save files, replaced with attribute on vagina class
		public static const DefenseCanopy:StatusEffectType = mk("Defense: Canopy");
		public static const DeluxeOnaholeUsed:StatusEffectType = mk("deluxe onahole used");
		public static const DogWarning:StatusEffectType = mk("dog warning");
		public static const DragonBreathBoost:StatusEffectType = mk("Dragon Breath Boost");
		public static const DragonBreathCooldown:StatusEffectType = mk("Dragon Breath Cooldown");
		public static const Dysfunction:StatusEffectType = mk("dysfunction");
		public static const Edryn:StatusEffectType = mk("Edryn");
		public static const Eggchest:StatusEffectType = mk("eggchest");
		public static const Eggs:StatusEffectType = mk("eggs");
		public static const EmberFuckCooldown:StatusEffectType = mk("ember fuck cooldown");
		public static const EmberMilk:StatusEffectType = mk("Ember's Milk");
		public static const EmberNapping:StatusEffectType = mk("Ember Napping");
		public static const EverRapedJojo:StatusEffectType = mk("Ever Raped Jojo");
		public static const Exgartuan:StatusEffectType = mk("Exgartuan");
		public static const ExploredDeepwoods:StatusEffectType = mk("exploredDeepwoods");
		public static const FaerieFemFuck:StatusEffectType = mk("Faerie Fem Fuck");
		public static const FaerieFucked:StatusEffectType = mk("Faerie Fucked");
		public static const FappedGenderless:StatusEffectType = mk("fapped genderless");
		public static const Feeder:StatusEffectType = mk("Feeder");
		public static const Fertilized:StatusEffectType = mk("Fertilized");
		public static const FetishOn:StatusEffectType = mk("fetishON");
		public static const FuckedMarble:StatusEffectType = mk("FuckedMarble");
		public static const Fullness:StatusEffectType = mk("Fullness"); //Alternative to hunger
		public static const GlobalFatigue:StatusEffectType = Exhaustion.TYPE;
		public static const Goojob:StatusEffectType = mk("GOOJOB");
		public static const GooStuffed:StatusEffectType = mk("gooStuffed");
		public static const Groundpound:StatusEffectType = GroundPoundDebuff.TYPE;
		public static const HairdresserMeeting:StatusEffectType = mk("hairdresser meeting");
		public static const Hangover:StatusEffectType = mk("Hangover");
		public static const Heat:StatusEffectType = mk("heat");
		public static const HorseWarning:StatusEffectType = mk("horse warning");
		public static const ImmolationSpell:StatusEffectType = mk("Immolation Spell");
		public static const ImpGangBang:StatusEffectType = mk("Imp GangBang");
		public static const Infested:StatusEffectType = mk("infested");
		public static const IzmaBlowing:StatusEffectType = mk("IzmaBlowing");
		public static const IzumisPipeSmoke:StatusEffectType = IzumiPipeSmoke.TYPE;
		public static const JerkingIzma:StatusEffectType = mk("JerkingIzma");
		public static const Jizzpants:StatusEffectType = mk("Jizzpants");
		public static const JojoMeditationCount:StatusEffectType = mk("Jojo Meditation Count");
		public static const JojoNightWatch:StatusEffectType = mk("JojoNightWatch");
		public static const JojoTFOffer:StatusEffectType = mk("JojoTFOffer");
		public static const Kelt:StatusEffectType = mk("Kelt");
		public static const KeltBJ:StatusEffectType = mk("KeltBJ");
		public static const KeltBadEndWarning:StatusEffectType = mk("Kelt Bad End Warning");
		public static const KeltOff:StatusEffectType = mk("KeltOff");
		public static const kitsuneVision:StatusEffectType = KitsuneVision.TYPE;
		public static const KnowsArouse:StatusEffectType = mk("Knows Arouse");
		public static const KnowsBlind:StatusEffectType = mk("Knows Blind");
		public static const KnowsCharge:StatusEffectType = mk("Knows Charge");
		public static const KnowsHeal:StatusEffectType = mk("Knows Heal");
		public static const KnowsMight:StatusEffectType = mk("Knows Might");
		public static const KnowsWhitefire:StatusEffectType = mk("Knows Whitefire");
		public static const KnowsTKBlast:StatusEffectType = mk("Knows TK Blast");
		public static const KnowsBlackfire:StatusEffectType = mk("Knows Blackfire");
		public static const KnowsLeech:StatusEffectType = mk("Knows Leech");
		public static const KnowsSoulburst:StatusEffectType = mk("Knows Soulburst");
        public static const KnowsWither:StatusEffectType = mk("Knows Wither");
        public static const KnowsCSS:StatusEffectType = mk("Knows Circe's Summoned Scimitars");
        public static const KnowsDivineWind:StatusEffectType = mk("Knows Divine Wind");
		public static const LactationEndurance:StatusEffectType = mk("Lactation Endurance");
		public static const LactationReduction:StatusEffectType = mk("Lactation Reduction");
		public static const LactationReduc0:StatusEffectType = mk("Lactation Reduc0");
		public static const LactationReduc1:StatusEffectType = mk("Lactation Reduc1");
		public static const LactationReduc2:StatusEffectType = mk("Lactation Reduc2");
		public static const LactationReduc3:StatusEffectType = mk("Lactation Reduc3");
		public static const LootEgg:StatusEffectType = mk("lootEgg");
		public static const LostVillagerSpecial:StatusEffectType = mk("lostVillagerSpecial");
		public static const Luststick:StatusEffectType = mk("Luststick");
		public static const LustStickApplied:StatusEffectType = mk("Lust Stick Applied");
		public static const LustyTongue:StatusEffectType = mk("LustyTongue");
		public static const MalonVisitedPostAddiction:StatusEffectType = mk("Malon Visited Post Addiction");
		public static const Marble:StatusEffectType = mk("Marble");
		public static const MarbleHasItem:StatusEffectType = mk("MarbleHasItem");
		public static const MarbleItemCooldown:StatusEffectType = mk("MarbleItemCooldown");
		public static const MarbleRapeAttempted:StatusEffectType = mk("Marble Rape Attempted");
		public static const MarblesMilk:StatusEffectType = mk("Marbles Milk");
		public static const MarbleSpecials:StatusEffectType = mk("MarbleSpecials");
		public static const MarbleWithdrawl:StatusEffectType = mk("MarbleWithdrawl");
		public static const Meditated:StatusEffectType = mk("Meditated"); // DEPRECATED
		public static const MeanToNaga:StatusEffectType = mk("MeanToNaga");
		public static const MeetWanderer:StatusEffectType = mk("meet wanderer");
		public static const MetRathazul:StatusEffectType = mk("metRathazul");
		public static const MetWorms:StatusEffectType = mk("metWorms");
		public static const MetWhitney:StatusEffectType = mk("Met Whitney");
		public static const Milked:StatusEffectType = mk("Milked");
		public static const MinoPlusCowgirl:StatusEffectType = mk("Mino + Cowgirl");
		public static const Naga:StatusEffectType = mk("Naga");
		public static const NakedOn:StatusEffectType = mk("NakedOn");
		public static const NoJojo:StatusEffectType = mk("noJojo");
		public static const NoMoreMarble:StatusEffectType = mk("No More Marble");
		public static const Oswald:StatusEffectType = mk("Oswald");
		public static const ParasiteSlug:StatusEffectType = mk("infected by slug parasite");
		public static const ParasiteSlugReproduction:StatusEffectType = mk("slug parasite reproducing");
		public static const ParasiteSlugMet:StatusEffectType = mk("met a parasite in the bog");
		public static const ParasiteSlugMatureDay:StatusEffectType = mk("sets a delay before parasite can reproduce after maturing");
		public static const ParasiteEel:StatusEffectType = mk("infected by eel parasite");
		public static const ParasiteEelNeedCum:StatusEffectType = mk("ParasiteEel needs specific cum");
		public static const ParasiteEelReproduction:StatusEffectType = mk("ParasiteEel ready to reproduce");
		public static const PlainOnaholeUsed:StatusEffectType = mk("plain onahole used");
		public static const PhoukaWhiskeyAffect:StatusEffectType = mk("PhoukaWhiskeyAffect");
		public static const PostAkbalSubmission:StatusEffectType = mk("Post Akbal Submission");
		public static const PostAnemoneBeatdown:StatusEffectType = mk("Post Anemone Beatdown");
		public static const PureCampJojo:StatusEffectType = mk("PureCampJojo");
		public static const RathazulArmor:StatusEffectType = mk("RathazulArmor");
		public static const RepeatSuccubi:StatusEffectType = mk("repeatSuccubi");
		public static const Rut:StatusEffectType = mk("rut");
		public static const SharkGirl:StatusEffectType = mk("Shark-Girl");
		public static const ShieldingSpell:StatusEffectType = mk("Shielding Spell");
		public static const SlimeCraving:StatusEffectType = mk("Slime Craving");
		public static const SlimeCravingFeed:StatusEffectType = mk("Slime Craving Feed");
		public static const SlimeCravingOutput:StatusEffectType = mk("Slime Craving Output");
		public static const SuccubiFirst:StatusEffectType = mk("SuccubiFirst");
		public static const SuccubiNight:StatusEffectType = mk("succubiNight");
		public static const TakenGroPlus:StatusEffectType = mk("TakenGro+");
		public static const TakenLactaid:StatusEffectType = mk("TakenLactaid");
		public static const Tamani:StatusEffectType = mk("Tamani");									//Used only for compatibility with old save files, otherwise no longer in use
		public static const TamaniFemaleEncounter:StatusEffectType = mk("Tamani Female Encounter");	//Used only for compatibility with old save files, otherwise no longer in use
		public static const TelAdre:StatusEffectType = mk("Tel'Adre");
		public static const TellyVised:StatusEffectType = TellyVisedStatus.TYPE;
		public static const TentacleBadEndCounter:StatusEffectType = mk("TentacleBadEndCounter");
		public static const TentacleJojo:StatusEffectType = mk("Tentacle Jojo");
		public static const TensionReleased:StatusEffectType = mk("TensionReleased");
		public static const TrackingPositive:StatusEffectType = mk("TrackingPositive"); // v1-v4: species to encounter more often
		public static const TrackingNegative:StatusEffectType = mk("TrackingNegative"); // v1-v4: species to encounter less often
		public static const TransformationDoses:StatusEffectType = mk("Transformation stuff"); //tracks TF item usage to decrease grind a bit, maybe not really
		public static const TF2:StatusEffectType = mk("TF2");
		public static const TookBlessedSword:StatusEffectType = mk("Took Blessed Sword");
		public static const ParasiteNephila:StatusEffectType = mk("infected by nephila parasite");
		public static const ParasiteNephilaNeedCum:StatusEffectType = mk("ParasiteNephila needs specific cum");
		public static const ParasiteNephilaReproduction:StatusEffectType = mk("ParasiteNephila ready to reproduce");

		//Old status plots. DEPRECATED, DO NOT USE. Currently cannot be removed without breaking existing saves.
		public static const DungeonShutDown:StatusEffectType = mk("DungeonShutDown");
		public static const FactoryOmnibusDefeated:StatusEffectType = mk("FactoryOmnibusDefeated");
		public static const FactoryOverload:StatusEffectType = mk("FactoryOverload");
		public static const FactoryIncubusDefeated:StatusEffectType = mk("FactoryIncubusDefeated");
		public static const FoundFactory:StatusEffectType = mk("Found Factory");
		public static const IncubusBribed:StatusEffectType = mk("IncubusBribed");
		public static const FactorySuccubusDefeated:StatusEffectType = mk("FactorySuccubusDefeated");
		public static const MaraeComplete:StatusEffectType = mk("Marae Complete");
		public static const MaraesLethicite:StatusEffectType = mk("Marae's Lethicite");
		public static const MaraesQuestStart:StatusEffectType = mk("Marae's Quest Start");
		public static const MetCorruptMarae:StatusEffectType = mk("Met Corrupt Marae");
		public static const MetMarae:StatusEffectType = mk("Met Marae");

		//Prisoner status effects.
		public static const PrisonCaptorEllyStatus:StatusEffectType = mk("prisonCaptorEllyStatus");
		public static const PrisonCaptorEllyQuest:StatusEffectType = mk("prisonCaptorEllyQuest");
		public static const PrisonCaptorEllyPet:StatusEffectType = mk("prisonCaptorEllyPet");
		public static const PrisonCaptorEllyBillie:StatusEffectType = mk("prisonCaptorEllyBillie");
		public static const PrisonCaptorEllyScruffy:StatusEffectType = mk("prisonCaptorEllyScruffy");
		public static const PrisonRestraints:StatusEffectType = mk("prisonRestraint");
		public static const PrisonCaptorEllyScratch:StatusEffectType = mk("prisonCaptorEllyScatch");

		public static const UmasMassage:StatusEffectType = mk("Uma's Massage"); //v1 = bonus index; v2 = bonus value; v3 = remaining time
		public static const Uniball:StatusEffectType = mk("Uniball");
		public static const UsedNaturalSelfStim:StatusEffectType = mk("used natural self-stim");
		public static const used_self_dash_stim:StatusEffectType = mk("used self-stim");
		public static const Victoria:StatusEffectType = mk("Victoria");
		public static const VoluntaryDemonpack:StatusEffectType = mk("Voluntary Demonpack");
		public static const WormOffer:StatusEffectType = mk("WormOffer");
		public static const WormPlugged:StatusEffectType = mk("worm plugged");
		public static const WormsHalf:StatusEffectType = mk("wormsHalf");
		public static const WormsOff:StatusEffectType = mk("wormsOff");
		public static const WormsOn:StatusEffectType = mk("wormsOn");
		public static const WandererDemon:StatusEffectType = mk("wanderer demon");
		public static const WandererHuman:StatusEffectType = mk("wanderer human");
		public static const Yara:StatusEffectType = mk("Yara");

		// monster
		public static const Attacks:StatusEffectType = mk("attacks");
		public static const ChargeAttack:StatusEffectType = mk("charge attack");
		public static const BimboBrawl:StatusEffectType = mk("bimboBrawl");
		public static const BowCooldown:StatusEffectType = mk("Bow Cooldown", CombatStatusEffect);
		public static const BowDisabled:StatusEffectType = mk("Bow Disabled", CombatStatusEffect);
		public static const Charged:StatusEffectType = mk("Charged");
		public static const Climbed:StatusEffectType = mk("Climbed");
		public static const Concentration:StatusEffectType = mk("Concentration");
		public static const Constricted:StatusEffectType = mk("Constricted");
		public static const CoonWhip:StatusEffectType = mk("Coon Whip");
		public static const Counter:StatusEffectType = mk("Counter");
		public static const DomFight:StatusEffectType = mk("domfight");
		public static const DrankMinoCum:StatusEffectType = mk("drank mino cum");
		public static const DrankMinoCum2:StatusEffectType = mk("drank mino cum2")
		public static const Drunk:StatusEffectType = mk("Drunk");
		public static const Earthshield:StatusEffectType = mk("Earthshield");
		public static const Fear:StatusEffectType = mk("Fear");
		//public static const FearCounter:StatusEffectType = mk("FearCounter");
		public static const GenericRunDisabled:StatusEffectType = mk("Generic Run Disabled");
		public static const Gigafire:StatusEffectType = mk("Gigafire");
		public static const GottaOpenGift:StatusEffectType = mk("Gotta Open Gift");
		public static const HolliBurning:StatusEffectType = mk("Holli Burning");
		public static const Illusion:StatusEffectType = mk("Illusion");
		public static const ImpSkip:StatusEffectType = mk("ImpSkip");
		public static const ImpUber:StatusEffectType = mk("ImpUber");
		public static const JojoIsAssisting:StatusEffectType = mk("Jojo Is Assisting");
		public static const JojoPyre:StatusEffectType = mk("Jojo Pyre");
		public static const Keen:StatusEffectType = mk("keen");
		public static const Level:StatusEffectType = mk("level");
		public static const KitsuneFight:StatusEffectType = mk("Kitsune Fight");
		public static const LethicesRapeTentacles:StatusEffectType = mk("Lethices Rape Tentacles");
		public static const LustAura:StatusEffectType = mk("Lust Aura");
		public static const LustStick:StatusEffectType = mk("LustStick");
		public static const Milk:StatusEffectType = mk("milk");
		public static const MilkyUrta:StatusEffectType = mk("Milky Urta");
		public static const MinoMilk:StatusEffectType = mk("Mino Milk");
		public static const MinotaurEntangled:StatusEffectType = mk("Minotaur Entangled");

		public static const MissFirstRound:StatusEffectType = mk("miss first round");
		public static const NoLoot:StatusEffectType = mk("No Loot");
		public static const OnFire:StatusEffectType = mk("On Fire");
		public static const PCTailTangle:StatusEffectType = mk("PCTailTangle");
		public static const PeachLootLoss:StatusEffectType = mk("Peach Loot Loss");

		// @aimozg i don't know and do not fucking care if these two should be merged
		public static const PhyllaFight:StatusEffectType = mk("PhyllaFight");
		public static const phyllafight:StatusEffectType = mk("phyllafight");
		public static const Platoon:StatusEffectType = mk("platoon");
		public static const QueenBind:StatusEffectType = mk("QueenBind");
		// @aimozg HA HA HA
		public static const Vapula:StatusEffectType = mk("Vapula");//what the fuck is this

		public static const WhipReady:StatusEffectType = mk("Whip Ready", CombatStatusEffect);
		public static const AikoLustPrank:StatusEffectType = mk("Aiko sex prank");
		public static const AikoHyper:StatusEffectType = mk("Aiko hyper attacks");
		public static const AikoArcaneArcher:StatusEffectType = mk("Aiko archer attacks");
		public static const YamataCannon:StatusEffectType = mk("Yamata Foxfire Cannon");

		//Plantgirl
		public static const happy:StatusEffectType = mk("happy");
		public static const horny:StatusEffectType = mk("horny");
		public static const grouchy:StatusEffectType = mk("grouchy");

		// universal combat buffs
		public static const GenericCombatStrBuff:StatusEffectType  = CombatStrBuff.TYPE;
		public static const GenericCombatSpeBuff:StatusEffectType  = CombatSpeBuff.TYPE;
		public static const GenericCombatTouBuff:StatusEffectType  = CombatTouBuff.TYPE;
		public static const GenericCombatInteBuff:StatusEffectType = CombatInteBuff.TYPE;
		// combat
		public static const AcidSlap:StatusEffectType = mk("Acid Slap", CombatStatusEffect);
		public static const AkbalSpeed:StatusEffectType = AkbalSpeedDebuff.TYPE;
		public static const AkbalFlameDebuff:StatusEffectType = mk("Akbal Flame Debuff", CombatStatusEffect);
		public static const AkbalFireUsed:StatusEffectType = mk("AkbalFireUsed", CombatStatusEffect);
		public static const AkbalHealUsed:StatusEffectType = mk("AkbalHealUsed", CombatStatusEffect);
		public static const AmilyVenom:StatusEffectType = AmilyVenomDebuff.TYPE;
		public static const AnemoneVenom:StatusEffectType = AnemoneVenomDebuff.TYPE;
		public static const ArmorRent:StatusEffectType = mk("Armor Rent", CombatStatusEffect);
		public static const Apotheosis:StatusEffectType = mk("Exponential spell power, exponentially less HP", CombatStatusEffect);
		public static const AttackDisabled:StatusEffectType = mk("Attack Disabled", CombatStatusEffect);
		public static const BasiliskCompulsion:StatusEffectType = mk("Basilisk Compulsion", CombatStatusEffect);
		public static const BasiliskSlow:StatusEffectType = BasiliskSlowDebuff.TYPE;
		public static const Berzerking:StatusEffectType = mk("Berzerking", CombatStatusEffect);
		public static const Blind:StatusEffectType = mk("Blind", CombatStatusEffect);
		public static const Bound:StatusEffectType = mk("Bound", CombatStatusEffect);
		public static const CalledShot:StatusEffectType = CalledShotDebuff.TYPE;
		public static const ChargeWeapon:StatusEffectType = mk("Charge Weapon", CombatStatusEffect);
		public static const Chokeslam:StatusEffectType = mk("Chokeslam", CombatStatusEffect);
		public static const CirceSummonedScimitar:StatusEffectType = CirceScimitarBuff.TYPE;
		public static const Confusion:StatusEffectType          = mk("Confusion", CombatStatusEffect);
		public static const DemonSeed:StatusEffectType       = mk("DemonSeed", CombatStatusEffect);
	    public static const CorrWitchBind:StatusEffectType = mk("Corrupted Witch headlock", CombatStatusEffect);
		public static const Disarmed:StatusEffectType        = mk("Disarmed", CombatStatusEffect);
		public static const DriderKiss:StatusEffectType      = mk("Drider Kiss", CombatStatusEffect);
		public static const EmpathicAgony:StatusEffectType      = mk("Emphatic Agony", CombatStatusEffect);
		public static const CounterAB:StatusEffectType = mk("Revengeance", CombatStatusEffect);
		public static const FirstAttack:StatusEffectType     = mk("FirstAttack", CombatStatusEffect);
		public static const GiantBoulder:StatusEffectType    = mk("Giant Boulder", CombatStatusEffect);
		public static const GiantGrabbed:StatusEffectType    = mk("Giant Grabbed", CombatStatusEffect);
		public static const GiantStrLoss:StatusEffectType    = GiantStrLossDebuff.TYPE;
		public static const GnollSpear:StatusEffectType      = GnollSpearDebuff.TYPE;
		public static const Grappled:StatusEffectType = mk("Grappled", CombatStatusEffect);
		public static const Grappling:StatusEffectType = mk("Grappling", CombatStatusEffect);
		public static const GuardAB:StatusEffectType = mk("Targetguarded", CombatStatusEffect);
		public static const Marked:StatusEffectType = mk("Player is marked, less armor", CombatStatusEffect);
		public static const Resolve:StatusEffectType = mk("Test your resolve. A buff, or a debuff.", CombatStatusEffect)
		public static const Revelation:StatusEffectType = mk("Player gained a crumb of cosmic truth", CombatStatusEffect);

		public static const Round:StatusEffectType = mk("Round", CombatStatusEffect);
		public static const round:StatusEffectType = mk("round", CombatStatusEffect);
		public static const RunDisabled:StatusEffectType = mk("Run Disabled", CombatStatusEffect);
		public static const Shell:StatusEffectType = mk("Shell", CombatStatusEffect);
		public static const SirenSong:StatusEffectType = mk("Siren Song", CombatStatusEffect);
		public static const Soulburst:StatusEffectType = mk("Soulburst", CombatStatusEffect);
		public static const Spar:StatusEffectType = mk("spar", CombatStatusEffect);
		public static const Sparring:StatusEffectType = mk("sparring", CombatStatusEffect);
		public static const spiderfight:StatusEffectType = mk("spiderfight", CombatStatusEffect);
		public static const StimulatingAura:StatusEffectType = StimulatingAuraDebuff.TYPE;
		public static const StunCooldown:StatusEffectType = mk("Stun Cooldown", CombatStatusEffect);
		public static const TentacleCoolDown:StatusEffectType = mk("TentacleCoolDown", CombatStatusEffect);
		public static const Timer:StatusEffectType = mk("Timer");
		public static const TimesBashed:StatusEffectType = mk("TimesBashed", CombatStatusEffect);
		public static const Uber:StatusEffectType= mk("Uber", CombatStatusEffect);
		public static const VolcanicUberHEAL:StatusEffectType = mk("Volcanic Golem's uberheal", CombatStatusEffect);
		public static const UrtaSecondWinded:StatusEffectType = mk("Urta Second Winded", CombatStatusEffect);
		public static const UsedTitsmother:StatusEffectType = mk("UsedTitsmother", CombatStatusEffect);
		public static const Vala:StatusEffectType= mk("vala", CombatStatusEffect);
		public static const GooArmorBind:StatusEffectType    = mk("GooArmorBind", CombatStatusEffect);
		public static const GooArmorSilence:StatusEffectType = mk("GooArmorSilence", CombatStatusEffect);
		public static const GooBind:StatusEffectType         = mk("GooBind", CombatStatusEffect);
		public static const HarpyBind:StatusEffectType       = mk("HarpyBind", CombatStatusEffect);
		public static const HolliConstrict:StatusEffectType = mk("Holli Constrict", CombatStatusEffect);
		public static const InfestAttempted:StatusEffectType = mk("infestAttempted", CombatStatusEffect);
		public static const IsabellaStunned:StatusEffectType = mk("Isabella Stunned", CombatStatusEffect);
		public static const IzmaBleed:StatusEffectType = mk("Izma Bleed", CombatStatusEffect);
		public static const Ironflesh:StatusEffectType = mk("Ironflesh", CombatStatusEffect);
		public static const KissOfDeath:StatusEffectType = mk("Kiss of Death", CombatStatusEffect);
		public static const LizanBlowpipe:StatusEffectType = LizanBlowpipeDebuff.TYPE;
		public static const LustStones:StatusEffectType = mk("lust stones", CombatStatusEffect);
		public static const lustvenom:StatusEffectType = mk("lust venom", CombatStatusEffect);
		public static const Lustzerking:StatusEffectType = mk("Lustzerking", CombatStatusEffect);
		public static const Might:StatusEffectType = mk("Might", CombatStatusEffect) //MightBuff.TYPE;
		public static const MothDose:StatusEffectType = MothPheromones.TYPE;
		public static const NagaBind:StatusEffectType = mk("Naga Bind", CombatStatusEffect);
		public static const NagaVenom:StatusEffectType = NagaVenomDebuff.TYPE;
		public static const Deafeningbuzz:StatusEffectType = DeafeningBuzz.TYPE;
		public static const PermaFlyStatus:StatusEffectType = PermaFly.TYPE;
		public static const NoFlee:StatusEffectType = mk("NoFlee", CombatStatusEffect);
		public static const Overhealing:StatusEffectType = mk("Overhealing", CombatStatusEffect);
		public static const ParalyzeVenom:StatusEffectType = ParalyzeVenomDebuff.TYPE;
		public static const PhysicalDisabled:StatusEffectType = mk("Physical Disabled", CombatStatusEffect);
		public static const Poison:StatusEffectType = mk("Poison", CombatStatusEffect);
		public static const Sandstorm:StatusEffectType = mk("sandstorm", CombatStatusEffect);
		public static const Sealed:StatusEffectType = mk("Sealed", CombatStatusEffect);
		public static const SheilaOil:StatusEffectType = mk("Sheila Oil", CombatStatusEffect);
		public static const Shielding:StatusEffectType = mk("Shielding", CombatStatusEffect);
		public static const StoneLust:StatusEffectType = mk("Stone Lust", CombatStatusEffect);
		public static const Stunned:StatusEffectType = mk("Stunned", CombatStatusEffect);
		public static const TailWhip:StatusEffectType = mk("Tail Whip", CombatStatusEffect);
		public static const TemporaryHeat:StatusEffectType = mk("Temporary Heat", CombatStatusEffect);
		public static const TentacleBind:StatusEffectType = mk("TentacleBind", CombatStatusEffect);
		public static const ThroatPunch:StatusEffectType = mk("Throat Punch", CombatStatusEffect);
		public static const Titsmother:StatusEffectType = mk("Titsmother", CombatStatusEffect);
		public static const TwuWuv:StatusEffectType = mk("Twu Wuv", CombatStatusEffect);
		public static const UBERWEB:StatusEffectType = mk("UBERWEB", CombatStatusEffect);
		public static const Web:StatusEffectType = WebDebuff.TYPE;
		public static const WebSilence:StatusEffectType = mk("Web-Silence", CombatStatusEffect);
		public static const Whispered:StatusEffectType = mk("whispered", CombatStatusEffect);
		public static const TrueWhispered:StatusEffectType = WhisperedDebuff.TYPE;
		public static const RemovedArmor:StatusEffectType = mk("Removed Armor", CombatStatusEffect);
		public static const JCLustLevel:StatusEffectType = mk("JC Lust Level", CombatStatusEffect);
		public static const Leeching:StatusEffectType = mk("Player is stealing health with every regular attack", CombatStatusEffect);
		public static const MirroredAttack:StatusEffectType = mk("Mirrored Attack", CombatStatusEffect);
		public static const KnockedBack:StatusEffectType = mk("Knocked Back", CombatStatusEffect);
		public static const Tentagrappled:StatusEffectType = mk("Tentagrappled", CombatStatusEffect);
		public static const TentagrappleCooldown:StatusEffectType = mk("Tentagrapple Cooldown", CombatStatusEffect);
		public static const ShowerDotEffect:StatusEffectType = mk("Shower Dot Effect", CombatStatusEffect);
		public static const GardenerSapSpeed:StatusEffectType = GardenerSapSpeedDebuff.TYPE;
		public static const VineHealUsed:StatusEffectType = mk("Vine Heal Used", CombatStatusEffect);
		public static const DriderIncubusVenom:StatusEffectType = DriderIncubusVenomDebuff.TYPE;
		public static const NagaSentVenom:StatusEffectType = mk("Naga Sentinel Venom", CombatStatusEffect);
		public static const Nothingness:StatusEffectType = mk("Player doesn't exist", CombatStatusEffect);
		public static const PurpleHaze:StatusEffectType = mk("PurpleHaze", CombatStatusEffect);
		public static const TaintedMind:StatusEffectType = mk("Tainted Mind", CombatStatusEffect);
		public static const MinotaurKingMusk:StatusEffectType = mk("Minotaur King Musk", CombatStatusEffect);
		public static const MinotaurKingsTouch:StatusEffectType = mk("Minotaur Kings Touch", CombatStatusEffect);
		public static const MosquitoNumb:StatusEffectType = mk("Mosquito Numb", CombatStatusEffect);
		public static const ParasiteSlugMusk:StatusEffectType = mk("Smell that musk man", CombatStatusEffect);
		public static const ParasiteQueen:StatusEffectType = mk("Being boosted by your parasites!", CombatStatusEffect);
		public static const NephilaQueen:StatusEffectType = mk("Being boosted by your parasites!", CombatStatusEffect);
		public static const NephilaCompulsion:StatusEffectType = mk("Nephila Compulsion", CombatStatusEffect);
		public static const NephilaSlow:StatusEffectType = NephilaSlowDebuff.TYPE;
		public static const PigbysHands:StatusEffectType = mk("Pigbys Hands", CombatStatusEffect);
		public static const WhipSilence:StatusEffectType = mk("Whip-Silence", CombatStatusEffect);
		public static const AikoLightningArrow:StatusEffectType = mk("Aiko archer attacks", CombatStatusEffect);
		public static const YamataEntwine:StatusEffectType = mk("Yamata Entwine", CombatStatusEffect);
		public static const PhoenixOrder:StatusEffectType = mk("Phoenix Commander issued order", CombatStatusEffect);//it's weird, but it's simpler to use this to alter the Platoon AI.
		public static const Refashioned:StatusEffectType = mk("Player has been remade", CombatStatusEffect);
		public static const SentinelOmniSilence:StatusEffectType = mk("Super silenced", CombatStatusEffect);
		public static const SentinelPhysicalDisabled:StatusEffectType = mk("No physical", CombatStatusEffect);
		public static const SentinelNoTease:StatusEffectType = mk("No tease", CombatStatusEffect);
		public static const Backstab:StatusEffectType = BackstabBuff.TYPE;
		public static const VolcanicFistProblem:StatusEffectType = mk("Golem stuck its fist in the ground.", CombatStatusEffect);
		public static const VolcanicFrenzy:StatusEffectType = mk("Golem is pissed off.", CombatStatusEffect);
		public static const VolcanicArmorRed:StatusEffectType = mk("Armor temporarily reduced", CombatStatusEffect);
	    public static const VolcanicWeapRed:StatusEffectType = mk("Weapon damage temporarily reduced", CombatStatusEffect);
		public static const WaitReadiness:StatusEffectType = mk("Extra dodge due to wait", CombatStatusEffect);
		public static const Withering:StatusEffectType = WitheringDebuff.TYPE;
        public static const DivineWind:StatusEffectType = DivineWindBuff.TYPE;
        public static const TargetMarkedBuff:StatusEffectType = TargetMarked.TYPE;
		public static const TFPlate:StatusEffectType = mk("Plate", CombatStatusEffect);
		public static const TFInflame:StatusEffectType = TFInflameBuff.TYPE;
		public static const TFMoltenPlate:StatusEffectType = mk("Molten Plate", CombatStatusEffect);
		public static const TFShell:StatusEffectType = TFShellBuff.TYPE;
		public static const TFQuake:StatusEffectType = TFQuakeBuff.TYPE;
		public static const TFScorch:StatusEffectType = TFScorchBuff.TYPE;
		public static const TFGeodeKnuckle:StatusEffectType = TFGeodeKnuckleBuff.TYPE;
		public static const TFTerraCore:StatusEffectType = mk("Terrestrial Core", CombatStatusEffect);
		public static const TFTerraStar:StatusEffectType = mk("Terrestrial Star", CombatStatusEffect);
		public static const TFTerraStarCooldown:StatusEffectType = TerraStarCooldown.TYPE;
		public static const TFTerraStarWeaken:StatusEffectType = TerraStarDebuff.TYPE;
		public static const TFSupercharging:StatusEffectType = mk("Supernova Charging", CombatStatusEffect);

        public static const TimeWarp:StatusEffectType = mk("Time is warped", CombatStatusEffect);
		public static const dispellablePositiveEffects:Array = [TargetMarkedBuff, ChargeWeapon, Might, Leeching, ParasiteQueen, NephilaQueen, Resolve, Lustzerking, Berzerking, Ironflesh, Overhealing, DivineWind, TFPlate, TFInflame, TFMoltenPlate, TFShell];
		public static const monsterNegativeEffects:Array = [OnFire, IzmaBleed, Blind, Fear, Stunned, Illusion, BasiliskCompulsion, NagaVenom, lustvenom, LustStick, CoonWhip, Constricted, TFTerraStarWeaken];
		public static const spellsWhite:Array = [KnowsWhitefire, KnowsCharge,  KnowsBlind];
		public static const spellsBlack:Array = [KnowsBlackfire, KnowsArouse, KnowsHeal, KnowsMight];
		public static const spellsGray:Array = [KnowsTKBlast, KnowsLeech];
		public static const spellsOther:Array = [KnowsDivineWind, KnowsWither, KnowsCSS, KnowsSoulburst];
		public static const spells:Array = [].concat(spellsWhite, spellsBlack, spellsGray, spellsOther);

		/**
		 * Creates status affect
		 */
		private static function mk(id:String, clazz:Class = null, arity: int = 1):StatusEffectType
		{
			return new StatusEffectType(id,clazz ? clazz : StatusEffect,arity);
		}
	}
}


code:
package classes.StatusEffects.Combat {
import classes.StatusEffectType;

public class AkbalSpeedDebuff extends CombatBuff {
	public static const TYPE:StatusEffectType = register("Akbal Speed",AkbalSpeedDebuff);
	public function AkbalSpeedDebuff() {
		super(TYPE,'spe');
	}

	override protected function apply(firstTime:Boolean):void {
		buffHost('spe', -host.spe / 5);
	}
}

}


code:
/**
 * Coded by aimozg on 24.08.2017.
 */
package classes.StatusEffects.Combat {
import classes.StatusEffectType;

public class AmilyVenomDebuff extends CombatBuff {
	public static const TYPE:StatusEffectType = register("Amily Venom",AmilyVenomDebuff);
	public function AmilyVenomDebuff() {
		super(TYPE,'str','spe');
	}

	override protected function apply(firstTime:Boolean):void {
		buffHost('str', -2 - rand(5),'spe', -2 - rand(5));
	}
}
}


code:
package classes.StatusEffects.Combat {
import classes.StatusEffectType;

public class AnemoneVenomDebuff extends CombatBuff {
	public static const TYPE:StatusEffectType = register("Anemone Venom",AnemoneVenomDebuff);
	public function AnemoneVenomDebuff() {
		super(TYPE,'str','spe');
	}

	public function applyEffect(str:Number):void {
		host.takeLustDamage((2 * str), true);
		buffHost('str', -str,'spe',-str);
	}
}

}


code:
/**
 * Coded by OtherCoCAnon on 15.02.2018.
 */
package classes.StatusEffects.Combat {
import classes.BonusDerivedStats;
import classes.Monster;
import classes.StatusEffectType;

public class AngeredPugilist extends TimedStatusEffect {
	public static const TYPE:StatusEffectType = register("AngeredPugilist", TargetMarked);
    public var id:String = "AngeredPugilist";
	public function AngeredPugilist(duration:int = 1, accBoost:Number = 15, HPboost:Number = 750 , physBoost:Number=1.50) {
		super(TYPE, "");
		setDuration(duration);
        this.value1 = accBoost;
        this.value2 = HPboost;
        this.value3 = physBoost;
	}

    override public function onAttach():void{
        setUpdateString(host.capitalA + host.short + " is still angered.");
        setRemoveString(host.capitalA + host.short + " is no longer angered.");
        boostsAccuracy(id,this.value1);
        boostsMaxHP(id,this.value2);
        boostsPhysicalDamage(id,this.value3,true);
        host.addBonusStats(this.bonusStats);
        this.tooltip = "Angered & Pumped: Target is angered, but still keeping his cool. " + this.value1 + "% extra accuracy, " + this.value2 + "% extra health and " + (this.value3 - 1)*100 + "% extra damage for " + getDuration() + " turns."
    }

    override public function onRemove():void{
        host.removeBonusStats(this.bonusStats);
    }

}
}


code:
/**
 * Coded by OtherCoCAnon on 15.02.2018.
 */
package classes.StatusEffects.Combat {
import classes.StatusEffectType;

public class BackstabBuff extends TimedStatusEffect {
    public static const TYPE:StatusEffectType = register("Backstab", BackstabBuff);
    public function BackstabBuff(duration:int = 1) {
        super(TYPE, "");
        setDuration(duration);
        setUpdateString("");
        setRemoveString("");
    }

    override public function onTurnEnd():void{
        if(value1 == 0){
            game.combat.combatAbilities.backstabExec();
        }
    }
    override public function onCombatRound():void{
        super.onCombatRound();
    }

}
}


code:
package classes.StatusEffects.Combat {
import classes.StatusEffectType;

public class BasiliskSlowDebuff extends CombatBuff {
	public static const TYPE:StatusEffectType = register("BasiliskSlow",BasiliskSlowDebuff);
	public function BasiliskSlowDebuff() {
		super(TYPE,'spe');
	}

	public function applyEffect(amount:Number):void {
		buffHost('spe', -amount, 'scale', false, 'max', false);
	}
}

}


code:
package classes.StatusEffects.Combat {
import classes.StatusEffectType;
import classes.StatusEffects.CombatStatusEffect;

public class CalledShotDebuff extends CombatBuff {

	public static const TYPE:StatusEffectType = register("Called Shot",CalledShotDebuff);
	public function CalledShotDebuff() {
		super(TYPE,'spe');
	}

	override protected function apply(firstTime:Boolean):void {
		buffHost('spe', -20 - rand(5));
	}
}

}


code:
/**
 * Coded by OtherCoCAnon on 15.02.2018.
 */
package classes.StatusEffects.Combat {
import classes.StatusEffectType;

public class CirceScimitarBuff extends CombatBuff {
    public static const TYPE:StatusEffectType = register("CirceScimitarBuff", CirceScimitarBuff);
    public function CirceScimitarBuff() {
        super(TYPE, "");
    }

    override public function onTurnEnd():void{
        for(var i:int = 0;i < value1;i++){
            game.combat.combatAbilities.summonedSwordSlash();
        }
    }

}
}


code:
package classes.StatusEffects.Combat {
import classes.StatusEffectType;
import classes.StatusEffects.TemporaryBuff;

public class CombatBuff extends TemporaryBuff{
	public function CombatBuff(stype:StatusEffectType, stat1:String, stat2:String ='', stat3:String ='', stat4:String ='') {
		super(stype, stat1, stat2, stat3, stat4);
	}

	public var tooltip:String = "";
	override public function onCombatEnd():void {
		super.onCombatEnd();
		restore();
		remove();
	}
}
}


code:
/**
 * Coded by aimozg on 23.09.2017.
 */
package classes.StatusEffects.Combat {
import classes.StatusEffectType;

public class CombatInteBuff extends CombatBuff {
	public static const TYPE:StatusEffectType = register("Combat Inte Buff", CombatInteBuff);
	public function CombatInteBuff() {
		super(TYPE, "inte");
	}
	public function applyEffect(inteBuff:Number):Number {
		return buffHost("inte", inteBuff).inte;
	}
}
}


code:
/**
 * Coded by aimozg on 23.09.2017.
 */
package classes.StatusEffects.Combat {
import classes.StatusEffectType;

public class CombatSpeBuff extends CombatBuff {
	public static const TYPE:StatusEffectType = register("Combat Spe Buff", CombatSpeBuff);
	public function CombatSpeBuff() {
		super(TYPE, "spe");
	}
	public function applyEffect(speBuff:Number):Number {
		return buffHost("spe", speBuff).spe;
	}
}
}


code:
/**
 * Coded by aimozg on 23.09.2017.
 */
package classes.StatusEffects.Combat {
import classes.StatusEffectType;

public class CombatStrBuff extends CombatBuff {
	public static const TYPE:StatusEffectType = register("Combat Str Buff", CombatStrBuff);
	public function CombatStrBuff() {
		super(TYPE, "str");
	}
	public function applyEffect(strBuff:Number):Number {
		return buffHost("str", strBuff).str;
	}
}
}


code:
/**
 * Coded by aimozg on 23.09.2017.
 */
package classes.StatusEffects.Combat {
import classes.StatusEffectType;

public class CombatTouBuff extends CombatBuff {
	public static const TYPE:StatusEffectType = register("Combat Tou Buff", CombatTouBuff);
	public function CombatTouBuff() {
		super(TYPE, "tou");
	}
	public function applyEffect(touBuff:Number):Number {
		return buffHost("tou", touBuff).tou;
	}
}
}


code:
/**
 * Coded by OtherCoCAnon on 15.02.2018.
 */
package classes.StatusEffects.Combat {
import classes.StatusEffectType;

public class DeafeningBuzz extends TimedStatusEffect {
	public static const TYPE:StatusEffectType = register("Deafening Buzz", DeafeningBuzz);
	public function DeafeningBuzz(duration:int = 1) {
		super(TYPE, "");
		setDuration(duration);
		setUpdateString("The mosquito girl's deafening buzzing still pierces your mind, ruining any focus you might attempt to force.");
		setRemoveString("The mosquito girl's buzzing finally wanes; you can cast spells again!");
	}

	override public function onCombatRound():void{
		host.silence();
		super.onCombatRound();
	}

}
}


code:
/**
 * Coded by OtherCoCAnon on 15.02.2018.
 */
package classes.StatusEffects.Combat {
import classes.Monster;
import classes.StatusEffectType;

public class DivineWindBuff extends TimedStatusEffect {
	public var casterSpellPower:Number;
	public static const TYPE:StatusEffectType = register("DivineWind", DivineWindBuff);
	public function DivineWindBuff(duration:int = 1) {
		super(TYPE, "");
		setDuration(duration);
        setUpdateString("A soothing, enchanted wind is still coursing through the battlefield.");
        setRemoveString("The wind's enchantment fades, and its healing properties vanish.");
	}

    override public function onCombatRound():void{
        game.outputText("The blessed wind washes through the battlefield.");
        for each(var currTarget:Monster in game.monsterArray){
            if(rand(3) == 0){
                game.outputText(currTarget.capitalA + currTarget.short + " is healed! ");
                currTarget.HPChange(currTarget.maxHP() * (0.1 + Math.random()*0.10) * host.spellMod()/1.75,true);
                game.outputText("\n");
            }
        }
		if(rand(3) == 0) game.player.HPChange(game.player.maxHP() * (0.1 + Math.random()*0.10) * host.spellMod()/1.75,true);
        super.onCombatRound();
    }

}
}


code:
/**
 * Coded by aimozg on 01.09.2017.
 */
package classes.StatusEffects.Combat {
import classes.PerkLib;
import classes.StatusEffectType;

public class DriderIncubusVenomDebuff extends CombatBuff {
	public static const TYPE:StatusEffectType = register("Drider Incubus Venom",DriderIncubusVenomDebuff);
	public function DriderIncubusVenomDebuff() {
		super(TYPE,'str');
	}

	override protected function apply(firstTime:Boolean):void {
		// -5 perm -30 temp
		host.dynStats('str',-5);
		buffHost('str',-30);
	}
	override public function onCombatRound():void {
		//Chance to cleanse!
		if (host.findPerk(PerkLib.Medicine) >= 0 && rand(100) <= 14) {
			if (playerHost) game.outputText("You manage to cleanse the drider incubus venom from your system with your knowledge of medicine!\n\n");
			remove();
		}
	}
}

}


code:
/**
 * Coded by aimozg on 01.09.2017.
 */
package classes.StatusEffects.Combat {
import classes.StatusEffectType;

public class GardenerSapSpeedDebuff extends CombatBuff {
	public static const TYPE:StatusEffectType = register("Sap Speed",GardenerSapSpeedDebuff);
	public function GardenerSapSpeedDebuff() {
		super(TYPE,'spe');
	}

	override protected function apply(firstTime:Boolean):void {
		buffHost('spe',-host.spe*0.2);
	}
}

}


code:
/**
 * Coded by aimozg on 01.09.2017.
 */
package classes.StatusEffects.Combat {
import classes.StatusEffectType;

public class GiantStrLossDebuff extends CombatBuff {
	public static const TYPE:StatusEffectType = register("GiantStrLoss",GiantStrLossDebuff);
	public function GiantStrLossDebuff() {
		super(TYPE,'str');
	}

	public function applyEffect(magnitude:Number):void {
		buffHost('str', -magnitude);
	}
}

}


code:
package classes.StatusEffects.Combat {
import classes.StatusEffectType;

public class GnollSpearDebuff extends CombatBuff {
	public static const TYPE:StatusEffectType = register("Gnoll Spear",GnollSpearDebuff);
	public function GnollSpearDebuff() {
		super(TYPE,'spe');
	}

	override protected function apply(firstTime:Boolean):void {
		buffHost('spe', -15);
	}
}

}


code:
package classes.StatusEffects.Combat {
import classes.StatusEffectType;

public class GroundPoundDebuff extends TimedStatusEffect {
	public static const TYPE:StatusEffectType = register("Groundpound", GroundPoundDebuff);
	public function GroundPoundDebuff(duration:int = 3) {
		super(TYPE, "spe");
		setDuration(duration);
	}

    override protected function apply(firstTime:Boolean):void {
        buffHost('spe',-host.spe*0.25);
	}
}
}


code:
package classes.StatusEffects.Combat {
import classes.PerkLib;
import classes.StatusEffectType;

public class Immobilized extends CombatBuff {

	public static const TYPE:StatusEffectType = register("Immobilized", Immobilized);
	public function Immobilized() {
		super(TYPE,"");
	}

	override protected function apply(first:Boolean):void {
		host.immobilize();
	}

	override public function onCombatRound():void {
		host.immobilize();
	}

	override public function onRemove():void{
		host.isImmobilized = false;
	}
	override public function onCombatEnd():void{
		host.isImmobilized = false;
		remove();
	}
}

}


code:
/**
 * Coded by aimozg on 01.09.2017.
 */
package classes.StatusEffects.Combat {
import classes.StatusEffectType;

public class LizanBlowpipeDebuff extends CombatBuff {
	public static const TYPE:StatusEffectType = register("Lizan Blowpipe", LizanBlowpipeDebuff);
	public function LizanBlowpipeDebuff() {
		super(TYPE, 'str', 'tou', 'spe', 'sens');
	}
	public function debuffStrSpe():void {
		var power:Number = 5;
		if (!host.isPureEnough(50)) {
			power = 10;
		}
		buffHost('str', -power, 'spe', -power);
	}
	public function debuffTouSens():void {
		var power:Number = 5;
		if (!host.isPureEnough(50)) {
			power = 10;
		}
		buffHost('tou', -power, 'sens', power);
	}
}

}


code:
/**
 * Coded by aimozg on 24.08.2017.
 */
package classes.StatusEffects.Combat {
import classes.StatusEffectType;

public class MightBuff extends CombatBuff {
	public static const TYPE:StatusEffectType = register("Might",MightBuff);
	public function MightBuff() {
		super(TYPE,'str','tou');
	}

	override protected function apply(firstTime:Boolean):void {
		var buff:Number = 10 * host.spellMod();
		if (buff > 100) buff = 100;
		buffHost('str',buff,'tou',buff,'scale',false,'max',false);
	}

}
}


code:
package classes.StatusEffects.Combat
{
	import classes.PerkLib;
	import classes.StatusEffectType;

	public class MothPheromones extends TimedStatusEffect {
		public static const TYPE:StatusEffectType = register("Moth Pheromones", MothPheromones);
		 public var id:String = "MothDose";
		public function MothPheromones(duration:int = 5, sensDebuff:int = 20, speDebuff:int = -20) {
			super(TYPE, 'sens', 'spe');
			setDuration(duration);
			this.value1 = sensDebuff;
			this.value2 = speDebuff;
		}

		override public function onAttach():void {
			buffHost("sens", this.value1, "spe", this.value2);
			setUpdateString("Your face flushes as a wave of dizziness hits you, the pheromones still coursing through your system.");
			setRemoveString("You shake your head and begin to feel a little bit more lucid.\n\nThe pheromones have worn off!\n");
		}

		override public function onCombatRound():void {
			countdownTimer();
			if (!playerHost) return;
			host.takeLustDamage(rand(10) + 5);
			game.outputText("\n\n");
		}

		override public function countdownTimer():void{
		setDuration(getDuration()-1);
		if (getDuration() <= 0){
			game.outputText("You shake your head and begin to feel a little bit more lucid.\n\nThe pheromones have worn off!\n\n");
			remove();
		}
		else game.outputText("Your face flushes as a wave of dizziness hits you, the pheromones still coursing through your system."); //Need to get rid of the newline for lust damage
	}

	}
}


code:
package classes.StatusEffects.Combat {
import classes.PerkLib;
import classes.StatusEffectType;

public class NagaVenomDebuff extends CombatBuff {

	public static const TYPE:StatusEffectType = register("Naga Venom",NagaVenomDebuff);
	public function NagaVenomDebuff() {
		super(TYPE,'spe');
	}

	override protected function apply(first:Boolean):void {
		var debuff:* = buffHost('spe',first?-3:-2);
		if (debuff.spe == 0) host.takeDamage(5+rand(5));
		host.takeDamage(5+rand(5));
	}

	override public function onCombatRound():void {
		//Chance to cleanse!
		if (host.hasPerk(PerkLib.Medicine) && rand(100) <= 14) {
			if (playerHost) game.outputText("You manage to cleanse the naga venom from your system with your knowledge of medicine!\n\n");
			remove();
			return;
		}
		var debuff:* = buffHost('spe',-2);
		if (debuff.spe == 0) host.takeDamage(5);
		host.takeDamage(2);
		if (playerHost) game.outputText("You wince in pain and try to collect yourself, the naga's venom still plaguing you.\n\n");
	}
}

}


code:
package classes.StatusEffects.Combat {
import classes.StatusEffectType;

public class NephilaSlowDebuff extends CombatBuff {
	public static const TYPE:StatusEffectType = register("NephilaSlow",NephilaSlowDebuff);
	public function NephilaSlowDebuff() {
		super(TYPE,'spe');
	}

	public function applyEffect(amount:Number):void {
		buffHost('spe', -amount, 'scale', false, 'max', false);
	}
}

}


code:
package classes.StatusEffects.Combat {
import classes.StatusEffectType;

public class ParalyzeVenomDebuff extends CombatBuff {

	public static const TYPE:StatusEffectType = register("paralyze venom",ParalyzeVenomDebuff);
	public function ParalyzeVenomDebuff() {
		super(TYPE,'str','spe');
	}

	override public function onRemove():void {
		if (playerHost) {
			game.outputText("<b>You feel quicker and stronger as the paralyzation venom in your veins wears off.</b>\n\n");
		}
	}

	override protected function apply(firstTime:Boolean):void {
		buffHost('str',firstTime?-2:-3,'spe',firstTime?-2:-3);
	}

}

}


code:
package classes.StatusEffects.Combat {
import classes.PerkLib;
import classes.StatusEffectType;

public class PermaFly extends CombatBuff {

	public static const TYPE:StatusEffectType = register("Permanent Flying", PermaFly);
	public function PermaFly() {
		super(TYPE,"");
	}

	override protected function apply(first:Boolean):void {
		var debuff:* = buffHost('spe',first?-3:-2);
		if (debuff.spe == 0) host.takeDamage(5+rand(5));
		host.takeDamage(5+rand(5));
	}

	override public function onCombatRound():void {
		game.outputText("\n<b>" + host.capitalA + host.short + "'s wings continue to flap.</b>");
		host.fly();
	}

	override public function onRemove():void{
		host.isFlying = false;
	}
}

}


code:
/**
 * Coded by OtherCoCAnon on 15.02.2018.
 */
package classes.StatusEffects.Combat {
import classes.StatusEffectType;

public class RetributionBuff extends TimedStatusEffect {
    public static const TYPE:StatusEffectType = register("RetributionBuff", RetributionBuff);
    public function RetributionBuff(duration:int = 1) {
        super(TYPE, "");
        setDuration(duration);
        setUpdateString("");
        setRemoveString("");
    }

    override public function onAttach():void {
        host.isImmobilized = true;
    }

    override public function onTurnEnd():void{
        game.combat.combatAbilities.retributionExec();
        host.isImmobilized = false;
    }
    override public function onCombatRound():void{
        super.onCombatRound();
    }

}
}


code:
/**
 * Coded by OtherCoCAnon on 15.02.2018.
 */
package classes.StatusEffects.Combat {
import classes.StatusEffectType;

public class Sealed extends TimedStatusEffect {
	public static const TYPE:StatusEffectType = register("Sealed", Sealed);
	public function Sealed(duration:int = 1,type) {
		super(TYPE, "",type);
		setDuration(duration);
		switch(type){
			case 0:
				setUpdateString("You attempt to muster the will to attack, but it is impossible! The kitsune's seals have made normal attack impossible!");
				setRemoveString("The mosquito girl's buzzing finally wanes; you can cast spells again!");
				break;
			case 1:
				setUpdateString("The mosquito girl's deafening buzzing still pierces your mind, ruining any focus you might attempt to force.");
				setRemoveString("The mosquito girl's buzzing finally wanes; you can cast spells again!");
				break;
			case 2:
				setUpdateString("The mosquito girl's deafening buzzing still pierces your mind, ruining any focus you might attempt to force.");
				setRemoveString("The mosquito girl's buzzing finally wanes; you can cast spells again!");
				break;
			case 3:
				setUpdateString("The mosquito girl's deafening buzzing still pierces your mind, ruining any focus you might attempt to force.");
				setRemoveString("The mosquito girl's buzzing finally wanes; you can cast spells again!");
				break;
			case 4:
				setUpdateString("The mosquito girl's deafening buzzing still pierces your mind, ruining any focus you might attempt to force.");
				setRemoveString("The mosquito girl's buzzing finally wanes; you can cast spells again!");
				break;
		}
	}

	override public function onCombatRound():void{
		switch(value2){
			case 0:
				host.atrophy();
				break;
			case 1:
				host.prude();
				break;
			case 2:
				host.silence();
				host.unfocus();
				break;
			case 3:
				host.clumsy();
				break;
			case 4:
				host.isCornered();
				break;
		}
		super.onCombatRound();
	}

}
}


code:
package classes.StatusEffects.Combat {
	import classes.PerkLib;
	import classes.StatusEffectType;
	import classes.BonusDerivedStats;

	public class StimulatingAuraDebuff extends CombatBuff {
		public static const TYPE:StatusEffectType = register("Stimulating Aura", StimulatingAuraDebuff);
		public function StimulatingAuraDebuff() {
			super(TYPE, 'sen');
		}

		public function resistPenalty():Number {
			var multi:Number = (100 + value2) / 100;
			return multi;
		}

		override public function onRemove():void{
			host.removeBonusStats(bonusStats);
		}

		override protected function apply(firstTime:Boolean):void {
			buffHost('sen', 2);
			value2 += 2;
			if (!firstTime) host.removeBonusStats(bonusStats);
			boostsDamageTaken("StimulatingAura", resistPenalty(), true);
			host.addBonusStats(bonusStats);
		}

		override public function onCombatRound():void {
			if (host.hasPerk(PerkLib.Medicine) && rand(100) < 15) {
				if (playerHost) game.outputText("With your knowledge of medicine, you manage to cleanse yourself of the alraune's stimulating effect.\n\n");
				remove();
			}
		}
	}
}


code:
package classes.StatusEffects.Combat {
import classes.StatusEffectType;

public class TFGeodeKnuckleBuff extends TimedStatusEffect {
	public static const TYPE:StatusEffectType = register("Geode Knuckle", TFGeodeKnuckleBuff);
	public function TFGeodeKnuckleBuff(duration:int = 1) {
		super(TYPE, "");
		setDuration(duration);
	}

}
}


code:
package classes.StatusEffects.Combat {
import classes.StatusEffectType;

public class TFInflameBuff extends CombatBuff {
    public static const TYPE:StatusEffectType = register("Inflame", TFInflameBuff);
    public function TFInflameBuff() {
        super(TYPE, "");
    }

    override public function onCombatRound():void{
		if (playerHost) game.outputText("Searing pain ripples across your skin from the flames covering your body. ");
		if (playerHost) game.combat.monsterDamageType = game.combat.DAMAGE_FIRE;
		host.takeDamage(game.combat.combatAbilities.tfInflameCalc("self"), true);
		if (playerHost) game.outputText("[pg]");
    }
}
}


code:
package classes.StatusEffects.Combat {
import classes.StatusEffectType;

public class TFQuakeBuff extends TimedStatusEffect {
	public static const TYPE:StatusEffectType = register("Quake", TFQuakeBuff);
	public function TFQuakeBuff(duration:int = 3) {
		super(TYPE, "");
		setDuration(duration);
	}

}
}


code:
package classes.StatusEffects.Combat {
import classes.StatusEffectType;

public class TFScorchBuff extends TimedStatusEffect {
	public static const TYPE:StatusEffectType = register("Scorch", TFScorchBuff);
	public function TFScorchBuff(duration:int = 3) {
		super(TYPE, "");
		setDuration(duration);
	}

}
}


code:
package classes.StatusEffects.Combat {
import classes.StatusEffectType;

public class TFShellBuff extends TimedStatusEffect {
	public static const TYPE:StatusEffectType = register("Stone Shell", TFShellBuff);
	public function TFShellBuff(duration:int = 1) {
		super(TYPE, "");
		setDuration(duration);
	}

}
}


code:
/**
 * Coded by OtherCoCAnon on 15.02.2018.
 */
package classes.StatusEffects.Combat {
import classes.BonusDerivedStats;
import classes.Monster;
import classes.StatusEffectType;

public class TargetMarked extends TimedStatusEffect {
	public static const TYPE:StatusEffectType = register("TargetMarked", TargetMarked);
    public var id:String = "TargetMarked";
	public function TargetMarked(duration:int = 1,accBoost:Number = 15,critBoost:Number = 25 ,physBoost:Number=1.50) {
		super(TYPE, "");
		setDuration(duration);
        this.value1 = 30;
        this.value2 = 25;
        this.value3 = 1.75
	}

    override public function onAttach():void{
        setUpdateString(host.capitalA + host.short + " is still deeply focused.");
        setRemoveString(host.capitalA + host.short + " is no longer focused.");
        boostsAccuracy(id,this.value1);
        boostsCriticalChance(id,this.value2);
        boostsPhysicalDamage(id,this.value3,true);
        host.addBonusStats(this.bonusStats);
        this.tooltip = "Focused: Target is focused on you, gaining an extra " + this.value1 + "% extra accuracy, " + this.value2 + "% extra critical chance and " + (this.value3 - 1)*100 + "% extra damage for " + getDuration() + " turns."
    }

    override public function onRemove():void{
        host.removeBonusStats(this.bonusStats);
    }

}
}


code:
package classes.StatusEffects.Combat {
import classes.StatusEffectType;
import classes.StatusEffects.TimedStatusEffectReal;

public class TerraStarCooldown extends TimedStatusEffectReal{
	public static const TYPE:StatusEffectType = register("Terrestrial Star Cooldown", TerraStarCooldown);
	public function TerraStarCooldown(duration:int = 24) {
		super(TYPE,"");
		this.setDuration(duration);
	}

	}
}


code:
package classes.StatusEffects.Combat {
import classes.StatusEffectType;

public class TerraStarDebuff extends CombatBuff {
	public static const TYPE:StatusEffectType = register("Terrestrial Star Debuff",TerraStarDebuff);
	public function TerraStarDebuff() {
		super(TYPE,'str');
	}

	override protected function apply(firstTime:Boolean):void {
		buffHost('str', -host.str / 10);
	}
}

}


code:
/**
 * Coded by OtherCoCAnon on 15.02.2018.
 */
package classes.StatusEffects.Combat {
import classes.Creature;
import classes.Player;
import classes.StatusEffectType;
import flash.utils.ByteArray;

public class TimeWalk extends TimedStatusEffect {

	public static const TYPE:StatusEffectType = register("TimeWalk", TimeWalk);
	public function TimeWalk(duration:int = 1) {
		super(TYPE, "");
		/*setDuration(duration);
		game.player2 = new Player();
		game.player2.HP = game.player.HP;
		game.player2.statusEffects = clone(game.player.statusEffects);
		setRemoveString("You feel yourself being warped back into time, turning into your being from moments ago.");*/
	}

}
}


code:
package classes.StatusEffects.Combat {
import classes.StatusEffectType;
import classes.StatusEffects.TemporaryBuff;

public class TimedStatusEffect extends CombatBuff{
	public function TimedStatusEffect(stype:StatusEffectType, stat1:String, stat2:String ='', stat3:String ='', stat4:String ='') {
		super(stype, stat1, stat2, stat3, stat4);
	}

	private var duration:int = 1;
	///String to be used in output whenever the round ends.
	private var updateString:String = "";
	///String to be used in output when the status timer reaches 0 and must be removed.
	private var removeString:String = "";
	override public function onCombatEnd():void {
		super.onCombatEnd();
		remove();
	}

	public function setDuration(turns:int):void{
		duration = turns;
	}
	public function getDuration():int{
		return duration;
	}
	/**
	* reduces the timer one tick. Returns true if the timer is 0, meaning it is removed.
	*/
	public function countdownTimer():void{
		duration -= 1;
		if (duration <= 0){
			if (removeString != "") game.outputText(removeString + "\n");
			remove();
		}
		else if (updateString != "") game.outputText(updateString + "\n");
	}

	override public function onCombatRound():void{
		countdownTimer();
	}

	public function setUpdateString(newString:String = ""):void{
		updateString = newString;
	}

	public function setRemoveString(newString:String = ""):void{
		removeString = newString;

	}
}
}


code:
/**
 * Coded by OtherCoCAnon on 15.02.2018.
 */
package classes.StatusEffects.Combat {
import classes.StatusEffectType;

public class Tripped extends TimedStatusEffect {
	public static const TYPE:StatusEffectType = register("Tripped", Tripped);
	public function Tripped(duration:int = 2) {
		super(TYPE, "spe");
		setDuration(duration);
	}

	override public function onCombatRound():void{
		super.onCombatRound();
	}

    override public function onRemove():void{
        host.isImmobilized = false;
    }

    override protected function apply(firstTime:Boolean):void {
        buffHost('spe',-host.spe*0.5);
        setUpdateString(host.capitalA + host.short + " is still unbalanced!");
        setRemoveString(host.capitalA + host.short + " is no longer unbalanced!");
		host.immobilize();
    }

}
}


code:
package classes.StatusEffects.Combat {
import classes.StatusEffectType;

public class VineTangled extends TimedStatusEffect {

	public static const TYPE:StatusEffectType = register("VineTangled", VineTangled);
	public function VineTangled(duration:int = 3) {
		super(TYPE,"");
		setDuration(duration);
	}

	override protected function apply(first:Boolean):void {
		if (playerHost) {
			setUpdateString("Vines coil around your [legs], holding you in place.");
			setRemoveString("You manage to free your [legs] from the vines!");
		}
		host.immobilize();
		super.apply(first);
	}

	override public function onCombatRound():void {
		host.immobilize();
		super.onCombatRound();
	}

	override public function onRemove():void{
		host.isImmobilized = false;
		super.onRemove();
	}
	override public function onCombatEnd():void{
		host.isImmobilized = false;
		super.onCombatEnd();
	}
}

}


code:
/**
 * Coded by aimozg on 22.08.2017.
 */
package classes.StatusEffects.Combat {
import classes.StatusEffectType;

public class WebDebuff extends CombatBuff{
	public static const TYPE:StatusEffectType = register("Web",WebDebuff);
	public function WebDebuff() {
		super(TYPE, 'spe');
	}

	override protected function apply(firstTime:Boolean):void {
		buffHost('spe',-25);
	}
}
}


code:
package classes.StatusEffects.Combat {
	import classes.StatusEffectType;
	import classes.StatusEffects;
	import classes.PerkLib;

	public class WhisperedDebuff extends CombatBuff {
		public static const TYPE:StatusEffectType = register("Whispered", WhisperedDebuff);
		public function WhisperedDebuff() {
			super(TYPE, 'inte');
		}

		override protected function apply(firstTime:Boolean):void {
			if (firstTime) {
				buffHost('inte', -5);
				host.createStatusEffect(StatusEffects.Whispered,0,0,0,0);
			}
			super.apply(firstTime);
		}

		override public function onCombatRound():void {
			var removeChance:int;
			var stunChance:int;
			if (value2 > 0) {
				removeChance = Math.max(10, host.inte / 5);
				stunChance = Math.max(20, 50 - host.inte / 4);
			}
			else {
				removeChance = Math.max(10, host.inte / 4);
				stunChance = Math.max(10, 25 - host.inte / 4);
			}
			if (host.hasPerk(PerkLib.Resolute)) {
				removeChance *= 2;
				stunChance /= 2;
			}
			if (rand(100) < removeChance) {
				if (playerHost) game.outputText("You manage to focus your mind and shake off the constant " + (value2 > 0 ? "mental assault" : "whispering") + ".\n");
				remove();
			}
			else {
				if (playerHost) {
					game.outputText("A chorus of " + (value2 > 0 ? "shrill screams" : "whispers") + " fills your mind with disturbing thoughts, making it hard to focus.");
					if (value2 > 0) {
						host.takeLustDamage(1+rand(5), true);
						buffHost('inte', -5);
					}
					game.outputText("\n");
				}
				if (rand(100) < stunChance) {
					host.createStatusEffect(StatusEffects.Whispered,0,0,0,0);
				}
			}
		}
	}
}