Search the Community

Showing results for tags 'pong'.



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

  1. Howdy friends! I'm proud to share my first production WebGL project: https://cash.me/reps (Scroll down to enter the game mode) Uses: GLTF assets Metallic Roughness Physics Camera Movements Force Touch on compatible devices Screenshots: Huge thanks to the community for helping answer my questions as I got up to speed! Especially @Deltakosh @bghgary @donmccurdy and @Wingnut
  2. WholemealDrop

    Trouble with Phaser in Pong like game

    Hey all, just started programming with Phaser and I'm still trying to get the hang of it. I fiddled around with with the sandbox environment and then decided to switch over to Sublime for easier formatting. I had a few issues with my game in the sandbox that I couldn't figure out and was going to be my main question but now my issue is that when I test my game in Chrome/Safari it doesn't display anything. I built it procedurally so I could verify that things were working and the only thing that ever worked was displaying my score and lives counters. In sandbox I had much more working so I can't figure out what is going on. Any tips or tricks that could help me remedy this would be awesome. I've scoured my code and can't find anything wrong but I know how it goes when staring at the same code for hours on end. Forgot to add details about the game. It is a Pong like game where the player has a paddle on the left side of the screen that they can move up and down using the arrow keys. They will use this paddle to block dust particles coming from the right side of the screen from getting by. Here is my .html <!DOCTYPE HTML> <html> <head> <title>dustPong</title> <script type="text/javascript" src="js/phaser.min.js"></script> <style type="text/css"> body { margin: 0;} </style> </head> <body> <h1>dustPong</h1> <script type="text/javascript"> var game = new Phaser.Game(800, 600, Phaser.AUTO, '', { preload: preload, create: create, update: update }); function preload() { //load images game.load.image('paddle', 'images/paddle.png'); game.load.image('bg', 'images/bg.png'); game.load.image('dustParticle', 'images/dustParticle.png'); } //varibales needed for objects var cursors; var paddle; var iWall; var dustParticle; //variables for text var lives = 5; var livesText; var score = 0; var scoreText; var introText; var outroText; function create() { //Display starting lives and score text scoreText = game.add.text(680, 550, 'Score: 0', { font: "20px Arial", fill: "#ffffff", align: "left" }); livesText = game.add.text(32, 550, 'Lives: 5', { font: "20px Arial", fill: "#ffffff", align: "left" }); // Enable p2 physics game.physics.startSystem(Phaser.Physics.P2JS); // Make things a bit more bouncey game.physics.p2.defaultRestitution = 0.8; // Add a sprite paddle = game.add.sprite(100, game.world.centerY, 'paddle', 'images/paddle.png'); paddle.anchor.setTo(0.5, 0.5); // Enable if for physics. This creates a default rectangular body. game.physics.p2.enable(paddle); // Modify a few body properties paddle.body.setZeroDamping(); paddle.body.fixedRotation = true; //player input cursors = game.input.keyboard.createCursorKeys(); //Invisible hitbox for dustParticle to collide with iWall = game.add.sprite(1, 200, 'iWall'); iWall.name = 'iWall'; game.physics.enable(iWall, Phaser.Physics.ARCADE); iWall.body.setSize(1, 600, 1, -200); iWall.body.immovable = true; //create dustParticle, give it random velocity and starting location dustParticle = game.add.sprite(700, Math.floor(Math.random() * (600)), 'dustParticle'); dustParticle.name = 'dustParticle'; game.physics.enable(dustParticle, Phaser.Physics.ARCADE); dustParticle.body.velocity.setTo(Math.floor(Math.random() * (300)+50)*-1,Math.floor(Math.random() * (300)+50)*-1); dustParticle.body.collideWorldBounds = true; dustParticle.body.bounce.set(1); } function update() { //set paddle velocity to zero, only moves with player input paddle.body.setZeroVelocity(); //user controls up/down arrow keys and paddle speed if (cursors.up.isDown) { paddle.body.moveUp(400); } else if (cursors.down.isDown) { paddle.body.moveDown(400); } //collision detection for paddle and iWall game.physics.arcade.collide(paddle, dustParticle, dustpaddleCollision, null, this); game.physics.arcade.collide(iWall, dustParticle, dustiWallCollision, null, this); } //collision call with paddle function dustpaddleCollision (obj1, obj2) { //destroy dustParticle instance dustParticle.kill(); //increment score and display new score score += 10; scoreText.text ='Score: ' + score; } //collision call with iWall function dustiWallCollision (obj1, obj2) { //decrease lives, disply new lives, destroy dustParticle instance lives--; livesText.text = 'Lives: ' + lives; dustParticle.kill(); //when lives = 0, gameover otherwise create new instance of dustParticle if (lives === 0) { gameOver(); } else { dustParticle.reset(700, Math.floor(Math.random() * (600))); dustParticle.body.velocity.setTo(Math.floor(Math.random() * (300)+50)*-1,Math.floor(Math.random() * (300)+50)*-1); } } //gameOver call, displays 'Game over' to user function gameOver () { introText.text = 'Game Over!'; introText.visible = true; } </script> </body> </html>
  3. julio

    WALLBALL

    Game Link: https://bitly.com/wallballgame Instagram: https://www.instagram.com/juliovegaart/ Tumblr: http://juliovegaart.tumblr.com/
  4. bohtm4711

    Pong Quest - Made With Phaser

    Pong Quest is an HTML5 game written using TypeScript and leveraging the Phaser game framework. The IDE used was Intel XDK and the game is now live in all major app stores! Google Play (Android): https://play.google.com/store/apps/details?id=com.mikeboht.pongquest Apple App Store (IOS): https://itunes.apple.com/gb/app/pong-quest/id1109884853?mt=8 Microsoft App Store (Windows): https://www.microsoft.com/en-us/store/apps/pong-quest/9nblggh4vtx9 Facebook Page: https://www.facebook.com/PongQuest Description: A classic pong quest where you journey through a series of unique levels, each with its own little twist. The levels are organized into areas, and each area has a special theme. Includes levels where the walls are closing in, or you use giant paddles, or beach ball sized ping pong balls! Plus boost levels that change paddle and ball sizes and speeds, or explode the ball into 4 balls! And many other unique twists on the classic game of Pong! This version of Pong will keep you guessing as to what unique twist will come next! You can also play 2 player mode against a friend, if you want to take a break from your pong quest! Or you can try out "Randomized" pong mode, where a game will be generated with a completely random set of twists worked into it! Available for both 1 player and 2 player. Enjoy, and please rate the app to show support; more support means more levels, more levels means more fun!
  5. Hi everyone, I just wrote a tutorial on how to remake the classic Pong game in HTML5 and Phaser. It's composed of 7-parts and I try to go as in-depth as possible to explain every single line of code I use. Tutorial Outline Project Setup Loading Assets & Adding Sprites Moving the Ball Adding the Game Mode Moving the Paddles & Adding Collisions Scoring and Resetting Adding Sounds and Wrapping Up Link to tutorial http://www.zekechan.net/getting-started-html5-game-development-pong1/ Source files https://github.com/zekechan/phaser-html5-tutorial-pong I'm also planning to write similar game tutorials on other classic games like: Breakout Space invaders Asteroids If you enjoy the tutorial and would like more I would love to hear your thoughts. Feel free to reply, send me a message, leave a comment on my blog =)
  6. sohardsohumble

    Question/Advice/Issue with pong game (Thank you!)

    Hello all, I'm new here and I am just getting into game development. I created a pong game from scratch (The file and code is attached). The game works and I'm happy with it, except for one little glitch that it has. Sometimes when the ball hits a wall or one of the paddles, it will stick for a moment in time before bouncing away. I know that it has something to do with the way I update the balls location using the variable time. I used this because I followed a quick tutorial for the game loop. Just wondering if someone with more experience could shed some light on this issue and how to get rid of it. Thanks in advance for any help!!! David test.html
  7. RustyMonster

    Rebound

    Just a simple pong-like game that I made in about 3 hours. It slowly speeds up overtime increasing the difficulty. The goal is to last as long as possible. And by "speeds up" I mean literally everything speeds up. It will even start speeding up faster and the score will count faster and the ball will move faster and the padle will move faster. Instructions : 1. Put all the files in the same folder. 2. Put the pictures in a folder called IMAGES 3. Put the sound file in a folder called SOUND Rebound.html Collision.wav
  8. I'm trying to do the pong. And when I want to collisions, I have the following: game.physics.collide (ball, playerBet, ballHitsBet, null, this); ballHitsBet is a function, but it gives me error then the program does not read my function, provides as follows: Uncaught TypeError: undefined is not a function What can be happening?
  9. Hi, I'm learning to make games Phaser, watching a tutorial to create the Pong. For starters, I have to draw all elements in screen, which are ball and two rackets. Failure to draw the ball, the ball is only draws and no draws snowshoes. The code is as follows <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" /> <title>Pong</title> </head> <body> <div id="ejemplo"></div> <script src="phaser.min.js"></script> <script> window.onload = function(){ var game = new Phaser.Game(640, 480, Phaser.CANVAS, 'ejemplo', { preload: preload, create: create, update: update }); var playerBet; var computerBet; var ball; var computerBetSpeed = 190; var ballSpeed = 300; function preload() { game.load.image('bet', 'assets/rocket.png'); game.load.image('ball', 'assets/ball.png'); game.load.image('background', 'assets/backg.png'); } function create() { game.add.tileSprite(0, 0, 640, 480, 'background'); ball = game.add.sprite(game.world.centerX, game.world.centerY, 'ball'); ball.anchor.setTo(0.5, 0.5); ball.body.collideWorldBounds = true; ball.body.bounce.setTo(1, 1); computerBet = createBet(620, game.world.centerY); playerBet = createBet(20, game.world.centerY); computerBet.body.collideWorldBounds = true; computerBet.body.bounce.setTo(1, 1); computerBet.body.immovable = true; } function update () { } //Funciones function createBet(x, y) { var bet = game.add.sprite(x, y, 'bet'); bet.anchor.setTo(0.5, 0.5); bet.body.collideWorldBounds = true; bet.body.bounce.setTo(1, 1); bet.body.immovable = true; return bet; } }; </script> </body> </html> and failure I get is: Uncaught TypeError: Can not set property 'collideWorldBounds' of null In line 39, that is: ball.body.collideWorldBounds = true; Help me please!!
  10. Gan_HOPE326

    [Phaser] qPong

    So here's my first game with Phaser.js... and in fact one of the first ever (at least completed ones, and if we don't count the ascii shooter I made with QBasic in middle school XD). http://gamejolt.com/games/arcade/qpong/28916/ This is qPong - a quantum version of the classical game of Pong, where the ball can be in multiple places at the same time and the outcome of a match is determined by both skill and randomness. I took inspiration from some actual physics (I work as a computational scientist, so I know a bit about this kind of simulations and some of that knowledge leaked into my game design ). The description explains it better... anyway it's pretty lackluster but it has good music (thanks to fellow GameJolt user Qwak) and what I hope is an interesting gameplay. I also plan to try and improve the AI a bit in the near future. Enjoy!
  11. I'm new to using Phaser, and I'm really excited to dig deeper into it. I followed the simple platformer tutorial and looked through the examples. I then began work on adding new sprites and spritesheets to the game, and I'm running into issues. 1. I'm using Shoebox to generate spritesheets exactly like the one found in the multiple anims/seacreatures example. In Shoebox, I use the pivot point tool to set the centroid of each sprite. http://renderhjs.net/shoebox/spritePivots.htm This adds padding to the input png sprites, but when I generate the spritesheet, the padding is cropped, and instead there are the frameX, frameY, frameWidth, and frameHeight parameters in the spritesheet's XML. Ideally, I would just be able to set my anchor to (.5,.5) and the sprite would use the pivot correctly. However, it seems that pivot only respects width and height, not frameWidth and frameHeight. How can I utilize frameWidth and frameHeight in phaser, esp. in relation to setting the sprites anchor? 2. Is pingpong animation looping supported by Phaser yet? The only mention I have found of it was from back in September. This would be a really good feature to have access to. 3. Is there a "Snap to nearest pixel" option for sprites and animations? FrameWidthTest.zip
  12. Ryguy

    PolyPong

    PolyPong - A single-player, powerup-heavy spin on a classic work. Hello everybody, I've haunted to forums for a while and thought I'd begin posting my work here as well. PolyPong is based on some ideas presented in Petri Purho's talk, Juice it or Lose it (http://indiegames.com/2012/05/juice_it_or_lose_it_-_a_talk_b.html). I asked myself, "how far can I push something as simple as Pong?" PolyPong is the result. The premise is simple: use the four paddles to keep the constantly spawning balls on the screen. As the game is played, the player receives new powers which alter the way the game is played. PolyPong is easy to pick up and master in a short time--even for people who are not normally very good at games. Play it here: http://creativeinkgames.wordpress.com/2012/10/24/polypong/ I'd love to know any of your thoughts. Any feedback is greatly appreciated! -Ryan