mirror of
https://github.com/rehlds/rehlds.git
synced 2025-01-04 02:55:50 +03:00
ReHLDS API: Added functions SetResourcesNum and GetResourcesAt for the API.
This commit is contained in:
parent
34537a7fda
commit
665605e0ab
@ -123,4 +123,6 @@ public:
|
|||||||
virtual int GetDecalNameNum() = 0;
|
virtual int GetDecalNameNum() = 0;
|
||||||
|
|
||||||
virtual double GetTime() = 0;
|
virtual double GetTime() = 0;
|
||||||
|
virtual void SetResourcesNum(int num) = 0;
|
||||||
|
virtual struct resource_s *GetResource(int index) = 0;
|
||||||
};
|
};
|
||||||
|
@ -230,6 +230,14 @@ double EXT_FUNC CRehldsServerData::GetTime() {
|
|||||||
return g_psv.time;
|
return g_psv.time;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void EXT_FUNC CRehldsServerData::SetResourcesNum(int num) {
|
||||||
|
g_psv.num_resources = num;
|
||||||
|
}
|
||||||
|
|
||||||
|
struct resource_s *EXT_FUNC CRehldsServerData::GetResource(int index) {
|
||||||
|
return &g_psv.resourcelist[index];
|
||||||
|
}
|
||||||
|
|
||||||
void Rehlds_Interfaces_FreeClients()
|
void Rehlds_Interfaces_FreeClients()
|
||||||
{
|
{
|
||||||
if (g_GameClients == NULL)
|
if (g_GameClients == NULL)
|
||||||
|
@ -117,6 +117,8 @@ public:
|
|||||||
virtual int GetDecalNameNum();
|
virtual int GetDecalNameNum();
|
||||||
|
|
||||||
virtual double GetTime();
|
virtual double GetTime();
|
||||||
|
virtual void SetResourcesNum(int num);
|
||||||
|
virtual struct resource_s *GetResource(int index);
|
||||||
};
|
};
|
||||||
|
|
||||||
extern CGameClient** g_GameClients;
|
extern CGameClient** g_GameClients;
|
||||||
|
Loading…
Reference in New Issue
Block a user