Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixing the Anti-Snipe bid timer issues. #372

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 8 additions & 4 deletions Modules/Bidding.lua
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,9 @@ function MonDKP_CHAT_MSG_WHISPER(text, ...)
local name = ...;
local cmd;
local dkp;
local seconds;
local response = L["ERRORPROCESSING"];
local snipemessage;
mode = MonDKP_DB.modes.mode;

if string.find(name, "-") then -- finds and removes server name from name if exists
Expand Down Expand Up @@ -185,10 +187,11 @@ function MonDKP_CHAT_MSG_WHISPER(text, ...)
MonDKP.Sync:SendData("MonDKPBidShare", Bids_Submitted)
end
if Timer ~= 0 and Timer > (core.BiddingWindow.bidTimer:GetText() - 10) and MonDKP_DB.modes.AntiSnipe > 0 then
seconds = core.BiddingWindow.bidTimer:GetText().."{"..MonDKP_DB.modes.AntiSnipe
if core.BiddingWindow.maxBid:GetNumber() ~= 0 then
MonDKP:BroadcastBidTimer(core.BiddingWindow.bidTimer:GetText().."{"..MonDKP_DB.modes.AntiSnipe, core.BiddingWindow.item:GetText().." Min Bid: "..core.BiddingWindow.minBid:GetText().." Max Bid: "..core.BiddingWindow.maxBid:GetText(), core.BiddingWindow.itemIcon:GetTexture());
MonDKP:BroadcastBidTimer(seconds, core.BiddingWindow.item:GetText().." Min Bid: "..core.BiddingWindow.minBid:GetText().." Max Bid: "..core.BiddingWindow.maxBid:GetText(), core.BiddingWindow.itemIcon:GetTexture());
else
MonDKP:BroadcastBidTimer(core.BiddingWindow.bidTimer:GetText().."{"..MonDKP_DB.modes.AntiSnipe, core.BiddingWindow.item:GetText().." Min Bid: "..core.BiddingWindow.minBid:GetText(), core.BiddingWindow.itemIcon:GetTexture());
MonDKP:BroadcastBidTimer(seconds, core.BiddingWindow.item:GetText().." Min Bid: "..core.BiddingWindow.minBid:GetText(), core.BiddingWindow.itemIcon:GetTexture());
end
end
elseif mode == "Static Item Values" or (mode == "Zero Sum" and MonDKP_DB.modes.ZeroSumBidType == "Static") then
Expand All @@ -204,11 +207,12 @@ function MonDKP_CHAT_MSG_WHISPER(text, ...)
MonDKP.Sync:SendData("MonDKPBidShare", Bids_Submitted)
end
response = L["BIDWASACCEPTED"]

if Timer ~= 0 and Timer > (core.BiddingWindow.bidTimer:GetText() - 10) and MonDKP_DB.modes.AntiSnipe > 0 then
MonDKP:BroadcastBidTimer(core.BiddingWindow.bidTimer:GetText().."{"..MonDKP_DB.modes.AntiSnipe, core.BiddingWindow.item:GetText().." Min Bid: "..core.BiddingWindow.minBid:GetText(), core.BiddingWindow.itemIcon:GetTexture());
seconds = core.BiddingWindow.bidTimer:GetText().."{"..MonDKP_DB.modes.AntiSnipe
MonDKP:BroadcastBidTimer(seconds, core.BiddingWindow.item:GetText().." Extended", core.BiddingWindow.itemIcon:GetTexture());
end
end

BidScrollFrame_Update()
else
response = L["BIDDENIEDMINBID"].." "..core.BiddingWindow.minBid:GetNumber().."!"
Expand Down