Mercurial > wow > devian
comparison Devian.lua @ 56:4b1b301cf8d4
movement faders obey the conditons asserted by db.workspace
author | Nenue |
---|---|
date | Wed, 06 Jan 2016 11:46:24 -0500 |
parents | 1b8c597dba44 |
children | 0d2967941745 |
comparison
equal
deleted
inserted
replaced
55:1b8c597dba44 | 56:4b1b301cf8d4 |
---|---|
51 headerblend = 'BLEND', | 51 headerblend = 'BLEND', |
52 headeralpha = 1, | 52 headeralpha = 1, |
53 headerfontcolor = {1,1,1,1}, | 53 headerfontcolor = {1,1,1,1}, |
54 | 54 |
55 backdrop = {1,1,1,1}, -- background frame info | 55 backdrop = {1,1,1,1}, -- background frame info |
56 backgrad = {'VERTICAL', 0.1, 0.1, 0.1, 1, 0, 0, 0, 1}, | 56 backgrad = {'VERTICAL', 0, 0, 0, .75, 0,0,0, .65}, |
57 backblend = 'BLEND', | 57 backblend = 'BLEND', |
58 backalpha = 1, | 58 backalpha = 1, |
59 backborder = {.5,.5,.5,1}, | 59 backborder = {.5,.5,.5,1}, |
60 backheader = {.25,.25,.25,1}, | 60 backheader = {.25,.25,.25,1}, |
61 | 61 |
62 frontdrop = {1,1,1,1}, -- foreground frame info | 62 frontdrop = {1,1,1,1}, -- foreground frame info |
63 frontgrad = {'VERTICAL', 0.1, 0.1, 0.1, 1, 0, 0, 0, 1}, | 63 frontgrad = {'VERTICAL', 0, 0, 0, 1, 0,0,0, 0.95}, |
64 frontblend = 'BLEND', | 64 frontblend = 'BLEND', |
65 frontalpha = 1, | 65 frontalpha = 1, |
66 frontborder = {.07,.47,1,1}, | 66 frontborder = {.07,.47,1,1}, |
67 frontheader = {1,1,1,1}, | 67 frontheader = {1,1,1,1}, |
68 tagcolor = {}, -- tag color repository | 68 tagcolor = {}, -- tag color repository |
397 | 397 |
398 if db.workspace == 1 then | 398 if db.workspace == 1 then |
399 D:Print('Gameplay mode active (list #'..db.workspace..'). Print handling turned |cFFFFFF00OFF|r.') | 399 D:Print('Gameplay mode active (list #'..db.workspace..'). Print handling turned |cFFFFFF00OFF|r.') |
400 else | 400 else |
401 D:Print('Development mode active (list #'..db.workspace..'). Print handling |cFF00FF00ON|r.') | 401 D:Print('Development mode active (list #'..db.workspace..'). Print handling |cFF00FF00ON|r.') |
402 -- movement fading | |
403 if db.movement_fade then | |
404 self:RegisterEvent('PLAYER_STARTED_MOVING', function() | |
405 for k, v in pairs(self.console) do | |
406 if v.enabled then | |
407 v.preAlpha = v:GetAlpha() | |
408 UIFrameFadeOut(v, db.movement_fade_time, v.preAlpha, 0) | |
409 UIFrameFadeOut(v.out, db.movement_fade_time, v.preAlpha, 0) | |
410 end | |
411 end | |
412 end) | |
413 self:RegisterEvent('PLAYER_STOPPED_MOVING', function() | |
414 for k, v in pairs(self.console) do | |
415 if v.enabled then | |
416 UIFrameFadeIn(v, db.movement_fade_time, v:GetAlpha(), v.alpha) | |
417 UIFrameFadeIn(v.out, db.movement_fade_time, v:GetAlpha(), v.alpha) | |
418 end | |
419 end | |
420 end) | |
421 end | |
402 end | 422 end |
403 | 423 |
404 --@debug@ | 424 --@debug@ |
405 self:RegisterChatCommand("dvg", function(input) | 425 self:RegisterChatCommand("dvg", function(input) |
406 if not self.config then | 426 if not self.config then |
409 end | 429 end |
410 self.modules.Config:ChatCommand(input) | 430 self.modules.Config:ChatCommand(input) |
411 end) | 431 end) |
412 --@end-debug@ | 432 --@end-debug@ |
413 | 433 |
414 -- movement fading | |
415 if db.movement_fade then | |
416 self:RegisterEvent('PLAYER_STARTED_MOVING', function() | |
417 for k, v in pairs(self.console) do | |
418 if v.enabled then | |
419 v.preAlpha = v:GetAlpha() | |
420 UIFrameFadeOut(v, db.movement_fade_time, v.preAlpha, 0) | |
421 UIFrameFadeOut(v.out, db.movement_fade_time, v.preAlpha, 0) | |
422 end | |
423 end | |
424 end) | |
425 self:RegisterEvent('PLAYER_STOPPED_MOVING', function() | |
426 for k, v in pairs(self.console) do | |
427 if v.enabled then | |
428 UIFrameFadeIn(v, db.movement_fade_time, v:GetAlpha(), v.alpha) | |
429 UIFrameFadeIn(v.out, db.movement_fade_time, v:GetAlpha(), v.alpha) | |
430 end | |
431 end | |
432 end) | |
433 end | |
434 end | 434 end |
435 | 435 |
436 function D:OnInitialize() | 436 function D:OnInitialize() |
437 -- commands | 437 -- commands |
438 self:RegisterChatCommand("cleandvn", function(args) | 438 self:RegisterChatCommand("cleandvn", function(args) |