Home
Intel Depot
Editors Depot
Missions Depot
Addons Depot
Forum
Home
Help
Search
Login
Register
OFPEC Forum
»
Editors Depot - Mission Editing and Scripting
»
OFP - Editing/Scripting General
(Moderators:
h-
,
savedbygrace
,
Gruntage
) »
Radar
« previous
next »
Send this topic
Print
Pages: [
1
]
Go Down
Author
Topic: Radar (Read 2164 times)
0 Members and 1 Guest are viewing this topic.
Hartza
Guest
Radar
«
on:
25 Aug 2002, 22:30:11 »
Hi!
Is it possible to create system which observates how high plane(s) is flying
I am trying to make mission where pilots should fly under radar and that way not to be discovered by enemy airforce.
If they fly too high, enemy is alerted ... :joystick:
Logged
seanver
Guest
Re:Radar
«
Reply #1 on:
25 Aug 2002, 22:47:31 »
Create a script:
#loop
? (position
plane
select 2) >
x
: goto "high"
; Put the max altitud instead of x
goto "loop"
#high
hint "What a pilot! You even can't fly below that height!"
alarm=true
exit
«
Last Edit: 25 Aug 2002, 23:09:19 by SeAnVeR
»
Logged
Hartza
Guest
Re:Radar
«
Reply #2 on:
25 Aug 2002, 23:19:22 »
Roger that !
I'll try it tomorrow, now I am too tired ...
Thanks SeAnVeR !
Logged
icarus_uk
Members
LiarLiarPants Inflame True
Re:Radar
«
Reply #3 on:
25 Aug 2002, 23:37:06 »
Or a trigger;
Condition; (getpos
PlaneName
select 2) >
HeightInMetres
Activation;
Whatever you want to happen here, alarms hints etc
Logged
seanver
Guest
Re:Radar
«
Reply #4 on:
25 Aug 2002, 23:48:07 »
come on icarus don't screw my work up! ;D
Logged
icarus_uk
Members
LiarLiarPants Inflame True
Re:Radar
«
Reply #5 on:
25 Aug 2002, 23:54:29 »
Sorry. A script is the best way... naw sorry I cant lie. The trigger is the best way so far. It wont use a looping script for a start, one that could have used a @ and not the looping ? though.
Logged
seanver
Guest
Re:Radar
«
Reply #6 on:
26 Aug 2002, 00:01:17 »
I was just joking
And explain me that about the @
«
Last Edit: 26 Aug 2002, 00:06:05 by SeAnVeR
»
Logged
icarus_uk
Members
LiarLiarPants Inflame True
Re:Radar
«
Reply #7 on:
26 Aug 2002, 00:18:44 »
I just relearnt this a few days ago. Instead of a script looping over a single check command you can use the @ to make the script wait until the condition is true.
So using your script above as an axample, you could write it alot easier with this;
@(position plane select 2) > x
hint "What a pilot! You even can't fly below that height!"
alarm=true
exit
And there you have the same thing, without the looping.
Logged
seanver
Guest
Re:Radar
«
Reply #8 on:
26 Aug 2002, 00:23:37 »
Nice thing
Logged
Hartza
Guest
Re:Radar
«
Reply #9 on:
26 Aug 2002, 07:46:45 »
Ok ...
What about that single plane, can I replace it with string of several planes, like [plane1,plane2 .....,plane6] ?
My mission uses 6 ultra light tandem planes ...
Logged
Send this topic
Print
Pages: [
1
]
Go Up
« previous
next »
OFPEC Forum
»
Editors Depot - Mission Editing and Scripting
»
OFP - Editing/Scripting General
(Moderators:
h-
,
savedbygrace
,
Gruntage
) »
Radar
Top of page