Stencyl 2 API question

neovive

  • Posts: 45
I typically avoid such comparison questions, but I have to make a platform decision relatively quickly regarding an SDK for an upcoming multi-level puzzler game for iPad.  I have some experience with CoronaSDK and Lua and have read through Stencylpedia.  Beyond the obvious differences in the platform and approach (code vs. GUI, remote compiling, available publishing platforms, etc.) are there any major features available in Corona's API that are currently missing from Stencyl 2?  For example, I wasn't able to find things such as external network requests, file I/O, SQLlite in Stencyl, but it's possible that I just missed it at api.stencyl.com.

Stencyl is very impressive and I can't wait to download v2 this weekend.  The application is beautiful and everything just feels seamless and well thought out.  I already plan to use Stencyl for a future project, but just do not have enough experience to make a definitive decision regarding the current puzzler project.  Any advice would be greatly appreciated.

« Last Edit: April 18, 2012, 08:29:11 am by neovive »

Jon

  • *
  • Posts: 17526
I'm not fully versed in Corona's API to tell you everything, but for the couple things you mentioned...

external network requests
Yes. http://www.stencyl.com/help/view/web-requests/

file I/O
Arbitrary file I/O is not built in at this time but is planned for the future. In the meantime, regular saving works for most needs. On iOS, it uses CoreData behind the scenes.
http://www.stencyl.com/help/view/saving-and-loading-games/

SQLlite in Stencyl
Not built in. That said, I'd personally never advocate having a client app do any kind of database connections. I recommend using a server to do that, through HTTP requests.

neovive

  • Posts: 45
@Jon:  Thank you very much for your detailed response and my apologies for interrupting you during your 2.0 launch preparations.  It's amazing to see such dedication!!

The web requests are perfect .. not sure how I missed that one.  Regarding the file i/o and sqllite, since the game involves word puzzles I was planning to store the dictionary in a table with associated meta attributes.  Besides hard-coding this data in the app itself within a data structure, is there a way to accomplish looking up lots of data with requiring repeated external network requests?

P.S.  Don't feel compelled to answer right away ... I know you are busy.   :)

neovive

  • Posts: 45
I'm very exciting to be testing out Stencyl 2.0!  What a great upgrade.

As a follow-up to my question, is there a recommended best practice to working on a game (such as a word puzzler) that will require a large data set of words to be referenced by the game?  My previous SQLite question was regarding access to the native SQLite instance on iOS devices, since using a network request for each query would impact performance.   I guess one option is to store the data remotely then use a web request that returns JSON or XML and parse it locally.

Is it possible in Stencyl to store and reference a custom data set as is typically done via data structures in programming-based development environments? Thank you in advance for any suggestions.

Jon

  • *
  • Posts: 17526
There are hackish ways to pull that off by dumping the data into Game Attributes (Which is just a NSMutableDictionary), but the best solution will be offered in 2.5 when we offer significantly more "to the metal" approches to work with code directly and define your own data structures to use.

neovive

  • Posts: 45
@Jon: Thanks for the tips.  I will test loading the data into attributes.  2.5 sounds really exciting.  I noticed the 2.5 mention on the road map (http://www.stencyl.com/stencyl/roadmap/) for July.  Is that just for Android release or is the direct access to build custom data structures planned for July  as well?  Thanks again.