12-10-08, 06:48 AM | #1 |
Micro Buttons disappear on Vehicle exit :(
Well the title says it all... How do i get the Micro buttons to go back where i placed them after you exit a vehicle? The graphic i have acting as my main menu bar hud hide's itself just fine when a vehicle is entered and brings up the bonus bar and comes back when leaving the vehicle... just the micro buttons stay gone.
Here is the code: Code:
local dummy = function() end local b = KranixActionButton1 local c = KranixActionButton2 local d = KranixActionButton3 local e = KranixActionButton4 local f = KranixActionButton5 local g = KranixActionButton6 local h = KranixActionButton7 local i = KranixActionButton8 local j = KranixActionButton9 local k = KranixActionButton10 local l = KranixActionButton11 local m = KranixActionButton12 local n = KranixActionButton13 local o = KranixActionButton14 local p = KranixActionButton15 local q = KranixActionButton16 local r = KranixActionButton17 local s = KranixActionButton18 local t = KranixActionButton19 local u = KranixActionButton20 local v = KranixActionButton21 local w = KranixActionButton22 local x = KranixActionButton23 local y = KranixActionButton24 local ab1 = KranixActionButton25 local ab2 = KranixActionButton26 local ab3 = KranixActionButton27 local ab4 = KranixActionButton28 local ab5 = KranixActionButton29 local ab6 = KranixActionButton30 local ab7 = KranixActionButton31 local ab8 = KranixActionButton32 local ab9 = KranixActionButton33 local ab10 = KranixActionButton34 local ab11 = KranixActionButton35 local ab12 = KranixActionButton36 local ab13 = KranixActionButton37 local ab14 = KranixActionButton38 local ab15 = KranixActionButton39 local ab16 = KranixActionButton40 local ab17 = KranixActionButton41 local ab18 = KranixActionButton42 local ab19 = KranixActionButton43 local ab20 = KranixActionButton44 local ab21 = KranixActionButton45 local ab22 = KranixActionButton46 local ab23 = KranixActionButton47 local ab24 = KranixActionButton48 b:SetScale(0.70) c:SetScale(0.70) d:SetScale(0.70) e:SetScale(0.70) f:SetScale(0.70) g:SetScale(0.70) h:SetScale(0.70) i:SetScale(0.70) j:SetScale(0.70) k:SetScale(0.70) l:SetScale(0.70) m:SetScale(0.70) n:SetScale(0.70) o:SetScale(0.70) p:SetScale(0.70) q:SetScale(0.70) r:SetScale(0.70) s:SetScale(0.70) t:SetScale(0.70) u:SetScale(0.70) v:SetScale(0.70) w:SetScale(0.70) x:SetScale(0.70) y:SetScale(0.70) ab1:SetScale(0.70) ab2:SetScale(0.70) ab3:SetScale(0.70) ab4:SetScale(0.70) ab5:SetScale(0.70) ab6:SetScale(0.70) ab7:SetScale(0.70) ab8:SetScale(0.70) ab9:SetScale(0.70) ab10:SetScale(0.70) ab11:SetScale(0.70) ab12:SetScale(0.70) ab13:SetScale(0.70) ab14:SetScale(0.70) ab15:SetScale(0.70) ab16:SetScale(0.70) ab17:SetScale(0.70) ab18:SetScale(0.70) ab19:SetScale(0.70) ab20:SetScale(0.70) ab21:SetScale(0.70) ab22:SetScale(0.70) ab23:SetScale(0.70) ab24:SetScale(0.70) CharacterMicroButton:UnregisterAllEvents() CharacterMicroButton:RegisterEvent("PLAYER_ENTERING_WORLD") CharacterMicroButton:RegisterEvent("UNIT_ENTERED_VEHICLE") CharacterMicroButton:RegisterEvent("UNIT_EXITED_VEHICLE") SpellbookMicroButton:UnregisterAllEvents() SpellbookMicroButton:RegisterEvent("PLAYER_ENTERING_WORLD") SpellbookMicroButton:RegisterEvent("UNIT_ENTERED_VEHICLE") SpellbookMicroButton:RegisterEvent("UNIT_EXITED_VEHICLE") TalentMicroButton:UnregisterAllEvents() TalentMicroButton:RegisterEvent("PLAYER_ENTERING_WORLD") TalentMicroButton:RegisterEvent("UNIT_ENTERED_VEHICLE") TalentMicroButton:RegisterEvent("UNIT_EXITED_VEHICLE") AchievementMicroButton:UnregisterAllEvents() AchievementMicroButton:RegisterEvent("PLAYER_ENTERING_WORLD") AchievementMicroButton:RegisterEvent("UNIT_ENTERED_VEHICLE") AchievementMicroButton:RegisterEvent("UNIT_EXITED_VEHICLE") QuestLogMicroButton:UnregisterAllEvents() QuestLogMicroButton:RegisterEvent("PLAYER_ENTERING_WORLD") QuestLogMicroButton:RegisterEvent("UNIT_ENTERED_VEHICLE") QuestLogMicroButton:RegisterEvent("UNIT_EXITED_VEHICLE") SocialsMicroButton:UnregisterAllEvents() SocialsMicroButton:RegisterEvent("PLAYER_ENTERING_WORLD") SocialsMicroButton:RegisterEvent("UNIT_ENTERED_VEHICLE") SocialsMicroButton:RegisterEvent("UNIT_EXITED_VEHICLE") PVPMicroButton:UnregisterAllEvents() PVPMicroButton:RegisterEvent("PLAYER_ENTERING_WORLD") PVPMicroButton:RegisterEvent("UNIT_ENTERED_VEHICLE") PVPMicroButton:RegisterEvent("UNIT_EXITED_VEHICLE") LFGMicroButton:UnregisterAllEvents() LFGMicroButton:RegisterEvent("PLAYER_ENTERING_WORLD") LFGMicroButton:RegisterEvent("UNIT_ENTERED_VEHICLE") LFGMicroButton:RegisterEvent("UNIT_EXITED_VEHICLE") MainMenuMicroButton:UnregisterAllEvents() MainMenuMicroButton:RegisterEvent("PLAYER_ENTERING_WORLD") MainMenuMicroButton:RegisterEvent("UNIT_ENTERED_VEHICLE") MainMenuMicroButton:RegisterEvent("UNIT_EXITED_VEHICLE") HelpMicroButton:UnregisterAllEvents() HelpMicroButton:RegisterEvent("PLAYER_ENTERING_WORLD") HelpMicroButton:RegisterEvent("UNIT_ENTERED_VEHICLE") HelpMicroButton:RegisterEvent("UNIT_EXITED_VEHICLE") local mb = MicroButtonHolder mb:RegisterEvent("PLAYER_ENTERING_WORLD") mb:RegisterEvent("UNIT_ENTERED_VEHICLE") mb:RegisterEvent("UNIT_EXITED_VEHICLE") local a = ABGraphic a:RegisterEvent("UNIT_ENTERED_VEHICLE") a:RegisterEvent("UNIT_EXITED_VEHICLE") a:SetScale(1.3) local a2 = ABGraphic2 a2:RegisterEvent("UNIT_ENTERED_VEHICLE") a2:RegisterEvent("UNIT_EXITED_VEHICLE") a2:SetScale(1.2) mb:SetScript("OnEvent", function(self,event,arg1) if(event=="PLAYER_ENTERING_WORLD") then MoveMicroButtons() end end) function MoveMicroButtons() local a = CharacterMicroButton local b = SpellbookMicroButton local c = TalentMicroButton local d = AchievementMicroButton local e = QuestLogMicroButton local f = SocialsMicroButton local g = PVPMicroButton local h = LFGMicroButton local i = MainMenuMicroButton local j = HelpMicroButton MainMenuBar:Hide() MainMenuBar.Show = dummy a:ClearAllPoints() a:SetParent(mb) a:SetPoint("LEFT",10,10) a.SetPoint = dummy a:SetScale(0.90) a:Show() b:ClearAllPoints() b:SetParent(mb) b:SetPoint("LEFT",a,"RIGHT",0,0) b.SetPoint = dummy b:SetScale(0.90) b:Show() c:ClearAllPoints() c:SetParent(mb) c:SetPoint("LEFT",b,"RIGHT",0,0) c.SetPoint = dummy c:SetScale(0.90) c:Show() d:ClearAllPoints() d:SetParent(mb) d:SetPoint("LEFT",c,"RIGHT",0,0) d.SetPoint = dummy d:SetScale(0.90) d:Show() e:ClearAllPoints() e:SetParent(mb) e:SetPoint("LEFT",d,"RIGHT",0,0) e.SetPoint = dummy e:SetScale(0.90) e:Show() f:ClearAllPoints() f:SetParent(mb) f:SetPoint("LEFT",e,"RIGHT",0,0) f.SetPoint = dummy f:SetScale(0.90) f:Show() g:ClearAllPoints() g:SetParent(mb) g:SetPoint("LEFT",f,"RIGHT",0,0) g.SetPoint = dummy g:SetScale(0.90) g:Show() h:ClearAllPoints() h:SetParent(mb) h:SetPoint("LEFT",g,"RIGHT",0,0) h.SetPoint = dummy h:SetScale(0.90) h:Show() i:ClearAllPoints() i:SetParent(mb) i:SetPoint("LEFT",h,"RIGHT",0,0) i.SetPoint = dummy i:SetScale(0.90) i:Show() j:ClearAllPoints() j:SetParent(mb) j:SetPoint("LEFT",i,"RIGHT",0,0) j.SetPoint = dummy j:SetScale(0.90) j:Show() local k = MainMenuBarBackpackButton local l = CharacterBag0Slot local m = CharacterBag1Slot local n = CharacterBag2Slot local o = CharacterBag3Slot local p = KeyRingButton p:ClearAllPoints() p:SetParent(mb) p:SetPoint("CENTER",105,0) p.SetPoint = dummy p:SetScale(0.80) p:Show() o:ClearAllPoints() o:SetParent(mb) o:SetPoint("CENTER",p,"RIGHT",17,0) o.SetPoint = dummy o:SetScale(1.00) o:Show() n:ClearAllPoints() n:SetParent(mb) n:SetPoint("CENTER",o,"RIGHT",17,0) n.SetPoint = dummy n:SetScale(1.00) n:Show() m:ClearAllPoints() m:SetParent(mb) m:SetPoint("CENTER",n,"RIGHT",17,0) m.SetPoint = dummy m:SetScale(1.00) m:Show() l:ClearAllPoints() l:SetParent(mb) l:SetPoint("CENTER",m,"RIGHT",17,0) l.SetPoint = dummy l:SetScale(1.00) l:Show() k:ClearAllPoints() k:SetParent(mb) k:SetPoint("CENTER",l,"RIGHT",17,0) k.SetPoint = dummy k:SetScale(0.80) k:Show() end local mc = ShapeStanceHolder mc:RegisterEvent("PLAYER_ENTERING_WORLD") mc:SetScript("OnEvent", function(self,event,arg1) if(event=="PLAYER_ENTERING_WORLD") then MoveSSPetBar() end end) function MoveSSPetBar() local a = ShapeshiftButton1 local b = ShapeshiftButton2 local c = ShapeshiftButton3 local d = ShapeshiftButton4 local e = ShapeshiftButton5 local f = ShapeshiftButton6 local g = ShapeshiftButton7 a:UnregisterAllEvents() a:ClearAllPoints() a:SetParent(ShapeStanceHolder) a:SetPoint("LEFT",0,-7) a.SetPoint = dummy a:SetScale(0.60) a:Show() b:UnregisterAllEvents() b:ClearAllPoints() b:SetParent(ShapeStanceHolder) b:SetPoint("CENTER",a,"RIGHT",27,0) b.SetPoint = dummy b:SetScale(0.60) b:Show() c:UnregisterAllEvents() c:ClearAllPoints() c:SetParent(ShapeStanceHolder) c:SetPoint("CENTER",b,"RIGHT",27,0) c.SetPoint = dummy c:SetScale(0.60) c:Show() d:UnregisterAllEvents() d:ClearAllPoints() d:SetParent(ShapeStanceHolder) d:SetPoint("CENTER",c,"RIGHT",27,0) d.SetPoint = dummy d:SetScale(0.60) d:Show() e:UnregisterAllEvents() e:ClearAllPoints() e:SetParent(ShapeStanceHolder) e:SetPoint("CENTER",d,"RIGHT",27,0) e.SetPoint = dummy e:SetScale(0.60) e:Show() f:UnregisterAllEvents() f:ClearAllPoints() f:SetParent(ShapeStanceHolder) f:SetPoint("CENTER",e,"RIGHT",27,0) f.SetPoint = dummy f:SetScale(0.60) f:Show() g:UnregisterAllEvents() g:ClearAllPoints() g:SetParent(ShapeStanceHolder) g:SetPoint("CENTER",f,"RIGHT",27,0) g.SetPoint = dummy g:SetScale(0.60) g:Show() local p10 = PetActionButton10 local p9 = PetActionButton9 local p8 = PetActionButton8 local p7 = PetActionButton7 local p6 = PetActionButton6 local p5 = PetActionButton5 local p4 = PetActionButton4 local p3 = PetActionButton3 local p2 = PetActionButton2 local p1 = PetActionButton1 p10:UnregisterAllEvents() p10:ClearAllPoints() p10:SetParent(ShapeStanceHolder) p10:SetPoint("RIGHT",0,-7) p10.SetPoint = dummy p10:SetScale(0.60) p10:Show() p9:UnregisterAllEvents() p9:ClearAllPoints() p9:SetParent(ShapeStanceHolder) p9:SetPoint("CENTER",p10,"LEFT",-20,0) p9.SetPoint = dummy p9:SetScale(0.60) p9:Show() p8:UnregisterAllEvents() p8:ClearAllPoints() p8:SetParent(ShapeStanceHolder) p8:SetPoint("CENTER",p9,"LEFT",-20,0) p8.SetPoint = dummy p8:SetScale(0.60) p8:Show() p7:UnregisterAllEvents() p7:ClearAllPoints() p7:SetParent(ShapeStanceHolder) p7:SetPoint("CENTER",p8,"LEFT",-20,0) p7.SetPoint = dummy p7:SetScale(0.60) p7:Show() p6:UnregisterAllEvents() p6:ClearAllPoints() p6:SetParent(ShapeStanceHolder) p6:SetPoint("CENTER",p7,"LEFT",-20,0) p6.SetPoint = dummy p6:SetScale(0.60) p6:Show() p5:UnregisterAllEvents() p5:ClearAllPoints() p5:SetParent(ShapeStanceHolder) p5:SetPoint("CENTER",p6,"LEFT",-20,0) p5.SetPoint = dummy p5:SetScale(0.60) p5:Show() p4:UnregisterAllEvents() p4:ClearAllPoints() p4:SetParent(ShapeStanceHolder) p4:SetPoint("CENTER",p5,"LEFT",-20,0) p4.SetPoint = dummy p4:SetScale(0.60) p4:Show() p3:UnregisterAllEvents() p3:ClearAllPoints() p3:SetParent(ShapeStanceHolder) p3:SetPoint("CENTER",p4,"LEFT",-20,0) p3.SetPoint = dummy p3:SetScale(0.60) p3:Show() p2:UnregisterAllEvents() p2:ClearAllPoints() p2:SetParent(ShapeStanceHolder) p2:SetPoint("CENTER",p3,"LEFT",-20,0) p2.SetPoint = dummy p2:SetScale(0.60) p2:Show() p1:UnregisterAllEvents() p1:ClearAllPoints() p1:SetParent(ShapeStanceHolder) p1:SetPoint("CENTER",p2,"LEFT",-20,0) p1.SetPoint = dummy p1:SetScale(0.60) p1:Show() end a:SetScript("OnEvent", function(self,event,arg1) if(event=="UNIT_ENTERED_VEHICLE") then a:Hide() a2:Hide() mb:Hide() CharacterMicroButton:Hide() SpellbookMicroButton:Hide() TalentMicroButton:Hide() AchievementMicroButton:Hide() QuestLogMicroButton:Hide() SocialsMicroButton:Hide() PVPMicroButton:Hide() LFGMicroButton:Hide() MainMenuMicroButton:Hide() HelpMicroButton:Hide() elseif(event=="UNIT_EXITED_VEHICLE") then a:Show() a2:Show() mb:Show() end end) Thanks rabbit Before: In Vehicle: Exited from Vehicle: Last edited by Rabbit007 : 12-10-08 at 09:46 AM. |
|
12-10-08, 07:06 AM | #2 |
Seems like those micro buttons are really giving you a headache eh! I'm sure someone will come along soon enough to help you out again.
Be sure to post your finished product when everything's done btw, I'm interested in the outcome. |
|
12-10-08, 08:08 AM | #3 |
This is what i have so far... created the 4 rows of buttons through the XML... still have a ton to do. Not sure if i want to put the xp bar or the casting bar inbetween the 2 rows.. will see . this is the starting stage and i believe i am gonna keep going on this one . Have a TON of coding to do and also taking a bit longer as i am still learning a chunk of everything... but i am starting to get a good idea of it.. just need to learn the tricks of the trade and memorize the wow and widget api. also note i still haven't changed the graphic of the buttons yet.. gonna get everything in a general setup then go back and do the tweaks So needless to say this is still a long way off as i also want to add my own modifications such as a threat meter, dmg meter, a onebag type deal and quite a few other things to make it fully my own while giving the user a ZERO setup and raid ready UI. Just put the folder into your add-ons folder and walla your done... least thats the idea anyway Also once it gets to a certain point i will upload it to here and have people test and report bugs as it is also being made for a faster release of a HOPEFULLY bug free UI. Last edited by Rabbit007 : 12-10-08 at 09:49 AM. |
|
12-11-08, 07:55 AM | #4 |
Anybody ?
|
|
12-12-08, 09:34 AM | #5 |
kk... figured it out
|
|
12-12-08, 11:49 AM | #6 |
WoWInterface » Developer Discussions » Lua/XML Help » Micro Buttons disappear on Vehicle exit :( |
«
Previous Thread
|
Next Thread
»
|
Display Modes |
Linear Mode |
Switch to Hybrid Mode |
Switch to Threaded Mode |
|
|