DayZ
DayZ-Dynamic-AI-Addon
Multiple Vector Points per Load-out
1.) Is it possible to add multiple vector points for one load out? I'd like to use loot zone appropriate AI, but I don't want to have to make hundreds of the same load outs if I can just specify multiple vectors.

2.) I read in a comment, you said AI spawns on the spatial radius. Does the AI that spawns from points, on the spatial radius come from a random direction or do the always spawn at the same place until the server restarts?

3.) Pushing off those two questions, If question 1 is yes, are the spawn points random. In other words, AI might spawn at point 1, then point 2, point 1 again, point 3, etc rather than the same point every time, until the server reboots. --- in expansion AI, if you set a string of coordinates for AI to travel on, even if you set them to random, AI will always spawn at one point, until the server restarts.
< >
Showing 1-7 of 7 comments
An Engineer  [developer] 20 Jun, 2023 @ 9:07pm 
Points are an area the player is in for that specific loadout/faction to be set to the group spawning on that player.
The actual spawn position used for those is still based off of the player itself, not the point zone.

2. Random every time based on min and max distance unless using location spawns.
I think I see what you're saying. If I set the Spatial Radius to 1000, all the dynamic AI in that radius will be the ZoneLoadout specified in the line below? It will override whatever the group is, within 1000 meters but it will still spawn out to a maximum of whatever the MaxDistance is, say, 250?
Something must not be right. Points=1 and I set the first point to this: I'm standing a couple meters away from those coordinates


"Spatial_Radius": 1000.0,
"Spatial_ZoneLoadout": "TestLoadout.json",
"Spatial_Faction": "East",
"Spatial_Name": "East",
"Spatial_HuntMode": 3,
"Spatial_MinCount": 1,
"Spatial_MaxCount": 1,
"Spatial_Safe": 0,
"Spatial_Position": [
[
4489.23,
7.54147,
2524.87
]



Where TestLoadout.json should only spawn with an apple and a glock, but it's spawning this group and loadout...

"Spatial_MinCount": 2,
"Spatial_MaxCount": 3,
"Spatial_Weight": 350.0,
"Spatial_Loadout": "EastLoadout.json",
"Spatial_Faction": "Passive",
"Spatial_Name": "Passive"
I think I figured it out, Dolphin. I had too many layers in the vector, Spatial_Position, when I was testing (there is another ] in the vector, after the last one I posted above that I forgot to remove); although, it would be nice to be able to supply a point with an array of vectors, instead of having to create a new point for each one. I am reading the code, but I'm not a dev, so... maybe you can answer if that's possible?
Update: Although this corrected the error, it didn't fix the problem. If points override the group, it's not working for me.

11:02:56.164 [Spatial AI] points Enabled
11:02:56.164 [Spatial AI] Trigger at location: <4489.229980, 7.541470, 2524.870117> - Radius: 1000
11:02:56.164 [Spatial AI] Safe: false - Faction: East - Loadout: TestLoadout.json - counts: 1:1
11:13:34.886 [Spatial AI] Player: theonlytalkinggoat Number: 2, Faction name: Passive, Loadout: EastLoadout.json
11:13:34.890 [Spatial AI] Spawning 2 Passive bots at <4735.895508, 9.673083, 2476.846436>



Ok, so I got it to spawn, but it seems it won't work unless I'm within 50 meters of the spawn point. Still testing.
Last edited by theonlytalkinggoat; 21 Jun, 2023 @ 10:21am
Dolphin, are you sure the radius is being taken into account, when assigning the loadout of the group?

I see, in MissionServer.c, where you're sending the data to the log in the function InitSpatialTriggers.

But I'm not seeing an evaluation of whether or not the player is within the spatial radius or a logic cycle to tell it to use the layout in Spatial_ZoneLoadout.
An Engineer  [developer] 22 Jun, 2023 @ 12:48am 
It might just be incorrect logging of spawns.
I'll look into it.
< >
Showing 1-7 of 7 comments
Per page: 1530 50