Files
Sun1602/Server/GameServer/World/ChaosZoneSystem/BattleGroundTeam.h
T
2022-10-26 12:25:11 +08:00

82 lines
2.9 KiB
C++

#pragma once
//_NA_005026_20120527_CHAOS_ZONE_BATTLE_GROUND
class BattleGround;
struct BattleGroundInfo;
//_NA_007065_20140217_BATTLEGROUND_REFACTORYING
#include "World/ChaosZoneSystem/ChaosZoneBattleTeam.h"
class BattleGroundTeam : public ChaosZoneBattleTeam
{
public:
explicit BattleGroundTeam(BattleGround* const battle_ground);
virtual ~BattleGroundTeam() {}
void Update();
void Start();
void AddMember(Player* const player);
void AllDeathMemberResurrectionAtSafezone();
RC::eSTATUS_RESULT OnMoveToSafezone(Player* const player);
void OnResult(const eBATTLEGROUND_RESULT result_type);
void IncreasePlayerKillPoint(Player* const player, Player* const target_player);
void IncreaseVictroyPoint(const int increase_victory_point);
void IncreaseStrongpointCount() { ++strongpoint_count_; }
void DecreaseStrongpointCount()
{
if (strongpoint_count_ > 0)
--strongpoint_count_;
}
#ifdef _NA_008679_20160202_REWORK_BATTLEGROUND
VOID SetPlayerFalseName(Player* _player);
VOID SetFalseCostumeCode(const SLOTCODE& code) {false_costume_code_ = code;}
SLOTCODE GetFalseCostumeCode() {return false_costume_code_;}
#endif //_NA_008679_20160202_REWORK_BATTLEGROUND
#ifdef _NA_006800_20130703_BATTLE_GROUND_VOTE_SYSTEM
bool IsInitialteTime();
bool OnInitiateVote(Player* initiate_player, Player* van_player);
void OnVote(CHARGUID char_guid, bool vote_result);
bool CheckVoteResult();
void OnVoteResult(bool van_result);
void OnVanPlayer();
inline bool GetIsInitiateVote() { return is_initialte_vote_; }
#endif //_NA_006800_20130703_BATTLE_GROUND_VOTE_SYSTEM
// inline..
inline void SetBattleGroundInfo(const BattleGroundInfo* battle_ground_Info) { battle_ground_Info_ = battle_ground_Info; }
inline BYTE GetStrongpointCount() const { return strongpoint_count_; }
inline WORD GetVictoryPoint() const { return victory_point_; }
private:
bool _IsExpired();
void _End();
void _OnReward(Player* const player, const eBATTLEGROUND_RESULT result_type);
void _OnFinishResult(Player* const player, const eBATTLEGROUND_RESULT result_type);
private:
BattleGround* battle_ground_;
const BattleGroundInfo* battle_ground_Info_; // 전장파서
WORD victory_point_; // 거점 점령 포인트(승점)
BYTE strongpoint_count_; // 현재 거점 점령 갯수
#ifdef _NA_006800_20130703_BATTLE_GROUND_VOTE_SYSTEM
bool is_initialte_vote_;
TCHAR van_player_name_[MAX_CHARNAME_LENGTH];
PLAYER_HASH vote_player_hash_map_; // 투표를 진행한 멤버 리스트
util::Timer voting_timer_; // 투표 진행 시간.. 30초..
util::Timer initialte_vote_timer_; // 투표 발의 가능 시간. 1분..
#endif //_NA_006800_20130703_BATTLE_GROUND_VOTE_SYSTEM
#ifdef _NA_008679_20160202_REWORK_BATTLEGROUND
SLOTCODE false_costume_code_; // MAKEWORD(clothes, weapon)
#endif //_NA_008679_20160202_REWORK_BATTLEGROUND
};