clang format
This commit is contained in:
parent
03f74192d5
commit
52c35ad2ff
@ -165,7 +165,8 @@ CachedEntity *NearestEnemy()
|
|||||||
ent->m_iTeam() == LOCAL_E->m_iTeam())
|
ent->m_iTeam() == LOCAL_E->m_iTeam())
|
||||||
continue;
|
continue;
|
||||||
float scr = ent->m_flDistance();
|
float scr = ent->m_flDistance();
|
||||||
if (g_pPlayerResource->GetClass(ent) == tf_engineer || g_pPlayerResource->GetClass(ent) == tf_heavy)
|
if (g_pPlayerResource->GetClass(ent) == tf_engineer ||
|
||||||
|
g_pPlayerResource->GetClass(ent) == tf_heavy)
|
||||||
scr *= 5.0f;
|
scr *= 5.0f;
|
||||||
if (g_pPlayerResource->GetClass(ent) == tf_pyro)
|
if (g_pPlayerResource->GetClass(ent) == tf_pyro)
|
||||||
scr *= 7.0f;
|
scr *= 7.0f;
|
||||||
@ -361,9 +362,11 @@ bool NavToEnemy()
|
|||||||
{
|
{
|
||||||
int nearestvalid{};
|
int nearestvalid{};
|
||||||
if (!*heavy_mode)
|
if (!*heavy_mode)
|
||||||
nearestvalid = nav::FindNearestValidbyDist(ent->m_vecOrigin(), 2000, 6000);
|
nearestvalid =
|
||||||
|
nav::FindNearestValidbyDist(ent->m_vecOrigin(), 2000, 6000);
|
||||||
else
|
else
|
||||||
nearestvalid = nav::FindNearestValidbyDist(ent->m_vecOrigin(), 200, 1000);
|
nearestvalid =
|
||||||
|
nav::FindNearestValidbyDist(ent->m_vecOrigin(), 200, 1000);
|
||||||
if (nearestvalid != -1)
|
if (nearestvalid != -1)
|
||||||
{
|
{
|
||||||
auto area = nav::areas[nearestvalid];
|
auto area = nav::areas[nearestvalid];
|
||||||
|
14
src/irc.cpp
14
src/irc.cpp
@ -130,7 +130,9 @@ void cc_party(std::string &msg)
|
|||||||
}
|
}
|
||||||
else if (answer_steam && msg.find("cc_partysteam") == 0)
|
else if (answer_steam && msg.find("cc_partysteam") == 0)
|
||||||
{
|
{
|
||||||
irc.privmsg(format("cc_partysteamrep", g_ISteamUser->GetSteamID().GetAccountID()), true);
|
irc.privmsg(format("cc_partysteamrep",
|
||||||
|
g_ISteamUser->GetSteamID().GetAccountID()),
|
||||||
|
true);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
void cc_cmd(std::string &msg)
|
void cc_cmd(std::string &msg)
|
||||||
@ -250,11 +252,14 @@ static HookedFunction paint(HookedFunctions_types::HF_Paint, "IRC", 16, []() {
|
|||||||
idx = i;
|
idx = i;
|
||||||
}
|
}
|
||||||
if (idx != -1)
|
if (idx != -1)
|
||||||
hack::command_stack().push(format("tf_party_request_join_user ", steamidvec[idx]));
|
hack::command_stack().push(
|
||||||
|
format("tf_party_request_join_user ", steamidvec[idx]));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (irc_party && last_sent_steamid.test_and_set(*party_cooldown * 1000))
|
if (irc_party && last_sent_steamid.test_and_set(*party_cooldown * 1000))
|
||||||
irc.privmsg(format("cc_partysteam", g_ISteamUser->GetSteamID().GetAccountID()), true);
|
irc.privmsg(format("cc_partysteam",
|
||||||
|
g_ISteamUser->GetSteamID().GetAccountID()),
|
||||||
|
true);
|
||||||
irc.Update();
|
irc.Update();
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
@ -303,7 +308,8 @@ static CatCommand irc_exec_all("irc_exec_all", "Send command to C&C channel",
|
|||||||
irc.privmsg(msg, true);
|
irc.privmsg(msg, true);
|
||||||
});
|
});
|
||||||
|
|
||||||
static CatCommand invite_all("irc_invite_all", "Inivte all people in C&C channel",
|
static CatCommand invite_all(
|
||||||
|
"irc_invite_all", "Inivte all people in C&C channel",
|
||||||
[](const CCommand &args) {
|
[](const CCommand &args) {
|
||||||
std::string msg("cc_cmdtf_party_request_join_user ");
|
std::string msg("cc_cmdtf_party_request_join_user ");
|
||||||
msg.append(std::to_string(g_ISteamUser->GetSteamID().GetAccountID()));
|
msg.append(std::to_string(g_ISteamUser->GetSteamID().GetAccountID()));
|
||||||
|
Reference in New Issue
Block a user