///////////////////////////////////////////////////////////////////////////////
//
// File   : AVP_AlienQueen_MeleeCounter_System.cpp
// Author : David Wooldridge
// Date   : 06/11/2008
//
// Copyright (C) 2008 Rebellion, All Rights Reserved.
//
///////////////////////////////////////////////////////////////////////////////

#include "Core/Asura.h"

// This files header
#include "Actor/Vertebrates/AlienQueen/AVP_AlienQueen_MeleeCounter_System.h"

// AVP
#include "Blueprint/AVP_Blueprint_HashIDs.h"
#include "Entity/AVP_Entity_Classification.h"
#include "Entity/PhysicalObject/Actor/Vertebrates/AlienQueen/AVP_ServerActor_AlienQueen.h"
#include "Inventory/AVP_Inventory_HashIDs.h"
#include "Inventory/AVP_Inventory_System.h"
#include "Moves/Vertebrates/AlienQueen/AVP_AlienQueen_MovesMelee.h"

AVP_AlienQueen_MeleeCounter_System::AVP_AlienQueen_MeleeCounter_System(AVP_ServerActor_AlienQueen& xOwner)
: AVP_Vertebrate_MeleeCounter_System(xOwner)
{
}

Asura_Hash_ID AVP_AlienQueen_MeleeCounter_System::GetMeleeMoveHash(u_int uType) const
{
	switch (uType)
	{
		////////////////////
		case AVP_ALIENQUEEN_MELEEATTACK_TYPE_PRIMARYATTACK:
		case AVP_MELEEATTACK_TYPE_NORMAL: // TODO - Probably wants to be its own attack.
		////////////////////
		{
			return AVP_AlienQueen_Move_Melee_Charge_BuildUp::GetStaticHash();
		}
		////////////////////
		case AVP_ALIENQUEEN_MELEEATTACK_TYPE_SLASH_R:
		////////////////////
		{
			return AVP_AlienQueen_Move_Melee_ClawSwipe_Right_Start::GetStaticHash();
		}
		////////////////////
		case AVP_ALIENQUEEN_MELEEATTACK_TYPE_SLASH_L:
		////////////////////
		{
			return AVP_AlienQueen_Move_Melee_ClawSwipe_Left_Start::GetStaticHash();
		}
		////////////////////
		case AVP_ALIENQUEEN_MELEEATTACK_TYPE_SLASHLOOP_L:
		////////////////////
		{
			return AVP_AlienQueen_Move_Melee_ClawSwipe_Left_Loop_Start::GetStaticHash();
		}
		////////////////////
		case AVP_ALIENQUEEN_MELEEATTACK_TYPE_SLASHLOOP_R:
		////////////////////
		{
			return AVP_AlienQueen_Move_Melee_ClawSwipe_Right_Loop_Start::GetStaticHash();
		}
		////////////////////
		case AVP_ALIENQUEEN_MELEEATTACK_TYPE_CLAWSWIPEKILL_GRAPPLE:
		////////////////////
		{
			return AVP_AlienQueen_Move_Melee_ClawSwipeKill_Start::GetStaticHash();
		}
		////////////////////
		case AVP_ALIENQUEEN_MELEEATTACK_TYPE_POST_ATTACK_ROAR:
		////////////////////
		{
			return AVP_AlienQueen_Move_Melee_Stationary_Roar::GetStaticHash();
		}
		////////////////////
		default:
		////////////////////
		{
			return PARENT::GetMeleeMoveHash(uType);
		}
	}
}

float AVP_AlienQueen_MeleeCounter_System::GetAttackDamage() const
{
	switch (m_uCurrentAttackType)
	{
		////////////////////
		case AVP_ALIENQUEEN_MELEEATTACK_TYPE_PRIMARYATTACK:
		case AVP_MELEEATTACK_TYPE_NORMAL:
		////////////////////
		{
			return m_fMajorDamageAmount;
		}

		////////////////////
		case AVP_ALIENQUEEN_MELEEATTACK_TYPE_SLASH_R:
		case AVP_ALIENQUEEN_MELEEATTACK_TYPE_SLASH_L:
		case AVP_ALIENQUEEN_MELEEATTACK_TYPE_SLASHLOOP_L:
		case AVP_ALIENQUEEN_MELEEATTACK_TYPE_SLASHLOOP_R:
		////////////////////
		{
			return m_fMinorDamageAmount;
		}

		////////////////////
		case AVP_ALIENQUEEN_MELEEATTACK_TYPE_CLAWSWIPEKILL_GRAPPLE:
		////////////////////
		{
			return 0.0f;
		}

		////////////////////
		default:
		////////////////////
		{
			return PARENT::GetAttackDamage();
		}
	}
}

Asura_Hash_ID AVP_AlienQueen_MeleeCounter_System::GetAttackDamageType() const
{
	switch (m_uCurrentAttackType)
	{
		////////////////////
		case AVP_ALIENQUEEN_MELEEATTACK_TYPE_PRIMARYATTACK:
		case AVP_MELEEATTACK_TYPE_NORMAL:
		////////////////////
		{
			return uAVP_BLUEPRINT_NAME_DAMAGE_MELEE;
		}

		////////////////////
		case AVP_ALIENQUEEN_MELEEATTACK_TYPE_SLASH_R:
		case AVP_ALIENQUEEN_MELEEATTACK_TYPE_SLASH_L:
		case AVP_ALIENQUEEN_MELEEATTACK_TYPE_SLASHLOOP_L:
		case AVP_ALIENQUEEN_MELEEATTACK_TYPE_SLASHLOOP_R:
		////////////////////
		{
			return uAVP_BLUEPRINT_NAME_DAMAGE_CLAW;
		}

		////////////////////
		case AVP_ALIENQUEEN_MELEEATTACK_TYPE_CLAWSWIPEKILL_GRAPPLE:
		////////////////////
		{
			return uAVP_BLUEPRINT_NAME_DAMAGE_GRAPPLE;
		}
	
		////////////////////
		default:
		////////////////////
		{
			return PARENT::GetAttackDamageType();
		}
	}
}

