//=============================================================================
// Male2.
//=============================================================================
class RPGAssassin extends HumanCivilian;


var int talked;
var _MMRPGPlayer talkto;

function TakeDamageBase(int Damage, Pawn instigatedBy, Vector hitlocation, Vector momentum, name damageType,
                        bool bPlayAnim)
{}

function Frob(Actor Frobber, Inventory frobWith)
{
	local _MMRPGPlayer Player;
	local Medkit med;

	If (Frobber.IsA('DeusExPlayer'))
	{
		If(talked != 0)
		{
			_MMRPGPlayer(Frobber).ReceiveMessage("Someone is already talking to this person!");
			return;
		}
	}

//	Super.Frob(Frobber, frobWith);
	Player = _MMRPGPlayer(Frobber);
	talkto = Player;

	Player.bInConv = True;
		LookAtActor(Frobber, True, True, False);
	
	if (player.killmission == 1)
	{
		Player.ReceiveMessage("JOHNNY: Don't bother me.");
		talked = 0;
		Player.bInConv = False;
		return;
	}

	if (player.killmission == 2)
	{
		Player.ReceiveMessage(""$Player.PlayerReplicationInfo.PlayerName$": You must be Johnny...");
		talked = 1;
		SetTimer(2.4,False);
		return;
	}

	if (player.killmission == 3)
	{
		Player.ReceiveMessage("JOHNNY: Be quick, I need that businessman on his back.");
		talked = 0;
		Player.bInConv = False;
		return;
	}

	if (player.killmission == 4)
	{
		Player.ReceiveMessage(""$Player.PlayerReplicationInfo.PlayerName$": He's dead.");
		talked = 10;
		SetTimer(2.4,False);
		return;
	}

	if (player.killmission == 5)
	{
		Player.ReceiveMessage("JOHNNY: Good doing business with you.");
		talked = 0;
		Player.bInConv = False;
		return;
	}

}

function Timer()
{
	local Medkit med;
	local MMRPGCreditCard Cred;

	Cred = talkto.CreditCard;


	if (talked == 1)
	{
		talkto.ReceiveMessage("JOHNNY: Who wants to know?");
		talked = 2;
		SetTimer(2.9,False);
		return;
	}

	else if (talked == 2)
	{
		talkto.ReceiveMessage(""$talkto.PlayerReplicationInfo.PlayerName$": I heard that you needed an assassin?");
		talked = 3;
		SetTimer(3.5,False);
		return;
	}

	else if (talked == 3)
	{
		talkto.ReceiveMessage("JOHNNY: Are you an assassin?");
		talked = 4;
		SetTimer(3.0,False);
		return;
	}
	else if (talked == 4)
	{
		talkto.ReceiveMessage(""$talkto.PlayerReplicationInfo.PlayerName$": When necessary");
		talked = 5;
		SetTimer(2.9,False);
		return;
	}
	else if (talked == 5)
	{
		talkto.ReceiveMessage("JOHNNY: Well in that case I have a job for you");
		talked = 6;
		SetTimer(2.9,False);
		return;
	}
	else if (talked == 6)
	{
		talkto.ReceiveMessage("JOHNNY: There's a businessman who's lately been causing me a lot of trouble.");
		talked = 7;
		SetTimer(3.5,False);
		return;
	}
	else if (talked == 7)
	{
		talkto.ReceiveMessage("JOHNNY: Let's just say that I need him dead...");
		talked = 8;
		SetTimer(3.5,False);
		return;
	}
	else if (talked == 8)
	{
		talkto.ReceiveMessage("JOHNNY: He's often lurking around the Players' club.");
		talked = 9;
		SetTimer(3.5,False);
		return;
	}
	else if (talked == 9)
	{
		talkto.ReceiveMessage(""$talkto.PlayerReplicationInfo.PlayerName$": I'll see what I can do.");
		talked = 0;
		talkto.bInConv = False;
		talkto.killmission = 3;
		talkto.ClientMessage("Goal Received (Press F2 for details)");
		return;
	}
	else if (talked == 10)
	{
		talkto.ReceiveMessage("JOHNNY: Yeah? Hmm... this could mean a lot of money for me, and a bonus for you.");
		talked = 11;
		SetTimer(3.5,False);
		return;
	}
	else if (talked == 11)
	{
		talkto.ReceiveMessage(""$talkto.PlayerReplicationInfo.PlayerName$": Well good luck, I guess...");
		talked = 0;
		Cred.CreditAmount +=190;
		talkto.bInConv = False;
		talkto.killmission = 5;
		talkto.SkillPointsAdd(1600);
		talkto.ClientMessage("|p2Goal Completed! 1600 Skill Points and 190c awarded!");
		return;
	}
}


defaultproperties
{
     talked=0
     bfearAlarm=False
     bFearCarcass=False
     bFearDistress=False
     bFearShot=False
     bFearIndirectInjury=False
     Orders=Sitting
     bInvincible=True
     bHateShot=False
     bHateInjury=False
     bReactPresence=False
     bEmitDistress=False
     CarcassType=Class'DeusEx.LowerClassMale2Carcass'
     WalkingSpeed=0.213333
     walkAnimMult=0.750000
     GroundSpeed=180.000000
     Mesh=LodMesh'DeusExCharacters.GM_Suit'
     MultiSkins(0)=Texture'DeusExCharacters.Skins.LowerClassMale2Tex0'
     MultiSkins(1)=Texture'DeusExCharacters.Skins.LowerClassMale2Tex2'
     MultiSkins(2)=Texture'DeusExCharacters.Skins.LowerClassMale2Tex0'
     MultiSkins(3)=Texture'DeusExCharacters.Skins.LowerClassMale2Tex1'
     MultiSkins(4)=Texture'DeusExCharacters.Skins.LowerClassMale2Tex1'
     MultiSkins(5)=Texture'DeusExItems.Skins.GrayMaskTex'
     MultiSkins(6)=Texture'DeusExItems.Skins.BlackMaskTex'
     MultiSkins(7)=Texture'DeusExItems.Skins.PinkMaskTex'
     CollisionRadius=20.000000
     CollisionHeight=47.500000
     BindName="LowerClassMale"
     FamiliarName="Johnny"
     UnfamiliarName="Johnny"
}
