(not enough caffeine this morning). Sorry, the last was a mix between yor
aproach and one using childs. This really works, tested)


class PlayerBox(Sprite):
   # standart sprite
  ...

class BoxBlur(ParticleSystem):
     def __init__(self, playerbox)
          super(ParticleSisytem,self).__init__()
          playerbox.rotation = 180
          playerbox.position = 0 # offset from boxblur to playerbox; child
position                                                # are relative to
parent
          self.add(playerbox)

def update(self,dt):
     # CocosNode machinery will show playerbox at offset playerbox.position
from      # BoxBlur position
     # if you update self.position and dont mess with playerbox.position
     # then the playerbox image will follow the particles view
     pass

layer = Layer()
playerbox = PlayerBox()
boxblur = BoxBlur(playerbox)
# layer.add(playerbox) --> playerbox is included into boxblur
layer.add(boxblur)
--
claudio

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"cocos2d discuss" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/cocos-discuss?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to