Jump to content
Sign in to follow this  
CapBlackShot

Two Simple Problems With Bargate

Recommended Posts

Hello, guys!

Currently, I'm working on a Altis Life map. I put some "bargates" for cops to open automatically when they are close of the selected area. I also put those bargates on a "checkpoint" area, so it's not so big. The problems are:

• When there is a lot of people/cars on the area (including civilians and cops), the bargate turns crazy and starts to close and open quickly, or it just closes on the car, resulting in a explosion. I don't know why, all appear to be correctly configured.

• The bargate, after some time, closes automatically, but there is no 'time out' or 'cooldown' set.

These are my currently settings:

tygieCq.png

To prevent those bugs, I tried putting the condition below, but I really don't know if it will solve (I have to wait the admin of the server to put ir for test):

0sBRa4S.png

I don't know, but, I think when two cops are on the same area and one of them leaves the zone, the bargate closes. Whatever, is there anything wrong with my system? What do you think that I can do to eliminate bugs like these ones?

Thank you so much!

Share this post


Link to post
Share on other sites

Place two triggers as shown in these pictures:

Trigger1:

VhSI2Ky.jpg

Trigger2:

yzjP7nE.jpg

Now the bargate will stay open for at least n seconds (Timeout value in trigger2) before closing.

Share this post


Link to post
Share on other sites
Place two triggers as shown in these pictures:

Trigger1:

http://i.imgur.com/VhSI2Ky.jpg

Trigger2:

http://i.imgur.com/yzjP7nE.jpg

Now the bargate will stay open for at least n seconds (Timeout value in trigger2) before closing.

Thank you, but I have some questiones yet:

1. Why would it solve the "crazy" bargate?

2. How can the bargate never closes if there is a player on the selected area?

3. What is the difference between mine and yours?

4. Could you post a screenshot of your structure and trigger?

Thank you again for the attention! :)

Share this post


Link to post
Share on other sites
Does anyone else knows about bargates?

I don't but picked up the following for use in a simple trigger. Adjust the size of the trigger area to suit.

Name the gate: gate1

Then in the gate init line put: this allowdamage false;

Put this into the trigger:

Activation:

Blufor

Condition:

this

On Act:

gate1 animate ["Door_1_rot", 1]; off1

On Dea:

gate1 animate ["Door_1_rot", 0]; off1

Then whenever a unit goes into the trigger area the gate opens until all units leave the area.

Share this post


Link to post
Share on other sites
I don't but picked up the following for use in a simple trigger. Adjust the size of the trigger area to suit.

Name the gate: gate1

Then in the gate init line put: this allowdamage false;

Put this into the trigger:

Activation:

Blufor

Condition:

this

On Act:

gate1 animate ["Door_1_rot", 1]; off1

On Dea:

gate1 animate ["Door_1_rot", 0]; off1

Then whenever a unit goes into the trigger area the gate opens until all units leave the area.

I think my objects are configured like yours. The problem is when there is more than one person on the same area (2 cops and 1 civilian, for example). Maybe the trigger detects the both and gets crazy.

Share this post


Link to post
Share on other sites
I think my objects are configured like yours. The problem is when there is more than one person on the same area (2 cops and 1 civilian, for example). Maybe the trigger detects the both and gets crazy.

Have you tried altering the size of the trigger or reducing it so that it is only activated by a cop standing next to the weighted end of the gate. I assume the craziness is caused by people moving in and out of the trigger area. I find that when a gate is put down in the editor, it is off to one side so your trigger in the editor could be offset slightly in the game and not quite where you think it should be.

Share this post


Link to post
Share on other sites
Have you tried altering the size of the trigger or reducing it so that it is only activated by a cop standing next to the weighted end of the gate. I assume the craziness is caused by people moving in and out of the trigger area. I find that when a gate is put down in the editor, it is off to one side so your trigger in the editor could be offset slightly in the game and not quite where you think it should be.

Well, I tried to adjust the size as much as I can, because I can't leave it so small. Otherwise, the bargate will close on cars again. So, I just neeed to set "off1" at the end of the code?

Thank you!

Share this post


Link to post
Share on other sites

off1 doesn't seem to relate to anything unless it's some command I've missed.

Share this post


Link to post
Share on other sites
off1 doesn't seem to relate to anything unless it's some command I've missed.

I think it's something to do with animations, but I can't find it documented anywhere so I can only guess.

I suspect it kills the animation keeping the gate open until the trigger deactivates, then closes the gate. I haven't tried sending a convoy through to test it though. Perhaps someone who knows about animations can shed some light on it, but it worked for my purposes.

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×