Editors Depot - Mission Editing and Scripting > Arma3 - Editing/Scripting Multiplayer

Resizing a Trigger

(1/2) > >>

Mad Pup:
Exactly what the title says.

I know I used to do it in OFP, but I can't remember the code. I've tried searching around for an answer, but can't seem to find one.

The trigger (named "trigkz") is a zone restriction, and at a certain point after aprox. 10 minutes, I want the trigger to move to a different location (a trigger, 0x0, named "kz0").

Thanks in advance,
~Mad Pup

Side note: also, is it possible to resize at trigger via .sqf?

EDIT: OKAY I figured out how to move it  :good: SO, for those who have the same question:


--- Code: ---vehicle trigkz setPos getPos kz0
--- End code ---

Although, I still am curious about the "Side Note" above, re-sizing a trigger via the .sqf. So I've renamed the Subject from "Moving a Trigger" to "Resizing a Trigger".  :D

SoldierEPilot:
'bout moving: it's must also work without "vehicle" command

--- Code: ---trigkz setPos getPos kz0
--- End code ---

'bout resizing, changing trigger side, etc:
 in PBOed missions, editable missions placed to "Missions/MPMissions" folder
and campaigns you can clone existing triggers


--- Code: ---trigkz saveStatus "Sample"
trigkz2="EmptyDetector" createVehicle somePos
trigkz2 loadStatus "Sample"
--- End code ---

So ALL params of trigkz (AFAIK without position) will be copied to trigkz2.

You can also just use several similar triggers of different sizes
store 'em at [0, 0, 0] and switch dynamically via sqs/sqf...

I see no other workarounds in OFP.


h-:
Soldier is right, no need for the 'vehicle' when setpossing a trigger.

Resizing a trigger is easy, use setTriggerArea (assuming this is indeed for Arma3 and not OFP)..

SoldierEPilot:

--- Quote ---assuming this is indeed for Arma3 and not OFP
--- End quote ---
My apologies, it's because of magic word "OFP" in the second line of request :)

+50c:  there are 6 setTrigger* commands in ARMA-3

Mad Pup:

--- Quote ---it's must also work without "vehicle" command
--- End quote ---

Huh... when testing, I couldn't get it to move without the "vehicle" part. Weird... Anywho it moves  :D

Thank you h- for the SetTriggerArea command... didn't know that was a thing.

On Another Note: This a mp mission on Stratis. And about every 5 minutes the "play zone" shrinks. No problems, anyone not in the zone when the timer is up, dies. But I have multiple warnings. One for 5 minutes, 2 minutes, and 60 seconds. I've used this code to display the warnings:


--- Code: ---["In 5 (FIVE) Minutes, Play Will Be Reduced To The Red Circle Marked On Your Map! If You Are Not Within This Circle When Play Is Reduced, You Will Be Killed!"] spawn BIS_fnc_dynamicText;
sleep 180;
["In 2 (TWO) Minutes, Play Will Be Reduced To The Red Circle Marked On Your Map!"] spawn BIS_fnc_dynamicText;
sleep 60;
["In 60 SECONDS, Play Will Be Reduced To The Red Circle Marked On Your Map!"] spawn BIS_fnc_dynamicText;
sleep 60;
["PLAY HAS BEEN REDUCED! If You Are Outside The Red Circle Right Now, You Are Going To Be Killed!"] spawn BIS_fnc_dynamicText;
--- End code ---

Now during testing, with another player and I in a LAN server, my computer was the only one receiving the warnings (my computer being the server). So any way I can fix this? I used the dynamicText because it was relatively large text in the middle of the screen.

Once again, Thanks in advance.

~Mad Pup

Navigation

[0] Message Index

[#] Next page

Go to full version