obiot

Members
  • Content Count

    190
  • Joined

  • Last visited

Everything posted by obiot

  1. obiot

    Can't Add Image Layer from PNG

    Can u share your game.resource list to verify if background is the actual asset name ? (As opposed to the filename)
  2. well that's an interesting one too, I was just looking at the code and indeed there is nothing to manage key status when the window/browser is losing status. So two solutions to that : you can disable the pauseOnBlur feature (true by default), which means the game won't pause when the window will loose focus, and that the keys will properly "behave" or (and this is what I would do in melonJS to fix this), is to register on the state pause or resume event (that are called when the window is losing/regaining focus) and simulate the required keydown or registered keys using `triggerKeyEvent(YOU_KEY, false) these are more workaround, but at least they won't conflict with a later fix in melonJS
  3. obiot

    melonJS 6.1.0 release

    Hi fellow melon lovers Here is a 6.1.0 version, beside others small improvements, this version focus mainly on the issue(s) raised with the 6.0.0 version around Linux and our WebGL Renderer (as you can read it here). Download link : https://github.com/melonjs/melonJS/releases/tag/6.1.0 Full changelog : Audio : latest audio core update (2.0.15) Core : new linux detection flag under me.device Renderer : now systematically warn when using non POT texture in both Canvas and WebGL mode Sprite : new function to allow reversing a given or current animation TMX : support for the Tiled 1.2 beta JSON property format (backward compatible with previous 1.1 version) CanvasRenderer : fix drawImage sub-pixel rendering in Canvas mode when using the short notation (2 or 4 parameters) WebGLRenderer : only throw an exception (e.g. stop execution) when using repeat/wrap mode with a non POT texture WebGLRenderer : properly fallback to Canvas mode in AUTO and WEBGL mode when failing at creating a valid WebGL Context Also, there are no API breaking changes, so purely a "drop-in" replacement ! Cheers, -- the melonJS Team
  4. glad that you found it, thank you for the analysis and feedback, I guess a way to prevent this kind of error would be to throw an exception if the loader ecounters assets with duplicate/similar names. what do you think ?
  5. Hi, to help me track down the issue, or at least allow me to confirm it's still present in the current 6.2 version, could you define the most minimal example that reproduce the issue and share it ? you know that if this is a bug I'll fix it on the coming 6.2 version though.... so unless you want to back port it to the 5.1 version, you will have to upgrade thanks !
  6. obiot

    hidden GUI objects slow game render?

    @can2nac FYI https://github.com/melonjs/melonJS/issues/943 I know that since you changed the way you implemented the UI, but yet I did the changes we discussed in the thread. how is your game progressing by the way ?
  7. obiot

    frame has no offset property

    oh ok good you did then ! what exactly was the issue ? (I fail to see how it was triggering the above exception) Else you should really upgrade to at least 6.1 (6.2 is not yet publicly released), tons of improvements since 5.1 https://github.com/melonjs/melonJS/blob/master/CHANGELOG and except for the utils.xxxx functions, there are no major breaking changes https://github.com/melonjs/melonJS/wiki/Upgrade-Guide
  8. obiot

    melonJS 6.1.0 release

    Good catch on this one, was probably hanging there since version 5.x !
  9. added to master : https://github.com/melonjs/melonJS/issues/947
  10. there is no really an event for it currently, but you can check for the inViewport value to detect if the object is currently in the viewport or not. definitely a good addition though, created a ticket to keep it under our radar : https://github.com/melonjs/melonJS/issues/947
  11. obiot

    Disable respawn on leaving viewport

    Hi, did you progress or find out what is happening ?
  12. obiot

    Disable respawn on leaving viewport

    2 more things : * first your game is really looking awesome so far * in the latest 6.0 version of melonJS we added a camera damping features that really help in smoothing camera movements : // set the camera to follow this renderable on both axis, and enable damping me.game.viewport.follow(this, me.game.viewport.AXIS.BOTH, 0.1);
  13. obiot

    Disable respawn on leaving viewport

    well honestly.... I don't know..... I really don't see what would be causing that in melonJS. would you mind setting a breakpoint on the loadLevel function https://github.com/melonjs/melonJS/blob/master/src/level/LevelDirector.js#L208 so that we can see the call tree ?
  14. obiot

    Using sprite animations with particles

    I feel like I'm only the bearer of bad news recently, but for now the particle emitter only accept image .... that should not be that hard to add though, basically just check what is passed as parameter and either just draw it if an image, or call the update/xxx-draw method of the sprite from the corresponding methods, if a renderable is passed. https://github.com/melonjs/melonJS/blob/master/src/particles/emitter.js#L47-L55 https://github.com/melonjs/melonJS/blob/master/src/particles/particle.js#L35 https://github.com/melonjs/melonJS/blob/master/src/particles/particle.js#L159
  15. obiot

    registerPointerEvent not emitting in 5.1

    FYI, added it in the boilerplate : https://github.com/melonjs/boilerplate/commit/6b0708dea30fdf15a1a68d8398aa3265feec652b
  16. obiot

    .wav files loaded as .mp3 from game engine

    Hi, well this is just not how the current implementation works, the engine will just pick up one that is supported by the target broswer based on the given priority, and if you want to provide the 3 formats, you cannot therefore mix&match them. Keep in mind also that not all browsers will support ogg for example. I would personnaly recommend to stick to mp3 amd webm (wav files are just to big), and itโ€™s pretty simple to convert them (some website even provide some online converter).
  17. obiot

    .wav files loaded as .mp3 from game engine

    Hi, the list of extensions is also a list of priority, which means that in this case melonjs will check if mp3 is supported, and if yes try to load the corresponding mp3 assets. if you need .wav, just put it first, or only that extension.
  18. obiot

    melonJS 6.0.0 release

    Hi guys, Happy to finally announce the latest release of melonJS with version 6.0.0 ! Blog Announcement : https://blog.melonjs.org/2018/08/melonjs-600.html lib and plugin download link : https://github.com/melonjs/melonJS/releases/tag/6.0.0 As announced on the blog, the previously announced ES6 version is being delayed a bit. Main reason being the unexpected huge amount of work required to make it happen, and the fact at the end that while we are working on building an equivalent ES6 version of melonJS, we are basically not adding any new features, or fixing anything to the current ES5 branch.... which we need as well ! so we choose to go with a more "hybrid" and progressive approach --- melonJS Team
  19. obiot

    melonJS 6.0.0 release

    awesome, looks I'm going to call it working then now on Linux, beside small improvements. we now have at least we have a proper fallback for browser that are not able to provide a performant webgl context.
  20. obiot

    melonJS 6.0.0 release

    Hi @can2nac and thanks for the feedback. And yeah it looks like it's working now in both mode though under Linux (performances aside). but I would definitely agree with you when you say that this is "it's all about Linux" (or at least the GPU support/driver), and the fact that setting failIfMajorPerformanceCaveat to true prevent the browser from succefuslly creating a gl context proves the point. As for Mac that's definitely working as this is my main working environment, and I see a ~2x speed improvement on my side ๐Ÿ˜› Only on Linux we have these issues with our WebGL implementation (or had, since it least It does not seem to miserably crash any ore).
  21. obiot

    melonJS 6.0.0 release

    Hi guys ( @can2nac , @TheBoneJarmer ), I have been doing some house cleaning on both renderer, while trying to figure out the current issue with Linux, and ended up fixing a few things. The first thing is that the WebGL Renderer was never checking the returned GL Context for error, and therefore never properly falling back to Canvas Mode. Also, after the remark of @can2nac on the `failIfMajorPerformanceCaveat` option, I did check in Pixi (which I think we can agree as a reference in the matter) and they also pass true for that one, so I kept it that way, but now with the fallback properly working this might actually better work. And finally, I changed a bit how stuff are working when checking for POT or non POT texture, and melonJS is now only throwing an exception when using the repeat/wrap mode with non POT texture (else it's just a warning, and the wrap mode is force to Clamp) And so, since I don't have a Linux machine to test it, would you mind giving it a try to see if there are any changes or improvements ? the latest build is available here : https://melonjs-builds.s3.amazonaws.com/index.html?prefix=artifacts/master/2292/build/ (there are no API changes, so it's just a basic drop replacement) Last but not least, after working on my macbook today (as I'm travelling) and comparing both renderer, I must say that it's really way faster with the WebGL one (2ms to draw a frame with the platformer example, vs 5ms with the canvas Renderer!). Goes without saying I know, but I tend to forget how faster it its :P:P:P thanks ! Oliver.
  22. obiot

    melonJS 6.0.0 release

    @can2nac interesting especially since it's used to detect when rendering on software.... In theory when true and on low performance machine this should force melonJS to swith to the Canvas Renderer : do you mean that in your case it still use the WebGL Renderer but then display the same errors as reported by @TheBoneJarmer ? And when set to false, it all works but with lower performances compared to Canvas (which would make sense actually) ? About the performance difference a few things can quickly degrade perf under WebGL, like too many texture (texture packing is definitely recommended also anyway with Canvas), non POT Texture, and especially standard web font (bitmap font is highly recommended if you don't use them already).
  23. obiot

    melonJS 6.0.0 release

    wow sure, that would be fan-tas-tic !
  24. obiot

    melonJS 6.0.0 release

    Constructive and positive criticism is always welcome, and you actually exactly put your finger where there is a need for improvements
  25. obiot

    melonJS 6.0.0 release

    Which browser are you using ? Chrome ? But we do indeed have known issues with our WebGL implementation and some configuration (GPU) on Linux based platforms. Unfortunately, none of us have a Linux machine to actually debug it, nobody came up with a fix or patch for it, and to be honest sinceLinux based Desktop account for less than 2 percent of total users, it's pretty low in my priority list