frozenpeas's Recent Forum Activity

  • Thanks, I obviously need to do some major reading on this.

  • I've made the bottom layer transparent and tried the following code.

    I can see the image appears briefly but then disappears.

    So, is it possible to load an image into and change the c2canvas background through javascript?

     
    var canvas = document.getElementById('c2canvas'),
    context = canvas.getContext('2d');
    make_base();
    function make_base()
    {
      base_image = new Image();
      base_image.src = 'icon-256.png';
      base_image.onload = function(){
        context.drawImage(base_image, 100, 100);
      }
    }
     [/code:3uranuhu]
  • I have a sprite called "Tank" on "Layer 0"

    Trying to reference the name of a sprite or a layer with javascript.

    Do these elements have ID's like <div id="Layer 0"> or <img id="Tank" scr......>

    First time delving into SDK so go easy on me

  • So, Construct's File Chooser cannot natively load an image from either the camera or the gallery into a sprite on Android.

    Bit of a deal breaker for my current ideas, but at least I can now move on and explore other methods like Bitmap and BitmapFactory. Lots of apps have this feature so it must be possible.

    Thanks Ashley for your reply

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Removed camera plugin and tried the "cordova-plugin-file"

    Same thing opens recent files list, lets me choose gallery etc

    Select png or jpg and sprite does not change.

    Strange thing also happens when I specify .jpg,.png within construct and build the app. The file chooser does not open the file browser at all !

  • Trying to get my head around how to make an app that is dual aspect ratio.

    My initial thoughts are making a layout 1280 square

    Place all elements in relation to the centre of the display

    Have all the menus appear with the square so that I only have to place them once

    Not sure if this is the way to achieve this.

    Anyone have any insight or best practices into dual aspect ratio apps?

    Thanks

  • Built a simple file chooser and sprite using XDK with just the android version and cordova camera plugin - Load image from FileChooser.FileURLAt(0)

    Permissions show as "modify or delete the contents of your SD card read the contents of your SD card"

    When you click the file chooser, the recent files list appears (the one that has links to galley, videos, etc) which seems correct

    However, when you click an image, nothing happens. Added a text box to show location of the file which reads something like blob:file%3A///0af12f87.... etc

    Android 5.0.2

  • Crikey the months fly by

  • When using features like FileChooser and Canvas Snapshot are there any additional plugins required to make these features work correctly when exported to apk?

    If so what are the plugins required and is there any Construct 2 documentation containing a full list?

    Thanks

  • Wow never knew you could disable groups

    That will make things a lot easier

    Thanks

  • One of the things I learned early on was to create a global variable called something like "menuToggle" and when an option or menu item is selected I set menuToggle = 1

    This can then be used to disable all other screen clickable objects when one is active.

    Test for it by using:

    On touch object and menuToggle = 0

    》do something and set menuToggle = 1

    When the user closes the menu or clicks next you set menuToggle back to zero.

  • Thanks for posting.

    I've been banging my head against a brick wall for days trying to find a solution to a problem similar to yours regarding the file chooser and loading a file from the phone gallery and you may be on to something.

    Can I ask, from that Intel page what exactly you did to remedy the problem.

    Thanks

    Rob

frozenpeas's avatar

frozenpeas

Member since 14 Apr, 2015

None one is following frozenpeas yet!

Trophy Case

  • 9-Year Club
  • RTFM Read the fabulous manual
  • Email Verified

Progress

11/44
How to earn trophies