File tree Expand file tree Collapse file tree 8 files changed +22
-19
lines changed
addons/source-python/packages/source-python Expand file tree Collapse file tree 8 files changed +22
-19
lines changed Original file line number Diff line number Diff line change 7
7
# =============================================================================
8
8
# Python Imports
9
9
# Enum
10
- from enum import IntEnum
10
+ from enum import IntFlag
11
11
12
12
13
13
# =============================================================================
50
50
# =============================================================================
51
51
# >> ENUMERATORS
52
52
# =============================================================================
53
- class ConVarFlags (IntEnum ):
53
+ class ConVarFlags (IntFlag ):
54
54
"""ConVar's flags wrapper enumerator."""
55
55
56
56
NONE = FCVAR_NONE
Original file line number Diff line number Diff line change 7
7
# =============================================================================
8
8
# Python Imports
9
9
# Enum
10
- from enum import IntEnum
10
+ from enum import IntFlag
11
11
12
12
# Source.Python Imports
13
13
# Entities
124
124
# =============================================================================
125
125
# >> ENUMERATORS
126
126
# =============================================================================
127
- class ContentFlags (IntEnum ):
127
+ class ContentFlags (IntFlag ):
128
128
"""Content flags wrapper enumerator."""
129
129
130
130
EMPTY = CONTENTS_EMPTY
@@ -162,7 +162,7 @@ class ContentFlags(IntEnum):
162
162
HITBOX = CONTENTS_HITBOX
163
163
164
164
165
- class ContentMasks (IntEnum ):
165
+ class ContentMasks (IntFlag ):
166
166
"""Content masks wrapper enumerator."""
167
167
168
168
ALL = MASK_ALL
Original file line number Diff line number Diff line change 8
8
# Python Imports
9
9
# Enum
10
10
from enum import IntEnum
11
+ from enum import IntFlag
11
12
12
13
13
14
# =============================================================================
161
162
# =============================================================================
162
163
# >> ENUMERATORS
163
164
# =============================================================================
164
- class DamageTypes (IntEnum ):
165
+ class DamageTypes (IntFlag ):
165
166
"""Damage types wrapper enumerator."""
166
167
167
168
GENERIC = DMG_GENERIC
@@ -199,7 +200,7 @@ class DamageTypes(IntEnum):
199
200
HEADSHOT = DMG_HEADSHOT
200
201
201
202
202
- class EntityStates (IntEnum ):
203
+ class EntityStates (IntFlag ):
203
204
"""Entity state flags wrapper enumerator."""
204
205
205
206
FLY = FL_FLY
@@ -225,7 +226,7 @@ class EntityStates(IntEnum):
225
226
UNBLOCKABLE_BY_PLAYER = FL_UNBLOCKABLE_BY_PLAYER
226
227
227
228
228
- class EntityEffects (IntEnum ):
229
+ class EntityEffects (IntFlag ):
229
230
"""Entity effects wrapper enumerator."""
230
231
231
232
BONEMERGE = EF_BONEMERGE
@@ -261,7 +262,7 @@ class TakeDamage(IntEnum):
261
262
AIM = DAMAGE_AIM
262
263
263
264
264
- class EntityFlags (IntEnum ):
265
+ class EntityFlags (IntFlag ):
265
266
"""Entity flags wrapper enumerator."""
266
267
267
268
KILLME = EFL_KILLME
Original file line number Diff line number Diff line change 7
7
# =============================================================================
8
8
# Python Imports
9
9
# Enum
10
- from enum import IntEnum
10
+ from enum import IntFlag
11
11
12
12
# Source.Python Imports
13
13
# Memory
73
73
# =============================================================================
74
74
# >> ENUMERATORS
75
75
# =============================================================================
76
- class TypeDescriptionFlags (IntEnum ):
76
+ class TypeDescriptionFlags (IntFlag ):
77
77
"""TypeDescription flags wrapper enumerator."""
78
78
79
79
GLOBAL = FTYPEDESC_GLOBAL
Original file line number Diff line number Diff line change 7
7
# =============================================================================
8
8
# Python Imports
9
9
# Enum
10
- from enum import IntEnum
10
+ from enum import IntFlag
11
11
12
12
13
13
# =============================================================================
53
53
# =============================================================================
54
54
# >> ENUMERATORS
55
55
# =============================================================================
56
- class SendPropFlags (IntEnum ):
56
+ class SendPropFlags (IntFlag ):
57
57
"""SendProp flags wrapper enumerator."""
58
58
59
59
UNSIGNED = SPROP_UNSIGNED
Original file line number Diff line number Diff line change 8
8
# Python Imports
9
9
# Enum
10
10
from enum import IntEnum
11
+ from enum import IntFlag
11
12
12
13
13
14
# =============================================================================
106
107
# =============================================================================
107
108
# >> ENUMERATORS
108
109
# =============================================================================
109
- class PlayerStates (IntEnum ):
110
+ class PlayerStates (IntFlag ):
110
111
"""Player states wrapper enumerator."""
111
112
112
113
ONGROUND = FL_ONGROUND
@@ -131,7 +132,7 @@ class LifeState(IntEnum):
131
132
DISCARDBODY = LIFE_DISCARDBODY
132
133
133
134
134
- class PlayerButtons (IntEnum ):
135
+ class PlayerButtons (IntFlag ):
135
136
"""Player buttons wrapper enumerator."""
136
137
137
138
ATTACK = IN_ATTACK
@@ -162,7 +163,7 @@ class PlayerButtons(IntEnum):
162
163
LOOKSPIN = IN_LOOKSPIN
163
164
164
165
165
- class HideHudFlags (IntEnum ):
166
+ class HideHudFlags (IntFlag ):
166
167
"""Hide hud flags wrapper enumerator."""
167
168
168
169
WEAPONSELECTION = HIDEHUD_WEAPONSELECTION
Original file line number Diff line number Diff line change 7
7
# =============================================================================
8
8
# Python Imports
9
9
# Enum
10
- from enum import IntEnum
10
+ from enum import IntFlag
11
11
12
12
13
13
# =============================================================================
48
48
# =============================================================================
49
49
# >> ENUMERATORS
50
50
# =============================================================================
51
- class StudioFlags (IntEnum ):
51
+ class StudioFlags (IntFlag ):
52
52
"""Studio flags wrapper enumerator."""
53
53
54
54
NONE = STUDIO_NONE
Original file line number Diff line number Diff line change 8
8
# Python Imports
9
9
# Enum
10
10
from enum import IntEnum
11
+ from enum import IntFlag
11
12
12
13
# Source.Python Imports
13
14
# Core
73
74
# =============================================================================
74
75
# >> ENUMERATORS
75
76
# =============================================================================
76
- class ItemFlags (IntEnum ):
77
+ class ItemFlags (IntFlag ):
77
78
"""Item flags wrapper enumerator."""
78
79
79
80
SELECTONEMPTY = ITEM_FLAG_SELECTONEMPTY
You can’t perform that action at this time.
0 commit comments