当前位置: 首页>>代码示例>>Python>>正文


Python core.GameElement类代码示例

本文整理汇总了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
开发者ID:sgottlieb,项目名称:oop_lesson,代码行数:7,代码来源:game.py

示例2: __init__

 def __init__(self):
     GameElement.__init__(self)
     self.points = 0
     self.inventory = []
     self.IMAGE = "Horns"
     self.name = "Horns"
     self.selector_image = "Yellow_selector"
开发者ID:br3annalynn,项目名称:oop_lesson,代码行数:7,代码来源:game.py

示例3: __init__

 def __init__(self):
     GameElement.__init__(self)
     self.inventoryBlueGems=[]
     self.inventoryGreenGems=[]
     self.inventorychests=[]  
     self.inventoryDoor=[]
     self.inventoryKeys=[]
开发者ID:margaretblue,项目名称:oop_lesson,代码行数:7,代码来源:game.py

示例4: __init__

 def __init__(self):
     GameElement.__init__(self)
     self.inventory = []
     self.tree_inventory = []
     self.heart_inventory =[]
     self.rock_inventory =[]
     self.key_inventory = []
开发者ID:k8k,项目名称:HBGame,代码行数:7,代码来源:game.py

示例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
开发者ID:byslee3,项目名称:oop_lesson,代码行数:10,代码来源:game.py

示例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
开发者ID:coderkat,项目名称:oop_lesson,代码行数:10,代码来源:game.py

示例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,
             }
开发者ID:coderkat,项目名称:zelda_game,代码行数:6,代码来源:game_backup.py

示例8: __init__

 def __init__(self, player):
     GameElement.__init__(self)
     self.inventory = []
     self.IMAGE = player
开发者ID:ingridavendano,项目名称:oop_lesson,代码行数:4,代码来源:game.py

示例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
开发者ID:RunnerMom,项目名称:oop_lesson,代码行数:3,代码来源:game.py

示例10: __init__

 def __init__(self):
     GameElement.__init__(self)
     self.inventory = []
     self.ridinglist = []
     self.popoexists = False
开发者ID:amitch23,项目名称:oop,代码行数:5,代码来源:game.py

示例11: __init__

	def __init__(self):
		GameElement.__init__(self)
		self.last_move = 0
		self.velocity_x = 1
开发者ID:chrismeono1022,项目名称:oop_game,代码行数:4,代码来源:game.py

示例12: __init__

 def __init__(self):
     GameElement.__init__(self)
     self.inventory_gems = []
     self.inventory_hearts = []
开发者ID:bexcitement,项目名称:Oop_Exercise,代码行数:4,代码来源:game.py

示例13: __init__

 def __init__(self):
     GameElement.__init__(self)
     self.IMAGE = random.choice(self.imagelist)
     self.SOLID = False
开发者ID:blythest,项目名称:oop_lesson,代码行数:4,代码来源:game.py

示例14: __init__

 def __init__(self):
     GameElement.__init__(self)
     self.inventory = []
     self.key_list = []
开发者ID:fcoggins,项目名称:ObjectOrientedProg,代码行数:4,代码来源:game.py

示例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)
开发者ID:mxcapo,项目名称:hb_oop,代码行数:6,代码来源:game.py


注:本文中的core.GameElement类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。