Director 1.5 - What do you want?

Hello everyone!

After a hard work on Director 1.4 adding the books feature, it’s time to think about bugs, issues and other features on Director Class. I know there are many things to do but I want your help to do it right. What I need? Simple, tell me what you want on the next version of Director.

Here are some things on my roadmap:

  • Better sample
  • Send parameters on closePopUp
  • Remove module()
  • New flow:
    1 - insert missing objects into old scene
    2 - load new scene
    3 - insert missing objects into new scene
    4 - transition
    5 - old scene clean()
    6 - remove old scene
    7 - new scene initVars()
  • New effects on goToPage (books)
  • String target on goToPage
  • Bug fix on turnToScenes

So, what do you want? [import]uid: 8556 topic_id: 15701 reply_id: 315701[/import]

First of all great work with the director framework :slight_smile:

I like to see a sample that matches the new director.
The new flow seems really good and makes sense to me.
[import]uid: 73836 topic_id: 15701 reply_id: 57967[/import]

I think mine is simple.

I’d like the ability to load an interstitial screen without loosing the screen I was on.

For example;

That way I could show a screen like a help screen or an inventory but return to the game screen leaving it in the same state it was when I departed.

If it can do this now, I’d love to know how. It would seem to me to be the single biggest feature needed.

Thanks
Rob
[import]uid: 19626 topic_id: 15701 reply_id: 57971[/import]

claes.lindblom

Thanks, I’m planning a new sample using all the features from Director.

robmiracle

What about the pop up? It is shown above the current scene. [import]uid: 8556 topic_id: 15701 reply_id: 57978[/import]

Not to sound ignorant (because I am with this subject) is there an example somewhere for a popup? [import]uid: 19626 topic_id: 15701 reply_id: 57984[/import]

On your list, “Remove module()” is the one for me…

And might be on the edge but what about a page turn fx :slight_smile: [import]uid: 10478 topic_id: 15701 reply_id: 57986[/import]

robmiracle

Download the 1.4 version and take a look on the green pop up button, it’s very simple to use it.

PixelEnvision

Page turn fx is hard to do and need some special features like the “2.5d image transform” feature of the Ansca roadmap. [import]uid: 8556 topic_id: 15701 reply_id: 57991[/import]

Sweet!!! [import]uid: 19626 topic_id: 15701 reply_id: 58003[/import]

1.4 was such a great release.

+1 on remove module

and, even though you need Ansa to add 2.5d transforms…
+1 on page turn animation (flipboard style) [import]uid: 60707 topic_id: 15701 reply_id: 58022[/import]

Hello!

  1. What about an easy - fast way to reload the screen
  2. A change screen function with loading screen option
  3. For sure, passing parameters with closePopUp
  4. Clean function

Thank you for this great tool! [import]uid: 38658 topic_id: 15701 reply_id: 58031[/import]

Thank you for this awesome class, Ricardo.

I’m not sure if anyone has seen this, but there’s one thing that’s been bothering me. I like using flip and it looks great on iPhone, but when I run it on iPad, I see a straight vertical line across the center of the screen splitting the image for a second as the scene changes. I don’t see this on iPhone. FYI, my game is configured for 320x480 with letterbox scaling.

Could it be possible to hide/remove this hairline split somehow? [import]uid: 67217 topic_id: 15701 reply_id: 58036[/import]

photiscta

1 - You can easy reload your scene with changeScene, just call it the same!

-- game.lua  
...  
local params = {  
 level = 2,  
 lifes = 3  
}  
director:changeScene( params, "game", "fade" )  
...  

2 - What kind of loading are you talking about? Like the one of ZeptoLab on Cut The Rope or just the standard animated circle?

4 - Clean function is working for the localGroup, just use like this:

... localGroup.clean = function() spritesheet:dispose() end ... [import]uid: 8556 topic_id: 15701 reply_id: 58038[/import]

ask

That’s strange but I will take a look, maybe just an isVisible = false would work. [import]uid: 8556 topic_id: 15701 reply_id: 58041[/import]

Ricardo, thank you so much for looking into this.

I’m not sure where I am to set isVisible = false.

The “image” that shows the hairline split in the center is the entire scene (the old scene to be changed to new scene). When I’m changing darker scene to lighter scene, I see pale line, and when I change lighter scene to darker scene, I see dark line. When I’m changing between dark scene to dark scene, I see the dark line (a bit jagged, or dotted with lighter color, maybe because the scene consists of varying degree of dark colors). [import]uid: 67217 topic_id: 15701 reply_id: 58043[/import]

Ricardo,

the Clean function for the localGroup, does not clears the Runtime eventListener.
I am using Runtime:removeEventListener(“enterFrame”,goBack) inside Clean with no luck.
But, if I put the Runtime:removeEventListener(“enterFrame”,goBack) inside the goBack() it works.

local function goBack(event) timer.performWithDelay( 3000, function() director:changeScene( "screen1") end) Runtime:removeEventListener("enterFrame",goBack) end

As for loading screen, the best is to have full feature screen (transitions, update score, animation etc).
The ZeptoLab’s main loading and level transition screens are great! [import]uid: 38658 topic_id: 15701 reply_id: 58044[/import]

2 - load new scene
3 - insert missing objects into new scene
4 - transition

:wink: [import]uid: 86417 topic_id: 15701 reply_id: 58047[/import]

ask

Try this:

[code]

– EFFECT: Flip

elseif effect == “flip” then

nextView.xScale = 0.001

nextView.x = _W / 2

local phase1, phase2

local hideCurrView = function( e )
currView.isVisible = false
end
showFx = transition.to( currView, { xScale = 0.001, time = fxTime, onComplete = hideCurrView } )
showFx = transition.to( currView, { x = _W / 2, time = fxTime } )

phase1 = function( e )
showFx = transition.to( nextView, { xScale = 0.001, x = _W / 2, time = fxTime, onComplete = phase2 } )
end

phase2 = function( e )
showFx = transition.to( nextView, { xScale = 1, x = 0, time = fxTime, onComplete = fxEnded } )
end

showFx = transition.to( nextView, { time = 0, onComplete = phase1 } )
[/code] [import]uid: 8556 topic_id: 15701 reply_id: 58070[/import]

photiscta

I did a test here and it worked fine, maybe it’s about your timer. Timers work as threads, so you have to be careful.

I put this code on the Director sample at the end of the screen2.lua file:

[code]
local count = 0
local add = function()
count = count + 1
print(count)
end
Runtime:addEventListener( “enterFrame”, add )

localGroup.clean = function()
Runtime:removeEventListener( “enterFrame”, add )
end


– MUST return a display.newGroup()

return localGroup

end
[/code] [import]uid: 8556 topic_id: 15701 reply_id: 58072[/import]

Thank you for looking into this, Ricardo.

I replaced the EFFECT: Flip section with the code you provided, but unfortunately, I still see the same vertical line on iPad screen as the scene changes. [import]uid: 67217 topic_id: 15701 reply_id: 58091[/import]

I’d definately say to be able to find the progress of loading like in Cut The Rope! So we can have a loading bar on our splash screens! [import]uid: 50842 topic_id: 15701 reply_id: 58108[/import]