oops kwarg
This commit is contained in:
parent
bdd7160dde
commit
44db6927c4
1 changed files with 3 additions and 3 deletions
|
@ -125,10 +125,10 @@ class Enchantment:
|
||||||
type : EnchantmentType
|
type : EnchantmentType
|
||||||
level : int
|
level : int
|
||||||
|
|
||||||
def __init__(self, type:EnchantmentType=None, eid:int=None, level:int=1):
|
def __init__(self, type:EnchantmentType=None, id:int=None, level:int=1):
|
||||||
if not type and not eid:
|
if not type and not id:
|
||||||
raise ValueError("No enchantment type or enchantment id provided")
|
raise ValueError("No enchantment type or enchantment id provided")
|
||||||
self.type = type or EnchantmentType(eid)
|
self.type = type or EnchantmentType(id)
|
||||||
self.eid = self.type.value
|
self.eid = self.type.value
|
||||||
self.level = level
|
self.level = level
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue