Warcraft III resources & community, 2003–2006 · archived

Map movement triggering help

4 posts
#1

Map movement triggering help

Ok, basically i am making a map at the moment and in an etempt to cut off numerous triggering time and nursing my sore fingers at the end of the day i have a question for you all. Is it possible to give and order to a unit that when it enters region "A", that it is given a order to move to either region "B" or region "C"? So i need to know is it possible to make a unit randomly move to one of multiple region? Is this possible and if so how would i do this? Help would be greatly appreciated! :D
#2

yep

didnt understand you so i think 2 diff ways may solve ur problem....

if you wanted it to be random to go from either a to b or a to c....

first create a integer variable... and anme it wolf
event - map initialization

action- set wolf[1] = rect 1
action - set wolf [1] = rect 2

event - unit enters rect 1

conditions - XXXXXXXXXXXX


action - set wolf to random number between 1 and 2.....
wait 0.10

if wolf = to 1 then unit- order triggering unit to move to rect 1

if wolf = 2 then unit- order triggering unit to move to rect 1

second way.... ( if u meant it like this )

event - unit enters rect 1

condition - XXXXXXXX

action - unit - order entering unit to move too rect 2
#3

Re: yep

wolf_kid_is_me
action- set wolf[1] = rect 1
action - set wolf [2] = rect 2 <<<< here a 2 ^^



well it could be easier: RandomRect is a rect-variable array

EVENT:

Unit - A unit enters No rect

ACTIONS:

Actions
    Set RandomRect[1] = A
    Set RandomRect[2] = B
    Set RandomRect[3] = C
    Unit - Order (Entering unit) to Move To (Center of RandomRect[(Random integer number between 1 and 3)])
#4
Thanks a ton both of you! I'm gonna have to try this out it should work fine though. Well again, thanks for the help :!: