OFPEC Forum

Editors Depot - Mission Editing and Scripting => OFP - Editing/Scripting General => Topic started by: CooK on 17 Oct 2002, 01:29:16

Title: 2 questions--
Post by: CooK on 17 Oct 2002, 01:29:16
Hello, im cook :)
my computer crashed a bit ago and i lost all my info and maps.

my questions are.

(The Example)- im making a map where the a person goes up to a object and i addaction ( iknow how to addaction + script).

My question(1) is how u put it where a person comes up to it and a action appears ( i dont want to add action to just the object)? .....<= 0.5  that kind of command...

2-==-=-

Respawning vehicles....
i have the scipt for it.. and i put the server galme logic down..

my ?(2) IS what i do next? put the following command ([tank1, m2spawn, 90, bradley, 180] exec "vclrespawn.sqs" )
   
                       without the ( and )

and i made a marker (rectangle) called m2spawn

=info= i tryed putting the sriptcall in anouther game logic
but it dident work, the vehicle would disappear but not respawn vehicle would appear. help me plz :)
Title: Re:2 questions--
Post by: Kaliyuga on 17 Oct 2002, 02:03:02
 Well.. about the first Q:

use a distance command in the condition field of a trigger

player distance object < x  

where x=meters  

;)

then the addaction will be activated when the player is less than x meters from the object
:toocool:
Title: Re:2 questions--
Post by: HALO_TheWolf on 17 Oct 2002, 07:16:58
No need to set distance.  There is a much simpler way.

Just make a trigger around that area(may take tweaking to get distance right.  And just set it activated by anybody, repeatedly, and in the OnAc, just run the script(to add the action).


Also, in the OnDeAc field, you have to remove the action, or it will stay there.
Title: Re:2 questions--
Post by: Kaliyuga on 17 Oct 2002, 08:45:31
 Using distance gets rid of both the need for the deactivation field as well as "tweaking with the size of your trigger"

since you set a condition for your trigger, it can made 0 x 0

and since the condition must be met for the action to be added, simply moving the prescribed distance from the object will remove the action

and since you state who activates the trigger in the aforementioned activation field that gets rid of the need to "set your trigger to be activated by anyone "

Seems about three steps less than yer version ..... not knocking it.... there are a million ways to accomplish things in OFP , but as far as your version being simpler... I beg to differ ;)

Title: Re:2 questions--
Post by: CooK on 18 Oct 2002, 07:16:22
ok say i did do any of those, what is the command to remove action?

like

art1 "........" kk


for kk being the action name. kk need to have " 's?
Title: Re:2 questions--
Post by: Chris Death on 18 Oct 2002, 08:06:46
Just for info:

In multiplayer maps, my experience told me, that:

Triggers with a "distance" condition are better working
than simple triggers (covering an area).

For example: you have a trigger with a size of 50/50
activated by: west/present
activation field: thislist select 0 sidechat "blablabla"

Result: the sidechat message appears only on screens of
players, inside the trigger area, while it appears later on
screens of players, entering the area at a later time
(expecting they are also west).

While using a trigger with a condition like:

"_x distance leader enemy_group < 50" count units west_group > 0
activation field: leader west_group sidechat "blablabla"

Result: the message appears on all client screens, even
if not inside the 50 meters range.

~S~ CD
Title: Re:2 questions--
Post by: Kaliyuga on 18 Oct 2002, 08:26:10
 Well.. had this been posted in the proper place in the first place ::)  we might have avoided all this confusion...

I assumed that since this isn't the MP board, we weren't talking about MP issues ;)

But it's good to know that there are issues with this in multiplayer ;)
Title: Re:2 questions--
Post by: Chris Death on 18 Oct 2002, 16:20:32
Quote
Respawning vehicles....
i have the scipt for it.. and i put the server galme logic down..


Just thought, that he's working on a mp map, because of the
line above, taken from his first post in this thread  :)

But also in single player missions there's a difference of
cpu usage between area covering trigger's and condition-
triggers. To check an area for something does always use
more cpu-power than simple conditions.
This info came from SUMA (the one who should know it).

~S~ CD