forked from metin2/server
remove unnecessary leftover closures
This commit is contained in:
parent
dbcabd7fa9
commit
0a907f41d2
|
@ -215,9 +215,7 @@ EVENTFUNC(oxevent_timer)
|
|||
SendNoticeMap(LC_TEXT("No (X)"), OXEVENT_MAP_INDEX, true);
|
||||
}
|
||||
|
||||
{
|
||||
SendNoticeMap(LC_TEXT("In 5 sec. everyone who gave an incorrect answer will be removed."), OXEVENT_MAP_INDEX, true);
|
||||
}
|
||||
|
||||
flag++;
|
||||
return PASSES_PER_SEC(5);
|
||||
|
|
|
@ -205,20 +205,15 @@ int CalcMagicDamage(LPCHARACTER pkAttacker, LPCHARACTER pkVictim)
|
|||
|
||||
float CalcAttackRating(LPCHARACTER pkAttacker, LPCHARACTER pkVictim, bool bIgnoreTargetRating)
|
||||
{
|
||||
int iARSrc;
|
||||
int iERSrc;
|
||||
int iARSrc = std::min(90, (attacker_dx * 4 + attacker_lv * 2) / 6);
|
||||
int iERSrc = std::min(90, (victim_dx * 4 + victim_lv * 2) / 6);
|
||||
|
||||
{
|
||||
int attacker_dx = pkAttacker->GetPolymorphPoint(POINT_DX);
|
||||
int attacker_lv = pkAttacker->GetLevel();
|
||||
|
||||
int victim_dx = pkVictim->GetPolymorphPoint(POINT_DX);
|
||||
int victim_lv = pkAttacker->GetLevel();
|
||||
|
||||
iARSrc = std::min(90, (attacker_dx * 4 + attacker_lv * 2) / 6);
|
||||
iERSrc = std::min(90, (victim_dx * 4 + victim_lv * 2) / 6);
|
||||
}
|
||||
|
||||
float fAR = ((float) iARSrc + 210.0f) / 300.0f; // fAR = 0.7 ~ 1.0
|
||||
|
||||
if (bIgnoreTargetRating)
|
||||
|
|
|
@ -2112,10 +2112,8 @@ void CHARACTER::ComputeBattlePoints()
|
|||
iArmor += GetPoint(POINT_PARTY_DEFENDER_BONUS);
|
||||
|
||||
// INTERNATIONAL_VERSION
|
||||
{
|
||||
PointChange(POINT_DEF_GRADE, iDef + iArmor);
|
||||
PointChange(POINT_CLIENT_DEF_GRADE, (iShowDef + iArmor) - GetPoint(POINT_DEF_GRADE));
|
||||
}
|
||||
// END_OF_INTERNATIONAL_VERSION
|
||||
|
||||
PointChange(POINT_MAGIC_ATT_GRADE, GetLevel() * 2 + GetPoint(POINT_IQ) * 2 + GetPoint(POINT_MAGIC_ATT_GRADE_BONUS));
|
||||
|
@ -5124,11 +5122,9 @@ bool CHARACTER::WarpSet(int x, int y, int lPrivateMapIndex)
|
|||
|
||||
GetDesc()->Packet(&p, sizeof(TPacketGCWarp));
|
||||
|
||||
{
|
||||
char buf[256];
|
||||
snprintf(buf, sizeof(buf), "%s MapIdx %d DestMapIdx%d DestX%d DestY%d Empire%d", GetName(), GetMapIndex(), lPrivateMapIndex, x, y, GetEmpire());
|
||||
LogManager::instance().CharLog(this, 0, "WARP", buf);
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
|
|
@ -473,7 +473,6 @@ bool CHARACTER::LearnSkillByBook(DWORD dwSkillVnum, BYTE bProb)
|
|||
|
||||
SPDLOG_DEBUG("LearnSkillByBook {} table idx {} value {}", GetName(), idx, aiSkillBookCountForLevelUp[idx]);
|
||||
|
||||
{
|
||||
int need_bookcount = GetSkillLevel(dwSkillVnum) - 20;
|
||||
|
||||
PointChange(POINT_EXP, -need_exp);
|
||||
|
@ -538,7 +537,6 @@ bool CHARACTER::LearnSkillByBook(DWORD dwSkillVnum, BYTE bProb)
|
|||
// 사용자의 퀘스트 정보 로드 실패
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (bLastLevel != GetSkillLevel(dwSkillVnum))
|
||||
{
|
||||
|
|
|
@ -271,7 +271,6 @@ EVENTFUNC(timed_event)
|
|||
{
|
||||
ch->m_pkTimedEvent = NULL;
|
||||
|
||||
{
|
||||
switch (info->subcmd)
|
||||
{
|
||||
case SCMD_LOGOUT:
|
||||
|
@ -287,7 +286,6 @@ EVENTFUNC(timed_event)
|
|||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
switch (info->subcmd)
|
||||
{
|
||||
|
@ -2233,7 +2231,6 @@ ACMD(do_cube)
|
|||
|
||||
ACMD(do_in_game_mall)
|
||||
{
|
||||
{
|
||||
char country_code[3];
|
||||
country_code[0] = 'd'; country_code[1] = 'e'; country_code[2] = '\0';
|
||||
|
||||
|
@ -2243,7 +2240,6 @@ ACMD(do_in_game_mall)
|
|||
g_strWebMallURL.c_str(), ch->GetPlayerID(), country_code, g_server_id);
|
||||
|
||||
ch->ChatPacket(CHAT_TYPE_COMMAND, buf);
|
||||
}
|
||||
}
|
||||
|
||||
// 주사위
|
||||
|
|
|
@ -355,7 +355,6 @@ void DBManager::AnalyzeReturnQuery(SQLMsg * pMsg)
|
|||
|
||||
char szCreateDate[256] = "00000000";
|
||||
|
||||
{
|
||||
str_to_number(aiPremiumTimes[PREMIUM_EXP], row[col++]);
|
||||
str_to_number(aiPremiumTimes[PREMIUM_ITEM], row[col++]);
|
||||
str_to_number(aiPremiumTimes[PREMIUM_SAFEBOX], row[col++]);
|
||||
|
@ -374,7 +373,6 @@ void DBManager::AnalyzeReturnQuery(SQLMsg * pMsg)
|
|||
|
||||
SPDLOG_DEBUG("Create_Time {} {}", retValue, szCreateDate);
|
||||
SPDLOG_DEBUG("Block Time {} ", strncmp(szCreateDate, g_stBlockDate.c_str(), 8));
|
||||
}
|
||||
|
||||
int nPasswordDiff = strcmp(szEncrytPassword, szPassword);
|
||||
|
||||
|
|
|
@ -1085,10 +1085,8 @@ void CItem::SetOwnership(LPCHARACTER ch, int iSec)
|
|||
if (m_pkOwnershipEvent)
|
||||
return;
|
||||
|
||||
{
|
||||
if (iSec <= 10)
|
||||
iSec = 30;
|
||||
}
|
||||
|
||||
m_dwOwnershipPID = ch->GetPlayerID();
|
||||
|
||||
|
|
|
@ -228,11 +228,7 @@ CCI * P2P_MANAGER::FindByPID(DWORD pid)
|
|||
|
||||
CCI * P2P_MANAGER::Find(const char * c_pszName)
|
||||
{
|
||||
TCCIMap::const_iterator it;
|
||||
|
||||
{
|
||||
it = m_map_pkCCI.find(c_pszName);
|
||||
}
|
||||
TCCIMap::const_iterator it = m_map_pkCCI.find(c_pszName);
|
||||
|
||||
if (it == m_map_pkCCI.end())
|
||||
return NULL;
|
||||
|
|
Loading…
Reference in New Issue