> Hmm. OK, perhaps there's a different approach that might be taken. I'm  
> just a little put off by the __init__ / super() yuckiness.

Perhaps there could be a combination of approaches. Since most things
won't need that customized behavior, they could use your solution to
initialize their GameObjects. Since behaviors can be added at any
time, they could just add it outside of __init__. Maybe I could also
add an extra_behaviors dict to GameObject's constructor.

That introduces another problem, though: behaviors need to have
references to their targets. I could probably deal with that by
delaying behavior initialization if target == None or something.

> How much other customisation would you expect on the Player class? Is  
> the customisation just supplying information to the GameObject class  
> (as arguments or filling out GameObject attributes?) What other sorts  
> of GameObjects can you see there being?

Frankly, I'm not sure. This started as a simple refactoring of an
existing game and is slowly turning into a more generalized, more
useful chunk of code. I probably won't know the answer to this
question until I start writing a game using the framework.

Since my short-term goal is to have a base for collaboration on a team
I'll be working with in the near future, my focus for the next couple
of months will be on things I will need for that project. Hence, there
is now a "Hex Map Demo" button on the title screen which shows - you
guessed it - a hex map. The code is extremely simplistic for now, but
I will expand it into a reasonably usable tile engine. I won't do use
fancy OpenGL tricks, but it should fine work for medium-to-small maps.

> Consider also that there's Rabbyt which also provides some animation  
> framework elements, but uses a different API approach to Cocos2d.  
> Probably worth looking at.

I definitely will at some point. I also plan to integrate Chipmunk
Physics, or Box2D if pymunk continues to be less than spectacular.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"pyglet-users" 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/pyglet-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to