本文整理汇总了Python中core.GameElement类的典型用法代码示例。如果您正苦于以下问题:Python GameElement类的具体用法?Python GameElement怎么用?Python GameElement使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
在下文中一共展示了GameElement类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: __init__
def __init__(self):
GameElement.__init__(self)
self.inventory = []
self.gem_inventory = []
self.key_inventory = []
self.tree_inventory = []
self.princess_interaction = 0
示例2: __init__
def __init__(self):
GameElement.__init__(self)
self.points = 0
self.inventory = []
self.IMAGE = "Horns"
self.name = "Horns"
self.selector_image = "Yellow_selector"
示例3: __init__
def __init__(self):
GameElement.__init__(self)
self.inventoryBlueGems=[]
self.inventoryGreenGems=[]
self.inventorychests=[]
self.inventoryDoor=[]
self.inventoryKeys=[]
示例4: __init__
def __init__(self):
GameElement.__init__(self)
self.inventory = []
self.tree_inventory = []
self.heart_inventory =[]
self.rock_inventory =[]
self.key_inventory = []
示例5: __init__
def __init__(self, state):
GameElement.__init__(self)
self.STATE = state
if state == "Open":
self.IMAGE = "DoorOpen"
self.SOLID = False
elif state == "Closed":
self.IMAGE = "DoorClosed"
self.SOLID = True
示例6: __init__
def __init__(self): # initializer that sets up object with initial values
GameElement.__init__(self) # tells Character class to call parent class' initializer so that it uses the behaviors of board interactions set
# self.inventory = []
self.inventory = {
"Potion":0,
"Rocks":0,
"Hearts":0,
"Keys":0,
"Torches":0
} # this instance's inventory starts as an empty list
示例7: __init__
def __init__(self): # initializer that sets up object with initial values
GameElement.__init__(self) # tells Character class to call parent class' initializer so that it uses the behaviors of board interactions set
# self.inventory = []
self.inventory = {
"Torches":0,
}
示例8: __init__
def __init__(self, player):
GameElement.__init__(self)
self.inventory = []
self.IMAGE = player
示例9: __init__
def __init__(self): # every class has a default init. If you want to change the Init, you define it here.
GameElement.__init__(self)
self.inventory = [] #creates empty inventory list
示例10: __init__
def __init__(self):
GameElement.__init__(self)
self.inventory = []
self.ridinglist = []
self.popoexists = False
示例11: __init__
def __init__(self):
GameElement.__init__(self)
self.last_move = 0
self.velocity_x = 1
示例12: __init__
def __init__(self):
GameElement.__init__(self)
self.inventory_gems = []
self.inventory_hearts = []
示例13: __init__
def __init__(self):
GameElement.__init__(self)
self.IMAGE = random.choice(self.imagelist)
self.SOLID = False
示例14: __init__
def __init__(self):
GameElement.__init__(self)
self.inventory = []
self.key_list = []
示例15: __init__
def __init__(self, position):
GameElement.__init__(self)
self.position = position
x_coord, y_coord = position
GAME_BOARD.register(self)
GAME_BOARD.set_el(x_coord, y_coord, self)