BuckyBoy
12-07-08, 01:21
The code is self-explanatory i think..
-- make localized string
function LOC2(text)
local text2 = LOC(text)
text2[1] = text
return text2
end
MY_OBJECTIVE = {
SetupUI = function()
end,
OnStart = function()
end,
OnComplete = function()
end,
OnFail = function()
end,
Title = LOC2("Get Ready!"),
Description = LOC2("Get Ready for the Next Round."),
Type = OT_Primary,
}
Objective_Register(MY_OBJECTIVE)
Objective_Start(MY_OBJECTIVE, false)
Objective_StartTimer(MY_OBJECTIVE, COUNT_DOWN, 60)
Rule_AddOneShot(DoSomething, 60)
function DoSomething()
Objective_Complete(MY_OBJECTIVE, false)
--
-- some code
--
end
-- make localized string
function LOC2(text)
local text2 = LOC(text)
text2[1] = text
return text2
end
MY_OBJECTIVE = {
SetupUI = function()
end,
OnStart = function()
end,
OnComplete = function()
end,
OnFail = function()
end,
Title = LOC2("Get Ready!"),
Description = LOC2("Get Ready for the Next Round."),
Type = OT_Primary,
}
Objective_Register(MY_OBJECTIVE)
Objective_Start(MY_OBJECTIVE, false)
Objective_StartTimer(MY_OBJECTIVE, COUNT_DOWN, 60)
Rule_AddOneShot(DoSomething, 60)
function DoSomething()
Objective_Complete(MY_OBJECTIVE, false)
--
-- some code
--
end