bool isMechAllowed(AuthMechanism mech)
{ return allowed_auth_mechs & mech; }
- RemoteClient() = default;
+ RemoteClient();
~RemoteClient() = default;
/*
u32 getSendingCount() const { return m_blocks_sending.size(); }
+ bool isBlockSent(v3s16 p) const
+ {
+ return m_blocks_sent.find(p) != m_blocks_sent.end();
+ }
+
// Increments timeouts and removes timed-out blocks from list
// NOTE: This doesn't fix the server-not-sending-block bug
// because it is related to emerging, not sending.
v3s16 m_last_center;
float m_nearest_unsent_reset_timer = 0.0f;
+ const u16 m_max_simul_sends;
+ const float m_min_time_from_building;
+ const s16 m_max_send_distance;
+ const s16 m_block_optimize_distance;
+ const s16 m_max_gen_distance;
+ const bool m_occ_cull;
+
/*
Blocks that are currently on the line.
This is used for throttling the sending of blocks.
void step(float dtime);
/* get list of active client id's */
- std::vector<u16> getClientIDs(ClientState min_state=CS_Active);
+ std::vector<session_t> getClientIDs(ClientState min_state=CS_Active);
+
+ /* mark block as not sent to active client sessions */
+ void markBlockposAsNotSent(const v3s16 &pos);
/* verify is server user limit was reached */
bool isUserLimitReached();