Hi!
The following trigger is supposed to create a floating text over a unit every 10 seconds, but only as long as the unit is on the map. For some reason the floating text is created in the center of the map in the beginning of the game, even though the condition isn't fulfilled (nobody has got the unit yet). As soon as a player gets the unit, where the text is supposed to be, the problem is solved and the text is displayed at the correct position.
Regards,
McLovin
The following trigger is supposed to create a floating text over a unit every 10 seconds, but only as long as the unit is on the map. For some reason the floating text is created in the center of the map in the beginning of the game, even though the condition isn't fulfilled (nobody has got the unit yet). As soon as a player gets the unit, where the text is supposed to be, the problem is solved and the text is displayed at the correct position.
-
Eriks Tower
-
Events
- Time - Every 10.00 seconds of game time
- Conditions
-
Actions
- Set Temp_Group = (Units of type Gåård's Cubade Morsa (Erik))
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
- ((Playable map area) contains (Random unit from Temp_Group)) Equal to True
-
Then - Actions
- Floating Text - Create floating text that reads Eriks_Tower[(Random integer number between 1 and 14)] above (Random unit from Temp_Group) with Z offset 0.00, using font size 7.00, color (100.00%, 0.00%, 0.00%), and 0.00% transparency
- Wait 5.00 seconds
- Floating Text - Destroy (Last created floating text)
-
Else - Actions
- Do nothing
-
If - Conditions
- Custom script: call DestroyGroup (udg_Temp_Group)
-
Events
Regards,
McLovin
Last edited by a moderator: