igortyhon's Forum Posts

  • All of this can be done without external plugins. Although it's not very convenient.

    If loading external resources becomes more convenient, I will be very happy.

    Please provide the name or link to your plugin. I want to see what features it has.

  • Thank you igortyhon.

    that's exactly what I was looking for. But I can't figure out how it works. the sprite skeletton goes translucent on your project but when I do the same on mine, it is visible on source atop blend configuration. I've c/c the skeleton sprite, that still visible on my project. why does that happen?

    Check out the blending modes in the sprite or layer.

    Actually, the construct has many such modes, you can also look at this example.

    editor.construct.net

    I don't use it often, so I have this cheat sheet.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • This is just a reminder; it does not affect the promotion of the game in the store in any way.

  • Can you not design your layouts with the right initial objects placed? Then both layout-by-layout memory loading, and spritesheet generation, should work better.

    I showed these three objects in the screenshot, and they are located on separate layouts. And they are still grouped into one sprite sheet.

    And when I create Boss20 somewhere on the level, Boss40 and Tree are loaded into memory.

  • Construct attempts to group images based on their usage on layouts in your project (similar to the way layout-by-layout image loading works as described in memory usage. Have you designed your project this way? Or do you rely on a lot of dynamic loading, in which case Construct won't be able to know which images go together?

    ..

    Yes, everything is stored in the “repository” sheet, and when I start the level, I create everything dynamically.

    In the screenshot above, you can see that there is a sprite sheet with three objects, and every time one of them is created on the level, the engine has to load two extra objects into memory. Isn't this a waste of memory?

    I'm not asking for an immediate fix. However, I believe your team is smart, and when you consider this challenge, you might come up with a great solution down the line.

  • Hello, engine developers and users who are interested in this topic. I think this is especially relevant for mobile developers.

    Question for developers Ashley and Tom: our engine is constantly growing and filling up with various interesting and useful tools.

    It would be nice to fix this mess in the sprite sheets. Currently, sprite sheets are compiled automatically and quite densely. We can even choose their size (512, 1024, 2048). But this compilation is often illogical and leads to unnecessary memory consumption at the level.

    In the screenshot, I have given an example of a sprite sheet with only three images, and they will never be used on the same level but are always loaded together.

    It is high time to do something about this, perhaps adding a tag to the sprite to which it belongs to a separate scene. Or maybe you have another solution.

  • When i check on admob, they ask me to "validate my game" and insert an "fichier app-ads.txt" into it.

    Everything works.

    The file (app-ads.txt) must be placed on your website.

  • Yeah, but +55% CPU usage - it makes no sense! And if I move the "is visible" condition inside the loop, the difference is only 3%

    dop2000 I think our colleague Je Fawk found a bug. In fact, with these tasks, a load of 5-10% is normal, because it only involves checking two parameters in a total of 3,000 objects. This is an easy task for JS, and all this load is mainly overhead and rendering costs.

    For such a task, a load of 60% is something abnormal.

  • igortyhon thank you for the testing. My point was to first filter all the objects and then do the loop with the check, to make it run better.

    Obviously it didn't work, hence why I asked if people know the reason.

    But (visible) is not a trigger, and when you have one object on stage, you can do this, and it will check that object. But when you have 500 objects, which object will be checked for visibility?

    This creates uncertainty, and thanks to Construct3, such code did not generate an error. But it is good practice to choose in the code which object you need to check through the peak or go through all of them.

  • Using r. 449.2

    Hi. You are using the optimization condition incorrectly. If you are forced to go through all objects every tick, then at least try to do all the checks in the middle of the iteration cycle.

    To make the result more visible, I increased the number of objects to 10,000.

    If we disregard overhead costs, I think the optimization gives about a 50% improvement.

  • Is there any easy way to do this? As width and height of screens could be very different from tablet to tablet

    Thanks!

    In this case, it is better to use these expressions

    PlatformInfo.CanvasDeviceHeight/PlatformInfo.CanvasDeviceWidth
    

    to determine the screen resolution on which you want the banner to be displayed, and only display it there.

    I use these expressions to adapt the game interface to tablets and smartphones.

  • Thanks, I'll try. However last time I had problems with IDFA + consent on AppStore. First IDFA is displayed, then Consent, the Apple Support want to display them in another order for some reasons

    You'll have to code it.

    When I published my first apps, I followed all the rules.

    - First, the window where I explain why I'm collecting data (to improve the game) is a design window. This recommended window is optional.

    - Then GDPR.

    - Next comes ATT.

    But in my latest app, I followed your advice, simply enabling the checkbox in the plugin. I trusted the correctness of the AdMob SDK itself. The only thing I did was remove the identifier for Android in the plugin settings, leaving it only for iOS. I didn't even test it, but it quickly passed moderation.

    That's why I gave this advice.

  • Leave the checkbox (show on startup) checked in the plugin settings and remove everything you do in the code.

    In this case, the AdMob SDK will determine whether the player should be shown the consent window; this is a problem for Google's SDK itself. You can then check your AdMob account to see how many people have given their consent or refused.

    There is no need to complicate things where it is not necessary.

  • I clearly stated in the screenshot that checks longer than 30 minutes and longer than 22 hours are a single block through the OR block.

    I also wrote this in the post.

    If you need such detailed instructions, you need to save the project in a single file (*.c3p) and post it, then it will be easier to make corrections and check.