示例#1
0
 def attack(self, target):
     self.validify()
     if not isinstance(target, Unit):
         raise TypeError('target should be of [Unit]')
     target.validify()
     return library.botAttack(self.ptr, target.ptr)
示例#2
0
 def attack(self, target):
   self.validify()
   if not isinstance(target, Unit):
     raise TypeError('target should be of [Unit]')
   target.validify()
   return library.botAttack(self.ptr, target.ptr)
示例#3
0
 def attack(self, target):
   self.validify()
   if target.__class__ not in [Unit]:
     raise TypeError('target should be of [Unit]')
   target.validify()
   return library.botAttack(self.ptr, target.ptr)