Search the Community

Showing results for tags 'phaser'.



More search options

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • HTML5 Game Coding
    • News
    • Game Showcase
    • Coding and Game Design
  • Frameworks
    • Phaser 3
    • Phaser 2
    • Pixi.js
    • Babylon.js
    • Panda 2
    • melonJS
    • Haxe JS
    • Kiwi.js
  • General
    • General Talk
  • Business
    • Collaborations (un-paid)
    • Jobs (Hiring and Freelance)
    • Services Offered

Found 3,233 results

  1. Button animation

    Hi, I want to create an animated button, how can i do it? Can i set some animations on the over, up and active states of the button? Thank you
  2. How to apply Filter to entire game?

    I'm really liking Phaser, and am trying out converting a WIP Flixel project. I'd like to do a bloom filter over the whole canvas. What's the best way of going about this? I have a working bloom filter already; I'm just trying to figure out how to apply it to an entire Game or State. Sprites seem to have the filters property, but Game doesn't seem to have an equivalent. I've tried drilling into the Pixi code, but its filters don't seem to be superclasses of Phaser's filters, and I thought I'd ask a question before hacking away any further.
  3. Performances questions

    Hi everyone, Just begining with Phaser, i love the phylosophy and how it works For my game, I'm drawing a big tilemap (100 x 100), adding static objects with no problems. Then I want to add moving objects, so I create a group and add sprites to the group, with a simple velocity. And... it doesn't work very well. It seems like each time a new sprite is attached to the group, the animation stops, then restart, so it's not smooth at all Maybe I'm doing something wrong, but I don't think so (i'm properly destroying objects). I tried with Tweens too, but the result is the same. You can check it here : http://benjans.byethost3.com/city/ Thank you for your help guys!
  4. Hey, We have a 3/4 perspective game running at 800x800 with about 50 32x32 sprites on the screen at one time. After loading our game, within about 30 seconds with movement of our character, the game starts to bog down, shortly hangs, and we receive the error in the Javascript Console: Cannot set property '__next' of null (line 4197 of phaser.js) We are running the dev version of phaser, but have tried with the stable version with no success either. I suspect we just need to optimise our game, but it doesn't seem to be overly complicated - we are surprised that it starts to bog down with only 80 or so sprites on the screen. Any help would be greatly appreciated Thanks
  5. Please tell me, how I can use P2.js physics in phaser framework? Whether there is an example of this? I have seen what p2 files included in sources framework? but I don't know how to call P2 physics in phaser. I would be very grateful for the help)
  6. Hi! I'm wondering how can i and whats the best way to handle some rendering order or some z axis depth? Like if i have a tree in my game and my character walk in front of a tree. It's ok, my character is on the first plan. But if my character walk behind the tree? How can i change the rendering order or the depth? Like this game when you pass behind or in front of houses or trees. http://browserquest.mozilla.org Thank you
  7. Well, I found this just today and didn't remember seeing it in the forum. There is no talking or whatever but hey it's coding experience and it's in nice quality. So if you have intereset and time can check it. Game Development http://www.justin.tv/undeadfavorite/videos p.s. I don't have contacts with author but the videos are public, and I hope he doesn't mind posting them here.
  8. Here is my first try at HTML5 games, built in few weeks with Phaser JS for GitHub Gameoff. Personally, the best "feature" must be randomly generated level, there are couple of errors / corner cases that could do with extra polish. I was planning to add changing level graphics (ie if timer runs out, the level becomes covered with snow etc), but unfortunately ran out of time. Sprites are mine, but all the tiles are from http://opengameart.org/content/gfxlib-fuzed In case anyone feels like giving some coding pointers, the source code is a bit of a mess, a bit of a quickly bash out some code and hope for the best. At first I used global variables to deal with everything, which is OK for simple example program, but not really a working game. Once I got to the enemies, everything is held in individual objects along with helper methods that deal with AI or death animations etc. Links Play [http://webviking.co.uk/github-gameoff/] Source code [https://github.com/vikerlane/game-off-2013] Conclusion I found Phaser JS to be extremely fitting with my own coding style, and in the end I feel pretty confident on how I would tackle my next HTML5 game. On the negative side, I'm not as strong in game art than I assumed I was and it was much harder to actually finish a simple game than it seems when looking at stuff other people put out. On to the next challenge?!
  9. My Super-Generic Newbie Games!

    Hey guys! I'm just getting started in HTML5 development so I thought I'd join up and post what I'm up to. In the last week I've created two super small, generic games, using two different frameworks. They're extremely basic, as I'm still learning the ins and outs of developing plugin-free games! Pixols - TypeScript + Phaser Link: http://2dheroes.com/blog/presenting-power-of-2-1-pixols/ BoxBot - Haxe + OpenFL Link: http://2dheroes.com/blog/presenting-one-day-monday-1-boxbot/ Feedback is more than welcome, and if you have any guidance for a newbie like myself, I'd love to hear it. Cheers!
  10. Hi, I want to change temporary my main character's spritesheet by another one on overlap. When my character overlap a NPC, he will take his spritesheet and inherit of his animations. I tried to change it with Sprite.loadTexture, but it glitch between the frames. How can i handle this? Thank you
  11. Group trouble or Pixi?

    Hi. I use Phaser 1.1.3, and this code gives me this error: Uncaught TypeError: Object TurnGroup has no method 'addChild' at line 10897 Here's the code: <!DOCTYPE html><html lang="en" xmlns="http://www.w3.org/1999/xhtml"><head> <meta charset="utf-8" /> <script src="js/phaser.min.js"></script></head><body><div id="gameContainer"></div><script type="text/javascript">SQ = {};SQ.Game = function(game) { this.game = game;};SQ.Game.prototype = { create: function() { this.turn = new SQ.Turn(this); }};SQ.Turn = function(sq_game) { Phaser.Group.call(this, sq_game.game, 'TurnGroup', true);};SQ.Turn.prototype = Object.create(Phaser.Group.prototype);SQ.Turn.prototype.constructor = SQ.Turn;window.onload = function() { var game = new Phaser.Game(288, 512, Phaser.CANVAS, 'gameContainer'); game.state.add('Game', SQ.Game); game.state.start('Game');};</script></body></html>
  12. All of the attached files within are located in my www root directory wamp folder. phaser.min.js is also included but I am unable to upload it to the forums. Anybody else having this problem? aliengame.html
  13. Sprite body size transform

    Hi, I got my sprite, who is 58 x 74 and i set it body at this.sprite.body.setSize(30, 63, 6, 11);It's a character, so when i press the left button i scale it at -1 in X. But i don't know how i can adjust the body size. There's a screenshot of both position, how can i adjust the left one? Thank you
  14. Text Above Sprites

    Hey guys, Ive have been playing around with Phaser 1.1.3 for the past few days and currently loving its ease of use. There is, however one problem. When I draw text to the game it seems to be drawn below the zombie sprites, I assume this is because the sprite are created and drawn after the text and thus are placed on top. You can see what I mean here: My question it this, is there anyway to make the text drawn on the top and still have the zombies being drawn afterwards (due to spawning code)? Thanks, Eamon
  15. Retina Graphics

    Hi, Does Phaser support supplying high resolution graphics (@2x) for retina displays? I cant find any information on this. If so, how do you go about implementing this? Thanks
  16. Mode Landscape

    I would like my device always display mode landscape the game that I do with phaser, ie that no matter what position move the device, my game always see in landscape position, the question is phaser has some functionality for it? . otherwise as always manages to force the game in landscape mode
  17. Timer Countdown in Phaser ?

    Hello, I would like to know how hard is it to make an accurate timer count down. For example, count down for 1 minute. I would also need to tell player the time left every second. I have heard that setTimeout may not be accurate. What is the best way to do this?
  18. It seems that the TypeScript definition for Phaser.Animation.generateFrameNames is missing. I think that's the problem since the function seems to be in the Phaser JS but I can't use that function in TS.
  19. While trying to get our last game Fip to run on CocoonJS launcher, we noticed that the sound wasn't playing at all. After much investigation we were able to make it play but after making some changes to Phaser (dev branch). The first problem encountered was in Sound.js, inside update() function here: if (this.game.cache.getSound(this.key) && this.game.cache.getSound(this.key).locked){ // console.log('tried playing locked sound, pending set, reload started'); this.game.cache.reloadSound(this.key); this.pendingPlayback = true;}the ".locked" attribute was "undefined" so the sound never reloads. So our first change was inside Cache.js/addSound(), changing this: this._sounds[key] = { url: url, data: data, isDecoding: false, decoded: decoded, webAudio: webAudio, audioTag: audioTag };with this one: this._sounds[key] = { url: url, data: data, isDecoding: false, decoded: decoded, webAudio: webAudio, audioTag: audioTag, locked: this.game.sound.touchLocked };The second problem was in Sound.js/update() at the following line: if (this._sound && this._sound.readyState == 4)the attribute "readyState" is undefined. Changing the previous test to the following fixes the problem: if (this._sound && (this.game.device.cocoonJS || this._sound.readyState == 4))Now the game plays sounds nicely inside CocoonJS launcher Please note, that we didn't try yet to play audiosprites, but just regular sound files (a music actually).
  20. Hi, How can i play right with the acceleration of the velocity? In this tutorial http://www.photonstorm.com/phaser/tutorial-making-your-first-phaser-game (really well done), but it only change the velocity. How can i accelerate it the way a race game works? I want to accelerate it from 0 to a maximum number, or it's current value to a maximum number. How can i do this? What's the best way to handle it and create a maximum speed? Thank you very much guys
  21. On key up event or on release

    Hi, I want to make my character jump, but stop the acceleration in Y when i release the up key. How can i do this? (sorry for the noob question) Thank you
  22. Setting full screen in Phaser

    Hi!, I'd like to ask why setting full screen in Phaser can only be called using the input from the user game.input.onDown.add(gofull, this);function gofull(){ Phaser.StageScaleMode.EXACT_FIT = 0; game.stage.scale.startFullScreen(); alert('full screen');}When calling the function gofull() in the create function or update function, the game doesn't go full. Thanks in advance!
  23. Enhanced physics

    Hi, Is there a way to enhance the framework's physics? like if i have a platform who fall on another one, but they touch just a little, I want the falling one to rotate like real gravity collision. For now, it just stop falling and stay horizontal. How can i do this or how can i enhance it (tutorial on how to create a pahser plugin or extension maybe)? Thank you
  24. Hello, I have found that some website e.g. http://middle-earth.thehobbit.com/ is able to download multiple SVG, PNG, JS files simultaneously (You can use Google DevTool in 'Network' tab to see this) Currently the preload function in Phaser seems to download one file at a time which make loading game slow for graphic/audio heavy game. Is there a way or future plan to make the preload download multiple files simultaneously?
  25. Currently I'm building my games using Haxe / Openfl because I can target Flash, Android, Blackberry adn HTML5 with just one code base. Unfortunatelly despite the fact that Haxe is a marvelous programming language and that Openfl is a great project, I'm having many problems using Haxe so I'm thinking to develop 2 versions of the game: one of them using Haxe / Openfl just for Flash and another version made in HTML5 (with Phaser). Could you please kindly point me tutorials that teach us how to package HTML5 games as native applications (using Cocoonjs, Phonegap, Electra)? I'd appreciate if one could point me tutorials that show not only the integration itself, but how to call native functions (for instace, calling Flurry libray / AdMob libray on Android). Thank you all.