From 6f519c75518a14699108e1710bcebe2f8a0eff99 Mon Sep 17 00:00:00 2001 From: s1lentq Date: Wed, 1 Jun 2016 18:27:20 +0600 Subject: [PATCH] Refactoring sdk of the party amxx --- .../amxmodx/scripting/include/cssdk_const.inc | 1026 +++++++++++++++++ .../extra/amxmodx/scripting/include/reapi.inc | 11 +- .../scripting/include/reapi_engine.inc | 2 +- .../scripting/include/reapi_gamedll.inc | 10 +- .../scripting/include/reapi_gamedll_const.inc | 296 +---- 5 files changed, 1042 insertions(+), 303 deletions(-) create mode 100644 reapi/extra/amxmodx/scripting/include/cssdk_const.inc diff --git a/reapi/extra/amxmodx/scripting/include/cssdk_const.inc b/reapi/extra/amxmodx/scripting/include/cssdk_const.inc new file mode 100644 index 0000000..f74bebd --- /dev/null +++ b/reapi/extra/amxmodx/scripting/include/cssdk_const.inc @@ -0,0 +1,1026 @@ +#if defined _cssdk_const_included +#endinput +#endif +#define _cssdk_const_included + +#define NULLENT -1 + +#define MAX_WEAPONS 32 +#define MAX_CLIENTS 32 // Max # of clients allowed in a server. +#define MAX_ITEM_TYPES 6 // hud item selection slots + +#define MAX_EDICT_BITS 11 // How many bits to use to encode an edict. # of bits needed to represent max edicts +#define MAX_EDICTS (1< -#include // NOTE: only for ReHLDS -#include // NOTE: only for gamedll Counter-Strike (ReGameDLL_CS) -#include // NOTE: 3-rd party addons -#include -#include +#include // NOTE: only for ReHLDS +#include // NOTE: only for gamedll Counter-Strike (ReGameDLL_CS) +#include // NOTE: 3-rd party addons +#include // hookchain return type enum diff --git a/reapi/extra/amxmodx/scripting/include/reapi_engine.inc b/reapi/extra/amxmodx/scripting/include/reapi_engine.inc index 04920b1..ebf4ae1 100644 --- a/reapi/extra/amxmodx/scripting/include/reapi_engine.inc +++ b/reapi/extra/amxmodx/scripting/include/reapi_engine.inc @@ -4,7 +4,7 @@ #define _reapi_engine_included -#include +#include /* * Sets entvars data for an entity. diff --git a/reapi/extra/amxmodx/scripting/include/reapi_gamedll.inc b/reapi/extra/amxmodx/scripting/include/reapi_gamedll.inc index 03d4865..9b7a5de 100644 --- a/reapi/extra/amxmodx/scripting/include/reapi_gamedll.inc +++ b/reapi/extra/amxmodx/scripting/include/reapi_gamedll.inc @@ -4,7 +4,7 @@ #define _reapi_gamedll_included -#include +#include /* * Sets a value to an CSGameRules_Members members @@ -167,13 +167,13 @@ native rg_multidmg_add(const inflictor, const victim, const Float:flDamage, cons * @param vecDirShooting Direction shooting * @param vecSpread Spread * @param flDistance Max shot distance -* @param iBulletType Bullet type +* @param iBulletType Bullet type, look at the enum's with name Bullet cssdk_const.inc * @param iTracerFreq Tracer frequancy * @param iDamage Damage amount * * @noreturn */ -native rg_fire_bullets(const inflictor, const attacker, const shots, Float:vecSrc[3], Float:vecDirShooting[3], Float:vecSpread[3], const Float:flDistance, const iBulletType, const iTracerFreq, const iDamage); +native rg_fire_bullets(const inflictor, const attacker, const shots, Float:vecSrc[3], Float:vecDirShooting[3], Float:vecSpread[3], const Float:flDistance, const Bullet:iBulletType, const iTracerFreq, const iDamage); /* * Fire bullets from player's weapon @@ -185,7 +185,7 @@ native rg_fire_bullets(const inflictor, const attacker, const shots, Float:vecSr * @param vecSpread Spread * @param flDistance Max shot distance * @param iPenetration The number of penetration -* @param iBulletType Bullet type +* @param iBulletType Bullet type, look at the enum's with name Bullet cssdk_const.inc * @param iDamage Damage amount * @param flRangeModifier Damage range modifier * @param bPistol Pistol shot @@ -193,7 +193,7 @@ native rg_fire_bullets(const inflictor, const attacker, const shots, Float:vecSr * * @return Float:[3] The result spread */ -native Float:[3] rg_fire_bullets3(const inflictor, const attacker, Float:vecSrc[3], Float:vecDirShooting[3], const Float:vecSpread, const Float:flDistance, const iPenetration, const iBulletType, const iDamage, const Float:flRangeModifier, const bool:bPistol, const shared_rand); +native Float:[3] rg_fire_bullets3(const inflictor, const attacker, Float:vecSrc[3], Float:vecDirShooting[3], const Float:vecSpread, const Float:flDistance, const iPenetration, const Bullet:iBulletType, const iDamage, const Float:flRangeModifier, const bool:bPistol, const shared_rand); /* * Complete the round diff --git a/reapi/extra/amxmodx/scripting/include/reapi_gamedll_const.inc b/reapi/extra/amxmodx/scripting/include/reapi_gamedll_const.inc index e5ed5a0..f20028b 100644 --- a/reapi/extra/amxmodx/scripting/include/reapi_gamedll_const.inc +++ b/reapi/extra/amxmodx/scripting/include/reapi_gamedll_const.inc @@ -4,20 +4,12 @@ #define _reapi_gamedll_const_included -// flags for CUnifiedSignals m_signals -#define SIGNAL_BUY (1<<0) -#define SIGNAL_BOMB (1<<1) -#define SIGNAL_RESCUE (1<<2) -#define SIGNAL_ESCAPE (1<<3) -#define SIGNAL_VIPSAFETY (1<<4) - // Returns 1, if round ended by expired time // NOTE: Use this for hookchain RG_RoundEnd with the parameter ScenarioEventEndRound:event #define HadRoundExpired(event) (1<