mirror of
https://github.com/alliedmodders/sourcemod.git
synced 2025-12-16 17:27:17 +00:00
Add methods for clearing netprop cache
This commit is contained in:
parent
850f96b986
commit
88f0c74b79
@ -503,6 +503,26 @@ bool CHalfLife2::FindDataMapInfo(datamap_t *pMap, const char *offset, sm_datatab
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void CHalfLife2::ClearDataTableCache()
|
||||||
|
{
|
||||||
|
m_Maps.clear();
|
||||||
|
}
|
||||||
|
|
||||||
|
void CHalfLife2::ClearDataTableCache(datamap_t *pMap)
|
||||||
|
{
|
||||||
|
m_Maps.removeIfExists(pMap);
|
||||||
|
}
|
||||||
|
|
||||||
|
void CHalfLife2::ClearSendPropCache()
|
||||||
|
{
|
||||||
|
m_Classes.clear();
|
||||||
|
}
|
||||||
|
|
||||||
|
bool CHalfLife2::ClearSendPropCache(const char *classname)
|
||||||
|
{
|
||||||
|
return m_Classes.remove(classname);
|
||||||
|
}
|
||||||
|
|
||||||
void CHalfLife2::SetEdictStateChanged(edict_t *pEdict, unsigned short offset)
|
void CHalfLife2::SetEdictStateChanged(edict_t *pEdict, unsigned short offset)
|
||||||
{
|
{
|
||||||
#if SOURCE_ENGINE != SE_DARKMESSIAH
|
#if SOURCE_ENGINE != SE_DARKMESSIAH
|
||||||
|
|||||||
@ -257,6 +257,11 @@ private:
|
|||||||
private:
|
private:
|
||||||
void InitLogicalEntData();
|
void InitLogicalEntData();
|
||||||
void InitCommandLine();
|
void InitCommandLine();
|
||||||
|
public:
|
||||||
|
void CHalfLife2::ClearDataTableCache();
|
||||||
|
void CHalfLife2::ClearDataTableCache(datamap_t *pMap);
|
||||||
|
void CHalfLife2::ClearSendPropCache();
|
||||||
|
bool CHalfLife2::ClearSendPropCache(const char *classname);
|
||||||
private:
|
private:
|
||||||
typedef ke::HashMap<datamap_t *, DataMapCache *, ke::PointerPolicy<datamap_t> > DataTableMap;
|
typedef ke::HashMap<datamap_t *, DataMapCache *, ke::PointerPolicy<datamap_t> > DataTableMap;
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user