From bf64caf8a31b049fa4a8b312b02ca4d8aed1ddae Mon Sep 17 00:00:00 2001 From: Artem Golubikhin Date: Wed, 22 Mar 2017 00:35:51 +0300 Subject: [PATCH] Added tag safety for get/set_member --- reapi/extra/amxmodx/scripting/include/reapi_gamedll.inc | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/reapi/extra/amxmodx/scripting/include/reapi_gamedll.inc b/reapi/extra/amxmodx/scripting/include/reapi_gamedll.inc index 13fe562..f4d6f14 100644 --- a/reapi/extra/amxmodx/scripting/include/reapi_gamedll.inc +++ b/reapi/extra/amxmodx/scripting/include/reapi_gamedll.inc @@ -33,7 +33,9 @@ native any:get_member_game(CSGameRules_Members:member, any:...); * * @return 1 on success. */ -native set_member(const index, any:member, any:...); +native set_member(const index, {CBaseEntity_Members, CBaseAnimating_Members, CBaseMonster_Members, + CBasePlayer_Members, CCSPlayer_Members, CBasePlayerItem_Members, CBasePlayerWeapon_Members, + CWeaponBox_Members, CArmoury_Members}:member, any:...); /* * Returns a value from an entity's member @@ -43,7 +45,9 @@ native set_member(const index, any:member, any:...); * * @return If an integer or boolean or one byte, array or everything else is passed via 3rd argument and more, look at argument list for specified member */ -native any:get_member(const index, any:member, any:...); +native any:get_member(const index, {CBaseEntity_Members, CBaseAnimating_Members, CBaseMonster_Members, + CBasePlayer_Members, CCSPlayer_Members, CBasePlayerItem_Members, CBasePlayerWeapon_Members, + CWeaponBox_Members, CArmoury_Members}:member, any:...); /* * Sets a playermove vars