1
|
1 |
|
|
2
|
1 |
|
from candv import Constants |
3
|
1 |
|
from candv import Values |
4
|
|
|
from candv import VerboseConstant |
5
|
1 |
|
from candv import VerboseValueConstant |
6
|
|
|
from candv import with_constant_class |
7
|
|
|
|
8
|
1 |
|
from ._translations import gettext_lazy as _ |
9
|
1 |
|
from ._utils import export |
10
|
|
|
|
11
|
|
|
|
12
|
1 |
|
@export |
13
|
1 |
|
class TargetTypeConstant(VerboseValueConstant): |
14
|
1 |
|
... |
15
|
1 |
|
|
16
|
1 |
|
|
17
|
1 |
|
@export |
18
|
1 |
|
class TARGET_TYPES(with_constant_class(TargetTypeConstant), Values): |
19
|
1 |
|
DESTROY = TargetTypeConstant(0, _("destroy")) |
20
|
1 |
|
DESTROY_AREA = TargetTypeConstant(1, _("destroy area")) |
21
|
|
|
DESTROY_BRIDGE = TargetTypeConstant(2, _("destroy bridge")) |
22
|
|
|
RECON = TargetTypeConstant(3, _("recon")) |
23
|
1 |
|
ESCORT = TargetTypeConstant(4, _("escort")) |
24
|
1 |
|
COVER = TargetTypeConstant(5, _("cover")) |
25
|
|
|
COVER_AREA = TargetTypeConstant(6, _("cover area")) |
26
|
|
|
COVER_BRIDGE = TargetTypeConstant(7, _("cover bridge")) |
27
|
1 |
|
|
28
|
1 |
|
|
29
|
1 |
|
@export |
30
|
1 |
|
class TargetPriorityConstant(VerboseValueConstant): |
31
|
|
|
... |
32
|
|
|
|
33
|
|
|
|
34
|
|
|
@export |
35
|
|
|
class TARGET_PRIORITIES(with_constant_class(TargetPriorityConstant), Values): |
36
|
|
|
PRIMARY = TargetPriorityConstant(0, _("primary")) |
37
|
|
|
SECONDARY = TargetPriorityConstant(1, _("secondary")) |
38
|
|
|
HIDDEN = TargetPriorityConstant(2, _("hidden")) |
39
|
|
|
|
40
|
|
|
|
41
|
|
|
@export |
42
|
|
|
class TargetStateConstant(VerboseConstant): |
43
|
|
|
... |
44
|
|
|
|
45
|
|
|
|
46
|
|
|
@export |
47
|
|
|
class TARGET_STATES(with_constant_class(TargetStateConstant), Constants): |
48
|
|
|
COMPLETE = TargetStateConstant(verbose_name=_("Complete")) |
49
|
|
|
FAILED = TargetStateConstant(verbose_name=_("Failed")) |
50
|
|
|
|