obiot

Members
  • Content Count

    183
  • Joined

  • Last visited

About obiot

  • Rank
    Advanced Member
  • Birthday July 20

Contact Methods

  • Website URL
    http://melonjs.org/
  • Twitter
    melonjs

Profile Information

  • Gender
    Male
  • Location
    Singapore

Recent Profile Visitors

1,908 profile views
  1. added to master : https://github.com/melonjs/melonJS/issues/947
  2. 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
  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. obiot

    Disable respawn on leaving viewport

    Hi, did you progress or find out what is happening ?
  5. 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);
  6. 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 ?
  7. 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
  8. obiot

    registerPointerEvent not emitting in 5.1

    FYI, added it in the boilerplate : https://github.com/melonjs/boilerplate/commit/6b0708dea30fdf15a1a68d8398aa3265feec652b
  9. 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).
  10. 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.
  11. 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.
  12. 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).
  13. 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.
  14. 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).
  15. obiot

    melonJS 6.0.0 release

    wow sure, that would be fan-tas-tic !