File tree Expand file tree Collapse file tree 2 files changed +15
-3
lines changed
addons/source-python/packages/source-python Expand file tree Collapse file tree 2 files changed +15
-3
lines changed Original file line number Diff line number Diff line change 7474# =============================================================================
7575# >> CLASSES
7676# =============================================================================
77- class Player (Entity , PlayerMixin ):
77+ class Player (PlayerMixin , Entity ):
7878 """Class used to interact directly with players."""
7979
8080 def __init__ (self , index ):
@@ -85,7 +85,8 @@ def __init__(self, index):
8585 :raise ValueError:
8686 Raised if the index is invalid.
8787 """
88- super ().__init__ (index )
88+ PlayerMixin .__init__ (self , index )
89+ Entity .__init__ (self , index )
8990 object .__setattr__ (self , '_playerinfo' , None )
9091
9192 @classmethod
Original file line number Diff line number Diff line change 2424# =============================================================================
2525# >> CLASSES
2626# =============================================================================
27- class Weapon (Entity , WeaponMixin ):
27+ class Weapon (WeaponMixin , Entity ):
2828 """Allows easy usage of the weapon's attributes."""
2929
30+ def __init__ (self , index ):
31+ """Initialize the object.
32+
33+ :param int index:
34+ A valid weapon index.
35+ :raise ValueError:
36+ Raised if the index is invalid.
37+ """
38+ WeaponMixin .__init__ (self , index )
39+ Entity .__init__ (self , index )
40+
3041 def _validate_clip (self ):
3142 """Test if the weapon has a clip."""
3243 if (
You can’t perform that action at this time.
0 commit comments