Jump to content

Search the Community

Showing results for tags 'playback'.

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • HTML5 Game Coding
    • News
    • Game Showcase
    • Facebook Instant Games
    • Web Gaming Standards
    • Coding and Game Design
    • Paid Promotion (Buy Banner)
  • Frameworks
    • Pixi.js
    • Phaser 3
    • Phaser 2
    • Babylon.js
    • Panda 2
    • melonJS
    • Haxe JS
    • Kiwi.js
  • General
    • General Talk
    • GameMonetize
  • Business
    • Collaborations (un-paid)
    • Jobs (Hiring and Freelance)
    • Services Offered
    • Marketplace (Sell Apps, Websites, Games)

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


Website URL


Twitter


Skype


Location


Interests

Found 4 results

  1. So I'm running into this problem where I initialize a sprite with multiple animations, but only the animation specified in the creation of the sprite is ever played. When I attempt to update the sprite with a new animation, it simply changes the framerate. I have debugged the game to see if it is actually updating the currentAnim, and it is. Also, I have tested the other animations too see if they loaded correctly by inputting them into the initializing sprite animation. Now, code: player = this.game.add.sprite(400, 400, 'player_idle'); this.game.physics.p2.enable(player, false); player.body.fixedRotation = true; player.animations.add('player_idle'); player.animations.add('player_left'); player.animations.add('player_right'); controls.left.onDown.add(() => { console.log("Begin left: " + player.animations.currentAnim.name); player.animations.play('player_left', 14, true); console.log("End left: " + player.animations.currentAnim.name); }, this); controls.right.onDown.add(() => { console.log("Begin right: " + player.animations.currentAnim.name); player.animations.play('player_right', 14, true); console.log("End right: " + player.animations.currentAnim.name); }, this); update() { player.body.setZeroVelocity(); controls.up.isDown ? player.body.moveUp(200) : null controls.down.isDown ? player.body.moveDown(200) : null controls.left.isDown ? player.body.moveLeft(200) : null controls.right.isDown ? player.body.moveRight(200) : null if(!controls.left.isDown && !controls.right.isDown && !controls.up.isDown && !controls.down.isDown) { player.animations.play('player_idle', 3, true); } } I am using "[email protected]". I need some help. Thank you a bunch.
  2. Hi, I'm having some issues trying to load and display an MP4 video in a sprite, which also need to loop endlessly. I'm using the loader class in order to be sure that the video is loaded. The video is loaded and I don't get any errors, but the video is not showing. Then I try using the code from the samples page and I can hear the video, but I can't see it (codepen sample line 53 through 78, comment out the other code first). Also I want to loop the video and I used the code I found in this issue: https://github.com/pixijs/pixi.js/issues/1872 But this code doesn't returns the HTML video element: var video = texture.baseTexture.source; So it doesn't have a loop property on it. To confuse me even more, I tried the loader code with a newest version (currently working with 4.0.3) and from version 4.1.0 and up I'm getting errors when I try to create the video texture: Uncaught TypeError: source.addEventListener is not a function(…) pixi.js:23585 In that case all I have in the loader callback is this: function loaderComplete(){ console.log( videoLoader.resources.testVideo ); // on load complete create the video texture var videoTexture = PIXI.Texture.fromVideo(videoLoader.resources.testVideo); } And also tried to create a video base texture but I get the same error. Here is a simple codepen sample: http://codepen.io/rhernando/pen/a556304479d6a44bfa5b698e40b18307/?editors=0010 As you can see I'm not getting any errors on loading the video, and the video is actually loading. In fact I added an image to the loader and I had no problems with that. The issue appears with the video. Thanks, Rodrigo.
  3. Hi all, So I'm trying to add background music to my game, and I've provided phaser with a .ogg and a .mp3 file so it has a fallback. Problem is, the audio doesn't play/load at all in Google Chrome (latest build). In Firefox the audio is working fine for me. I've looked at some examples on examples.phaser.io and added the audio the same way they did there, like this: game.load.audio('backgroundMusic', ['assets/audio/TakingFlight.mp3', 'assets/audio/TakingFlight.ogg']);Later in the javascript I play the music using this code: backgroundMusic = game.add.audio('backgroundMusic');backgroundMusic.play('', 0, 1, true);Any suggestions / ideas? I've added the mp3 file of the background music in this post, wasn't allowed to upload the ogg.. TakingFlight.mp3
  4. Hello! I was wondering if there are any nifty ways to mute SFX and music separately? This can be achieved with Web Audio API easily by using separate gainNodes for each type of sounds, but I'd rather have a more compatible solution. Apparently Rich is working on an overhaul of the sound system in Phaser, but does the overhaul possibly cover audio grouping? -V
×
×
  • Create New...