Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
O
oUF_Classic
Project overview
Project overview
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Azilroka
oUF_Classic
Commits
db75951d
Commit
db75951d
authored
Jan 25, 2009
by
Trond A Ekseth
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix [smartlevel].
parent
eb267114
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
15 additions
and
1 deletion
+15
-1
elements/tags.lua
elements/tags.lua
+15
-1
No files found.
elements/tags.lua
View file @
db75951d
...
...
@@ -48,12 +48,26 @@ tags = {
[
"[resting]"
]
=
function
(
u
)
return
u
==
"player"
and
IsResting
()
and
"zzz"
end
,
[
"[sex]"
]
=
function
(
u
)
local
s
=
UnitSex
(
u
)
return
s
==
2
and
"Male"
or
s
==
3
and
"Female"
end
,
[
"[smartclass]"
]
=
function
(
u
)
return
UnitIsPlayer
(
u
)
and
tags
[
"[class]"
](
u
)
or
tags
[
"[creature]"
](
u
)
end
,
[
"[smartlevel]"
]
=
function
(
u
)
return
UnitClassification
(
u
)
==
"worldboss"
and
"Boss"
or
tags
[
"[level]"
](
u
)
..
tags
[
"[plus]"
](
u
)
end
,
[
"[status]"
]
=
function
(
u
)
return
UnitIsDead
(
u
)
and
"Dead"
or
UnitIsGhost
(
u
)
and
"Ghost"
or
not
UnitIsConnected
(
u
)
and
"Offline"
or
tags
[
"[resting]"
](
u
)
end
,
[
"[threat]"
]
=
function
(
u
)
local
s
=
UnitThreatSituation
(
u
)
return
s
==
1
and
"++"
or
s
==
2
and
"--"
or
s
==
3
and
"Aggro"
end
,
[
"[threatcolor]"
]
=
function
(
u
)
return
Hex
(
GetThreatStatusColor
(
UnitThreatSituation
(
u
)))
end
,
[
"[cpoints]"
]
=
function
(
u
)
local
cp
=
GetComboPoints
(
u
,
'target'
)
return
(
cp
>
0
)
and
cp
end
,
[
'[smartlevel]'
]
=
function
(
u
)
local
c
=
UnitClassification
(
u
)
if
(
c
==
'worldboss'
)
then
return
'Boss'
else
local
plus
=
tags
[
'[plus]'
](
u
)
local
level
=
tags
[
'[level]'
](
u
)
if
(
plus
)
then
return
level
..
plus
else
return
level
end
end
end
,
[
"[classification]"
]
=
function
(
u
)
local
c
=
UnitClassification
(
u
)
return
c
==
"rare"
and
"Rare"
or
c
==
"eliterare"
and
"Rare Elite"
or
c
==
"elite"
and
"Elite"
or
c
==
"worldboss"
and
"Boss"
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment