Sea Power

Sea Power

oscar19681 Nov 13, 2024 @ 12:00am
How to set trigger to spawn enemy unit ?
Im trying to figure out how I can spawn in an enemy unit when a bluefor unit enters a certain trigger area but I can’t seem to make it work. Anyone can help me out here ?
Last edited by oscar19681; Nov 13, 2024 @ 12:00am
< >
Showing 1-15 of 15 comments
Flakyhtf Nov 13, 2024 @ 12:30am 
I think you cannot do that as to spawn, but there is a workaround:
1. in the mission editor, spawn a unit very far away
2. set a position trigger that when condition = x (unit enters area or after a fixed time) -> effect = teleport unit to another area
BarMan_Forasteiro Nov 17, 2024 @ 9:01am 
have been trying for hourts to get unit enters area trigger to work and it just doesnt work, following two video tutorials doing exactly the same steps and the trigger just fails at mission start
Max Sprin Nov 17, 2024 @ 9:07am 
Originally posted by BarMan_Forasteiro:
have been trying for hourts to get unit enters area trigger to work and it just doesnt work, following two video tutorials doing exactly the same steps and the trigger just fails at mission start

yes, triggers really mess up things in the game. We need to wait until devs will fix all these issues.
oscar19681 Nov 18, 2024 @ 12:05pm 
Originally posted by Max Sprin:
Originally posted by BarMan_Forasteiro:
have been trying for hourts to get unit enters area trigger to work and it just doesnt work, following two video tutorials doing exactly the same steps and the trigger just fails at mission start

yes, triggers really mess up things in the game. We need to wait until devs will fix all these issues.

It’s kind of a letdown because is seriously limited mission editing, which I had high hopes for untill the Dynamic campaign drops. I hope the missions editor gets some love before that
[NcK]MasterShake|CM Nov 18, 2024 @ 12:10pm 
Originally posted by BarMan_Forasteiro:
have been trying for hourts to get unit enters area trigger to work and it just doesnt work, following two video tutorials doing exactly the same steps and the trigger just fails at mission start
Post conditions.
oscar19681 Nov 18, 2024 @ 2:29pm 
Originally posted by NcKMasterShake|CM:
Originally posted by BarMan_Forasteiro:
have been trying for hourts to get unit enters area trigger to work and it just doesnt work, following two video tutorials doing exactly the same steps and the trigger just fails at mission start
Post conditions.

I tried but they are broken to.
carvajrBR Nov 20, 2024 @ 2:56pm 
I've been playing with heavily scripting a simple air patrol mission. Especially for aircraft, spawning (teleporting) units is hard. If you just do the usual teleport to an area thing, it teleports the planes to ground level and so the planes crash immediately. I found that there is a workaround. You can add an altitude to the teleport area manually in the .ini file. It seems to work. But that is not very practical, as any changes you do in the editor will overwrite your changes and sometimes even break something (instead of going back to the default 0 altitude, it puts your planes somewhere near the orbit of Jupiter with 9e11 nm hehe). But with some love it can work.

You can take a look here:
https://steamcommunity.com/sharedfiles/filedetails/?id=3368291077

But even if all that is already implemented in the editor is fixed, I really think we need many more possibilities than just the ones there (teleporting, chaanging sides, messages, etc...)
Things like changing course, attacking specific targets, changing parameters (EMCOM, weapons stance), among many others. I'm sure we'll get there!
I'm not sure units can be spawned from the mission files yet. I think your best bet at present is to have a 'goody box' somewhere far and out of the way and have it contain units you want to use. You might even consider setting them to neutral... then when something "triggers" those units to spawn set the action area for where you want them to go, swap their taskforce to the appropriate team and use the teleport action to actually move them.

I have used this with a neutral sea mine to have vessel losses by script as I don't think there's any ability to set fire, flooding, damage etc from the mission file. Hopefully more flexibility is added in the near future.
carvajrBR Nov 20, 2024 @ 3:13pm 
I'm quite new to all this, but I couldn't find any way to do it, even manually in the file. The "goody box" way, I guess, is almost as good and should be enough for now. As MasterShake said, consider setting the goodies to neutral. If they are yours they'll show in the map and break the illusion of spawning..
carvajrBR Nov 21, 2024 @ 8:17am 
I've been playing a bit more with teleportation. There seems to be a few bugs if you change the side of the units, so setting them initially as neutral and changing that
to ally or enemy before, during or after teleportation can make units invisible (not because they're below ground) or unclickable. So, if you want to spawn enemies, create the group as enemy, put them far away, and everything will be fine. If you want to spawn allies, I'd suggest creating them as allies to start with. The negative of this is that they'll be visible in your unit list (or map if you go there). But it's better than having an invisible or unclickable unit later. Maybe I'll make a video with the tests I did.
Last edited by carvajrBR; Nov 21, 2024 @ 8:29am
This is what I wound up doing, put a sub and a few sea mines in a lake and then moved them with a trigger... You can be precise with AreaRadiusNM=0.

I would like to know more about the problems you are having with swapping from neutral, because I have done that too without anything turning invisible-- but I'm not trying to do much with the unit I swapped sides on, just set waypoints and telegraph and such.
carvajrBR Nov 21, 2024 @ 8:31am 
I think I did that as well before the last update, but I'm not sure if I changed sides or not.
Last edited by carvajrBR; Nov 21, 2024 @ 8:32am
Just turn on truth [tf sensors? something like that] with the debug tools to see if it's doing what it is supposed to. It's a life saver.
carvajrBR Nov 21, 2024 @ 2:29pm 
I made a quick and dirty video with a small explanation on how to teleport and the bugs related to it. I hope it is helpful to someone:

https://www.youtube.com/watch?v=axxyS8NoWGQ
Last edited by carvajrBR; Nov 21, 2024 @ 2:31pm
carvajrBR Nov 24, 2024 @ 5:33am 
Hi again! It seems last Friday's update makes the same ini file behave differently in the editor and in the game. In the editor the altitude is read in nm, while in the game it is now read as feet. See my appendix video below explaining this.

https://youtu.be/Rc7s_S0jo1c

I have updated my workshop missions that uses teleportation of aircraft in order to take this into account:

An ace over Hanoi (V2):
https://steamcommunity.com/sharedfiles/filedetails/?id=3368291077

Bandar Abbas:
https://steamcommunity.com/sharedfiles/filedetails/?id=3370853850
Last edited by carvajrBR; Nov 24, 2024 @ 5:34am
< >
Showing 1-15 of 15 comments
Per page: 1530 50

Date Posted: Nov 13, 2024 @ 12:00am
Posts: 15