Closed crashzk closed 3 years ago
Try to unload [LR] Module - Boost(Vip)
Try to unload
[LR] Module - Boost(Vip)
It looks like that was it, I removed the plugin and it was, thank you.
I will leave the code here for anyone who can fix it, I would really like to implement this feature on my servers.
#pragma semicolon 1
#pragma newdecls required
#include <sourcemod>
#include <vip_core>
#include <lvl_ranks>
#define Crash(%0) SetFailState("[LR::BoostVip] " ... %0)
public Plugin myinfo =
{
name = "[LR] Module - Boost (VIP Core)",
author = "Designed (Discord: .Designed#7985)",
version = PLUGIN_VERSION,
}
static const char g_szFeature[] = "LrBoost";
public void OnPluginStart()
{
if(VIP_IsVIPLoaded())
{
VIP_OnVIPLoaded();
}
if(LR_IsLoaded())
{
LR_OnCoreIsReady();
}
}
public void LR_OnCoreIsReady()
{
if (!LR_Hook(LR_OnPlayerKilledPre, CallBack_OnPlayerKilledPre))
Crash("Failed to hook event");
}
public void VIP_OnVIPLoaded()
{
VIP_RegisterFeature(g_szFeature, FLOAT, HIDE);
}
public void CallBack_OnPlayerKilledPre(Event hEvent, int& iExpCaused, int iExpVictim, int iExpAttacker)
{
int iClient = GetClientOfUserId(hEvent.GetInt("attacker"));
if(VIP_IsClientVIP(iClient) && VIP_IsClientFeatureUse(iClient, g_szFeature))
{
iExpCaused = RoundToNearest(iExpCaused * VIP_GetClientFeatureFloat(iClient, g_szFeature));
}
}
public void OnPluginEnd()
{
if(CanTestFeatures() && GetFeatureStatus(FeatureType_Native, "VIP_UnregisterFeature") == FeatureStatus_Available)
{
VIP_UnregisterFeature(g_szFeature);
}
}
Thank you again!
I'm having a problem when it comes to earning points / xp when the player kills someone.
Currently, if a player kills the player normally, without any event like HS, NoScope and tals, he is not counting points for the player, he simply does not earn points, same thing if he dies, he does not lose points.
Only if you are gaining or losing points with the kills that you have the Unusual Kills module.
Full list of the plugin and modules I use:
Follow the link to download the plugin and module I'm using, configuration included.
https://drive.google.com/file/d/1C6rUIradnMtxvrGT4yR9P7tvy6P38l93/view?usp=sharing