help with timers??
2 posters
Operation Flashpoint Dragon Rising OFDR Forums :: OPERATION FLASHPOINT: DRAGON RISING :: OFDR EDITING :: EDITING Q+A
Page 1 of 1
help with timers??
tvig0r0us wrote:You will have to use OFP commands. The idea behind the edx is to expand the functionallity of the editor from a coding perspective. As I've put it before, it's like having a toolbench for missions and the edx just puts alot more tools on the bench for you to use. I recommend looking over the documentation I've posted and download the quickstart module to get you going with the edx on the right foot.
Cheers
i dont know how to use the timer properly... if i want the chopper named "mh60" to move to "lz" 15 secs after the player "b1" is on board, how should the script look like? and... it will be much easier if i can just get the chopper to move after the whole fireteam has got in =D but i dunno how to script that =/
nepgeargo- Points : 62
Reputation : 0
Join date : 2013-03-20
Re: help with timers??
did you read my reply about the timers?? they work very much the same way using the OFP prefix except you use the EDX prefix.
this is just a guess at your code.
Now, I say a guess only because you haven't posted an example of what you tried. Hopefully you will be able to translate this into your script. This is a basic example to demostrate the use of the new format for the timers.
Previously we were calling the timer as:
then firing it using
this is just a guess at your code.
- Code:
function onMount(vehicleName,unitName,echelonName)
if vehicleName == "mh60" and unitName == "yourUnit" then
EDX:simpleTimer("mhtakeoff",15000) -- we call the event here
end
end
function mhtakeoff() --This is known as an event handler which is what is now used to fire Timers.
EDX:deleteTimer("mhtakeoff")
OFP:move("pilot","lz","ADDTOFRONT")
end
Now, I say a guess only because you haven't posted an example of what you tried. Hopefully you will be able to translate this into your script. This is a basic example to demostrate the use of the new format for the timers.
Previously we were calling the timer as:
- Code:
OFP:addTimer("myTimer", 15000)
then firing it using
- Code:
function onTimer_myTimer()
OFP:removeTimer("mytimer")
my code etc.
end.
Operation Flashpoint Dragon Rising OFDR Forums :: OPERATION FLASHPOINT: DRAGON RISING :: OFDR EDITING :: EDITING Q+A
Page 1 of 1
Permissions in this forum:
You cannot reply to topics in this forum
|
|