Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- -- check classes
- local classes, alreadyon = {}, {}
- for w in string.gmatch(matches[2], "%a+") do
- if svo.classes[w] and not svo.enabledclasses[w] then classes[#classes+1] = w -- weed out invalid names
- elseif svo.classes[w] and svo.enabledclasses[w] then alreadyon[#alreadyon+1] = w end
- end
- for i = 1, #classes do
- svo.enableclass(classes[i])
- end
- local setsomething = false
- if classes[1] then
- svo.echof("Enabled %s %sclass%s.", svo.concatand(classes), (not only and '' or "only the "), (#classes == 1 and '' or 'es'))
- setsomething = true
- end
- if alreadyon[1] then
- svo.echof("%s %s already on.", svo.concatand(alreadyon):title(), (#alreadyon == 1 and 'is' or 'are'))
- setsomething = true
- end
- if not setsomething then
- svo.echof("'%s' isn't something you can change.", matches[2])
- end
Add Comment
Please, Sign In to add comment