comparison pytouhou/vm/eclrunner.py @ 152:86807b8a63bd

Add collisions with enemies and items.
author Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
date Sun, 09 Oct 2011 15:32:43 -0700
parents 5cf927cbd9c5
children 364935f6e313
comparison
equal deleted inserted replaced
151:5cf927cbd9c5 152:86807b8a63bd
697 697
698 698
699 @instruction(103) 699 @instruction(103)
700 def set_hitbox(self, width, height, depth): 700 def set_hitbox(self, width, height, depth):
701 self._enemy.hitbox = (width, height) 701 self._enemy.hitbox = (width, height)
702 self._enemy.hitbox_half_size = (width / 2., height / 2.)
702 703
703 704
704 @instruction(104) 705 @instruction(104)
705 def set_collidable(self, collidable): 706 def set_collidable(self, collidable):
706 """Defines whether the enemy is “collidable”. 707 """Defines whether the enemy is “collidable”.