mirror of
https://github.com/etlegacy/wolfadmin.git
synced 2024-11-22 04:12:19 +00:00
Fixed end of sprees not displayed in all cases
This commit is contained in:
parent
1a3b91fb06
commit
abb6c45e55
1 changed files with 2 additions and 2 deletions
|
@ -248,7 +248,7 @@ function sprees.onPlayerSpreeEnd(clientId, causeId, type)
|
||||||
local settingSpreeMessages = settings.get("g_spreeMessages")
|
local settingSpreeMessages = settings.get("g_spreeMessages")
|
||||||
|
|
||||||
if type == sprees.RECORD_DEATH then
|
if type == sprees.RECORD_DEATH then
|
||||||
if settingSpreeMessages ~= 0 and bits.hasbit(settingSpreeMessages, 2^type) and playerSprees[clientId][sprees.RECORD_DEATH] > spreeMessagesByType[sprees.RECORD_DEATH][1]["amount"] then
|
if settingSpreeMessages ~= 0 and bits.hasbit(settingSpreeMessages, 2^type) and playerSprees[clientId][sprees.RECORD_DEATH] >= spreeMessagesByType[sprees.RECORD_DEATH][1]["amount"] then
|
||||||
local msg = string.format("^7%s^d was the first victim of ^7%s ^dafter ^3%d ^d%ss!",
|
local msg = string.format("^7%s^d was the first victim of ^7%s ^dafter ^3%d ^d%ss!",
|
||||||
players.getName(causeId),
|
players.getName(causeId),
|
||||||
players.getName(clientId),
|
players.getName(clientId),
|
||||||
|
@ -262,7 +262,7 @@ function sprees.onPlayerSpreeEnd(clientId, causeId, type)
|
||||||
elseif type == nil then
|
elseif type == nil then
|
||||||
for i = 0, sprees.RECORD_NUM - 1 do
|
for i = 0, sprees.RECORD_NUM - 1 do
|
||||||
if i ~= sprees.RECORD_DEATH then
|
if i ~= sprees.RECORD_DEATH then
|
||||||
if settingSpreeMessages ~= 0 and bits.hasbit(settingSpreeMessages, 2^i) and playerSprees[clientId][i] > spreeMessagesByType[i][1]["amount"] then
|
if settingSpreeMessages ~= 0 and bits.hasbit(settingSpreeMessages, 2^i) and playerSprees[clientId][i] >= spreeMessagesByType[i][1]["amount"] then
|
||||||
local msg = ""
|
local msg = ""
|
||||||
|
|
||||||
if clientId == causeId then
|
if clientId == causeId then
|
||||||
|
|
Loading…
Reference in a new issue