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 77# =============================================================================
88# Python Imports
99# Enum
10- from enum import IntEnum
10+ from enum import IntFlag
1111
1212
1313# =============================================================================
5050# =============================================================================
5151# >> ENUMERATORS
5252# =============================================================================
53- class ConVarFlags (IntEnum ):
53+ class ConVarFlags (IntFlag ):
5454 """ConVar's flags wrapper enumerator."""
5555
5656 NONE = FCVAR_NONE
Original file line number Diff line number Diff line change 77# =============================================================================
88# Python Imports
99# Enum
10- from enum import IntEnum
10+ from enum import IntFlag
1111
1212# Source.Python Imports
1313# Entities
124124# =============================================================================
125125# >> ENUMERATORS
126126# =============================================================================
127- class ContentFlags (IntEnum ):
127+ class ContentFlags (IntFlag ):
128128 """Content flags wrapper enumerator."""
129129
130130 EMPTY = CONTENTS_EMPTY
@@ -162,7 +162,7 @@ class ContentFlags(IntEnum):
162162 HITBOX = CONTENTS_HITBOX
163163
164164
165- class ContentMasks (IntEnum ):
165+ class ContentMasks (IntFlag ):
166166 """Content masks wrapper enumerator."""
167167
168168 ALL = MASK_ALL
Original file line number Diff line number Diff line change 88# Python Imports
99# Enum
1010from enum import IntEnum
11+ from enum import IntFlag
1112
1213
1314# =============================================================================
161162# =============================================================================
162163# >> ENUMERATORS
163164# =============================================================================
164- class DamageTypes (IntEnum ):
165+ class DamageTypes (IntFlag ):
165166 """Damage types wrapper enumerator."""
166167
167168 GENERIC = DMG_GENERIC
@@ -199,7 +200,7 @@ class DamageTypes(IntEnum):
199200 HEADSHOT = DMG_HEADSHOT
200201
201202
202- class EntityStates (IntEnum ):
203+ class EntityStates (IntFlag ):
203204 """Entity state flags wrapper enumerator."""
204205
205206 FLY = FL_FLY
@@ -225,7 +226,7 @@ class EntityStates(IntEnum):
225226 UNBLOCKABLE_BY_PLAYER = FL_UNBLOCKABLE_BY_PLAYER
226227
227228
228- class EntityEffects (IntEnum ):
229+ class EntityEffects (IntFlag ):
229230 """Entity effects wrapper enumerator."""
230231
231232 BONEMERGE = EF_BONEMERGE
@@ -261,7 +262,7 @@ class TakeDamage(IntEnum):
261262 AIM = DAMAGE_AIM
262263
263264
264- class EntityFlags (IntEnum ):
265+ class EntityFlags (IntFlag ):
265266 """Entity flags wrapper enumerator."""
266267
267268 KILLME = EFL_KILLME
Original file line number Diff line number Diff line change 77# =============================================================================
88# Python Imports
99# Enum
10- from enum import IntEnum
10+ from enum import IntFlag
1111
1212# Source.Python Imports
1313# Memory
7373# =============================================================================
7474# >> ENUMERATORS
7575# =============================================================================
76- class TypeDescriptionFlags (IntEnum ):
76+ class TypeDescriptionFlags (IntFlag ):
7777 """TypeDescription flags wrapper enumerator."""
7878
7979 GLOBAL = FTYPEDESC_GLOBAL
Original file line number Diff line number Diff line change 77# =============================================================================
88# Python Imports
99# Enum
10- from enum import IntEnum
10+ from enum import IntFlag
1111
1212
1313# =============================================================================
5353# =============================================================================
5454# >> ENUMERATORS
5555# =============================================================================
56- class SendPropFlags (IntEnum ):
56+ class SendPropFlags (IntFlag ):
5757 """SendProp flags wrapper enumerator."""
5858
5959 UNSIGNED = SPROP_UNSIGNED
Original file line number Diff line number Diff line change 88# Python Imports
99# Enum
1010from enum import IntEnum
11+ from enum import IntFlag
1112
1213
1314# =============================================================================
106107# =============================================================================
107108# >> ENUMERATORS
108109# =============================================================================
109- class PlayerStates (IntEnum ):
110+ class PlayerStates (IntFlag ):
110111 """Player states wrapper enumerator."""
111112
112113 ONGROUND = FL_ONGROUND
@@ -131,7 +132,7 @@ class LifeState(IntEnum):
131132 DISCARDBODY = LIFE_DISCARDBODY
132133
133134
134- class PlayerButtons (IntEnum ):
135+ class PlayerButtons (IntFlag ):
135136 """Player buttons wrapper enumerator."""
136137
137138 ATTACK = IN_ATTACK
@@ -162,7 +163,7 @@ class PlayerButtons(IntEnum):
162163 LOOKSPIN = IN_LOOKSPIN
163164
164165
165- class HideHudFlags (IntEnum ):
166+ class HideHudFlags (IntFlag ):
166167 """Hide hud flags wrapper enumerator."""
167168
168169 WEAPONSELECTION = HIDEHUD_WEAPONSELECTION
Original file line number Diff line number Diff line change 77# =============================================================================
88# Python Imports
99# Enum
10- from enum import IntEnum
10+ from enum import IntFlag
1111
1212
1313# =============================================================================
4848# =============================================================================
4949# >> ENUMERATORS
5050# =============================================================================
51- class StudioFlags (IntEnum ):
51+ class StudioFlags (IntFlag ):
5252 """Studio flags wrapper enumerator."""
5353
5454 NONE = STUDIO_NONE
Original file line number Diff line number Diff line change 88# Python Imports
99# Enum
1010from enum import IntEnum
11+ from enum import IntFlag
1112
1213# Source.Python Imports
1314# Core
7374# =============================================================================
7475# >> ENUMERATORS
7576# =============================================================================
76- class ItemFlags (IntEnum ):
77+ class ItemFlags (IntFlag ):
7778 """Item flags wrapper enumerator."""
7879
7980 SELECTONEMPTY = ITEM_FLAG_SELECTONEMPTY
You can’t perform that action at this time.
0 commit comments