Jump to content

Search the Community

Showing results for tags 'phaser-ce'.

  • 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 13 results

  1. Hi guys I met a very difficult problem, this problem has been bothering me for more than a month My game sometimes has a part of the image rendering can not come out, but its alpha channel rendering is no problem I have no idea about this problem. Does anyone know what caused it? here's my problem: I'm using: phaser 2.13.3 with CANVAS mode dragonbones 5.6.2 electron 5.0.11
  2. Hello, I wanted to share our demo release with you guys. Click & Play: https://tarutarolegends.com/ it can be played in chrome browser and on mobile IPhone7 and newer or comparable Android device. Plus, I hoped you may could help to spread the word, since I am pretty bad with social media. thx https://mobile.twitter.com/weedshaker more info at: https://shoga9team.com/
  3. I wanna create a single animation using multiple sprite sheets that I have, which are a kin da content.
  4. Hello all. I have a problem with Chrome on Android. When I switch to a fullscreen I can get different results: First one (all is ok): The Second one (a white band at the bottom): The third one when I leave fullscreen mode (white band at the top): I use the following code: this.scale.scaleMode = Phaser.ScaleManager.SHOW_ALL; this.scale.fullScreenScaleMode = Phaser.ScaleManager.SHOW_ALL; this.scale.pageAlignHorizontally = true; this.scale.pageAlignVertically = true; this.scale.forceOrientation(true, false); this.scale.enterIncorrectOrientation.add(this.enterIncorrectOrientation, this); this.scale.leaveIncorrectOrientation.add(this.leaveIncorrectOrientation, this); I get such results only in Chrome on Android. Does anybody know why this occurs and how to solve the problem? Any tips would be appreciated!
  5. Hello, This is my first post. I am facing problem on Microsoft Edge. Game is developed using phaser-ce. In @extends Phaser.Game Constructor, i have added all states. on Init, i have started state using this.state.start(stateName) but somehow its not starting the state. As soon as I switch between tabs, it loads the state. On other browsers, i haven't encountered this issue. (I believe its related to focus). Can anyone please help me out? Thanks,
  6. We moved our game from Phaser 2.6.2 "Kore Springs" to 2.10.3 and encountered this error in Firefox and Internet Explorer: IndexSizeError: Index or size is negative or greater than the allowed amount The exception is trown from PIXI.Sprite.prototype._renderCanvas: renderSession.context.drawImage(this.texture.baseTexture.source, cx, cy, cw, ch, dx, dy, cw / resolution, ch / resolution); The arguments are: cx : 803 cy : 899.37 cw : 168 ch : 0 dx : -0 dy : -0.6299999999999955 resolution : 1 Everything was fine in "Kore Springs" but we wanted to take advantage of all the fixes and updates on tilemaps in CE.
  7. So, I feel like maybe what I'm trying to do is very simple and I'm overthinking it, but I've spent the entire day on this and I think I just need someone to put me on the right track or tell me it's not possible. Essentially, I want to use 1 image to mask multiple sprites. I have various panels that look like this (ignore the images used, they're placeholders) In each panel, I intend to have multiple sprites inside of it. Technically, it works. Here is the first "layer" of the sprite that overlaps the red panels. This works too, as intended. It is currently stacked like: - Background image - Red panel SO, the issue comes in when I want to mask more images on top. Again, it technically works... but I guess the issue is that the red panel is still being used to create the mask (which is technically what's supposed to happen), but it's not what I was intending. (I'm providing images because I'm terrible at explaining, sorry). In this image below, it's become stacked like - Sprite B - Red Panel - Sprite A - Red Panel - Background image - Red panel What I need to happen is for the red panel to act as the mask for multiple sprites. Is this possible? I've been doing some reading and searching and should I be using a polygon mask? Below is the code I made for this. Hopefully it makes some sense. Please excuse the mess //Call this in every state for now, but maybe we can make it universal var panelsJSON = this.cache.getJSON('panels'); var testpage = this.cache.getJSON('testpage'); console.log(panelsJSON); console.log(testpage); for (i = 0; i < Object.keys(testpage.pages).length; i++) { //This loop is for building pages //sets the background of the page this.add.sprite(0, 0, testpage.pages[i]["bg"]); //sets a temporary variable that stores the panels var panels = testpage.pages[i]["panels"]; for (a = 0; a < panels.length; a++) { //This loop is to piece together each panel on each page //setting variables for each panel var type = panels[a]["type"]; var sprites = panels[a]["sprites"]; var panelBg = panels[a]["bg"]; //setting variables for panel types var panelWidth = panelsJSON.action[type]["width"]; var panelHeight = panelsJSON.action[type]["height"]; var panelPositionX = panelsJSON.action[type]["positionx"]; var panelPositionY = panelsJSON.action[type]["positiony"]; //Setting bitmap data for panel based on which type panelsJSON.action[type]["bitmapData"] = this.make.bitmapData(panelWidth, panelHeight); var bitmapData = panelsJSON.action[type]["bitmapData"]; //setting panel bg using the bitmap data panelsJSON.action[type]["alphaMaskBg"] = bitmapData.alphaMask(panelBg, type); var alphaMaskBg = panelsJSON.action[type]["alphaMaskBg"]; this.add.sprite(panelPositionX, panelPositionY, alphaMaskBg); for (s = 0; s < sprites.length; s++) { //This loop is for each sprite included in each panel including characters and objects //The problem is I'm using the bitmapData variable here again, which masks the sprite based on the red panel, which is the problem. var spriteName = sprites[s]["name"]; panelsJSON.action[type]["alphaMaskSprite"+s] = bitmapData.alphaMask(spriteName, type); var alphaMaskSprite = panelsJSON.action[type]["alphaMaskSprite"+s]; this.add.sprite(panelPositionX, panelPositionY, alphaMaskSprite); } } } At some point, I thought maybe if I use the alphaMaskBg variable that I created as the alphamask data would create the effect I wanted, but the red panels still plagued me for (s = 0; s < sprites.length; s++) { //This loop is for each sprite included in each panel including characters and objects //The problem is I'm using the bitmapData variable here again, which masks the sprite based on the red panel, which is the problem. var spriteName = sprites[s]["name"]; panelsJSON.action[type]["alphaMaskSprite"+s] = alphaMaskBg.alphaMask(spriteName, type); var alphaMaskSprite = panelsJSON.action[type]["alphaMaskSprite"+s]; this.add.sprite(panelPositionX, panelPositionY, alphaMaskSprite); } My only other thought was to make the red panel images transparent, but that defeats the purpose. Then my next leap of logic was to use phaser to make the red panels transparent, but that probably doesn't make much sense either (if it's even possible). If someone could set me on the right path, it'd be greatly appreciated In the end, I need it to work like: - Sprite B - Sprite A - Background image - Red panel
  8. https://github.com/GrindheadGames/phaser-ce-angular-cli-boilerplate This is a super bare bones, hello world app using Angular-CLI and phaser-ce. Thought someone might find it useful
  9. When adding a rectangle to a p2 body you have the option to specify a rotation in radians for the shape which it appears is just passed directly on to the p2 shape constructor (hence the need for it to be in radians instead of degrees as are used elsewhere in Phaser). I find that if I use any value other than 0 for a rotation, the shape is properly rotated however drawing of the body via the debug parameter ignores the rotation. Here is a quick codepen illustrating the bug. The character should have a long protrusion coming out the bottom achieved with a rotated rectangle. The physics collision seems to indicate that the rotation has occurred correctly, however the debug shape is not drawn rotated. Notice that he appears to sit a little ways off the ground due to the un-rotated debug visualization of the shape. It seems to me this must be a bug (or maybe a limitation of the debugbody drawing system) but I thought I would post here first for thoughts. I will likely dig in and see if I can find a fix / workaround for this. Phaser P2 DebugBody rotation bug (codepen)
  10. Version 2.9.1 (phaser-ce) I'm seeing some unexpected behavior with the physics body of child sprites lagging behind when accelerating the parent. So when debugging the bodies, they appear slightly offset in the opposite direction of the movement: This is the code for an example I made to illustrate my problem: var game = new Phaser.Game({ state: { preload: function() { this.load.baseURL = 'https://examples.phaser.io/assets/'; this.load.crossOrigin = 'anonymous'; this.load.atlas('spritesheet', 'atlas/megasetHD-1.png', 'atlas/megasetHD-1.json'); }, create: function() { this.physics.startSystem(Phaser.Physics.ARCADE); this.createVegetables(); }, update: function() { this.vegContainer.body.acceleration.y = 50 * this.time.physicsElapsedMS; }, render: function() { this.game.debug.physicsGroup(this.melons); this.game.debug.physicsGroup(this.mushrooms); }, createVegetables: function() { // Create veg groups. this.melons = this.add.group(); this.mushrooms = this.add.group(); // Container. this.vegContainer = this.add.graphics(); this.vegContainer.addChild(this.melons); this.vegContainer.addChild(this.mushrooms); const height = 120; const x = 350; for (let y = 0; y > -1000; y--) { let sprite; let isMelon = Math.random() > .5; if (isMelon) { sprite = this.melons.create(x, height * y, 'spritesheet', 'melon'); } else { sprite = this.mushrooms.create(x, height * y, 'spritesheet', 'mushroom'); } sprite.scale.set(3); } // Enable physics on container and all children. this.physics.arcade.enable(this.vegContainer); this.vegContainer.body.maxVelocity.y = 800; } } }); and this is the code pen link. It will work as expected if I accelerate the groups individually but this is not ideal as there are quite a lot of groups in the game. Is this a bug or is it working as expected?
  11. I would like to import the VirtualJoystick plugin into the application ionic3-phaser-ce. ionic-3 phaser-ce project example is here https://github.com/photonstorm/phaser-ce/tree/master/resources/Project%20Templates/ionic-example but I can not add plugins
  12. I would like to import the VirtualJoystick plugin into the application ionic3-phaser-ce. ionic-3 phaser-ce project example is here https://github.com/photonstorm/phaser-ce/tree/master/resources/Project%20Templates/ionic-example but I can not add plugins
  13. When using p2.js bodies have fixedX and fixedY properties which prevents movement on the given axis. It seems to me that when using p2 physics in Phaser-CE I'm unable to access these properties on a sprite body although fixedX and fixedY exist inside the source (here). Am I doing something wrong? I've noticed body.data DOES contain these properties although setting them to true has no effect.
×
×
  • Create New...