Bruno Assarisse Posted September 25, 2013 Share Posted September 25, 2013 Hey, guys! This is my first post here, and that is because I will start porting a code I started on cocos2d-html5 to Phaser. Basically, I'm not happy with the performance and I will try rewriting it so see how it turns out on this lib =) Here's what I built so far, pretty simple: http://bassarisse.com/webgames/platformer-test/ Firstly, I would like to know if anybody has some tips to learn the API easily (or any other tips that could help on this transition). Like, cocos2d-html5 don't have a good docs, but as I have read the docs from (and used) cocos2d-iphone, and the API is almost the same, I started coding without problem. If I go and read the Flixel API, would it help for me to know my way around Phaser? Well, I'm currently messing with the examples to get me started, good thing there's a lot of them =) Secondly, my main question: does Phaser supports sprite sheets generated by Zwoptex? I saw this template to export to JSON, but I'm not sure if it works.https://gist.github.com/darktable/1444795 Thanks in advance! Link to comment Share on other sites More sharing options...
rich Posted September 25, 2013 Share Posted September 25, 2013 Hi, The docs are coming really soon! We've nearly finished marking up the entire library. I fully expect we should be able to release them all next week. We are also producing as many new examples as we can, as I think you need both really. API docs will be great, but they don't show you how it should all glue together. The examples will. Zwoptex exports to JSON, so as long as it follows the Texture Packer way of handling things it should be fine. Try it and see - if it doesn't send me a PNG and JSON file that Zwoptex outputs and I'll look at supporting it. I'm sure it won't take long to add to the parser. Link to comment Share on other sites More sharing options...
Bruno Assarisse Posted September 25, 2013 Author Share Posted September 25, 2013 My Zwoptex doesn't contains a default JSON template =/Maybe I should try reinstalling it. I'll try as soon as I get home. Thanks! Link to comment Share on other sites More sharing options...
tyson Posted September 25, 2013 Share Posted September 25, 2013 Apparently the Cocos2d-html5 team are concentrating on mobile performance more in the next update. To be honest the perfomance on my games in Cocos2d-html5 seem OK. At least 30fps on iOS, 15-20 or so on Android.Maybe the tile engine isn't so optimized? Link to comment Share on other sites More sharing options...
Bruno Assarisse Posted September 25, 2013 Author Share Posted September 25, 2013 Yeah, I saw yesterday the new version, going to test today. But I'll port the code to Phaser anyway, so I can compare and see which is faster using the same graphics and everything. Link to comment Share on other sites More sharing options...
Bruno Assarisse Posted September 26, 2013 Author Share Posted September 26, 2013 Zwoptex does not exports to JSON out-of-the-box and I couldn't find a template that worked on Phaser, so I created a new one based on the one I linked before.Here's the code if anybody need it:https://gist.github.com/bassarisse/6709659Also, the new version of cocos2d-html5 really improved the performance on iOS: http://bassarisse.com/webgames/platformer-test2/ Link to comment Share on other sites More sharing options...
rich Posted September 26, 2013 Share Posted September 26, 2013 Nice - mind if we include this in the main repo? Link to comment Share on other sites More sharing options...
Bruno Assarisse Posted September 26, 2013 Author Share Posted September 26, 2013 Not at all Link to comment Share on other sites More sharing options...
Recommended Posts