Hello.
I'm developing a new game and I thought I'd share some code with you guys. I created a class for a puzzle quest-like match-3 grids. I thought maybe somebody would be interested so I'm uploading it here.
It's pretty stable. Instructions:
press 'c' to generate a new grid
press 'd' to clear the first set of matches
press 'a' to show a list of the matches currently possible
press keyboard number keys '1' through '6' while hovering over a tile to change it's color
left-click tiles to swap tiles (matches clear automatically after first clear or first swap)
That's pretty much it. Here's a .gif:
Enjoy.
Match 3 demo
- CaptainMaelstrom
- Party member
- Posts: 163
- Joined: Sat Jan 05, 2013 10:38 pm
Match 3 demo
- Attachments
-
- pquestclone.love
- canvas/one-click swap fixed (match 3 demo) .love
- (21.39 KiB) Downloaded 290 times
Last edited by CaptainMaelstrom on Tue Sep 30, 2014 3:27 am, edited 6 times in total.
Re: Match 3 demo
Code: Select all
Error
scripts/grid.lua:32: Cannot create canvas: Error in implementation. Possible fix: Make canvas width and height powers of two.
But ty for the code i'll see if i can get working on my crappy machine :p
Re: Match 3 demo
This error is related to your graphics adapter. Especially many old Laptop/Netbooks don't support canvas.
I usually avoud using canvas alltogether to maintian compatibility. There's almost always a way around canvasses.
Anyway, the game plays quite nice it has the same addiction factor but it doesn't one money from you like some similar game.
Maybe you should consider making the dots dragable, so you don't have to click twice everytime.
I usually avoud using canvas alltogether to maintian compatibility. There's almost always a way around canvasses.
Anyway, the game plays quite nice it has the same addiction factor but it doesn't one money from you like some similar game.
Maybe you should consider making the dots dragable, so you don't have to click twice everytime.
- CaptainMaelstrom
- Party member
- Posts: 163
- Joined: Sat Jan 05, 2013 10:38 pm
Re: Match 3 demo
Thanks guys. I got rid of the canvas part of the code and I made one-click tile-swapping possible. Those are both good suggestions.
Who is online
Users browsing this forum: No registered users and 3 guests