Search the Community
Showing results for tags 'Basics'.
-
Hi all! Does anyone know where I might look to find some tutorials regarding best practices (basic phaser 3 game code/file structures) and perhaps some resources on STATES? If I could get some resources for using states in Phaser 3 I would really appreciate it! I keep running into an issue with "game.state.add" being undefined? Basically, if someone could point me to some very basic JS related Phaser 3 tutorials (video or article is fine) I would greatly appreciate it! P.S. A little background on me: Several years of experience using PHP/MySQL, released several text based RPG's, designed an open source CMS and assisted a startup for a little while. I have very little experience/knowledge with Javascript/ECMAScript
-
I am just starting with Phaser and figured I should learn 3 instead of an earlier version. I have created a game, called in a scene, but can't seem to call a simple function. I have made tons of games in Actionscript, so am hoping to make this transition to Phaser easily. I am probably missing something basic or have screwed up something since I am going from 4 different tutorials. lol Any help would be great! When I run this, it gets to line 28 and then says SyntaxError: bad method definition. Help! Oh,... and while I have your attention... Anyone have a particular package for Sublime that helps with Phaser or Javascript? class FactChoice extends Phaser.Scene { constructor() { super({key:"FactChoice"}); } preload() { this.load.image('0', 'assets/images/numbers/0.png'); this.load.image('1', 'assets/images/numbers/1.png'); this.load.image('2', 'assets/images/numbers/2.png'); this.load.image('3', 'assets/images/numbers/3.png'); this.load.image('4', 'assets/images/numbers/4.png'); this.load.image('5', 'assets/images/numbers/5.png'); this.load.image('6', 'assets/images/numbers/6.png'); this.load.image('7', 'assets/images/numbers/7.png'); this.load.image('8', 'assets/images/numbers/8.png'); this.load.image('9', 'assets/images/numbers/9.png'); this.load.image('next', 'assets/images/btnNextLevel.png'); this.load.image('BG', 'assets/images/sky.png'); } create() { console.log("time to make FactChoice"); arraysChosen(); } arraysChosen: function(){ console.log("hey"); } }
-
Hey! I think this is going to be another one of those, "oh right, it's this" sort of questions, but after tinkering with it for far too long, I figured I'd tap into the brain trust that is this forum. I have a cylinder nested inside Epcot Center an icosphere. Both of these will have a mass of zero. Here's the PG: https://www.babylonjs-playground.com/#UGTGRU. Move your mouse over the icosphere—the cylinder positions/rotates along the picked facet/normal. Click the icosphere to enable physics and set the impostors starting with the cylinder, then the icosphere. Notice that the icosphere's rotation jumps Here's what I'm wondering: Since these things aren't supposed to move in my scene (since the mass === 0), how could I go about setting up these physics impostors in such a way that would preserve the rotation/position of the icosphere and the cylinder at the moment it's clicked? Also, what if the impostor hierarchy is three+ levels deep? Also wondering: Could the icosphere and cylinder (parent/child) impostors have different restitution and friction values? Thanks!!
-
Hey guys, I'm thinking there's a really simple answer to this, but I'm currently blanking on it. Basically, I'm trying to position/rotate a cylinder such that it is perpendicular to a given facet. Here's the PG: https://www.babylonjs-playground.com/#U8ZVF8 It looks like it works for facets on part of the sphere (maybe?), but there's clearly something I'm missing. Thanks in advance!
-
Hi guys, I am a new member to this community and entirely new to HTML5 game development. I came across Pandajs on my search for a viable 2D game engine with which I can pick up and excel my skills in HTML5 game development. Thanks to enpu for making this game engine! The below links and examples from github helped me to overcome issues during my initial stages of development. Like adding Sprite, Animations and Containers and also creating Modules and Classes. Even though I was able to achieve these, there are these couple of concepts which I am still unclear of and need help from someone to completely understand. I searched through the forums and also blogs to get some idea, but got lost. Finally I decided to post it here. What I would like to understand is 1. The structure of the game engine. The classification of game.module(), .body(function(){}), game.createScene() and others in it. 2. The relation of game.scene, this.body, shape, world and so on. Is it necessary to have all of these? If so, why? 3. If there is difference between game engine version 1 & 2 with regards to the structure? I would be very happy and thankful if someone can help me clear these doubts. Let me know as to where I can find/read the basics of HTML5 game devleopment, especially on Pandajs. Sorry to ask these questions if it has already been answered in this forum. Links I went through http://www.pandajs.net/cheatsheet/ http://vermeire.home.xs4all.nl/panda/index.html http://www.emanueleferonato.com/2014/03/05/look-at-panda-js-html5-game-engine-capabilities-with-a-working-game-prototype/ http://www.ninjadoodle.com/blog/tag/pandajs/
- 4 replies
-
- beginnersfundamentals
- basics
-
(and 6 more)
Tagged with:
-
Hi, i'm new in game development, so I decide start with some really simple - painting. I'm not sure if my througts are right, so I'll explain it little bit and pls give me feedback. I think painting is simple, so it should works like this: 1) User select color 2) User pick finger/mouse on board 3) In every rate (frame cycle) application add point to canvas and some kind of array(?) Let's move it on hight lvl - add restriction and check if user paint just in canvas 1) User select color 2) User pick finger/mouse on board 3) In every rate (frame cycle) application will check, if current position of finger(mouse) is in canvas 3a) if not show alert and change color of current stroke to red 3b) otherwise add point to canvas and some kind of array - I'll like to move from simple painting to coloring book - are my steps in right direction? Thank you and happy coding!