r5sdk/r5dev/game/shared/shareddefs.h
Kawe Mazidjatari 54f08bd887 Work-in-progress user command executor
* Added some getters in 'CBaseEntity' and 'CServerNetworkProperty'.
* Implemented 'CPlayer::SetTimeBase'.
* WIP implementation of 'CPlayer::RunNullCommand'.
2023-01-19 15:25:45 +01:00

27 lines
718 B
C

//======= Copyright (c) 1996-2009, Valve Corporation, All rights reserved. ======
//
// Purpose: Definitions that are shared by the game DLL and the client DLL.
//
//===============================================================================
#ifndef SHAREDDEFS_H
#define SHAREDDEFS_H
#ifdef _WIN32
#pragma once
#endif
#ifndef CLIENT_DLL
#include "game/server/gameinterface.h"
#define TICK_INTERVAL (g_pGlobals->m_nTickInterval)
#define TIME_TO_TICKS( dt ) ( (int)( 0.5f + (float)(dt) / TICK_INTERVAL ) )
#define TICKS_TO_TIME( t ) ( TICK_INTERVAL *( t ) )
#define ROUND_TO_TICKS( t ) ( TICK_INTERVAL * TIME_TO_TICKS( t ) )
#define TICK_NEVER_THINK (-1)
#endif // !CLIENT_DLL
#endif // SHAREDDEFS_H