#ifndef _G_PLAYER_SETTING_
#define _G_PLAYER_SETTING_

#include "GEnum.h"

#include <hpllib/HPLLib.h>

class AttackSetting {
public:
	int		m_nAttackType;	//! 攻撃手法の種類
	int		m_nProjectile;	//! ショットのタイプ
	float	m_fBlow;		//! 体当たりで吹き飛ぶスピード
	float	m_fDamage;		//! 体当たりで与えるダメージ量
	bool	m_bIsUseJumpAttackSequence;	//! ジャンプ中の攻撃絵をJUMP_ATTACKに変えるか
	HPLVector m_vDelta;		//! 発射位置の相対座標 From Center
	bool	m_bIsContinueAnimation;	//! 押しっぱなしの場合にアニメーションを継続するか


	AttackSetting() {
		this->m_nAttackType = GEnum::AttackType::SHOT;
		this->m_nProjectile = -1;
		this->m_fBlow = SETTING_NONE;
		this->m_fDamage = SETTING_NONE;
		this->m_bIsUseJumpAttackSequence = false;
		this->m_bIsContinueAnimation = false;
	}
	~AttackSetting(){}
};

class GPlayerSetting {
public:
	std::string		m_strName;	//! 名前
	HPLVector		m_vSize;	//! 画像サイズ。統一すること
	HPLRect			m_rHitRect;	//! 当たり判定

	std::vector<AttackSetting> m_vecAttacks;	//! 攻撃設定
public:
	GPlayerSetting() {
		m_strName = std::string("？？？");
		this->m_vSize = HPLVector(96,96);
		this->m_rHitRect.set(37,30,25,65);
		for( int i = 0; i < GEnum::PlayerSettingAttackType::MAX_NUM; i ++ ) {
			this->m_vecAttacks.push_back(AttackSetting());
		}
	}
	void load( const char* lpSettingFilePath );
	~GPlayerSetting(){}
};

#endif
