Skip to content

MessageManager

Classes

MessageManager

Bases: AoE2Object

Manager of the everything message tab related.

Source code in AoE2ScenarioParser/objects/managers/message_manager.py
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
class MessageManager(AoE2Object):
    """Manager of the everything message tab related."""

    _link_list = [
        RetrieverObjectLinkGroup("Messages", group=[
            RetrieverObjectLink("instructions", link="ascii_instructions"),
            RetrieverObjectLink("hints", link="ascii_hints"),
            RetrieverObjectLink("victory", link="ascii_victory"),
            RetrieverObjectLink("loss", link="ascii_loss"),
            RetrieverObjectLink("history", link="ascii_history"),
            RetrieverObjectLink("scouts", link="ascii_scouts"),

            RetrieverObjectLink("instructions_string_table_id", link="instructions"),
            RetrieverObjectLink("hints_string_table_id", link="hints"),
            RetrieverObjectLink("victory_string_table_id", link="victory"),
            RetrieverObjectLink("loss_string_table_id", link="loss"),
            RetrieverObjectLink("history_string_table_id", link="history"),
            RetrieverObjectLink("scouts_string_table_id", link="scouts"),
        ]),
    ]

    def __init__(self,
                 instructions: str,
                 hints: str,
                 victory: str,
                 loss: str,
                 history: str,
                 scouts: str,
                 instructions_string_table_id: int,
                 hints_string_table_id: int,
                 victory_string_table_id: int,
                 loss_string_table_id: int,
                 history_string_table_id: int,
                 scouts_string_table_id: int,
                 **kwargs
                 ):
        super().__init__(**kwargs)

        self.instructions: str = instructions
        self.hints: str = hints
        self.victory: str = victory
        self.loss: str = loss
        self.history: str = history
        self.scouts: str = scouts
        self.instructions_string_table_id: int = instructions_string_table_id
        self.hints_string_table_id: int = hints_string_table_id
        self.victory_string_table_id: int = victory_string_table_id
        self.loss_string_table_id: int = loss_string_table_id
        self.history_string_table_id: int = history_string_table_id
        self.scouts_string_table_id: int = scouts_string_table_id

Attributes

Attribute Type
hints instance-attribute
str
hints_string_table_id instance-attribute
int
history instance-attribute
str
history_string_table_id instance-attribute
int
instructions instance-attribute
str
instructions_string_table_id instance-attribute
int
loss instance-attribute
str
loss_string_table_id instance-attribute
int
scouts instance-attribute
str
scouts_string_table_id instance-attribute
int
victory instance-attribute
str
victory_string_table_id instance-attribute
int

Functions


def __init__(...)

Parameters:

Name Type Description Default
instructions str - required
hints str - required
victory str - required
loss str - required
history str - required
scouts str - required
instructions_string_table_id int - required
hints_string_table_id int - required
victory_string_table_id int - required
loss_string_table_id int - required
history_string_table_id int - required
scouts_string_table_id int - required
kwargs ? - {}
Source code in AoE2ScenarioParser/objects/managers/message_manager.py
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
def __init__(self,
             instructions: str,
             hints: str,
             victory: str,
             loss: str,
             history: str,
             scouts: str,
             instructions_string_table_id: int,
             hints_string_table_id: int,
             victory_string_table_id: int,
             loss_string_table_id: int,
             history_string_table_id: int,
             scouts_string_table_id: int,
             **kwargs
             ):
    super().__init__(**kwargs)

    self.instructions: str = instructions
    self.hints: str = hints
    self.victory: str = victory
    self.loss: str = loss
    self.history: str = history
    self.scouts: str = scouts
    self.instructions_string_table_id: int = instructions_string_table_id
    self.hints_string_table_id: int = hints_string_table_id
    self.victory_string_table_id: int = victory_string_table_id
    self.loss_string_table_id: int = loss_string_table_id
    self.history_string_table_id: int = history_string_table_id
    self.scouts_string_table_id: int = scouts_string_table_id