From aabb3e07c2950fe0545c8e3cc226d72b1197c402 Mon Sep 17 00:00:00 2001 From: Dysphie Date: Tue, 20 Jun 2023 03:11:16 -0300 Subject: [PATCH] Add targetname to backpacks --- scripting/nmrih-backpack2.sp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/scripting/nmrih-backpack2.sp b/scripting/nmrih-backpack2.sp index 20099ab..77c8b4d 100644 --- a/scripting/nmrih-backpack2.sp +++ b/scripting/nmrih-backpack2.sp @@ -16,7 +16,7 @@ #define PLUGIN_PREFIX "[Backpack2] " #define PLUGIN_DESCRIPTION "Portable inventory boxes" -#define PLUGIN_VERSION "2.0.17" +#define PLUGIN_VERSION "2.0.18" #define INVALID_USER_ID 0 @@ -283,6 +283,7 @@ enum struct Backpack // UNDONE: Can seemingly crash the server when CDynamicProp::~CDynamicProp() is invoked // SetEntPropString(attached, Prop_Data, "m_iClassname", "backpack_attached"); + DispatchKeyValue(attached, "targetname", "backpack_attached"); if (!DispatchSpawn(attached)) { @@ -353,6 +354,7 @@ enum struct Backpack // UNDONE: Can seemingly crash the server when CPhysicsProp::~CPhysicsProp() is invoked // SetEntPropString(dropped, Prop_Data, "m_iClassname", "backpack"); + DispatchKeyValue(dropped, "targetname", "backpack"); numDroppedBackpacks++;