BEGIN BSBGUARD

IF ~See(Player1)
Gender(Player1,FEMALE)
Global("BodhiStrongholdPledged","LOCALS",0)
Global("BodhiStronghold","GLOBAL",2)~ THEN BEGIN pledgeMaster1F
   SAY ~I will serve you, my mistress!~
IF ~~ THEN DO ~SetGlobal("BodhiStrongholdPledged","LOCALS",1)~ EXIT
END

IF ~See(Player1)
!Gender(Player1,FEMALE)
Global("BodhiStrongholdPledged","LOCALS",0)
Global("BodhiStronghold","GLOBAL",2)~ THEN BEGIN pledgeMaster1M
   SAY ~I will serve you, my master!~
IF ~~ THEN DO ~SetGlobal("BodhiStrongholdPledged","LOCALS",1)~ EXIT
END


IF ~See(Player1)
  Gender(Player1,FEMALE)
  Global("GuardResurrected","GLOBAL",1)~
THEN BEGIN greetingStartF
   SAY ~It's you! Why did you resurrect me?~
   ++ ~I will let you live, if you will swear to be my bodyguard as you was for Bodhi.~ + briefingNV1
   ++ ~I have a weakness for body guards. My sexual body needs to be guarded.~ + briefingNV1   
   ++ ~I wanted to kill you once more.~ + briefing3f
END


IF ~See(Player1)
!Gender(Player1,FEMALE)
  Global("GuardResurrected","GLOBAL",1)~
THEN BEGIN greetingStart
   SAY ~It's you! Why did you resurrect me?~
   ++ ~I want you to serve me. Or to die.~ + briefingNV1
   ++ ~I have a weakness for vampires.~ + briefingNV1
   ++ ~I wanted to kill you once more.~ + briefing3f
END


IF ~~ briefingNV1
  SAY ~I can guard you, if you will think about me, and not leave me to fight armed intruders alone.~
  ++ ~Then join my party.~ + briefing2
  ++ ~You are free. I release you.~ + briefing3
  ++ ~Die, cursed monster!~ + briefing3f
END



IF ~~ briefing2
  SAY ~I hope my guarding of you will be more successful.~
  IF ~~ THEN DO ~
  MakeGlobal()
  SetGlobal("GuardResurrected","GLOBAL",2)
  DestroyItem("VVHGUARD")
  GiveItemCreate("VVCASKET",Myself,1,1,0) // Empty Casket		
  JoinParty()
  ~ EXIT
END

IF ~~ briefing3f
  SAY ~I will guard myself!~
  IF ~~ THEN DO ~SetGlobal("GuardResurrected","GLOBAL",2)
SetGlobal("GuardLeft","GLOBAL",1)  
Enemy()
~ EXIT
END

IF ~~ briefing3
  SAY ~Goodbye, <CHARNAME>. I will try to find other master, who is more willing to be guarded.~
  IF ~~ THEN DO ~RunAwayFromNoInterrupt(Player1,50)
  SetGlobal("GuardResurrected","GLOBAL",2)
DestroySelf()
~ EXIT
END

//when thrown out
IF ~Gender(Player1,MALE)
!Global("BodhiStronghold","GLOBAL",2)
!InParty(Myself)~ THEN BEGIN GreetingVManB1
SAY ~Do you need me, my master?~ 
 ++ ~Come with me, Guard, I need your skills.~ + notparty1
 ++ ~Stay here, Guard, I will return.~ + notparty2
  ++ ~You are free to go. I release you from your duties.~ + briefing3 
 ++ ~I decided to end your life.~ + briefing3f
END

IF ~~ notparty2
SAY ~Okay, master!~
IF ~~ THEN DO ~~ EXIT
END

IF ~Gender(Player1,FEMALE)
!Global("BodhiStronghold","GLOBAL",2)
!InParty(Myself)~ THEN BEGIN GreetingVFemB1
SAY ~Do you need me, my mistress?~ 
 ++ ~Return, Guard, I need you, my servant.~ + notparty1
 ++ ~Stay here, Guard, I will return.~ + notparty2
  ++ ~You are free to go. I release you from your duties.~ + briefing3 
  ++ ~I decided to end your life.~ + briefing3f
END

IF ~Gender(Player1,FEMALE)
Global("BodhiStronghold","GLOBAL",2)
!InParty(Myself)~ THEN BEGIN GreetingVFemB1
SAY ~Do you need me, my mistress?~ 
 ++ ~Return, Guard, I need you, my servant.~ + notparty1
 ++ ~Go to our Stronghold in Grave Yard District. I will find you there, if it will be needed.~ + notpartGoST
 ++ ~Stay here, Guard, I will return.~ + notparty2
  ++ ~You are free to go. I release you from your duties.~ + briefing3 
 ++ ~I decided to end your life.~ + briefing3f
END

IF ~Gender(Player1,MALE)
Global("BodhiStronghold","GLOBAL",2)
!InParty(Myself)~ THEN BEGIN GreetingVMaleB1
SAY ~Do you need me, my master?~ 
 ++ ~Return, Guard, I need you, my servant.~ + notparty1
 ++ ~Go to our Stronghold in Grave Yard District. I will find you there, if it will be needed.~ + notpartGoST
 ++ ~Stay here, Guard, I will return.~ + notparty2
  ++ ~You are free to go. I release you from your duties.~ + briefing3 
 ++ ~I decided to end your life.~ + briefing3f
END

IF ~~ notparty1m
  SAY ~I was starting to get bored.~
  IF ~~ THEN DO ~
	//	DestroyItem("VVGuard")
	//	DestroyItem("MONHP1")
		JoinParty()~ EXIT
END

IF ~~ notparty1
  SAY ~I was starting to get bored.~
  IF ~~ THEN DO ~
		JoinParty()~ EXIT
END

IF ~~ notpartGoST
   SAY ~As you command!~
   IF ~~ THEN DO ~LeaveParty()
   RunAwayFromNoInterrupt(Player1,40)
   MoveBetweenAreas("AR0808",[2155.676],N)~ EXIT
 END  

// talk in party

IF ~Gender(Player1,MALE)
InParty(Myself)
Race(Player1,VAMPIRE)~ THEN BEGIN GreetingManV1
SAY ~My master, do you need something?~ 
 ++ ~Are you hungry? You can drink my blood, Guard.~ + suckblood
 ++ ~Tell me your story, Guard.~ + talkGuardM
 ++ ~No, nothing, sorry, Guard.~ + byesilent
  ++ ~I decided to end your life.~ + briefing3f
END

IF ~Gender(Player1,FEMALE)
InParty(Myself)
Race(Player1,VAMPIRE)~ THEN BEGIN GreetingFemV1
SAY ~My mistress, do you need something?~ 
 ++ ~Are you hungry? You can drink my blood, Guard.~ + suckblood
 ++ ~Tell me your story, Guard.~ + talkGuardF
 ++ ~No, nothing, sorry, Guard.~ + byesilent
  ++ ~I decided to end your life.~ + briefing3f
END

IF ~Gender(Player1,MALE)
InParty(Myself)
!Race(Player1,VAMPIRE)~ THEN BEGIN GreetingMan1
SAY ~<CHARNAME>, do you need something?~ 
 ++ ~Are you hungry? You can drink my blood, Guard.~ + suckblood
 ++ ~Make me a vampire, Guard.~ + vampconvm
 ++ ~Tell me your story, Guard.~ + talkGuardM
 ++ ~No, nothing, sorry, Guard.~ + byesilent
   ++ ~I decided to end your life.~ + briefing3f
END

IF ~Gender(Player1,FEMALE)
InParty(Myself)
!Race(Player1,VAMPIRE)~ THEN BEGIN GreetingFem1
SAY ~<CHARNAME>, do you need something?~ 
 ++ ~Are you hungry? You can drink my blood, Guard.~ + suckblood
 ++ ~Make me a vampire, Guard.~ + vampconvf 
 ++ ~Tell me your story, Guard.~ +   talkGuardM
 ++ ~No, nothing, sorry, Guard.~ + byesilent
   ++ ~I decided to end your life.~ + briefing3f
END

IF ~~ byesilent
SAY ~As you want!~
  IF ~~ THEN DO ~~ EXIT
END


IF ~~ talkGuardM
  SAY ~There is nothing to tell. I was working as a bodyguard from my young years. When Bodhi moved to Ahkatla, she killed my boss. I was good enough to defend him and defeated Tanova and Ulvaril, being an ordinary man.~
  IF ~~ THEN GOTO talkGuardM2
END

IF ~~ talkGuardM2
  SAY ~Bodhi decided I am resourceful and imprisoned me. Than I agreed to become vampire and guard her beautiful body.~
  IF ~~ THEN GOTO talkGuardM3
END

IF ~~ talkGuardM3
  SAY ~I hope you will be better master than Bodhi.~
  IF ~~ THEN EXIT
END


IF ~~ talkGuardF
 SAY ~There is nothing to tell. I was working as a bodyguard from my young years. When Bodhi moved to Ahkatla, she killed my boss. I was good enough to defend him and defeated Tanova and Ulvaril, being an ordinary man.~
  IF ~~ THEN GOTO talkGuardF2
END

IF ~~ talkGuardF2
 SAY ~Bodhi decided I am resourceful and imprisoned me. Than I agreed to become vampire and guard her beautiful body.~
  IF ~~ THEN GOTO talkGuardF3
END

IF ~~ talkGuardF3
  SAY ~I hope you will be better mistress than Bodhi. Your body is good as Bodhi's.~
   IF ~~ THEN EXIT
END


IF ~~ suckblood
  SAY ~I don't drink on work.~
  IF ~!Global("Player1RaceBlood","GLOBAL",4)~ THEN GOTO suckbloodNo  
  IF ~Global("Player1RaceBlood","GLOBAL",4)~ THEN GOTO suckblood2
END

IF ~~ suckbloodNo
  SAY ~And I don't drink this liquid.~
  IF ~~ THEN DO ~~ EXIT
END

IF ~~ suckblood2
  SAY ~At other point of view, it's a work!~
  IF ~~ THEN DO ~ApplyDamagePercent(Player1,80,MAGIC)
  SetGlobalTimer("BloodlustTimer","LOCALS",ONE_DAY)
		ApplySpell(Myself,RESTORE_FULL_HEALTH)~ EXIT 
END

IF ~~ vampconvm
  SAY ~(Guard gets closer.)~
  IF ~!Global("Player1RaceBlood","GLOBAL",4)~ THEN GOTO suckbloodNo  
  IF ~Global("Player1RaceBlood","GLOBAL",4)~ THEN GOTO vampconv2
END


IF ~~ vampconvf
  SAY ~(Guard's teeth go out and bites you in your neck.)~
  IF ~!Global("Player1RaceBlood","GLOBAL",4)~ THEN GOTO suckbloodNo  
  IF ~Global("Player1RaceBlood","GLOBAL",4)~ THEN GOTO vampconv2
END

IF ~~ vampconv2
  SAY ~(Suddently you feel his teeths have pierced your skin and gone to carotid vein. Blood flow is distracted and becomes pulsating. You feel that your blood flows into Guard.)~
IF ~~ GOTO vampconv3
END

IF ~~ vampconv3
  SAY ~(Soon you feel great weakness, your throuths are clouded. And you loose consciousness.)~
IF ~~ GOTO vampconv4
END

IF ~~ vampconv4
  SAY ~(...You open your eyes. World around you have changed. You have changed. You feel coldness of your body and immediately you feel all-consuming hunger growing in you.)~
IF ~~ GOTO vampconv5
END

IF ~~ vampconv5
  SAY ~(You are now undead, as you wished. Now you feel presence of Guard and his wary throughts. He will be loyal to you, if you will be loyal to him.)~

  IF ~~ THEN DO ~  ActionOverride(Player1,SetGlobal("ActorVampirisedLevel","LOCALS",2))
		ChangeStat(Player1,CON,3,ADD)
		ChangeStat(Player1,STR,1,ADD)
		ChangeStat(Player1,WIS,-2,ADD)
		ChangeStat(Player1,INT,-1,ADD)
	

		SetGlobal("GuardVampirized","GLOBAL",1)	
	~ EXIT
END


