• 0

    posted a message on 400x400 required for logo image?

    Hello, I was wondering why the logo image for a project is required to be 1:1 and at least 400x400? I can't find anywhere on the website that actually shows this image at full resolution. When you search for an addon it shows that logo shrunk down to like 80x80 or something and you cant click on it to see it zoomed in. I'd like to make a logo thats the size of the image displayed on the website for best results.

     

    Thanks

    Posted in: General Chat
  • 0

    posted a message on UnitBuff() help
    Quote from Allara
    Without looking at the code extremely carefully, I notice that "UNIT_PLAYER" should be "player" on the third line. Also the "event" variable referenced in line 2 is not part of the function definition. You should put local before lines 3 and 4. There may be other issues.

    This has not been thoroughly vetted for accuracy, it merely illustrates the changes I mentioned:
    function FlaskReminder_BuffChange(self, event)
    	if ( event == "UNIT_AURA" ) then
    		local name, rank, icon, count, debuffType, duration, expirationTime, unitCaster, isStealable, shouldConsolidate, spellId = UnitBuff("player", "Flask of Endless Rage")
    		local inInstance, instanceType = IsInInstance()
    		if ( inInstance == 1 and instanceType == "raid" and name == nil ) then
    			FlaskReminder_Frame:Show();
    			FlaskReminder_Frame_Text:SetText("Drink Your Flask!");
    		else
    			FlaskReminder_Frame_Text:SetText("Standby");
    		end
    	end
    end
    



    :D Thanks so much, works perfectly now!!
    Posted in: Lua Code Discussion
  • 0

    posted a message on UnitBuff() help
    I'm trying to use UnitBuff() to detect if I have Flask of Endless Rage on, and if not, tell me to drink my flask.

    My problem is that it always returns nil, if I have the buff or not. So I think I just don't have the code right.


    function FlaskReminder_BuffChange(self)
    	if ( event == "UNIT_AURA" ) then
    		name, rank, icon, count, debuffType, duration, expirationTime, unitCaster, isStealable, shouldConsolidate, spellId = UnitBuff("UNIT_PLAYER", "Flask of Endless Rage")
    		inInstance, instanceType = IsInInstance()
    		if ( inInstance == 1 and instanceType == "raid" and name == nil ) then
    			FlaskReminder_Frame:Show();
    			FlaskReminder_Frame_Text:SetText("Drink Your Flask!");
    		else
    			FlaskReminder_Frame_Text:SetText("Standby");
    		end
    	end
    end



    This is the first time I've attempted to create an AddOn. So please tell me if what I typed out was completely insane.

    EDIT: And I know that the IsInInstance() is working because I get Standby when I leave the instance.
    Posted in: Lua Code Discussion
  • To post a comment, please or register a new account.