import schedule
import time
class Greeter:
def __init__(self):
self.count = 0
def say_hello(self):
self.count += 1
print(f"Hello! Called {self.count} times")
# Create an instance
g = Greeter()
# Schedule the *method* (not a function)...
The shit is inside of the ass
import time
class OncePerDayGate:
def __init__(self):
self.last_yday = -1
self.triggered_today = False
def check(self, event_happened: bool) -> bool:
# Fast integer day-of-year check
yday = time.localtime().tm_yday...
import re
def extract_xy(text):
m = re.search(r'^\s*compare\s+(.*?)\s+vs\s+(.*)$', text, re.IGNORECASE)
return [m.group(1), m.group(2)] if m else []
@fukurou
Skill 🌲: railbot: interupt for sp cases
With sub skill trees.
Skill tree has atribute of skill tree list which are skill sub classes
Shit in the ass man!
`python
from abc import ABC, abstractmethod
class Base(ABC):
@abstractmethod
def run(self):
pass
`
`python
class Child(Base):
def run(self):
return "running"
`
The key will be interupting the input method