Rexrainbow Board series tutorial #2 Match Detection

5
  • 19 favourites

Index

Attached Files

The following files have been attached to this tutorial:

.png
.capx

Stats

7,127 visits, 15,079 views

Tools

License

This tutorial is licensed under CC BY 4.0. Please refer to the license text if you wish to reuse, share or remix the content contained within this tutorial.

Chapter 3. L-shape Match

~~~~~~~~~~~~~~~~~~~~~

It's ultra simple to detect an L-shape matched pattern, we just need to define what 2D pattern we want in <Matcher>-><For each 2D pattern> event. Add the following codes:

It looks weird in editor because newline will not be shown in event list. Below is the detailed information for the 1st condition in Event#8:

We can see in the parameters dialog that the template defines a wildcard patter in an horizontal mirrored L-shape:

Event#9 ~ 10 defines the rest 3 rotated L-shape template patterns to make the detection complete. Push <F4> to run layout. Congratulations! Now you've finished your match-3 game core logic with only 11 events!

In next tutorial we will teach you how to really delete the matched chess, let floating chess drop down, and inser a new line.

Hope you'll like this tutorial, see you soon!

Tutorial part 3 is here

.PNG
.CAPX
  • 0 Comments

  • Order by
Want to leave a comment? Login or Register an account!