SOLVED! Game question: Does app inventor have a solution for making irregular selection areas?

Quick map
tl;dr I'm making a game that has irregular areas. Is there a solution within MITAI that would make selecting these areas easier?

Here's what I've thought of so far and the problems I see with each:

  1. Make each area square, then the image itself would be the "hitbox" for the player to choose.
    Problem, that would make an ugly-looking map
  2. Mathematically define each area so that any tap would be evaluated to see if it was within a certain area.
    Problem, I don't know how to do that (yet!) and it sounds like a lot of work.

Flood Fill?

I realize the image shows poorly filled in areas... that is not my question.

My question is more directed at how to select the area in-game. For example if there are missions in different regions, I want the player to be able to select a particular region on the map. This is the nature of my question.

since different section has different color , you can figure out which section selected by the background color.

1 Like

Interesting. I'll look into that and then let everyone know.

Please forgive me, I'm lost. Is there a component that allows you to check the color at a touched point?

image

Usage

1 Like

This app does just that Mountain Kingdom - a chat real time two player, two device game using the CloudDB and a Canvas :astonished: using the color of areas in the Canvas background image.

See this discussion for a detailed explanation Button placement(How to use Canvas screen colors to create a Q&A Quiz

1 Like

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.