Raid Start DKP

Interested contributing to WebDKP? Find the latest development progress here.

Posts: 8
Joined: Thu Jun 23, 2011 11:33 am
PostPosted: Thu Dec 01, 2011 6:35 am
Does your guild automatically assign DKP to raid members for turning up for the raid and being present ontime? Well we do in our guild and it was a bit of a pain having to manually select all the raid members and having to award the DKP through the DKP table.

Realise that its quick and easy to do, but you be amazed how many times I forgot to do it. So I thought there must be a way to automate this. So rehashed some existing code to produce the following which works for us. I call this function in a macro at the start of the raid, which also does other guild announcements and such like.

It will assign whatever DKP you assign under 'local points =' to all raid members and flag the award with the date of the raid so you can keep track easier in the online table.

function WedDKP_StartDKP()
local name, class, guild;
local points = "2"
local playerdate= date("%d/%m")
local reason = "Raid Start".." ".. playerdate

points = tonumber(points);
points = WebDKP_ROUND(points,2);

local players = WebDKP_PlayersInGroup;

if ( players == nil ) then
WebDKP_Print("No players were selected. Award NOT made.");
PlaySound("igQuestFailed");
else
WebDKP_AddDKP(points, reason, "false", players);
WebDKP_UpdateTableToShow();
WebDKP_UpdateTable();
end

WebDKP_AnnounceAward(points,reason);
WebDKP_UnselectAll();
end

Return to Development

Who is online

Users browsing this forum: No registered users and 1 guest

cron