Search the Community
Showing results for tags 'Points'.
-
Hi, I'm new to the babylon.js. I've worked with Three.js and it was an awesome library. But I've realized that I cannot generate a mesh with points easily and there were limitations. Is there a feature in Babylon.js to generate a triangulated mesh with a pointcloud? You can view a sample pointcloud here. It's just a curved surface for the simplicity and a Three.js model. I just want to make know if this is possible to do with babylon.js https://codepen.io/brabbit640/pen/ZmpKpJ Thank you
- 2 replies
-
- babylon.js
- meshing
-
(and 1 more)
Tagged with:
-
I would like a timer to display in the top right of the game window. the time to be counting up in seconds . milliseconds to the 3rd decimal ( 00.000 ). i've found lots of examples to show an event on timer but not to just keep track of the game time and display. I'm assuming I need something in the update function to keep the time updating but not sure what. vaultage.game = function() {}; vaultage.game.prototype = { create : function() { // timer this.timer = game.time.create(); this.game.add.text(20, 700, this.timer,{ font: "10px Raleway"} ); this.timer.start(); }, update : function() { }, shutdown : function() { }, }
-
Hello! I am making my first ever game and am having trouble getting my character to lose points. In the game, the character can collect two types of bottles. One of them rewards them points, while the other one I want to take away points. However, after doing the codes, my character is still getting points from collecting the wrong bottles (the ones that should take points away) This was the code I am using to take points from the player (it is in the update function) function collectbottle (player, bottle) { // Removes the bottle from the screen bottle.kill(); // Subtract and update the score score -= score -1; scoreText.text = 'score: '-score; } Anyone have tips or ideas of how to fix? Thank you!
-
Hey all, My first problem I am trying to address is drawing a curved line through a set of points. I cannot seem to find this feature anywhere in the documentation (graphics or bitmapData). I am trying to use this curve as the top part of a polygon, which I intend to fill with a texture. Can anyone point me in the right direction here? Thanks!
-
I'm having a problem rendering phaser points after adding an animated sprite. I have created a screen full of stars and they are initially rendering as I would expect: Now if I add an animated sprite to the center of the world: rocketStarShip = this.game.add.sprite(this.game.world.centerX, this.game.world.centerY, 'rocketstarship'); rocketStarShip.anchor.setTo(0.5,0.5); rocketStarShip.scale.setTo(1.0, 1.0); rocketStarShip.animations.add('fly'); rocketStarShip.animations.play('fly', 3, true); My stars render into the lower right quadrant of the canvas: But if I turn on debug for Points: this.game.debug.renderPoint(starPoint, 'rgb(197,193,170)'); I can see that my Points are still rendering into the full screen: I'm not sure if I have a bug, or if I have a fundamental problem in understanding Phaser coordinates. I've put up a test demo at :http://rocketstar.comxa.com/Test/ Click the screen to rotate thru example states. Thanks for taking a look. I'm having a ton of fun with Phaser. Shawn Blessing Rocket Star
- 9 replies
-
- world coordinates
- animation
-
(and 2 more)
Tagged with: