mirror of
https://github.com/onyx-and-iris/vban-cmd-python.git
synced 2024-11-15 17:10:46 +00:00
apply extended to support button, vban
This commit is contained in:
parent
41e427e46b
commit
2c8659a4e5
@ -175,8 +175,10 @@ class VbanCmd(metaclass=ABCMeta):
|
|||||||
def param(key):
|
def param(key):
|
||||||
obj, m2, *rem = key.split("-")
|
obj, m2, *rem = key.split("-")
|
||||||
index = int(m2) if m2.isnumeric() else int(*rem)
|
index = int(m2) if m2.isnumeric() else int(*rem)
|
||||||
if obj in ("strip", "bus"):
|
if obj in ("strip", "bus", "button"):
|
||||||
return getattr(self, obj)[index]
|
return getattr(self, obj)[index]
|
||||||
|
elif obj == "vban":
|
||||||
|
return getattr(getattr(self, obj), f"{m2}stream")[index]
|
||||||
else:
|
else:
|
||||||
raise ValueError(obj)
|
raise ValueError(obj)
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user