MCPcopy Create free account
hub / github.com/PierreGode/Ragnar / __init__

Method __init__

comment.py:21–26  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

19class Commentaireia:
20 """Provides context-based random comments for ragnar."""
21 def __init__(self):
22 self.shared_data = shared_data
23 self.last_comment_time = 0 # Initialize last_comment_time
24 self.comment_delay = random.randint(self.shared_data.config['comment_delaymin'], self.shared_data.config['comment_delaymax']) # Initialize comment_delay
25 self.last_theme = None # Initialize last_theme
26 self.themes = self.load_comments(self.shared_data.commentsfile) # Load themes from JSON file
27
28 def load_comments(self, commentsfile):
29 """Load comments from a JSON file."""

Callers

nothing calls this directly

Calls 1

load_commentsMethod · 0.95

Tested by

no test coverage detected