Cocos2D-Mac Team!

Forums Programming cocos2d internals Cocos2D-Mac Team!

This topic contains 65 replies, has 22 voices, and was last updated by  finder39 2 years, 8 months ago.

Viewing 25 posts - 1 through 25 (of 66 total)
Author Posts
Author Posts
March 13, 2010 at 7:06 pm #220379

Connor
Participant
@techy

I have talked to riq, and now we are going to work on cocos2d specifically for mac… We are looking for a team… Right now we need some one who is good at going from opengl es to opengl… Post here if you are interested.

March 13, 2010 at 8:35 pm #276462

riq
Keymaster
@admin

Please, see the previous post where I mentioned how to approach this feature. cocos2d for Mac should not be a different project, but a feature of “cocos2d – objc”.

Initially it could be a branch just for the sake of not breaking things, but then it should be part of the main trunk.

From your post people might think that I will work specifically on the Mac port. I’m not. I’ll continue to work on v0.99 until v1.0 is released. And as I mentioned in previous posts, these 3 features are very important, and will be included post v1.0:

- OpenGL ES 2.0

- Mac support

- NSCoding support

March 13, 2010 at 11:17 pm #276463

Connor
Participant
@techy

@riq One thing about mac and iphone is that each library would have to be different.. iphone and mac may seem very similar, but in a lot of ways they are different… The iphone has UIKit and mac doesn’t… So UILabels UIColor ect… dont work on mac… instead it uses cocoa… Those two are pretty different… Also iphone has opengl es and mac uses opengl… So there are two ways of accomplishing a version for mac: getting rid of all the errors you get from compiling cocos2d-iphone on a mac and port everything or start from scratch and build it with the same structure…

March 14, 2010 at 12:11 am #276464

riq
Keymaster
@admin

@Techy: yes, I know that. Again, in a previous post I mentioned one way to address it. It might be difficult to find it (the “search” doesn’t work very well), but, really, it is not that difficult to support Mac and iPhone with the same source code.

95% of the code is reusable, the Mac port should be a feature of cocos2d, not a different project. Again, the research could be started in a branch, like @Rolando did when he started the Mac support a few months ago. @Rolando has some ideas about this project too.

If you see the Roadmap ( http://www.cocos2d-iphone.org/wiki/doku.php/roadmap ), Mac support is planned after v1.0.

[UPDATE]:

I appreciate your initiative, and I we don’t have to agree. But in this particular feature, since I want it to be part of cocos2d-iphone, I would appreciate if you think of a way of supporting both Mac and iPhone with the same source code.

March 14, 2010 at 12:14 am #276465

Connor
Participant
@techy

One thing is you could include both the mac and iphone library in the download with cocos2d-iphone

August 17, 2010 at 7:15 pm #276466

rolando
Moderator
@rolando

Sorry to bring this thread (I’m a little late in the discussion).

I might start working again on the Mac port of cocos2d… any update? has anyone been working on this?

August 17, 2010 at 8:35 pm #276467

riq
Keymaster
@admin

@rolando: Hey, this week I started working on this project :-) The 1st thing that I did was to download the OpenGL Mac Programming Guide, I downloaded a few samples, studied their source code, and nothing more for the moment… but this is MUST HAVE feature.

August 17, 2010 at 8:43 pm #276468

abitofcode
Moderator
@abitofcode

The day just got a little shinier :D

August 18, 2010 at 2:36 pm #276469

riq
Keymaster
@admin

This is just an experiment…

  • CCTexture2D ported to Mac: %60
  • EAGLView ported to Mac: %85
  • The rest of the objects: 0%

This is not going to be easy / quick, but it is an interesting experiment.

August 18, 2010 at 4:13 pm #276470

GameBit
@gamebit

nice!

August 18, 2010 at 4:20 pm #276471

asinesio
Participant
@asinesio

Sweet!

August 18, 2010 at 6:22 pm #276472

noocell
@noocell

Let me express a negative feeling about this Cocos2d for Mac project…

Cocos2d iPhone is now a mature engine (I’ve been a lurker grom the google group era). With the new TOS and the section about obj-c, Cocos2d has a huge advantage among other libraries/platforms. The potential of Cocos2d is now extraordinary.

At the same time, iOS and generally the concept of abstracted OSs is becoming clearly the future. iOS devices are even today the bigger money maker for Apple! There are already repeating rumors (call me “demand”) for an iOS based mac.This non-technical nature of operating systems is something unavoidable as the customer base is being extended to the whole population. Apple is already a leader to this OS transformation.

Having these in mind, getting a very promising one-man-show (Cocos2d iPhone) to become a half-man-show in favor of a platform that belongs to the past, is going to be proved a mistake in my opinion.

Instead, this is the best time for:

1) Some marketing! Cocos2d for iPhone should now have made real $$ for its developer and a strong team should have been built around it. Even as a free product, there are many ways to generate serious income towards a “team/company” goal. This would be for the best interest of the whole community!

2) New “Cocos for iOS” stuff. For example: a) an in-app purchases api + server. b) a 3d models importer and other 3d helper classes. c) extensive official documentation, which is something that would strongly accelerate the library adoption.

August 18, 2010 at 6:58 pm #276473

mobilebros
Moderator
@mobilebros

Wow very exciting!

@noocell – You get to a certain point in the development and it wouldn’t be like 50/50 time spent in both, you’d be pretty much writing code against the same base with [hopefully] minor tweaks to either side; I don’t think MacOS is going away anytime soon.

August 18, 2010 at 7:21 pm #276474

cybergreg
Participant
@cybergreg

@noocell – you make some excellent points especially about the direction Apple is headed. However, whenever we talk about supporting @riq I have noticed there seem to be two common issues:

1. Cocos2d users (developers) do not have any (extra) money to donate, regardless of the amount. Which is sad because even $10.00 would help.

2. Many users have asked for lower cost projects and/or documentation

So perhaps it would be better if @riq spent time on a second project he could sell (instead of Cocos2d-Mac). Maybe a side-scroller using OpenFeint. Heck I’d pay for that.

Anyhow, sorry I don’t mean to derail this thread, just @noocell, you’ve brought up some very valid points.

Cg

Edit: Let me add the question “Will this increase income for Riq”? If the answer is YES, go for it. If NO, well there you go. :-)

August 18, 2010 at 7:32 pm #276475

riq
Keymaster
@admin

@noocell: Thanks for the feedback.

They way I see it is that having cocos2d ported to mac is a very useful feature for cocos2d-iphone users:

- You’ll be able to develop games more quickly. The startup time is faster than the simulator.

- You’ll be able distribute your games for Mac. Think of “promo” games.

- I’ll be able to develop the “cocos2d world editor” :), which would be, IMHO, a killer feature.

August 18, 2010 at 7:36 pm #276476

chrisco
Participant
@chrisco

The cocos2d world editor would definitely be awesome :) But how would testing work in regards to multi-touch events? That is, would you have some sort of translation layer, or would you need to write specific “mouseDown”/”mouseUp” sort of functions just to be able to test it? If that were the case, then I think that would actually slow development quite a bit.

August 18, 2010 at 7:48 pm #276477

riq
Keymaster
@admin

@chrisco: you won’t be able to receive multitouch events, but you’ll be able to receive mouse and keyboard events. So you won’t be able to test/develop the multitouch part on the mac version.

August 18, 2010 at 7:54 pm #276478

chrisco
Participant
@chrisco

That’s understandable, but when you mention that you could test your app outside of the simulator, would we have to write specific code to emulate single-touch handling with the mouse?

For example, if I was working on a game for the iPhone, and I had some code to handle a single touch on a sprite, I’d be using ccTouchBegan… So if I wanted to test this outside of the simulator, would I also have to have code like ccMouseDown…?

I realize that you’re not that far into it yet, so don’t let me overcomplicate things ;)

August 18, 2010 at 8:16 pm #276479

mobilebros
Moderator
@mobilebros

@chrisco – Just guessing, but wouldn’t mousedown be equivalent as ccTouchBegan… and (mousedown/moving) the same as ccTouchMoved and mouseup the same as ccTouchEnded? so there wouldn’t be a need to differentiate… idk. If anything you’d have to worry about “extra” other events like mousehover, etc.

August 18, 2010 at 8:22 pm #276480

riq
Keymaster
@admin

Let me dream a little bit… if the mac port works OK and if I’m able to develop a good world cocos2d editor, and if the cocotron projects works as expected then your designer will be able to create a cocos2d level on a windows machine, and you’ll be able to test it on your iPhone.

August 18, 2010 at 8:28 pm #276481

abitofcode
Moderator
@abitofcode

How far back is the support for the Mac platform going to go? ;)

August 18, 2010 at 8:30 pm #276482

chrisco
Participant
@chrisco

@mobilebros – You’re right, they would be equivalent in terms of functionality, but I can’t imagine they’d have an identical API. I think in terms of developing games as either a Mac game or an iPhone game, the engine would be great. I just have a hard time understanding the benefits of building a Mac version of an iPhone game to avoid using the simulator for testing.

The simulator provides a translation layer that takes mouse events and passes them to your app as UITouch events, whereas a game compiled as a Mac version would only send mouse events. If you didn’t add code to your iPhone game to handle these mouse events, it would be very difficult to test.

And since a ccTouchBegan event wouldn’t make sense on the Mac in the same way that a ccMouseDown event wouldn’t make sense in an iPhone game, I don’t see how the two could share an API for interaction.

Maybe I’m just completely misunderstanding things…

August 18, 2010 at 8:36 pm #276483

noocell
@noocell

@riq – I very much like the way you see this Cocos for Mac project, as you further explaining it as an accessory platform and testbed for iOS development.

When that time will eventually come, plz plz plz charge something serious for it (the Zwoptex style ^10) … :)

As @cybergreg says “Will this increase income for Riq”? If the answer is YES, go for it.”

August 18, 2010 at 8:36 pm #276484

abitofcode
Moderator
@abitofcode

You could always create a multitouch server for the iPad/iPhone and have the Mac client connect to it during testing. I’m playing with something similar at the moment to use an iPad/iPhone to deliver touch events to flash.

Its suffering a bit from lag at the moment (TCP over wifi) but I’m pretty sure it’s down to the implementation rather than the idea.

August 18, 2010 at 9:14 pm #276485

roli
@roli

I am realy nteresting in something like this. I was making a multitouch table almost a year ago and this would be realy helpful back then. And because of the ease of use you could make a good multiouch application/game realy fast. So I would port the game library to the mac and implement the multitouch feature with tbeta (CCV): http://ccv.nuigroup.com/

Viewing 25 posts - 1 through 25 (of 66 total)

You must be logged in to reply to this topic.