Update more to 1.11

This commit is contained in:
Jackz 2022-07-05 13:50:51 -05:00
parent 0718b24855
commit 25a35284cd
No known key found for this signature in database
GPG key ID: E0BBD94CF657F603
13 changed files with 36 additions and 22 deletions

View file

@ -272,7 +272,7 @@ public Action L4D2_OnEntityShoved(int client, int entity, int weapon, float vecD
}
public Action OnClientSayCommand(int client, const char[] command, const char[] sArgs) {
if(sArgs[0] == '@') return Plugin_Continue; //Ignore admin chat
if(client <= 0 || sArgs[0] == '@') return Plugin_Continue; //Ignore admin chat or console
static int honkID;
static int profanityID;

View file

@ -280,4 +280,5 @@ Action Timer_SpawnBotsPost(Handle h) {
}
}
}
return Plugin_Handled;
}

View file

@ -196,12 +196,12 @@ stock void GetHorizontalPositionFromClient(int client, float units, float finalP
finalPosition = pos;
}
void SetParent(int child, int parent) {
stock void SetParent(int child, int parent) {
SetVariantString("!activator");
AcceptEntityInput(child, "SetParent", parent);
}
void SetParentAttachment(int child, const char[] attachment, bool withOffset = false) {
stock void SetParentAttachment(int child, const char[] attachment, bool withOffset = false) {
SetVariantString(attachment);
if(withOffset)
AcceptEntityInput(child, "SetParentAttachmentMaintainOffset");
@ -209,12 +209,10 @@ void SetParentAttachment(int child, const char[] attachment, bool withOffset = f
AcceptEntityInput(child, "SetParentAttachment");
}
void ClearParent(int child) {
stock void ClearParent(int child) {
AcceptEntityInput(child, "ClearParent");
}
static float EMPTY_ANG[3] = { 0.0, 0.0, 0.0 };
void SetPeekCamTarget(int target, bool showFPOV = false) {
if(seekerCam == INVALID_ENT_REFERENCE || !IsValidEntity(seekerCam)) {
seekerCam = CreateEntityByName("point_viewcontrol_survivor");
@ -253,10 +251,6 @@ void SetPeekCamTarget(int target, bool showFPOV = false) {
}
}
bool IsPeekCamActive(int client) {
return isViewingCam[client];
}
// int GetClientsInRange(const float origin[3], ClientRangeType rangeType, int[] clients, int size)
void SetPeekCamActive(int client, bool active) {
if(seekerCam != INVALID_ENT_REFERENCE) {

View file

@ -58,9 +58,9 @@
// Natives: 226
// L4D1 = 29 [left4downtown] + 47 [l4d_direct] + 15 [l4d2addresses] + 43 [silvers - mine!] + 4 [anim] = 132
// L4D2 = 59 [left4downtown] + 61 [l4d_direct] + 26 [l4d2addresses] + 79 [silvers - mine!] + 4 [anim] = 223
// Natives: 227
// L4D1 = 29 [left4downtown] + 47 [l4d_direct] + 15 [l4d2addresses] + 43 [silvers - mine!] + 4 [anim] = 133
// L4D2 = 60 [left4downtown] + 61 [l4d_direct] + 26 [l4d2addresses] + 80 [silvers - mine!] + 4 [anim] = 224
// Forwards: 144
// L4D1 = 109;
@ -331,6 +331,7 @@ public void __pl_l4dh_SetNTVOptional()
MarkNativeAsOptional("L4D2_Charger_StartCarryingVictim");
MarkNativeAsOptional("L4D2_Charger_PummelVictim");
MarkNativeAsOptional("L4D2_Charger_EndPummel");
MarkNativeAsOptional("L4D2_Jockey_EndRide");
MarkNativeAsOptional("L4D_CancelStagger");
MarkNativeAsOptional("L4D_CreateRescuableSurvivors");
MarkNativeAsOptional("L4D_ReviveSurvivor");
@ -4671,6 +4672,7 @@ native void L4D_CancelStagger(int client);
*
* @noreturn
*/
// L4D2 only.
native void L4D2_Charger_ThrowImpactedSurvivor(int victim, int attacker);
/**
@ -4683,6 +4685,7 @@ native void L4D2_Charger_ThrowImpactedSurvivor(int victim, int attacker);
*
* @noreturn
*/
// L4D2 only.
native void L4D2_Charger_StartCarryingVictim(int victim, int attacker);
/**
@ -4693,6 +4696,7 @@ native void L4D2_Charger_StartCarryingVictim(int victim, int attacker);
*
* @noreturn
*/
// L4D2 only.
native void L4D2_Charger_PummelVictim(int victim, int attacker);
/**
@ -4703,8 +4707,20 @@ native void L4D2_Charger_PummelVictim(int victim, int attacker);
*
* @noreturn
*/
// L4D2 only.
native void L4D2_Charger_EndPummel(int victim, int attacker);
/**
* @brief Makes a Jockey stop riding a Survivor
*
* @param victim Client index of the Survivor to affect
* @param attacker Client index of the Jockey riding the Survivor
*
* @noreturn
*/
// L4D2 only.
native void L4D2_Jockey_EndRide(int victim, int attacker);
/**
* @brief Spawns all dead survivors in rescuable rooms.
* @remarks L4D1: Any survivor must not be in the starting area for it to work.

View file

@ -661,7 +661,7 @@ stock int L4D_GetPendingTankPlayer()
* @return True if glow was set, false if entity does not support glow.
*/
// L4D2 only.
stock bool L4D2_SetEntityGlow(int entity, L4D2GlowType type, int range, int minRange, int colorOverride[3], bool flashing)
stock bool L4D2_SetEntityGlow(int entity, L4D2GlowType type, int range, int minRange, colorOverride[3], bool flashing)
{
if (!IsValidEntity(entity))
{