[PLUGIN] appMobi Plugin Updates

  • tap - yeah I have been through that pretty thoroughly a few times. I can get fullscreen to work on everything (previews in Construct, Visual Studios and Direct Canvas apps), just when I don't use direct canvas and go through appMobi the game bunches up into a corner (I would show you a picture, but I actually don't know how to do it on these forums...).

    I have another question though, is there any way to work with dynamic text in Direct Canvas? I have been making some little 10 minute RPGs for Windows 8 while waiting for DC and would like to port them over when it's ready, but lack of text object makes it seem undoable.

  • Hey Joannesalfa

    I added "Hide Status Bar"the plugin and it's live on github.

    Also how much of a delay are you seeing with touch events? Can you send me the capx to have a look?

  • Hey tap,

    I was just playing with the cookie object of appMobi plugin and was wondering... since there's a setCookie action, shouldn't there be also a getCookie? How could one read the value stored in a cookie? I know there's a getCookie in appMobi API, though...

  • Hey Tobye,

    If I understand correctly, the issue only presents when you export using the device browser. The project is probably being set to full screen scale letterbox and ends up on the left hand side of the screen, correct?

    One thing that I saw that resolved this was to either wrap the canvas tag in center tags or set the style so its centered.

    As for fonts under DC, I'll find out from our DC devs when that will be supported. In the mean time, you best best is to use image fonts. (not static images, but where you use images of the letters in place of text). This way you can still generate dynamic sentences but using images instead. I have not checked if there is a C2 plugin for them or not, but Let me know what you find. Again I will get back to you once I find out more.

  • xyboox - Actually there is a way, but not an action. It's an expression called appmobiDev.Cookie. However, I just looked and saw that it only works when not under DC. I will add that DC support for it and update github shortly.

    Thanks

  • Great stuff tap! Thanks once more.

  • Hey Joannesalfa

    I added "Hide Status Bar"the plugin and it's live on github.

    Also how much of a delay are you seeing with touch events? Can you send me the capx to have a look?

    I will send you a .capx via pm soon.

    Also i want to comment about Prevent auto-rotate, it doesn't even work because i used a trigger event, it doesn't work and still auto rotates when i do inverted portrait orientation and if i use every tick event to prevent auto-rotate, touch buttons take loooooooooooooong time to response and still auto-rotate

    I wanted to make it static orientation

  • tap - I found a spritefont plugin, but it is no longer being developed and does not work in appMobi. You can check it out here if you like:

    scirra.com/forum/plugin-spritefont-28th-august-2012_topic45876_page1.html

    And yep, that's the problem! Sorry but I don't know how to 'wrap the canvas tag in center tags or set the style so its centered.' Something I need to do inside of one of the .js files I take it?

  • xyboox - Files are now updated on github. You should be all set.

    Joannesalfa - I have not seen a PM but created a test capx and the orientation stays to what I set it to. Here is what I do:

    On Start of Layout

    • Action: appmobiDev Device > Prevent Auto-Rotate
    • Action: appmobiDev Device > Set orientation to Landscape

    I built it and tested it on device and the game starts and is locked in landscape mode and does not change when I rotate the device. I would only call these at the start and not in a loop as the case with every tick. That *could* be why you are seeing performance issues.

    Tobye - If you exported via appMobi using the device browser, just open up index.html in your favorite text editor. Scroll down and you will find a canvas tag. Just wrap that in center tags. In you index.html file you may see the start of the canvas tag around line 34. It would look like this <canvas ... >. Simply put the opening center tag before the canvas tag. Like so: <center><canvas ...> Then scroll down to around line 44ish and you will see the close canvas tag. It will look like this </canvas>. Just add a close center tag after it like so: </center>

    As for the image font, I will check out the link you sent.

    Thanks.

  • tap Oops, pm sent.

  • tap - thanks, I tried it out and it did centre the image, but it still doesn't resize it to fill the screen. Still looks much better though and maybe I can play around with it to get a suitable fit later.

  • Tobye - Glad that worked for you. If you are looking to fill the complete screen and not have the letterbox bars there are a couple things you might want to try:

    1.) Design your game with a width/height ratio that matches so that it can scale to fill.

    2.) Design your game to fit the largest screen and then use crop for smaller screens. This can be done by putting "filler" static content that wont matter if it is cropped out.

    3.) Edit your index.html to include a background image that is designed to fit the style of the game. This way you dont get black bars you get whatever design elements you add.

    4.) While not preferable, you can always create different sized copies of the game for the different platforms.

    Just some thoughts.

    Best of luck.

  • Hey tap i need to confirm, did you get my .capx via PM?

  • Yep Joannesalfa, I plan on taking a look at it tomorrow morning to see whats going on. Thanks!

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • Thanks i hope this issue will be fixed soon!

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)