MarvinHawkins Posted June 18, 2014 Share Posted June 18, 2014 Hello, I'm new to the forums, and new to Javascript/HTML5 game development. I'm coming from a background of Unity3d using Javascript. I've gone through the Easel.JS tutorials both on the site,and on Youtube. The basics make sense but I'm trying to create a puzzle game similar to Collapse or Candy crush. These games are different than Tetris in that Rows are generated from the bottom. Are there any type of tutorials with example code on how to generate rows? In Unity, I can just Instantiate an enemy. How would I go about instantiating and updating a row? Here's an example of what I'm talking about. https://www.youtube.com/watch?v=X97ANpVxOLY Not looking for Full code, but a push in the right direction would be awesome. How do I incorporate the Tutorials I see for Phaser into Easel.JS? Are frameworks that different? Quote Link to comment Share on other sites More sharing options...
MarvinHawkins Posted June 18, 2014 Author Share Posted June 18, 2014 To specify, here's my thought on how i'd do a row generator 1) Create 2 dimensional array to hold the playfield2) Create a second, 1 dimensional array for the temp row3) Have state that checks if that 1 dimensional array is filled or empty4) If empty, fill with one of 4 blocks at random, and move to next spell5) Push temp row to the playfield (Update playfield array) 6) Push all rows up by 1 Would I need two arrays or would 1 be okay? Also what does a library like Easel or Phaser actually do? Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.