HomeUser Control Panel (unavailable in archive)ForumsTutorialsArt GalleryResourcesMaps

Addint Expiration time on the fly

08-05-2004, 06:37 AM#1
Ghost_81st
Is there a way to adda life timer to a unit on the fly?
when I do
Code:
Unit - Add a 30.00 second Generic expiration timer to (Ownership-changed unit)  

It crashes my computer.... anyone have an answer?
08-05-2004, 08:02 PM#2
Dark_Uber
I've had problems with the ownership changed unit funtion so this is what I would do

Set (Ownership Changed Unit) = A variable

They do the fuction for the variable
08-05-2004, 08:08 PM#3
Ghost_81st
Quote:
Originally Posted by Computer[Uber]
I've had problems with the ownership changed unit funtion so this is what I would do

Set (Ownership Changed Unit) = A variable

They do the fuction for the variable

could u try it before u promote it?
besides, that HAS NOTHING TO do with my problem...
Thanks for the friendly tip tho.
08-05-2004, 08:10 PM#4
Vexorian
Try posting the complete trigger that is causing the crash
08-05-2004, 09:28 PM#5
Ghost_81st
Quote:
Originally Posted by Lord Vexorian
Try posting the complete trigger that is causing the crash


Code:
Switch owner
    Events
        Unit - A unit Changes owner
    Conditions
    Actions
        Set Unit = (Ownership-changed unit)
        Unit - Order Unit to Stop
        If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            If - Conditions
                Or - Any (Conditions) are true
                    Conditions
                        (Owner of Unit) Equal to Player 1 (Red)
                        (Owner of Unit) Equal to Player 2 (Blue)
                        (Owner of Unit) Equal to Player 3 (Teal)
                        (Owner of Unit) Equal to Player 4 (Purple)
            Then - Actions
                Set Monster_Amount[1] = (Monster_Amount[1] - 1)
                Multiboard - Set the text for Multiboard item in column 3, row RowNum[10] to (String(Monster_Amount[1]))
                Unit - Add a 60.00 second Generic expiration timer to Unit
                For each (Integer A) from 1 to 8, do (Actions)
                    Loop - Actions
                        Unit Group - Remove Unit from Team1Creep[(Integer A)]
            Else - Actions
                Set Monster_Amount[2] = (Monster_Amount[2] - 1)
                Multiboard - Set the text for Multiboard item in column 3, row RowNum[11] to (String(Monster_Amount[2]))
                For each (Integer A) from 1 to 8, do (Actions)
                    Loop - Actions
                        Unit Group - Remove Unit from Team2Creep[(Integer A)]