- Joined
- May 8, 2020
- Messages
- 90
I see some maps have this, I want to ask
Follow along with the video below to see how to install our site as a web app on your home screen.
Note: This feature may not be available in some browsers.
Events

Time - Every 1.00 seconds of game time
Conditions
Actions

Unit Group - Pick every unit in House_Group and do (Actions)


Loop - Actions



Player - Add 100 to (Owner of (Picked unit)) Current gold



Floating Text - Create floating text that reads +100 above (Picked unit) with Z offset 0.00, using font size 10.00, color (100.00%, 100.00%, 100.00%), and 0.00% transparency
Unit Group - Add (Triggering unit) to House_Group
You can just hide it using the Show/Hide function, it takes a Player Group which allows for individual players (group of 1).To hide it from enemy players, you'll need to use the local player utilities to change the value of the text. After creating the floating text, you can say something like if the local player is in a group of Enemies, set the text to empty string. I'm not exactly sure what this would look like in GUI.
Unit Group - Pick every unit in House_Group and do (Actions)
i want when i own 1/4 house of each human/orc/nightelf/undead race then when i have 1 baby dragonHouse_Group is an empty Unit Group:
That line adds units to it.
Unit Group - Pick every unit in House_Group and do (Actions)
So whenever a Player builds a house you would add that to the House_Group. Of course if you don't explain how your map works or give any details at all I can't really do anything but speculate on what you want.
Events

Time - Every 34.00 seconds of game time
Conditions
Actions

Unit Group - Pick every unit in House_Baby_Group and do (Actions)


Loop - Actions



Player - Add 200 to (Owner of (Picked unit)) Current lumber



Floating Text - Create floating text that reads +200 above (Picked unit) with Z offset 0.00, using font size 10.00, color (100.00%, 100.00%, 100.00%), and 0.00% transparency



Floating Text - Set the velocity of (Last created floating text) to 64.00 towards 90.00 degrees



Floating Text - Change (Last created floating text): Disable permanence



Floating Text - Change the lifespan of (Last created floating text) to 4.00 seconds



Floating Text - Change the fading age of (Last created floating text) to 3.00 seconds



Set PlayerGroup = (Player group((Owner of Picked unit)))



Floating Text - Hide (Last created floating text) for (All players)



Floating Text - Show (Last created floating text) for PlayerGroup



Custom script: call DestroyForce( udg_PlayerGroup )
Events

Time - Every 28.00 seconds of game time
Conditions
Actions

Unit Group - Pick every unit in House_Big_Group and do (Actions)


Loop - Actions



Player - Add 500 to (Owner of (Picked unit)) Current lumber



Floating Text - Create floating text that reads +500 above (Picked unit) with Z offset 0.00, using font size 10.00, color (100.00%, 100.00%, 100.00%), and 0.00% transparency



Floating Text - Set the velocity of (Last created floating text) to 64.00 towards 90.00 degrees



Floating Text - Change (Last created floating text): Disable permanence



Floating Text - Change the lifespan of (Last created floating text) to 4.00 seconds



Floating Text - Change the fading age of (Last created floating text) to 3.00 seconds



Set PlayerGroup = (Player group((Owner of Picked unit)))



Floating Text - Hide (Last created floating text) for (All players)



Floating Text - Show (Last created floating text) for PlayerGroup



Custom script: call DestroyForce( udg_PlayerGroup )
Events

Unit - A unit Finishes construction
Conditions

(Level of House Classification for (Triggering unit)) Equal to 1
Actions

Set TempGroup1 = (Units owned by (Owner of (Triggering unit)) matching (Unit-type of (Matching unit) Equal to Big Dragon) and (Matching unit) is Alive Equal to True)

If (All Conditions are True) then do (Then Actions) else do (Else Actions)


If - Conditions



(Number of units in TempGroup1 Greater than 0)


Then - Actions



Unit Group - Add (Triggering unit) to House_Big_Group


Else - Actions



Set TempGroup2 = (Units owned by (Owner of (Triggering unit)) matching (Unit-type of (Matching unit) Equal to Baby Dragon) and (Matching unit) is Alive Equal to True)



If (All Conditions are True) then do (Then Actions) else do (Else Actions)




If - Conditions





(Number of units in TempGroup2 Greater than 0)




Then - Actions





Unit Group - Add (Triggering unit) to House_Baby_Group




Else - Actions



Custom script: call DestroyGroup( udg_TempGroup2 )

Custom script: call DestroyGroup( udg_TempGroup1 )
Events

Unit - A unit Enters playable map area

Unit - A unit Dies
Conditions

(Unit-type of (Triggering unit)) Equal to Baby Dragon
Actions

Set TempGroup1 = (Units owned by (Owner of (Triggering unit)) matching (Unit-type of (Matching unit) Equal to Big Dragon) and (Matching unit) is Alive Equal to True)

Set TempGroup2 = (Units owned by (Owner of (Triggering unit)) matching (Unit-type of (Matching unit) Equal to Baby Dragon) and (Matching unit) is Alive Equal to True)

Set TempGroup3 = (Units owned by (Owner of (Triggering unit)) matching (Level of House Classification for (Matching unit) Equal to 1)

Set BabyDragonCount = (Number of units in TempGroup1)

Set BigDragonCount = (Number of units in TempGroup2)

If (All Conditions are True) then do (Then Actions) else do (Else Actions)


If - Conditions



(BabyDragonCount Equal to 0)



(BigDragonCount Equal to 0)


Then - Actions



Unit Group - Remove all units of TempGroup3 from House_Baby_Group.


Else - Actions



If (All Conditions are True) then do (Then Actions) else do (Else Actions)




If - Conditions





(BigDragonCount Equal to 0)




Then - Actions





Unit Group - Add all units of TempGroup3 to House_Baby_Group.




Else - Actions

Custom script: call DestroyGroup( udg_TempGroup1 )

Custom script: call DestroyGroup( udg_TempGroup2 )

Custom script: call DestroyGroup( udg_TempGroup3 )
Events

Unit - A unit Enters playable map area

Unit - A unit Dies
Conditions

(Unit-type of (Triggering unit)) Equal to Big Dragon
Actions

Set TempGroup1 = (Units owned by (Owner of (Triggering unit)) matching (Unit-type of (Matching unit) Equal to Big Dragon) and (Matching unit) is Alive Equal to True)

Set TempGroup2 = (Units owned by (Owner of (Triggering unit)) matching (Level of House Classification for (Matching unit) Equal to 1)

Set BigDragonCount = (Number of units in TempGroup2)

Unit Group - Remove all units of TempGroup2 from House_Baby_Group.

If (All Conditions are True) then do (Then Actions) else do (Else Actions)


If - Conditions



(BigDragonCount Greater than 0)


Then - Actions



Unit Group - Add all units of TempGroup2 to House_Big_Group.


Else - Actions

Custom script: call DestroyGroup( udg_TempGroup1 )

Custom script: call DestroyGroup( udg_TempGroup2 )
Events

Unit - A unit Dies
Conditions

(Level of House Classification for (Triggering unit)) Equal to 1
Actions

Set TempGroup1 = (Units owned by (Owner of (Triggering unit)) matching (Level of House Classification for (Matching unit) Equal to 1)

Unit Group - Remove (Triggering unit) from House_Baby_Group.

Unit Group - Remove (Triggering unit) from House_Big_Group.

Custom script: call DestroyGroup( udg_TempGroup1 )