mirror of
https://github.com/onyx-and-iris/vban-cmd-python.git
synced 2026-04-18 04:53:31 +00:00
levels reworked
comp generator function added to util. patch bump
This commit is contained in:
@@ -1,3 +1,6 @@
|
||||
from typing import Iterator
|
||||
|
||||
|
||||
def cache_bool(func, param):
|
||||
"""Check cache for a bool prop"""
|
||||
|
||||
@@ -49,3 +52,15 @@ def script(func):
|
||||
return func(remote, script)
|
||||
|
||||
return wrapper
|
||||
|
||||
|
||||
def comp(t0: tuple, t1: tuple) -> Iterator[bool]:
|
||||
"""
|
||||
Generator function, accepts two tuples.
|
||||
|
||||
Evaluates equality of each member in both tuples.
|
||||
"""
|
||||
for a, b in zip(t0, t1):
|
||||
if b <= 9500:
|
||||
yield a == b
|
||||
yield True
|
||||
|
||||
Reference in New Issue
Block a user