[Solved] Region contains region?

Status
Not open for further replies.
Level 18
Joined
Jun 2, 2009
Messages
1,276
Hello. I am trying to detect this one but after many tries i did not make it work.

  • Actions
    • Set TempPoint[0] = (Random point in (Entire map))
    • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
      • If - Conditions
  • I WANT TO DETECT THIS >>> TempPoint[0] NOT IN (REGION THAT I WANT TO ADD)
    • Then - Actions
      • Trigger - Run (This trigger) (checking conditions)
    • Else - Actions
      • Unit - Create 1 Rifleman for Player 12 (Brown) at TempPoint[0] facing (Position of (Triggering unit))
There is point contains region but it not works. Or i do not know how to use it.
 
This doesn't work?

  • (MyRegion) contains (MyPoint) Equal to False // It's in Boolean
Also I think it's safer to use Playable Map Area because I assume Entire Map contains the terrain in the black borders and we can't do anything there
I do not know how to use it.

Region 000 is half of the map. It says NO always.

  • Melee Initialization
    • Events
      • Time - Every 1.00 seconds of game time
    • Conditions
    • Actions
      • Set TempPoint[0] = (Random point in (Playable map area))
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • ((Region centered at TempPoint[0] with size (0.00, 0.00)) contains (Center of Region 000 <gen>)) Equal to True
        • Then - Actions
          • Game - Display to (All players) the text: yes
        • Else - Actions
          • Game - Display to (All players) the text: NO
 
Status
Not open for further replies.
Back
Top