Today I noticed that while the Scaleform plug in in 2014.0.5 is a great step forward still miss useful functionality.
Add to this that the performance of the various inter ops between c++ and Action Script is not really clear by both Project Anarchy and Scaleform manuals, the proper use of Scaleform is still a bit confusing.
Let's explore a bit what is missing...
Tools
Most of the provided scaleform tools doesn't work as require license (mostl relevants are gfx player and Amp profiling tool).
One quite bad and boring solution is to download udk and use the tools provided with the udk version of scaleform.Sad to see this as I remember that this problem was sorted out.
Invoke
People acclamed feature has been implemented in this version, but it doesn't look as something very optimized to use.
Isn't clear if there is a better way to call an action script function caching a reference to the function instead to look it up everytime.
Movieclip Playback
Mostly I missed GotoAndPlay and GotoAndStop function so added them today to the lua wrapper.
SetText
txtfields setText is also missing (this however can be replaced with setMember("text"," your text" or getting the text variable) but I suppose setText is a better one as it doesn't have to look up the member name string or store the binded variable c side?!?.
hope to test it today too.
Variable vs Value
Without to read the code the difference between Variable and Value is not really evident especially in lua where from manual they looks equivalent.
It's required a further description to let everyone use the right one in the right spot.
Another misconception is that Scaleform values doesn't make any difference between simple data and object references.
Movie clips
Capability to crate movieclip and add and remove movieclip's childrens is also missing in the plugin api.
This sound to me as something to better not do in c++ and manage those kind of things directly in action script after calling some As function that add movieclip from a pool.
But also managing the pool from c++ may be even better.
Also there more tests/infos is still required.
More Samples
It will be interesting to have an example of little 2d game with all gameplay done in c++ and using scaleform just for display.Puzzle example is good but it's gameplay is all actionscript.CLIK
CLIK widget oriented functionality and examples of Gui Binding.Wait for Update to Finish
Scaleform system have a single point of syncronization with Project Anarchy at the end of the update phase (of the specific movie?!?)(i have to check this as it may suggest that having more movies at the same time could be better for performances(less for memory) on multicore devices).
The update in progress is checked on every little modification to scaleform values .
It is checked with an if that always fail just pass 1 time per frame for every movie I guess.
So my humble opinion (to verify) is to cut all the checkings in every function that modify values and just make an api function to call manually before the first per movie per frame modification.
This just add an additional user call not so elegant ,but possibly rather functional.
Display Info
Display info is another thing that bothers me a bit.I haven't measured this but it seems to be something to investigate.In the actual api we doesn't have access to get and set display info, but everything is modified per property(this is true for lua as for c++ you always have the option to call scaleform api directly).
When you call Display_SetXScale or other set function first of all the plugin performs a display info check to see if our object is a display object and wait for the end of the movie update thread(yes also there).
Then it get and set the display info just to modify the single parameter of our call.
This makes you check for display info and get and set display info for every single property you want to change while commonly you want to check the object once, get the display info once, modify every property you want , set the display info once on the original object or even on whatever else movie clips.
Conclusions
I want always to give my thanks to the Project Anarchy team as even in this release they surpassed the just hi quality standards we are accustomed too.Just some more documentation and little fixes are still required.
Old scaleform plugin was little inferior to the competitors but actual one seem to be on par if not superior in some aspects of the api.
If you add that Project Anarchy unique features and the fact it is free I think it is the best engine to use Scaleform with.
If you add that Project Anarchy unique features and the fact it is free I think it is the best engine to use Scaleform with.
No comments:
Post a Comment