Composer and scene what's for?

Hello everyone,

I never used composer for my apps and I don’t really see the advantages of using them.

What do they really bring, are they only special property for groups?

I understood how to use them with the doc ( https://docs.coronalabs.com/api/library/composer/index.html )

but it didn’t convince me to use them.

Composer provides an easy way to separate and manage the tasks of creating, updating, showing, hiding, and eventually destroying game interfaces / scenes. 

That’s it.

If you don’t need it, don’t use it.  However, folks generally don’t want to code their own scene management and tweening code, so you’ll see a lot of folks using it.

Personally, I believe users should not use it till they know how to make their own game modules and have experimented making their own scene management code.

I all too often seen new Corona users jump into using composer.* like it is a requirement.  That, added to their ignorance of: Lua, Corona in general, scope and visiblity, … adds up to mistake after mistake and some terribly written game code.

Better IMHO if they had stayed with just config.lua, build.settings, and main.lua, then worked up from there.

Note: My answer is blunt, but should not be taken as angry, insulting, or otherwise.  I’m trying, recently, to modify the way I answer posts to make them more even and matter-of-fact in tone . 

I may be failing. :slight_smile:

@roaminggamer, what you say has a lot of truth to it. It takes time to learn scope and how Corona events work and asking people to imagine event phases when first getting started is asking a lot. 

I kinda miss the days where there were community developed scene management options. Of course I would encourage to use Composer because it’s supported, but the old Director class worked really well. But even when I was first starting, it took me 2-3 apps before I understood what Director did. 

It’s one reason our Getting Started guide spends several chapters only working in main.lua before we even introduce Composer. As I think about it, learning modules probably should be learned before jumping into Composer.  Had I learned modules, my first came wouldn’t have been a multi-thousand line main.lua :slight_smile:

Rob

@Rob - I agree with everything you say. 

However, I  want to mention that, no matter how carefully we try to direct new users, and no matter how much time we spend setting up a nice, easy, meaningful sequence for them to follow…

In my experience and observation the majority of new users rush pell-mell into development and skip over all the early bits.  They also don’t pause enough to learn, but switch from idea to idea like distracted cats.

I don’t blame them either.  I was the same way as a new programmer and game maker.  

The big difference is, when I did this and failed, I only had myself to work it out. 

Today, new users skip the ‘learning path’ and then when they fail…expect experienced folks to explain it all in easy bite-sized and customized responses. 

It drives me crazy. 

Still… I understand why they do it, so I have to remind myself regularly it is the natural way for new folks to operate.  :slight_smile:

Most of these problems would go away if Corona had an IDE (that created scene code in the background).  

With no IDE or visual flow editor, new users will stumble blindly…

Can’t really blame new users when all they are faced with is a blank notepad/text wrangler/sublime code window!

Tell you what.   You fund it, I’ll code it. :}

Composer provides an easy way to separate and manage the tasks of creating, updating, showing, hiding, and eventually destroying game interfaces / scenes. 

That’s it.

If you don’t need it, don’t use it.  However, folks generally don’t want to code their own scene management and tweening code, so you’ll see a lot of folks using it.

Personally, I believe users should not use it till they know how to make their own game modules and have experimented making their own scene management code.

I all too often seen new Corona users jump into using composer.* like it is a requirement.  That, added to their ignorance of: Lua, Corona in general, scope and visiblity, … adds up to mistake after mistake and some terribly written game code.

Better IMHO if they had stayed with just config.lua, build.settings, and main.lua, then worked up from there.

Note: My answer is blunt, but should not be taken as angry, insulting, or otherwise.  I’m trying, recently, to modify the way I answer posts to make them more even and matter-of-fact in tone . 

I may be failing. :slight_smile:

@roaminggamer, what you say has a lot of truth to it. It takes time to learn scope and how Corona events work and asking people to imagine event phases when first getting started is asking a lot. 

I kinda miss the days where there were community developed scene management options. Of course I would encourage to use Composer because it’s supported, but the old Director class worked really well. But even when I was first starting, it took me 2-3 apps before I understood what Director did. 

It’s one reason our Getting Started guide spends several chapters only working in main.lua before we even introduce Composer. As I think about it, learning modules probably should be learned before jumping into Composer.  Had I learned modules, my first came wouldn’t have been a multi-thousand line main.lua :slight_smile:

Rob

@Rob - I agree with everything you say. 

However, I  want to mention that, no matter how carefully we try to direct new users, and no matter how much time we spend setting up a nice, easy, meaningful sequence for them to follow…

In my experience and observation the majority of new users rush pell-mell into development and skip over all the early bits.  They also don’t pause enough to learn, but switch from idea to idea like distracted cats.

I don’t blame them either.  I was the same way as a new programmer and game maker.  

The big difference is, when I did this and failed, I only had myself to work it out. 

Today, new users skip the ‘learning path’ and then when they fail…expect experienced folks to explain it all in easy bite-sized and customized responses. 

It drives me crazy. 

Still… I understand why they do it, so I have to remind myself regularly it is the natural way for new folks to operate.  :slight_smile:

Most of these problems would go away if Corona had an IDE (that created scene code in the background).  

With no IDE or visual flow editor, new users will stumble blindly…

Can’t really blame new users when all they are faced with is a blank notepad/text wrangler/sublime code window!

Tell you what.   You fund it, I’ll code it. :}