forked from alterware/iw6-mod
Various minor tweaks (not user-facing).
This commit is contained in:
@@ -25,8 +25,8 @@ namespace // demo class
|
|||||||
[[nodiscard]] bool rewind_demo(std::optional<std::uint32_t> msec);
|
[[nodiscard]] bool rewind_demo(std::optional<std::uint32_t> msec);
|
||||||
[[nodiscard]] bool start(std::filesystem::path& path, bool repeat);
|
[[nodiscard]] bool start(std::filesystem::path& path, bool repeat);
|
||||||
[[nodiscard]] std::optional<std::reference_wrapper<std::filesystem::path>> restart();
|
[[nodiscard]] std::optional<std::reference_wrapper<std::filesystem::path>> restart();
|
||||||
template <typename Func, typename... Args> auto use_predicted_data(Func func, Args&&... args);
|
template <typename Func, typename... Args> [[nodiscard]] auto use_predicted_data(Func func, Args&&... args);
|
||||||
template <typename Func, typename... Args> auto handle_fast_forward(Func func, Args&&... args);
|
template <typename Func, typename... Args> [[nodiscard]] auto handle_fast_forward(Func func, Args&&... args);
|
||||||
|
|
||||||
void parse_demo_wrapper();
|
void parse_demo_wrapper();
|
||||||
void stop();
|
void stop();
|
||||||
|
|||||||
@@ -83,10 +83,12 @@ namespace // checked client num class
|
|||||||
return std::isdigit(c);
|
return std::isdigit(c);
|
||||||
});
|
});
|
||||||
|
|
||||||
|
if (all_digits)
|
||||||
|
{
|
||||||
auto value = std::numeric_limits<std::size_t>::max();
|
auto value = std::numeric_limits<std::size_t>::max();
|
||||||
const auto ec = std::from_chars(pid.data(), pid.data() + pid.size(), value).ec;
|
const auto ec = std::from_chars(pid.data(), pid.data() + pid.size(), value).ec;
|
||||||
|
|
||||||
if (all_digits && ec == std::errc{})
|
if (ec == std::errc{})
|
||||||
{
|
{
|
||||||
const auto client_num = check_client_num(value);
|
const auto client_num = check_client_num(value);
|
||||||
if (client_num)
|
if (client_num)
|
||||||
@@ -95,6 +97,7 @@ namespace // checked client num class
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
for (const auto& cl : game::mp::svs->clients)
|
for (const auto& cl : game::mp::svs->clients)
|
||||||
{
|
{
|
||||||
|
|||||||
Reference in New Issue
Block a user