From b002adc509d0f591937818e4f4610fd5153b681f Mon Sep 17 00:00:00 2001 From: FlaminSarge Date: Sat, 14 Apr 2012 00:15:50 +0100 Subject: [PATCH] Fixed potential player lag issue when "drugged" (bug 5217, r=asherkin). --- plugins/funcommands/drug.sp | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/plugins/funcommands/drug.sp b/plugins/funcommands/drug.sp index 9d2ca676..3b223a86 100644 --- a/plugins/funcommands/drug.sp +++ b/plugins/funcommands/drug.sp @@ -43,14 +43,12 @@ KillDrug(client) { KillDrugTimer(client); - new Float:pos[3]; - GetClientAbsOrigin(client, pos); new Float:angs[3]; GetClientEyeAngles(client, angs); angs[2] = 0.0; - TeleportEntity(client, pos, angs, NULL_VECTOR); + TeleportEntity(client, NULL_VECTOR, angs, NULL_VECTOR); new clients[2]; clients[0] = client; @@ -144,15 +142,12 @@ public Action:Timer_Drug(Handle:timer, any:client) return Plugin_Handled; } - new Float:pos[3]; - GetClientAbsOrigin(client, pos); - new Float:angs[3]; GetClientEyeAngles(client, angs); angs[2] = g_DrugAngles[GetRandomInt(0,100) % 20]; - TeleportEntity(client, pos, angs, NULL_VECTOR); + TeleportEntity(client, NULL_VECTOR, angs, NULL_VECTOR); new clients[2]; clients[0] = client;