julacariote

Members
  • Content Count

    25
  • Joined

  • Last visited

About julacariote

  • Rank
    Member

Profile Information

  • Gender
    Not Telling
  • Location
    Paris, France
  1. If anyone is interested in this issue, this is a bug in Firefox. Follow discussion here: https://bugzilla.mozilla.org/show_bug.cgi?id=1481406
  2. If anyone is interested in this issue, this is a bug in Firefox. Follow discussion here: https://bugzilla.mozilla.org/show_bug.cgi?id=1481406
  3. Hello, I tried to run this example https://pixijs.io/examples/#/basics/video.js with a video of mine (testVideo.mp4 returns a 404). On desktop, it works perfectly fine. But on Firefox Android, I got this error in the console: NS_ERROR_NOT_AVAILABLE. How can I make this example run on Firefox Android? Any ideas of what could be wrong? Thanks!
  4. Juste a little up...? I tested this page on a friend's phone and same result, so my device is not in cause here... And by the way, even loading a video without the "blob" mode fails too: https://phaser.io/examples/v2/video/play-video
  5. Hi everyone, I want to play a video loaded as a blob in my phaser game but unfortunately, this feature seems to be broken on Firefox Android (v.62). It does work on desktop and on Chrome mobile though. If I try to load this example page https://phaser.io/examples/v2/video/load-as-blob in Firefox Android, I got these messages displayed in the console: // I don't now if it is relevant to this problem? Error: WebGL warning: Failed to create WebGL context: WebGL creation failed: * Requires vertex_array_object. * Exhausted GL driver options. phaser.js:60447:25 Error: WebGL warning: Failed to create WebGL context: WebGL creation failed: * Requires vertex_array_object. * Exhausted GL driver options. phaser.js:60452:20 // And just after Phaser v2.6.2 | Pixi.js v2.2.9 | Canvas | WebAudio | http://phaser.io phaser.js:34896:8 NS_ERROR_NOT_AVAILABLE: phaser.2.6.2.min.js:7 b.Sprite.prototype._renderCanvas phaser.js:15357:8 b.DisplayObjectContainer.prototype._renderCanvas phaser.js:14662:4 b.DisplayObjectContainer.prototype._renderCanvas phaser.js:14662:4 b.CanvasRenderer.prototype.renderDisplayObject phaser.js:22308:69 b.CanvasRenderer.prototype.render phaser.js:22219:21 updateRender phaser.js:35424:25 update phaser.js:35316:38 updateRAF phaser.js:61331:22 start/this._onLoop phaser.js:61295:29 The same issue arises with Phaser CE v2.11.0 Can anyone reproduce this issue? May-be it's just my phone (Samsung Galaxy S5 Mini)? If not, do you have any idea where this problem comes from? It looks like something goes wrong when Pixi tries to draw the video frame on the canvas... Thanks!
  6. You're right, it works. Something is wrong in my code then... Sorry for that. Thanks!
  7. Yes, indeed but the code you posted is from the BitmapText class. I just use the Phaser.Text class and setting a new text by doing text.text = "new text" does not work... /** * The text to be displayed by this Text object. * Use a \n to insert a carriage return and split the text. * The text will be rendered with any style currently set. * * @name Phaser.Text#text * @property {string} text */ Object.defineProperty(Phaser.Text.prototype, 'text', { get: function() { return this._text; }, set: function(value) { if (value !== this._text) { this._text = value.toString() || ''; this.dirty = true; if (this.parent) { this.updateTransform(); } } } }); It seems to me that the updateTransform method is a Pixi function for position/rotation computations only.
  8. Hello, I have a text which is added to a sprite. If I call setText on this text to update it, it won't work because if I understand well, a sprite doesn't call update on its children: https://github.com/photonstorm/phaser/issues/1066: I need this text to be inside a sprite and to be updated on user input. How could I achieve that? I naively tried to manually set the dirty attribute to false on the text and calls its update method but it doesn't work...
  9. Thanks you very much for your suggestions. I should get it done now !
  10. Hi there, Is there any build-in way to make a text behave like if it had the CSS "overflow: hidden" property? Basically, I have a long text I want to write on a single line but I want any characters beyond a certain width hidden. Thanks!
  11. You're right, it's an issue related to the size of my sprite. It works now . Thank you!
  12. The blue block appears in front of the red one but there is flickering. I will check on the tile size as soon as I get some free time.
  13. Hello, I work on a project using @lewster32's isometric plugin. By the way, thank you very much lewster32 for this, it's really a huge add-on to Phaser . I have an issue with the topological sort: as you can see on the screenshot, the robot sprite should be drawn on top of the switch. I don't know what I'm doing wrong, could anyone help me? All the sprites used here are from separate pictures and the sprites edges are the same as the pictures (I mean there is no blank area in the pictures except in the corners). Thanks! The code: window.onload = function() { var game = new Phaser.Game(480, 260, Phaser.AUTO, 'test', null, true, false); var BasicGame = function (game) { }; BasicGame.Boot = function (game) { }; var isoGroup, isoGroup2, tilesMap, tilesMap2; var TILE_SIZE = 33; BasicGame.Boot.prototype = { preload: function () { game.load.image('tile_floor', 'assets/rust-sprites/tile_floor.png'); game.load.image('alt_robot', 'assets/rust-sprites/enemy_resized.png'); game.load.image('switch', 'assets/rust-sprites/tile_power_supply.png'); game.load.image('block', 'assets/rust-sprites/tile_block.png'); game.time.advancedTiming = true; game.plugins.add(new Phaser.Plugin.Isometric(game)); game.iso.anchor.setTo(0.5, 0.25); }, create: function () { // the floor isoGroup = game.add.group(); this.spawnTiles(); // elements on top of the floor (red switch, blue blocks and the bot) isoGroup2 = game.add.group(); this.spawnTiles2(); // -26 is to center the bot in the middle of a floor tile this.bot = game.add.isoSprite( TILE_SIZE * 3 - 26, TILE_SIZE * 5 - 26, 0, 'alt_robot', 0, isoGroup2 ); this.bot.anchor.set(0.5, 1); game.iso.topologicalSort(isoGroup2); }, update: function () { game.iso.topologicalSort(isoGroup2); }, render: function () { game.debug.text(game.time.fps || '--', 2, 14, "#a7aebe"); }, spawnTiles: function () { tilesMap = [ [0,0,0,0,0,0], [0,0,0,0,0,0], [0,0,0,0,0,0], [0,0,0,0,0,0], [0,0,0,0,0,0], [0,0,0,0,0,0], ]; var tile; for (var j = 0; j < tilesMap.length; j++) { for (var i = 0; i < tilesMap[j].length; i++) { if(tilesMap[j][i] == 0) { tile = game.add.isoSprite(i * TILE_SIZE, j * TILE_SIZE, 0, 'tile_floor', 0, isoGroup); } tile.anchor.set(0.5, 1); } } }, spawnTiles2: function () { // 2nd layer, on top of the first one (height +16px) var HEIGHT = 16; tilesMap2 = [ [0,0,0,0,0,0], [0,5,0,6,0,0], [0,5,0,0,0,0], [0,5,5,5,5,0], [0,0,0,0,0,0], [0,0,5,0,0,0], ]; var tile; for (var j = 0; j < tilesMap2.length; j++) { for (var i = 0; i < tilesMap2[j].length; i++) { if(tilesMap2[j][i] == 5) { tile = game.add.isoSprite(i * TILE_SIZE, j * TILE_SIZE, HEIGHT, 'switch', 0, isoGroup2); } if(tilesMap2[j][i] == 6) { tile = game.add.isoSprite(i * TILE_SIZE, j * TILE_SIZE, HEIGHT, 'block', 0, isoGroup2); } if(tile) tile.anchor.set(0.5, 1); } } }, }; game.state.add('Boot', BasicGame.Boot); game.state.start('Boot');};