Ashley's Forum Posts

  • I think this could prove very complicated, since you could accidentally make thousands of expressions invalid in your project, if you did a find-replace that produced invalid syntax. There would have to be some way to prevent that, and that may in turn prove sufficiently limiting that the feature doesn't do what you want it to any more.

    Find-replace is also notoriously error prone - for example if you do a naive text-based find and replace for "text" with "label", and buried somewhere in thousands of events you have some dialog shown in game saying something like "In the right context we could...", that will also update to "In the right conlabel we could...". Now you've mangled a bunch of your game's dialogue in hard-to-find ways that will only show up after hours of playtesting. This is such a common problem that whenever I want to do find-replace myself in Construct's code, I actually just do a find, and manually update all the results so I don't end up making that type of mistake. So I would suggest a similar approach in Construct is wise - and you can already do it that way.

    For the most part, if you rename something in the editor, like an object name, it automatically updates all its references in the rest of the project. So it kind of exists in that form already.

  • You do not have permission to view this post

  • I just checked and it seems to be working fine for me. Maybe check your Internet connection is working.

  • 700mb is a very large memory requirement for a mobile game. I would guess the app is crashing due to running out of memory. See Remember not to waste your memory.

  • We are unlikely to do this as it might draw new customers away from Construct 3. Construct 2 also uses commercial libraries that would make it difficult to open source.

  • You will need to use the postMessage() API to communicate with an iframe.

  • If you run in to a performance problem that only affects the APK and not the browser, please file an issue with Google at crbug.com with details about the device.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • I'm not familiar with the Unity tool, but you can repeat mesh distorted images with Tiled Background.

  • The last few tests I did on a Pixel 3 appeared to run perfectly smoothly.

    Once again, I think the only good way to investigate this and find out what's really going on, is to file an issue at crbug.com with details about the specific device. Any jank/webview-specific performance issues are beyond our control, so only Google can investigate and fix them, and the more issues are filed about this, the higher they will prioritise it.

  • In 2020 the problem was repeated with another application and I solved it by deleting addons "even if the addon was not used in the project, it interfered with the app's performance!"

    None of the official addons should have any performance impact at all if you don't use them. If you can measure a performance overhead, please file an issue - we should be able to fix it.

    If a third-party addon has a lot of performance overhead, you'll need to contact the addon developer about it.

    I'd add that without rigorous measurements, it's easy to be completely misled by changes. For example if you change 2 things, one has a huge impact on performance, and the other has no impact at all, you can easily come to the false conclusion that both of those things improved performance, or that the wrong one improved performance. Since your post mentioned several things you did, it's not at all clear that the issue with addons you mentioned actually caused the problem. Further, even if a single addon does have some performance overhead due to a bug or something, "remove unused addons" is still not actually helpful advice: someone could remove a whole bunch of addons, but unless they remove that single offending addon, it won't make any difference. So to be useful advice, you should specify which. And if you specify which, we can investigate a potential performance problem and optimise it.

    I don't mean to pick on this poster specifically, but this kind of thing is repeatedly coming up in this thread, and often plays out across the rest of the community. Guesswork can result in poor advice, misleading conclusions, time wasted on meaningless changes, and create fear and uncertainty in the community as people say things like "but I thought unused addons had no performance impact?!" when they're probably actually right. If something really matters to performance, prove it: make two projects with a single change, make performance measurements in both, and compare the results. I would hazard a guess that of all the things people are saying here, 3 in 4 of them will make no difference at all. Measurements are the only things that matter, and you should only ever take performance advice seriously if it mentions measurements, and those measurements clearly correlate to a single change.

  • You need to contact the library developer about this. They need to make sure the library supports JavaScript Modules.

  • Will there be a Scripting API for containers, to be able to reference them? A sample use-case is setting all containers with an instance variable of the uid of the parent object, upon creation.

    It's not currently supported. It's best to log suggestions at construct3.ideas.aha.io so they don't get lost in the forum.

    FWIW, containers are pretty straightforward: because they always create and destroy together, all instances have the same IID (i.e. the same index in the instance lists), so you should already be able to figure out the container instances fairly easily.

    I've tried picking the objects by manual name search (runtime.objects["name"]), however it seems that the container objects are only later created after the "instancecreate" event. So, it's not possible to reference them on creation, unlike events.

    It's impossible to reference all container instances in a create event, due to the reasons I explained here.

  • I tried a minified export in Firefox 86 and it worked fine.

    It can take a while though, so you may have to be patient.

    As ever if you run in to problems please file an issue following all the guidelines, since we need that information to be able to help.

  • For loading the game on the android app, we download and cache the whole game bundle locally to reduce the download time for subsequent game loads. We leverage the request interceptor functionality of WebView to intercept the network request and then use the WebViewAssetLoader to load the response for the intercepted request from internal storage.

    Can I ask why you are doing this in the first place? Construct's built-in Android export option already gives you an Android app with all the resources bundled, so it works offline, and you don't need to download anything from the Internet, do anything else to manage offline support, or write your own network request interceptor. Construct's Android export has quite a lot of complicated compatibility code to work around all these types of issues, and so if you don't use Construct's Android export, you're going to have a long path of reinventing all these difficult compatibility headaches, such as this one, and probably several more you will encounter in future.

    Anyway, this specific problem should be simple to solve: as the error message says you just need to make sure the returned MIME type is application/javascript for .js files. A quick Google shows that you can set this on the returned WebResourceResponse via setMimeType. However as I said, this will probably look like it works until you run in to the next compatibility problem which you have to add further hacks for...

  • In r235 we fixed a bug in vertical alignment: previously it was not actually correctly vertically aligning the text; now it does a better calculation which is closer to the true middle based on the text metrics. This is technically a breaking change, so if you had adjusted your text positions to compensate for the wrong position, now you don't need to do that and so you might need to move them back a bit again. Unfortunately this is something of an unavoidable consequence of changing the alignment.

    To be honest the alignment of the Text object is a bit of a mess - the Text object dates back to the original version of Construct 2 in 2011, where BBCode was not supported, browsers did not provide the necessary text metrics to accurately align text, and (partly due to the missing text metrics) the original top alignment was actually slightly wrong. These things have been adjusted and fixed over the years (as I explained in the earlier linked bug). However some things are too difficult to change - for example if we changed the default "top" alignment we would break 10 years worth of Construct projects and inevitably be forced to change it back again. The change to middle/bottom vertical alignment when using BBcode was deemed to be both infrequently used enough to justify changing, and necessary as the previous result was actually wrong.