As I move forward with the Sprite “Aliasing” updates I want to make sure that users can use these features as soon as they are ready in Zwoptex especially without having to manually patch cocos2d.

Since I’ve already implemented aliasing in some ways and have an idea on how the .plist will look I’m going to go ahead and patch support for it into cocos2d now and then it should be good to go as soon as Zwoptex is complete.

Aliasing will be simply in that each sprite frame in the .plist will have an array of “Aliases”. Loading the .plist you should first add all the normal sprites and then go back and add alias’s that have not already been created. This will prevent overwriting a real sprite with an alias.

The cocos2d implementation will work exactly like above. It’ll first add a CCSpriteFrame for each real sprite  in the .plist and then add a CCSpriteFrame for each alias that doesn’t already exist. If it does exists cocos2d will log a warning but not an exception.

The alias’d CCSpriteFrame will basically be a direct copy of the CCSpriteFrame it is aliasing but accessible via the alias name.

Hopefully this will alleviate some of the issues people have had with 1.0.0 and the rotational support when sprite aliasing comes out.

-Robert

 

Leave a Reply

Your email address will not be published. Required fields are marked *

*

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong> <pre lang="" line="" escaped="">