Example #1
0
	def onDestroy(self):
		"""
		KBEngine method.
		entity销毁
		"""
		DEBUG_MSG("Avatar::onDestroy: %i." % self.id)
		Teleport.onDestroy(self)
Example #2
0
	def __init__(self):
		GameObject.__init__(self) 
		Flags.__init__(self) 
		State.__init__(self) 
		Combat.__init__(self) 
		Spell.__init__(self) 
		Teleport.__init__(self) 
		Dialog.__init__(self) 
	def onEntitiesEnabled(self):
		"""
		KBEngine method.
		该entity被正式激活为可使用, 此时entity已经建立了client对应实体, 可以在此创建它的
		cell部分。
		"""
		INFO_MSG("[Base App] Avatar[%i-%s] entities enable. spaceUTypeB=%s, mailbox:%s" % (self.id, self.nameB, self.spaceUTypeB, self.client))
		Teleport.onEntitiesEnabled(self)
Example #4
0
	def __init__(self):
		KBEngine.Entity.__init__(self)
		GameObject.__init__(self)
		Flags.__init__(self) 
		State.__init__(self) 
		SkillBox.__init__(self) 
		Combat.__init__(self) 
		Spell.__init__(self) 
		Dialog.__init__(self)
		Teleport.__init__(self)
Example #5
0
	def __init__(self):
		KBEngine.Proxy.__init__(self)
		GameObject.__init__(self)
		Teleport.__init__(self)
		
		self.accountEntity = None
		self.cellData["dbid"] = self.databaseID
		self.nameB = self.cellData["name"]
		self.spaceUTypeB = self.cellData["spaceUType"]
		self.inventory = InventoryMgr(self)
Example #6
0
    def __init__(self):
        KBEngine.Proxy.__init__(self)
        GameObject.__init__(self)
        Teleport.__init__(self)

        self.accountEntity = None
        self.cellData["dbid"] = self.databaseID
        self.nameB = self.cellData["name"]
        self.spaceUTypeB = self.cellData["spaceUType"]

        self._destroyTimer = 0
Example #7
0
 def __init__(self):
     KBEngine.Entity.__init__(self)
     GameObject.__init__(self)
     Flags.__init__(self)
     State.__init__(self)
     SkillBox.__init__(self)
     Combat.__init__(self)
     Spell.__init__(self)
     Dialog.__init__(self)
     Motion.__init__(self)
     Teleport.__init__(self)
Example #8
0
    def onClientEnabled(self):
        """
        KBEngine method.
        该entity被正式激活为可使用, 此时entity已经建立了client对应实体, 可以在此创建它的
        cell部分。
        """
        #INFO_MSG("Avatar[%i-%s] entities enable. spaceUTypeB=%s, entityCall:%s" % (self.id, self.nameB, self.spaceUTypeB, self.client))
        Teleport.onClientEnabled(self)

        if self._destroyTimer > 0:
            self.delTimer(self._destroyTimer)
            self._destroyTimer = 0
Example #9
0
    def __init__(self):
        GameObject.__init__(self)
        Flags.__init__(self)
        State.__init__(self)
        Motion.__init__(self)
        Combat.__init__(self)
        Spell.__init__(self)
        Teleport.__init__(self)
        Dialog.__init__(self)

        # 设置每秒允许的最快速度, 超速会被拉回去
        self.topSpeed = 10.0
Example #10
0
	def __init__(self):
		GameObject.__init__(self) 
		Flags.__init__(self) 
		State.__init__(self) 
		Motion.__init__(self) 
		Combat.__init__(self) 
		Spell.__init__(self) 
		Teleport.__init__(self) 
		Dialog.__init__(self) 
		
		# 设置每秒允许的最快速度, 超速会被拉回去
		self.topSpeed = 10.0
Example #11
0
	def __init__(self):
		KBEngine.Entity.__init__(self)
		GameObject.__init__(self) 
		Flags.__init__(self) 
		State.__init__(self) 
		Motion.__init__(self) 
		SkillBox.__init__(self) 
		Combat.__init__(self) 
		Spell.__init__(self) 
		Teleport.__init__(self) 
		Dialog.__init__(self) 
		
		# 设置每秒允许的最快速度, 超速会被拉回去
		self.topSpeed = self.moveSpeed + 5.0
Example #12
0
    def __init__(self):
        KBEngine.Entity.__init__(self)
        GameObject.__init__(self)
        Flags.__init__(self)
        State.__init__(self)
        Motion.__init__(self)
        SkillBox.__init__(self)
        Combat.__init__(self)
        Spell.__init__(self)
        Teleport.__init__(self)
        Dialog.__init__(self)

        # 设置每秒允许的最快速度, 超速会被拉回去
        self.topSpeed = self.moveSpeed + 5.0
Example #13
0
    def onClientEnabled(self):
        """
		Ouroboros method.
		The entity is officially activated to be usable.
		At this point, the entity has established the client corresponding entity,
		and its cell part can be created here.
		"""
        INFO_MSG(
            "Avatar[%i-%s] entities enable. spaceUTypeB=%s, entityCall:%s" %
            (self.id, self.playerName, self.spaceUTypeB, self.client))

        Teleport.onClientEnabled(self)

        if self._destroyTimer > 0:
            self.delTimer(self._destroyTimer)
            self._destroyTimer = 0
Example #14
0
	def __init__(self):
		shyloo.Entity.__init__(self)
		GameObject.__init__(self) 
		Flags.__init__(self) 
		State.__init__(self) 
		Motion.__init__(self) 
		SkillBox.__init__(self) 
		Combat.__init__(self) 
		Spell.__init__(self) 
		Teleport.__init__(self) 
		Dialog.__init__(self) 
		
		# 设置每秒允许的最快速度, 超速会被拉回去
		self.topSpeed = self.moveSpeed + 5.0
		# self.topSpeedY = 10.0
		
		# 如果为7说明在UE4地图中,那么为了配合demo的移动速度,我们将限制设置得更大一些
		if self.spaceUType == 7:
			self.topSpeed = 0
Example #15
0
	def __init__(self):
		KBEngine.Entity.__init__(self)
		GameObject.__init__(self) 
		Flags.__init__(self) 
		State.__init__(self) 
		Motion.__init__(self) 
		SkillBox.__init__(self) 
		Combat.__init__(self) 
		Spell.__init__(self) 
		Teleport.__init__(self) 
		Dialog.__init__(self) 
		
		# 设置每秒允许的最快速度, 超速会被拉回去
		self.topSpeed = self.moveSpeed + 5.0
		# self.topSpeedY = 10.0
		
		if self.spaceUType == 1000:
			self.spaceUType = self.getCurrSpace().spaceUType
			self.topSpeed = 0
Example #16
0
	def __init__(self):
		KBEngine.Proxy.__init__(self)
		GameObject.__init__(self)
		Teleport.__init__(self)

		# 如果登录是一个副本, 无论如何登录都放置在主场景上
		spacedatas = d_spaces.datas [self.cellData["spaceUType"]]
		avatar_inittab = d_avatar_inittab.datas[self.roleType]

		if "Duplicate" in spacedatas["entityType"]:
			self.cellData["spaceUType"] = avatar_inittab["spaceUType"]
			self.cellData["direction"] = (0, 0, avatar_inittab["spawnYaw"])
			self.cellData["position"] = avatar_inittab["spawnPos"]
		
		self.accountEntity = None
		self.cellData["dbid"] = self.databaseID
		self.nameB = self.cellData["name"]
		self.spaceUTypeB = self.cellData["spaceUType"]
		
		self._destroyTimer = 0
Example #17
0
    def __init__(self):
        KBEngine.Proxy.__init__(self)
        GameObject.__init__(self)
        Teleport.__init__(self)

        # 如果登录是一个副本, 无论如何登录都放置在主场景上
        spacedatas = d_spaces.datas[self.cellData["spaceUType"]]
        avatar_inittab = d_avatar_inittab.datas[self.roleType]

        if "Duplicate" in spacedatas["entityType"]:
            self.cellData["spaceUType"] = avatar_inittab["spaceUType"]
            self.cellData["direction"] = (0, 0, avatar_inittab["spawnYaw"])
            self.cellData["position"] = avatar_inittab["spawnPos"]

        self.accountEntity = None
        self.cellData["dbid"] = self.databaseID
        self.nameB = self.cellData["name"]
        self.spaceUTypeB = self.cellData["spaceUType"]

        self._destroyTimer = 0
Example #18
0
    def __init__(self):
        Ouroboros.Entity.__init__(self)
        GameObject.__init__(self)
        State.__init__(self)
        AnimationState.__init__(self)
        Motion.__init__(self)
        AbilityBox.__init__(self)
        AuraBox.__init__(self)
        Ability.__init__(self)
        Teleport.__init__(self)
        Combat.__init__(self)
        Auxiliary.__init__(self)
        # Dialog.__init__(self)

        # Set the fastest speed allowed per second, the speed will be pulled back
        self.topSpeed = self.moveSpeed + 15.0
        # self.topSpeedY = 10.0

        self.setDefaultData()
        self.resetProperties()
        self.updateBaseProperties()
        self.resetEntity()
        self.onEnable()