Ashley's Recent Forum Activity

  • Construct already automatically hides the splash screen as soon as it is ready to show anything. If you want to hide the splash screen ASAP, the important thing is not to use loader style "none", which shows the splash screen until the entire project is loaded (hiding any loading progress). FWIW the root cause problem here appears to be Google measuring stats incorrectly, so for a real fix, ask Google to fix that.

    I think it would be misleading to call that option "percent". If there's another mode, it should just be the 0-1 value that goes directly to the Web Audio API, and then you can use your own formula if you want.

    I'm not sure what every software developer who has ever made a volume slider has done, but I would guess there is either a special case for volume slider 0 = -Infinity dB (i.e. at the very bottom it becomes a mute), or a very short linear ramp at the very bottom of the scale, or perhaps some other exponential formula that ends on 0. I think just special casing 0 = -Infinity is a reasonable way to handle it.

    I think dB is a better unit for volume because it better matches how human hearing works, as the human perception of volume is not linear.

    For example -10 dB sounds about half as loud (note that perceived volume is different to the actual sound power), -20 dB sounds about the same amount less loud, -30 dB sounds about the same amount less loud, and so on.

    If you work in percentages then that goes 31.6%, 10%, 3.1%. I don't think that's very intuitive - the percentage changes are wildly different but the perceived change is about the same.

    If you make a volume slider that works in percentages then you'll find the top half of the slider seems to do very little, and the very bottom end of the slider does very quick changes, which makes it harder to control low volumes. If the volume slider is in dB, then it works more like people expect it to. If you ever see volume controls in software, they are very likely working in dB - usually the linear scale with all the control really happening at the low end is seen as a mistake. Similarly if you want to fade in audio, it's better to fade it linearly in a dB scale for a natural increase in volume. Otherwise you get a similar problem to the linear volume slider: the volume very quickly increases to nearly full volume, and then the rest of the fade time it only gets very slightly louder.

    So really you should generally be working with volumes as dB all the time anyway. Can you give an example of when you'd prefer to do something with a percentage volume?

  • It's much easier to help if you share your project file. But from just looking at that code, it looks like textInstance refers to an ITextInstance. That's a whole class - you can't just assign a string to it. You probably meant to assign the text property instead.

  • Whenever I try it, offline support works. I just tried it again and it works for me. Usually whenever people complain about this, it turns out they're making some mistake, such as not waiting for the "ready to use offline" notification, or using browser privacy settings that prevent Construct saving itself for use offline.

    If you run in to a problem with offline support please file an issue - but note the steps to reproduce need to include clearing your browser cache, loading Construct, waiting for the "ready to use offline" notification, and then proceeding to reproduce the problem.

  • Again, the manual entry describes that:

    colorRgb ... An array with 3 elements specifying the red, green and blue color filter of the instance, with color values as floats in the 0-1 range.

    Using floats in the range 0-1 is how GPUs actually process the data. It makes many color calculations work more easily, and works regardless of the actual color data being processed. For example when using colors in the 0-1 range, the multiply effect is literally just "a x b". If you use colors in the 0-255 range, that is very much specific to 8-bit unsigned storage - e.g. 10-bit storage would use a 0-1024 range instead - and doing "a x b" will process an entirely different type of effect that isn't really useful - to get a multiply effect with the result also in the 0-255 you'd actually have to do "round(((a / 255) x (b / 255)) x 255)".

    So basically everything in computer graphics uses colors as floats in the 0-1 range as it works a lot better, and so does Construct.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Remember to think about the inherited classes. The ISpriteInstance manual entry states it derives from IWorldInstance, which in turn states it derives from IInstance. So all the properties and methods covered in all three manual entries are available for Sprite instances. (This is the standard way object-oriented programming works in a range of languages.)

  • Don't guess -look in the manual to see what methods and properties you can actually use. In this case you want the IWorldInstance property colorRgb, e.g. to set a red filter:

    inst.colorRgb = [1, 0, 0];
    

    You might also want to take a look at using TypeScript which provides precise autocomplete and error checking to help catch mistakes like the one you made.

  • You can diff the JSON files for the event sheets. I realize it might not be too easy to read but it will show things like where additions, changes and removals have been made.

  • The latest beta release r401 may be able to open the project, as it has improved automatic handling of invalid names. It may also be able to show the first invalid name it encountered which could help speed up identifying the invalid names if there's only a small number of them. This guide has some more information.

  • Construct doesn't support asyncronous loop condition methods. You'll have to find another way to achieve this.

  • In r401 the Mobile Advert plugin has now been updated. Internally it has switched over to using community-admob-plus-cordovayds@1.32.8 which now uses Google Mobile Ads SDK v23.2.0 for Android (and v11.3.0 for iOS). Hopefully this solves the immediate problem - let us know how it works out. We'll continue to review options for better long-term maintenance.

Ashley's avatar

Ashley

Early Adopter

Member since 21 May, 2007

Twitter
Ashley has 1,380,199 followers

Connect with Ashley

Trophy Case

  • Jupiter Mission Supports Gordon's mission to Jupiter
  • Forum Contributor Made 100 posts in the forums
  • Forum Patron Made 500 posts in the forums
  • Forum Hero Made 1,000 posts in the forums
  • Forum Wizard Made 5,000 posts in the forums
  • Forum Unicorn Made 10,000 posts in the forums
  • Forum Mega Brain Made 20,000 posts in the forums
  • x107
    Coach One of your tutorials has over 1,000 readers
  • x61
    Educator One of your tutorials has over 10,000 readers
  • x2
    Teacher One of your tutorials has over 100,000 readers
  • Sensei One of your tutorials has over 1,000,000 readers
  • Regular Visitor Visited Construct.net 7 days in a row
  • Steady Visitor Visited Construct.net 30 days in a row
  • RTFM Read the fabulous manual
  • x35
    Great Comment One of your comments gets 3 upvotes
  • Email Verified

Progress

32/44
How to earn trophies

Blogs