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
    • Facebook Instant Games
    • 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

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 3,361 results

  1. MC_CatMaster

    Collisions not detecting with Phaser

    I've started using the Coding with Chrome extension to code Phaser on my Chromebook. I've added gravity and I'm trying to detect when things collide using physics.arcade.overlap(), but the function I provide for when it collides is never called. What I do is I make a matrix of objects and then detect collisions between each of them and the player. I think there's a better way to do this with groups but I'll look into that later. Here's my code: var player, map, mapObjs; map = [['b', 'b', 'b', 'b', 'b', 'b', 'b', 'b', 'b', 'b', 'b', 'b'], ['b', 'b', 'b', 'b', 'b', 'b', 'b', 'b', 'b', 'b', 'b', 'b'], ['b', 'b', 'b', 'b', 'b', 'b', 'b', 'b', 'b', 'b', 'b', 'b'], ['b', 'b', 'b', 'b', 'b', 'b', 'b', 'b', 'b', 'b', 'b', 'b'], ['b', 'b', 'b', 'b', 'b', 'b', 'b', 'b', 'b', 'b', 'b', 'b'], ['b', 'b', 'b', 'b', 'b', 'b', 'b', 'b', 'b', 'b', 'b', 'b'], ['b', 'b', 'b', 'b', 'b', 'b', 'b', 'b', 'b', 'b', 'b', 'b'], ['b', 'b', 'b', 'b', 'b', 'b', 'b', 'b', 'b', 'b', 'b', 'b']]; mapObjs = new Array(map[0].length); var game = new Phaser.Game(768, 768, Phaser.AUTO, 'Unnamed Game'); game.state.add('main', { preload: function(e) { game.load.image('background', '{{ file:background.png }}'); game.load.image('player', '{{ file:download.jpeg }}'); game.load.image('block', '{{ file:Brick_Block.png }}'); }, create: function(e) { if (navigator.userAgent == 'CwC sandbox') {game.time.desiredFps = 30;} var backgroundImage = game.add.image(0, 0, 'background'); backgroundImage.width = 768; backgroundImage.height = 768; player = game.add.sprite(50, 100, 'player'); game.physics.startSystem(Phaser.Physics.ARCADE); game.physics.arcade.enable(player); player.body.gravity.y = 9; player.body.bounce.y = 0.1; player.width = 100; player.height = 100; player.body.collideWorldBounds = true; for(var i = 0; i < map[0].length; i++) { mapObjs[i] = []; for(var j = 0; j < map.length; j++) { mapObjs[i][j] = game.add.sprite(32*i, 300+32*j, 'block'); mapObjs[i][j].width = 32; mapObjs[i][j].height = 32; } } }, input_: function(e) { }, update: function(e) { this.input_(e); for(var i = 0; i < mapObjs.length; i++) { for(var j = 0; j < mapObjs[i].length; j++) { game.physics.arcade.overlap(player, mapObjs[i][j], function(object1, object2) { console.log('hi'); // This never happens for some reason even thought the objects are visibly overlapping player.body.gravity.y = 0; player.body.accelerationY = 20; }, null, this); } } }, render: function(e) { }, }, true); game.state.start('main'); The '{{ file:background.png }}' is just the way that the editor references images so you can ignore it.
  2. Hello everyone. I have built a game using Phaser. On game over, the players high score is recorded in a variable (this.inputScore). To submit their high score to the server, the player clicks a button that takes them to an Index.html page where there is a form they fill in. To avoid cheating, I want the high score variable to be passed from the game's JavaScript file (Game.js) to an input value on the form as a read only value. I have created a function (assignValue) inside the Game.js file to execute this task, but because of it's scope I cannot get the function to be read by the Index.html file. When I place the function at the top of the Game.js script (globally) the Index.html reads the function and executes it accordingly (but with a hard-coded value for testing purposes.) How can I get the Index.html file to read my assignValue() function and pass this.inputScore to the input value in Index.html? Any help would be greatly appreciated - still learning. Thanks. Game.js file: //INDEX.HTML READS THE assignValue function BELOW (WITH A HARD CODED VALUE FOR TESTING) AND //APPLIES IT BECAUSE IT IS IN GLOBAL SCOPE. BUT I NEED THE VALUE TO BE A VARIABLE TAKEN FROM THE //assignValue FUNCTION INSIDE THE GAME CODE. SEE GAME CODE BELOW: function assignValue() { document.getElementById("inputScore").value = 127; }; //GAME CODE var CrystalRunner = CrystalRunner || {}; CrystalRunner.GameState = { init: function() { //...code here }, create: function() { //...code here }, update: function() { //..code here //check if the player needs to die if(this.player.top >= this.game.world.height && this.counter === 0 || this.player.left <= 0 && this.counter === 0) { this.gameOver(); } }, gameOver: function(){ this.game.time.events.stop(); this.player.body.enable = false; //..code here this.updateHighscore(); //..code here }, updateHighscore: function(){ this.highScore = +localStorage.getItem('highScore'); if(this.highScore < this.myScore){ this.highScore = this.myScore; this.inputScore = this.highScore; this.congrats = this.game.add.sprite(this.game.world.centerX-193, this.game.world.centerY-20, 'congrats'); this.congrats.inputEnabled = true; this.congrats.fixedToCamera = true; this.submitScoreButton = this.game.add.sprite(this.game.world.centerX-135, this.game.world.centerY+100, 'submitScoreButton'); this.submitScoreButton.inputEnabled = true; this.submitScoreButton.fixedToCamera = true; this.submitScoreButton.events.onInputUp.add(function() { window.location.href = "index1.php"; }, this); } localStorage.setItem('highScore', this.highScore); }, //THE FUNCTION BELOW IS NOT BEING READ BECAUSE OF SCOPE. HOW TO I MAKE INDEX.HTML READ IT? assignValue: function() { document.getElementById("inputScore").value = this.inputScore; }, }; Index.html file: <?php require_once 'dbconnect.php'; ?> <!DOCTYPE html> <html lang="en"> <head> <title>Crystal Candy Game Login</title> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <link rel="stylesheet" href="css/bootstrap.min.css" type="text/css"/> <link href="css/style.css" rel="stylesheet"> <script type='text/javascript' src='js/jquery-2.2.3.min.js'></script> <script> $(window).on('load', function() { $('#status').fadeOut(); $('#preloader').delay(350).fadeOut('slow'); $('body').delay(350).css({'overflow':'visible'}); }) </script> </head> <body onload="assignValue()" class="bg"> <div id="preloader"> <div id="status">&nbsp;</div> </div> <div class="wrapper"> <div class="texte"> <header> <h1>SUBMIT YOUR SCORE</h1> <img id="logo" src="assets/images/logo.png"> </header> <p>Submit your highscore and you could stand a chance to win a prize!</p> </div> <div id="main"> <form id="form-style" method="post" action="crystalhandle.php" autocomplete="off"> <div class="form-group"> <label class="header-text"><span>First Name</span></label> <input class="form-control" type="text" id="name" name="username" placeholder="Name" title="Please enter your Firstname" required=""> </div> <div class="form-group"> <label class="header-text"><span>Surname</span></label> <input class="form-control" type="text" id="name" name="surname" placeholder="Surname" title="Please enter your Lastname" required=""> </div> <div class="form-group"> <label class="header-text"><span>Email</span></label> <input class="form-control" type="email" id="email" name="email" placeholder="Mail@example.com" title="Please enter a Valid Email Address" required=""> </div> <div class="form-group"> <label class="header-text"><span>Phone</span></label> <input class="form-control" type="tel" id="name" name="phone" placeholder="Phone" title="Please enter your Phone No" required=""> </div> <div class="form-group"> <label class="header-text"><span>Score</span></label> <input class="form-control" type="tel" id="inputScore" name="score" value="" readonly> </div> <!-- I need the above input value to have the variable from assignValue inserted into it--> <div class="w3ls-btn form-group"> <div class="wthreesubmitaits"> <input type="submit" name="signup" id="reg" class="button" id="next1" value="Send" style="font-family: sans-serif; font-size: 17px; font-weight: bold;" </div> </div> </form> </div> </div> <script type="text/javascript" src="js/phaser.min.js"></script> <!--the below js file is where assignValue() is defined:--> <script type="text/javascript" src="js/states/Game.js"/></script> </body> </html>
  3. Hey Guys I have a few eCards created in Phaser. Chrome 66 update has messed up the music and I need these fixed urgently for Christmas. Please help! Check some of the cards out here: https://ekarda.com/corporate-christmas-ecard/ https://ekarda.com/ekarda-gallery/corporate-holiday-ecards/ I think we have around 10 that need fixing. Please contact me initially via: https://ekarda.com/contact with pricing and suggested turn around time. I need this started immediately and completed QUICKLY as we supply cards for Christmas
  4. quiphop

    [WIP] Bumgineer Demo

    Heya everyone! I've just released my game (demo/beta) It's a sci-fi clicker/rpg/point-and-click adventure about the scientist in a parallel dimension It's available on play Market https://play.google.com/store/apps/details?id=com.quiphop.bumgineer Also You can play it in the browser (mobile-friendly) https://quiphop.itch.io/bumgineer It's absolutely free (screw ads!) I'll appreciate any feedback Enjoy! ps: the game made with Phaser. Thank You Rich for ability to create own worlds
  5. Walk without stepping on the line! The time limit is randomly from 15 seconds to one minute. Extend the record as long as possible.Once the walking distance per meter the earth will be saved (it is supposed to be). Even if the earth is safely saved, you will not get items or proceed to the next level. Even so, you should be happy that the earth was saved anyway.If you step on the line the distance is invalid and it will not be recorded. And the Earth will be destroyed once (it is supposed to be!). https://motquu.itch.io/earth-will-be-saved
  6. Hi everyone, Looking for some advice on the approach to coding multiple powerups/upgrades. I have googled how to do this but most answers are in c#/java or based on unity so I have trouble understanding what there doing. I am making a geometry wars/asteroids clone and I am giving the player upgrades when they defeat a boss or reach certain multipliers/kills. The problem is that I am having to change lots of code and using lots of if statements to see if a powerup has been activated then changing the bullet effect and then having to change the collision function for the bullets hitting the enemies so that each powerup does something different. For example in my powerup file (handles bullet changes when new power is activated and powerup pick ups) I add more if statements to the bullet logic to change for example the bullet speed and texture then I go into the file that handles collisions and make changes to the bullet / enemies function so that if the bullet is a fire bullet for example, the enemies particle effect is changed to red from blue. I know there are better ways to do this but I'm not sure how in javascript (or any language) any help would be really appreciated some code: powerups.js (bullet logic handler function for special bullets) const scene = this.scene; const utils = this.utils; const player = scene.player.sprite; if (bullet && utils.playerDied === false) { if(utils.explodingBullet) { if(utils.specialLevel > 1) { utils.bulletSpeedSpecial = 120; } else { utils.bulletSpeedSpecial = 250; } bullet.setTexture('explodeBullet'); } else if(utils.flameBullet) { utils.bulletSpeedSpecial = 75; bullet.setTexture('orange'); if(utils.specialLevelCheck === false) { utils.specialLevelCheck = true; scene.flameEmitter.explode(); } if(utils.specialLevel > 1) { player.setTexture('playerO'); scene.playerTrailEmitter.setFrame(['white', 'orange']); } } else { bullet.setTexture('bullet'); player.setTexture('player'); scene.playerTrailEmitter.setFrame(['white']); } bullet.fire(player, scene.reticle); utils.lastFiredSpecial = time + utils.bulletSpeedSpecial; scene.physics.add.overlap(scene.baddieGroup, bullet, scene.callBacks.shootingBaddies, null, scene);
  7. I have made a map in Tiled and I have a already generated a JSON. Whenever I try to load the map in Chrome and it load only a black screen. When I went to inspect the website there are warning like: No data found in the Json tilemap from Tiled matching the tileset name "RunItUpCity" Cannot create tilemap layer, invalid layer ID given: Bottom Layer TilemapParser.ParseTiledJSON - Layer compression is unsupported, skipping layer 'Bottom Layer' Also, I got an Error that read: Uncaught Type Error: cannot read property 'setCollisionProperty' of null Does anyone think that there is a problem with the map or the code? Here is the JavaScript code if anyone needs it. const config = { type: Phaser.AUTO, width: 800, height: 600, parent: "game-container", pixelArt: true, physics: { default: "arcade", arcade: { gravity: { y: 0 } } }, scene: { preload: preload, create: create, update: update } }; const game = new Phaser.Game(config); let cursors; let player; let showDebug = false; function preload() { this.load.image("tiles", "../assets/tilesets/RunItUpCity.png"); this.load.tilemapTiledJSON("map", "../assets/tilemaps/GetawayCity.json"); // An atlas is a way to pack multiple images together into one texture. I'm using it to load all // the player animations (walking left, walking right, etc.) in one image. For more info see: // https://labs.phaser.io/view.html?src=src/animation/texture%20atlas%20animation.js // If you don't use an atlas, you can do the same thing with a spritesheet, see: // https://labs.phaser.io/view.html?src=src/animation/single%20sprite%20sheet.js this.load.atlas("atlas", "../assets/atlas/atlas.png", "../assets/atlas/atlas.json"); } function create() { const map = this.make.tilemap({ key: "map" }); // Parameters are the name you gave the tileset in Tiled and then the key of the tileset image in // Phaser's cache (i.e. the name you used in preload) const tileset = map.addTilesetImage("RunitUpCity", "tiles"); // Parameters: layer name (or index) from Tiled, tileset, x, y const belowLayer = map.createStaticLayer("Bottom Layer", tileset, 0, 0); const worldLayer = map.createStaticLayer("Top Layer", tileset, 0, 0); const aboveLayer = map.createStaticLayer("Collision Layer", tileset, 0, 0); aboveLayer.setCollisionByProperty({ collides: true }); // By default, everything gets depth sorted on the screen in the order we created things. Here, we // want the "Above Player" layer to sit on top of the player, so we explicitly give it a depth. // Higher depths will sit on top of lower depth objects. worldLayer.setDepth(10); // Object layers in Tiled let you embed extra info into a map - like a spawn point or custom // collision shapes. In the tmx file, there's an object layer with a point named "Spawn Point" const spawnPoint = map.findObject("Objects", obj => obj.name === "Spawn Point"); Also, I will attach the JSON code to the post because it is 17000+ of code. GetawayCity.json
  8. Pilokio

    Phaser 2 Level switching

    Hi all, I have made a game where once the player reaches the end of it a new level should start but I'm not sure how to do this? I have set up multiple states such as a boot, load, game, main menu and the actual game. Is it possible to set up a state so that will switch to level 2 once the goal is reached? Here is my code for reference, any help is appreciated : (the win state takes the player to a menu that congratulates them, this is where I want the player to press a key and the next level can be loaded) //this game will have only 1 state var music; var score = 0; var scoreString = ''; var scoreText; var playState = { //initiate game settings init: function () { //adapt to screen size, fit all the game this.scale.scaleMode = Phaser.ScaleManager.SHOW_ALL; this.scale.pageAlignHorizontally = true; this.scale.pageAlignVertically = true; this.game.physics.startSystem(Phaser.Physics.ARCADE); this.game.physics.arcade.gravity.y = 1000; this.cursors = this.game.input.keyboard.createCursorKeys(); this.game.world.setBounds(0, 0, 360, 700); this.RUNNING_SPEED = 180; this.JUMPING_SPEED = 550; }, //executed after everything is loaded create: function () { this.sfx ={ jump : this.add.audio('jump'), coin: this.game.add.audio('coin') }; music = game.add.audio('lvl1'); music.play(); //Score scoreString = 'Score : '; scoreText = game.add.text(175, 55, scoreString + score, { font: '34px Arial', fill: '#fff' }); scoreText.fixedToCamera = true; this.ground = this.add.sprite(0, 638, 'ground'); this.game.physics.arcade.enable(this.ground); this.ground.body.allowGravity = false; this.ground.body.immovable = true; //Parse the file this.levelData = JSON.parse(this.game.cache.getText('level1')); this.platforms = this.add.group(); this.platforms.enableBody = true; this.levelData.platformData.forEach(function (element) { this.platforms.create(element.x, element.y, 'platform') }, this); this.platforms.setAll('body.immovable', true); this.platforms.setAll('body.allowGravity', false); //fires this.fires = this.add.group(); this.fires.enableBody = true; var fire; this.levelData.fireData.forEach(function (element) { fire = this.fires.create(element.x, element.y, 'fire'); fire.animations.add('fire', [0, 1], 4, true); fire.play('fire'); }, this); this.fires.setAll('body.allowGravity', false); //coins this.coins = this.add.group(); this.coins.enableBody = true; var coin; this.levelData.coinData.forEach(function (element) { coin = this.coins.create(element.x, element.y, 'coin'); coin.animations.add('coin', [0, 1, 2, 3], 8, true); coin.play('coin'); }, this); this.coins.setAll('body.allowGravity', false); //goal this.goal = this.add.sprite(this.levelData.goal.x, this.levelData.goal.y, 'goal'); this.game.physics.arcade.enable(this.goal); this.goal.body.allowGravity = false; //create player this.player = this.add.sprite(10, 545, 'player', 3); this.player.anchor.setTo(0.5); this.player.animations.add('walking', [0, 1, 2, 1], 6, true); this.game.physics.arcade.enable(this.player); this.player.body.collideWorldBounds = true; this.game.camera.follow(this.player); this.barrels = this.add.group(); this.barrels.enableBody = true; this.createBarrel(); this.barrelCreator = this.game.time.events.loop(Phaser.Timer.SECOND * this.levelData.barrelFrequency, this.createBarrel, this); }, update: function () { scoreText.bringToTop(); this.game.physics.arcade.collide(this.player, this.ground); this.game.physics.arcade.collide(this.player, this.platforms); this.game.physics.arcade.collide(this.barrels, this.ground); this.game.physics.arcade.collide(this.barrels, this.platforms); this.game.physics.arcade.overlap(this.player, this.coins, this.collectCoin,null,this); this.game.physics.arcade.overlap(this.player, this.fires, this.killPlayer); this.game.physics.arcade.overlap(this.player, this.barrels, this.killPlayer); this.game.physics.arcade.overlap(this.player, this.goal, this.win); this.player.body.velocity.x = 0; if (this.cursors.left.isDown) { this.player.body.velocity.x = -this.RUNNING_SPEED; this.player.scale.setTo(1, 1); this.player.play('walking'); } else if (this.cursors.right.isDown) { this.player.body.velocity.x = this.RUNNING_SPEED; this.player.scale.setTo(-1, 1); this.player.play('walking') } else { this.player.animations.stop(); this.player.frame = 3; } if (this.cursors.up.isDown && this.player.body.touching.down) { this.sfx.jump.play(); this.player.body.velocity.y = -this.JUMPING_SPEED; } this.barrels.forEach(function (element) { if (element.x < 10 && element.y > 600) { element.kill(); } }) }, collectCoin:function(player, coin){ // Increase the score score += 20; scoreText.text = scoreString + score; this.sfx.coin.play(); coin.kill(); }, killPlayer: function (player, fire) { score = 0; music.stop(); game.state.start('die'); }, win: function (player, goal) { game.state.start('won'); music.stop(); }, createBarrel: function () { //Give me the first dead sprite var barrel = this.barrels.getFirstExists(false); if (!barrel) { barrel = this.barrels.create(0, 0, 'barrel'); } barrel.body.collideWorldBounds = true; barrel.body.bounce.set(1, 0); barrel.reset(this.levelData.goal.x, this.levelData.goal.y); barrel.body.velocity.x = this.levelData.barrelSpeed; } };
  9. Our team is looking for experienced HTML5 developers who are able to join our team immediately as remote freelancers. Duties will range from creating mini games, to full HTML5 games (using Phaser). With this in mind, we need a developer who is dedicated, hard working, extremely knowledgeable and who takes pride in his or her product. The position will start with a few simple minigame projects, and has plenty of room to grow for the right candidate into more work, including full html5 games, conversions and more. Payments are flexible and can be made in fixed, hourly or salary methods. Please note that first we will do a test work with you which will be a fixed pay job. Afterwards we can move to whichever method you would like. Good English speaking and communication is needed so that there is no communication failures. You may be asked to work in some, or all of the following areas. Please note that you do not have to have experience in all of the areas, and that is ok! However, Phaser knowledge is a must. We do not mind people with less experience, they are welcome to apply. Slack: With all projects, we do require a very open communication dialogue. We use Slack for our team conversations. HTML5: You will be converting and/or creating HTML5 games for mobile, tablet, and all platforms. Git Repository: Experience with GIT is a plus, but can train for this. Phaser: Phaser knowledge is a must! You should demonstrate a mastery with all of it’s features, and have titles in your portfolio using the framework. Our games are very small and simple. You will be provided with all the assets and straightforward logic of what has to be done. We concentrate on polish such as tweens, particles and little details that give life to each game. Having an eye for game design and well polished end results are critical! (We can help you achieve it). Once applied, I can explain it to you on what exactly we want here by showing you samples. The three biggest things we look for are excellent communication skills, the ability to not only develop exactly what is given to you, but also contribute new ideas and creative thinking, and finally timeliness. Its absolutely needed that work is always completed on time. Please mention your time zone when applying for the job. Please only apply if you are 100% sure that you can dedicate the time towards it. Please submit your portfolio and hourly wage requirements to jobs by mailing to vivekagrawal57 [at] gmail.com, thanks!
  10. Hello everyone, BlockTanks is a simple and explosive multiplayer tank game. Join other players in a fast-paced and destructive team deathmatch. Collect weapons and defeat the enemy team using strategy, cooperation, or good old-fashioned brute force. Play the game at blocktanks.net Features: Lobby with multiple maps and matches. Power ups like rockets, bombs, and flashbangs. An account system so you can track your stats and level up. Unlockable items such as stickers and decals. Made with Phaser and NodeJS, and hosted on AWS Lightsail.
  11. Hi, I'm new with Phaser, I'm wondering how can I create a group of enemies that appears at the side of the screen in a random Y position between 550px and 745 px, after they appear they need to start to fire to my character Right now I have a function to create the bullets and how they will be fired: createBullets:function(laserToFire,track,offsetX, offsetY, bulletDirection,fireRate,bulletSpeed){ weapon = gameSP.add.weapon(10, laserToFire); weapon.bulletKillType = Phaser.Weapon.KILL_WORLD_BOUNDS; weapon.bulletSpeed = bulletSpeed; weapon.fireRate = fireRate; weapon.trackSprite(track, offsetX, offsetY); weapon.fireAngle = bulletDirection;right } So what I'm looking to do is to have each one of my enemies within the group to fire to my character. Thanks in advance.
  12. https://tibibi.herokuapp.com/ This is a prototype for an HTML5 multiplayer game I'm making. This prototype is actually defunct as I'm now starting up a new game--a 3D multiplayer game, in fact. The data and experienced gained from the development of this prototype will be used for the success of the 3D multiplayer game. Some of the technical aspects: Initially, socket.io was used to establish real-time communication between the client and the server, but the ws WebSocket library was then migrated to. A client-server protocol of binary data is primarily used to share game state between the clients and the server. On the client-side, the Phaser game development framework is used to render the game and perform client-side collision detection. On the server-side, a small and simple custom made game headless game engine made with Node.js is used to manage game state and also distribute the game state to the connected game clients. How to play: To move, use the WASD keys. To shoot, aim with the mouse and press the left mouse button in the direction that you want to shoot in. You can shoot and eliminate other connected players, making them respawn after five seconds.
  13. Game Link: Vocab RPG Vocab RPG is an Online RPG about catching Monsters & collecting Vocabulary Cards! Features: Open world with unique zones to explore MMO: Online multiplayer Monsters: Hunt, battle, and catch many unique monsters! Crafting: Collect different resources and use them to craft items & consumables Language Learning: Unlock vocabulary cards! Currently 4 vocabulary languages to choose from: Chinese, German, Japanese, Russian Overview: In Vocab RPG, you have all the elements of a monster-focused RPG: Hunting, fighting, catching, levelling, crafting, etc. But for every action that you take in the game, it will show you a vocabulary card! As a consequence, the more words you know, the stronger you also become in the game. The game starts very slowly with only 3 words unlocked. But as you progress in the game, you can unlock more cards and expand your vocabulary - at your own pace. Difficulties: To take into account different learning preferences, you can pick your challenge by choosing from 4 difficulty settings: - Normal: Wrong answers reduce your monster's attack or consumables (such as potions) by 25%. - Casual: Even if you answer wrong, you will attack and operate at 100% effectiveness. In other words, you see the cards but there is no consequence for answering wrong. - Hardcore: When you answer wrong, your monster's attack will fail! So answering wrong means 0 damage dealt. - Off: I also want people to enjoy this game, even when they are not really in the mood for studying vocabulary cards right now.... select 'Off' and you will not see any vocabulary cards in the game! Platform: Thanks to the power of Phaser 3, you can play this game on any device in your browser. No installation required. The game is mobile optimized, so whether you play on your laptop or phone / tablet, is only a matter of your preference. Game Link: If you are interested in trying the game, you can jump right into it: Vocab RPG Feedback: Any feedback is much appreciated! We also have a Discord server for the game where players are exchanging ideas, reporting bugs, and giving feedback: Vocab RPG Discord Credits: The game uses a lot of CC0 assets (like the monster sprites in this post) from various artists. I keep a list of all used assets here (which is also accessible from directly inside the game): Credits List
  14. BunBunBun

    gunfight.io

    Hi Everyone, GunFight.io - original HTML5 multiplayer game. Select your team Counter-terrorists or Terrorists and have fun! Play Made with: Phaser + NodeJS server framework - custom version of Colyseus scheduled to add: 1) Multi-language support 2) May be bots? 3) Mobile device support. 4) More emotions. Any suggestion and feedback are welcome.
  15. I'm trying to add a bubble-pop spritesheet animation to my game. I have added other sprites fine, and when I add the sprite for the bubble, everything is still good. However, when I go to add the animations, I get an error, "Cannot read property 'add' of undefined. How can I animate the bubble? var config = { type: Phaser.AUTO, width: 1366, height: 768, parent: "canvas", scene: { preload: preload, create: create} }; var game = new Phaser.Game(config); function preload () { this.load.image('freeplayBG', 'images/freeplay-BG.png'); this.load.image('shark', 'images/nice-shark.png'); this.load.spritesheet('bubblePop', 'images/bubble_pop_under_water_spritesheet.png', {frameWidth: 394, frameHeight: 511} ); } function create() { //Set background this.add.image(685, 384, 'freeplayBG'); //Set shark and make draggable var shark = this.add.sprite(200, 300, 'shark').setInteractive(); this.input.setDraggable(shark); this.input.dragDistanceThreshold = 16; this.input.on('drag', function (pointer, gameObject, dragX, dragY) { gameObject.x = dragX; gameObject.y = dragY; }); //create the bubble sprite var bubble = this.add.sprite(700, 300, 'bubblePop'); console.log(bubble); //Sprite {_events: Events, _eventsCount: 0, scene: Scene, type: "Sprite", parentContainer: null, …} console.log(bubble.animations); // undefined console.log(this) //Scene {sys: Systems, game: Game, anims: AnimationManager, cache: CacheManager, plugins: PluginManager, …} bubble.animations.add('pop'); //error happens here bubble.animations.play('pop', 10, false, true);
  16. Hey all, I'm trying to have a movable character go from no camera follow to camera follow when the game starts, but what happens is that when the camera follow gets called the movement is instant and doesn't look very good. Is there any way to have a smooth rather than instant camera follow transition? Thanks!
  17. Play Cool Math

    Multiplayer Flags Quiz

    Hi Everyone. I present my new multiplayer game Flags of the World Quiz (https://flagsquiz.games) There are 6 game types in the game: Multiplayer (speed game with other players); Find the flag; Choose a country; Quiz; 8 flags; Training. You can login by Facebook, and restore your score data on any mobile devices or computers Mobile Versions:
  18. Justin_Wang123

    Rogue Fable III

    Hello everyone! I've been working on Rogue Fable III for about 4 months now, preparing to bring it onto Steam through early access where development will then continue. Since I'm very nearly ready to make the transition I've released the game in its current form to the web which you can check out at the link below. As with RFII, the game was made using Phaser. All feedback is welcome and appreciated. https://www.kongregate.com/games/Justin_wang123/rogue-fable-iii
  19. Hello! Our team glad to introduce you fresh baked game - Kage: Ninja's Revenge! The game is brand new and was never published before. Main features are: 1. Total cross-platform experience. Every possible resolution is OK! 2. Completely self made everything ! (music, sounds, UI, graphics, code, ideas) Gameplay features: 1. 25+ deisgned levels 2. Every type of enemy and obstacle needs different approach 2. Survival mode 3. 4 exclusive trap style tracks made by our in-house artist You better to check it out by yourself here: http://fluffyfoxgames.com/devninja/ PM me for licensing and rev share offers.
  20. Ananth

    Remove shiftHSL in phaser

    How can i remove or reset shiftHSL if i set to bitmap image
  21. Hello there, I'm working on 2d collision and stumbled across the overlap function. I'm having trouble with something simple. I have an player entity and an npc entity with a physicsGroup set as a collision circle. As the player touches the circle, I want the npc entity to interact in some way. (say, shoots bullets at the player) I can easily listen to any collisions and trigger a boolean to true.. .. but am struggling to find a way to trigger to turn on or off depending on whether the player entity touches the collision circle. For example: Sends a log to console "collided" if player collides. If player doesnt collide, send a log to console "not colliding". Heres my entity code: export const createEntity = (scene) => { entitySprite = scene.add.sprite(487, 249, '') entityPhysicsGroup = scene.physics.add.group({}) entityPhysicsGroup.add(entitySprite) circleShape = scene.add.circle(0, 0, 0, "0xfb00", 0.3) circlePhysicsGroup = scene.physics.add.group({}) circlePhysicsGroup.add(circleShape) circleShape.body.setCircle(128, -128, -128) isTouching = false scene.physics.add.overlap(circleShape, playerSprite, (e) => { isTouching = true }) } I've tried declaring the boolean as false both globally and in the createEntity function. I've also tried this in the updateEntity function that I have. I personally would have thought that a second callback could be used to trigger a function if the player entity stops overlapping with the circle, or just something in general that listens when things are not touching. The boolean method may work but my logic used to implement it might be a little fuzzy. Any thoughts and help would be much appreciated. From a phaser 3 newbie.
  22. I tried out multiple methods and property from the https://labs.phaser.io/index.html?dir=&amp;q= https://photonstorm.github.io/phaser3-docs this both link for the phaser3 but not able to set the width of the perticular text i also try to apply font using css but it also not working for me. Thanks in advance.
  23. How can I use color code to change sprite color without using tint. It have any plugin to change color of sprite using color code. I want to adjust hue,saturation and RGB colors for my sprite.Is it possible with Phaser? - how?
  24. Like the Title says: I would like a game object (one) to become transparent only if another game object (two) is fully covered by the first object (one). What would be the best way about doing this? Thanks!
  25. Ananth

    color wheel

    How to add color wheel in phaser.And how to use it