Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- performLine={"s The trees are out.",3,"s All scattered about.",3,"s The snow falls silently,",2,"s wildly.",3,"s On this perfect winter's day.",3,"s So spread the cheer,",3,"s Winter Veil is here!",0,"d cheer",2,"e | The music starts to pick up pace, becoming more cheerful and upbeat. Yasmine lets loose and starts to jig her hips to the beat before returning to singing her song.",2,"s I can't wait, it's finally here.",3,"s And i can finally walk out and hear.",3,"s The bells for Winter veil are coming.",3,"s All the birds around are humming.",3,"s The children will not need to fear,",3,"s because Winter veil is here!",0,"d cheer",3,"s Before me i see, a great big feast,",3,"s that could only be eaten by a huge beast!",3,"s The cranberry sauce, the turkey, the stuffing galore!",3,"s My it is only what one could ask for.",3,"s The candles, the lights, they are all so bright.",3,"s To spread the happiness of all these upcoming nights!",3,"s So people shan't disappear,",3,"s because Winter veil is here!",0,"d cheer",3,"zw All come out onto stage and tilt towards facing Yasmine.",3,"s Sparkles, what do you want for Winter veil?",3,"q1s Erm, oh yes i want a male draenei!",3,"d facepalm",0,"q2d facepalm",2,"s Moving on!",3,"s Pan, what do you want for Winter veil?",3,"q2s I want a lovely dress,",3,"q2s one that stands out from the rest.",3,"q1s What do you want for Winter Veil Yasmine?",3,"s Me? I want a dazzling ring,",3,"s One that gives me a status of bling.",0,"zw All face foward.",3,"zs Getting presents isn't everything about Winter veil.",3,"s It is about showing love.",1,"q1s Kindness.",1,"q2s Respect.",3,"s So spread the cheer,",3,"zs Winter veil is here!",3,"zd bow"};
- thisDancer={"yasmine","Daxina","Panmaelon",""};
- local lineTotal = 45;
- local lineCurrent = 1;
- buzzchannel="Fableperform";
- local fablePerformCode = "!@#";
- local fableReadyRequestCode = "@&!";
- local fableReadyRespondCode = "*^!";
- function ensureChannel()
- id, name = GetChannelName(buzzchannel);
- if (id == 0 and name == nil) then
- JoinChannelByName(buzzchannel);
- GHI_Message("Joined "..buzzchannel.." - ensure it's not visible.");
- end
- end
- function stripRealm(player)
- local split = string.find(player,"-");
- return strsub(player,0,split-1);
- end
- function sendPerformMessage(player, text)
- ensureChannel();
- id, name = GetChannelName(buzzchannel);
- if (id > 0 and name ~= nil) then
- SendChatMessage(fablePerformCode..player.."@"..text, "CHANNEL", nil, id);
- end
- end
- function sendReadyCheckMessage(player)
- ensureChannel();
- id, name = GetChannelName(buzzchannel);
- if (id > 0 and name ~= nil) then
- SendChatMessage(fableReadyRequestCode..player, "CHANNEL", nil, id);
- end
- end
- function AutoPlay()
- local info = ChatTypeInfo["YELL"];
- if GHI_CountBuffs("Performing") > 0 then
- if strsub(performLine[lineCurrent],0,1) == "z" then
- performLine[lineCurrent] = strsub(performLine[lineCurrent],2);
- for i=2,noDancers do
- sendPerformMessage(thisDancer[i], performLine[lineCurrent]);
- end
- end
- if strsub(performLine[lineCurrent],0,1) == "q" then
- local tempVal = (strsub(performLine[lineCurrent],2,2)-1)+2;
- sendPerformMessage(thisDancer[tempVal], strsub(performLine[lineCurrent],3));
- elseif strsub(performLine[lineCurrent],0,1) == "s" then
- SendChatMessage(strsub(performLine[lineCurrent],3),"SAY",nil,nil);
- elseif strsub(performLine[lineCurrent],0,1) == "e" then
- SendChatMessage(strsub(performLine[lineCurrent],3),"EMOTE",nil,nil);
- elseif strsub(performLine[lineCurrent],0,1) == "y" then
- SendChatMessage(strsub(performLine[lineCurrent],3),"YELL",nil,nil);
- elseif string.lower(strsub(performLine[lineCurrent],0,1)) == "d" then
- GHI_Emote(strsub(performLine[lineCurrent],3),0,"none");
- else
- NEW_DANCE_OOC(strsub(performLine[lineCurrent],3));
- end
- if lineCurrent < ((lineTotal*2)-1) then
- local pauseTime=(performLine[lineCurrent+1]-1)+1;
- lineCurrent = lineCurrent+2;
- GHI_DoScript("AutoPlay()",pauseTime);
- else
- GHI_RemoveBuff("Performing", "Helpful");
- GHI_Message("Performance finished!");
- end
- else
- GHI_Message("Performance interrupted!");
- end
- end
- function NEW_DANCE_OOC(message)
- local info = ChatTypeInfo["YELL"];
- GHI_Message(message);
- UIErrorsFrame:AddMessage(message, info.r, info.g, info.b, info.id);
- end
- function SNGPLY_RESPOND(self, event, arg1, arg2, ...)
- if fableReadyRespondCode==strsub(arg1,1,3) then
- arg2 = stripRealm(arg2);
- local count = 0;
- for i=2,noDancers do
- if arg2==thisDancer[i] then
- dancerStatus[i] = 1;
- GHI_Message(arg2.." ready!");
- end
- count = count + dancerStatus[i];
- end
- if count == noDancers-1 then
- GHI_Message("Everyone's ready! Click to begin!");
- NEW_DANCE_GO = 1;
- end
- end
- end
- if SNGPLY_ACTIVE==nil or SNGPLY_ACTIVE==0 then
- SNGPLY_ACTIVE=1;
- SNGPLY_LISTENER=CreateFrame("Frame",nil,UIParent);
- SNGPLY_LISTENER:SetScript("OnEvent",function(...) SNGPLY_RESPOND(...) end);
- SNGPLY_LISTENER:RegisterEvent("CHAT_MSG_CHANNEL");
- end
- if NEW_DANCE_GO == nil then
- noDancers=3;
- dancerStatus={0,0,0,0};
- GHI_Message("Checking for performers...");
- for i=2,noDancers do
- dancerStatus[i] = 0;
- GHI_Message("sendReadyCheckMessage("..thisDancer[i]..")");
- GHI_DoScript("sendReadyCheckMessage(thisDancer["..i.."])",i-1);
- end
- else
- NEW_DANCE_GO = nil;
- GHI_ApplyBuff("Performing", "Performing with skill!", "Interface\\Icons\\ability_hunter_displacement", true, "Helpful", "Magic", 0, true, false, 1, 0, 0,1);
- GHI_DoScript("AutoPlay()", 2);
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement