vila4480's Recent Forum Activity

  • I found out that using a global layer with its own eventsheet works great for having the same info showing up in different layouts.

    Search for global layers learn how they work and how you can have the same layer in all layouts.

    Then animate stuff with lerp and "set X position every 0.1 seconds" to the objects.

    I'm using this method to make message boxes, UI menus, etc.

  • I believe this is related to CORS and Heroku.

    No idea how to fix this.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Braus,

    I'm having this exact problem.

    Did you succeed in resolving it ? If so could you post a how-to please.

    I do have the Rex Parse Initialize updated to the latest, installed and filled with ID, Key and URL but I only get "Login failed" message.

    Braus

    I have this exact same problem... did you manage to solve it?

    Thanks!

  • Nice to know, this will be helpful so we can exchange feedback and try to understand better the thing since I am not able to find anyone (aside for the ones in this discussion) that have done any experimentation with HTML5 games.

    Hopefully we can reach a 30 FPS for an average game soon

    Hi again , I just wanted to say that I cancelled my purchase of the Raspberry Pi 3 and instead bought the Asus Tinker Board as per suggestion by Ashley. I tried it out with the same game that I was using before (just a couple of textboxes and a simple 5 FPS sprite). I am now getting 52 FPS and it works pretty much flawlessly.

    Sometimes it does slow down a bit for a couple of frames but except for that it works great and my CPU usage is below 30% (I am running a vnc server on the board though).

  • I might be busy in the next 2-3 weeks so I will update you in a bit.

    Awesome thank you for your feedback! Here's mine:

    I decided to buy a Raspberry Pi 3 B+ because my Raspberry Pi Zero W wasn't able to handle Raspbian+Chromium (kept CPU at 100%) - I was running a "game" at 800x480 and with 3 textboxes & 2 small 5FPS sprites going on at an astounding 1FPS even with WebGL active (in the game as well as Chromium).

    However, when running the Arora browser from NOOBS I got a significant improvement with an average of 7 FPS.

    In any case this isn't close to what I need (at least 20FPS) - so I hope the Pi 3 will help. Waiting for it to arrive, I'll share all the details once I get my hands on it!

  • I have ordered one and I will give it a try. In the worst case scenario I will try to export the game for Android, or if sticking with HTML5, I will try turn based games that might suit better.

    I will keep you posted with the progress.

    Any updates ?

  • That may be a good tip for certain projects, but I really can't get nwjs to read the file in preview mode.

    So in preview, even if the path is correct, it just ignores the readfile command except when exported.

    It works well in export mode though.

  • If you use the nwjs export/preview you can use the readfile expression of the nwjs object to read a local file.

    I believe you are right... the nwjs readfile expression really does work very well and just enough for my requirements (I can even link my local dropbox file path or to a file in the app's folder). Performance is great and the code is simpler than using AJAX functions. Only downsize is not being able to experiment with it in Preview mode - having to export every time - but for that i can instead use the previous Filechooser method I referred.

    For future reference to other people: the nwjs readfile retrieves the contents of the file by inputting its path.

    I'm saving these contents as a string. NWjs.AppFolder refers to the exported App's path, but you may instead type the full path in " " including the filename:

    For further info please refer to this document: Exporting desktop apps with NW.js.

    R0j0hound you've been awesome for helping me out again! Thank you so much!

  • I probably rambled too much. Maybe this is helpful?

    https://www.scirra.com/manual/141/files

    Oh thank you, I was right-clicking the wrong folder!

    However, this does not seem to help in my particular case as my intention is to read a .txt file every x seconds because that file keeps changing over time by using another piece of software. When I import it to Construct it becomes a static file inside the .capx that can't be edited by external applications...

    Any other ideas on how to access an external local file? <img src="{SMILIES_PATH}/icon_e_sad.gif" alt=":(" title="Sad">

    ~

    Thank you for your help!

  • If you added the files from inside c2 the second should work.

    I was a bit confused by your reply. I can't seem to be able to add a file to the project... I suppose this could possibly be done using XML but to be honest i have no idea how to do that or if there's an easier approach.

    Instead I opted for the FileChooser object and then I asked AJAX to fetch the FileChooser's picked file's URL.

    However, this forces me to pick a file every single time I want to use my app since it does not allow for a default file to be picked at the start of the layout.

    This does work well.. but it is not viable for me to have to have to pick the same file every time just to get a proper URL to the file (a URL that works -> since I can't get my previous examples to work!).

    I noticed that the FileChooser's URL value is something like "Blob:http://localhost:50000/3e94a87df-6532-4413-n187-996830dnb630f" and it keeps changing every time I load the file manually.

    This is what I've got right now:

    ->Can there be a static URL to this local file?

    ->And how would you load it from inside Construct?

    Thanks!

  • R0J0hound you're being extremely helpful as usual and you saved me several times now - so I really appreciate your reply!

    I believe you may be right.. I also read this article on Making AJAX requests cross-domain which I'm not sure if it may be causing issues.

    Update: got this error which definitely confirms it:

    I have one question though when using your method: I tried adding the file to my .capx folder and called it like this:

    or like this:

    None of those methods worked at all... am I doing something wrong when loading a local file?

    I was in preview and using a local .capx file/folder.

  • Hi guys!

    Up until last wednesday i was able to use my code without any issues whatsoever.

    Now the files i was requesting turn out empty in my project. I checked the Dropbox URL and it is dead (as Dropbox dropped that direct access functionality recently).

    However, even after uploading this file to an FTP server I'm still not being able to read the file. I read something about MIME types conflicting with AJAX being able to read files?

    In other words:

    This no longer works:

    This does not work:

    You can try and access that last one yourself... you'll see a list of usernames but AJAX can't seem to fetch them.

    No other changes were made to the code whatsoever.

    Someone please help! All of my projects revolve around files and are no longer working since dropbox changed their ways - even though I can access them via an alternative method.

    Thanks for the tips in advance!

vila4480's avatar

vila4480

Member since 29 Jan, 2013

None one is following vila4480 yet!

Trophy Case

  • 11-Year Club
  • Email Verified

Progress

12/44
How to earn trophies