More offline squad oddities

carperbr
Scavenger
Posts: 27
Joined: 15 Oct 2015, 00:44

More offline squad oddities

Postby carperbr » 27 Oct 2015, 16:04

So I'm still dealing with some frustration in regards to offline squads. This time, its offline squads entering the level the actor is on and teleporting far from where they should be.

The specific issue occurs when a squad attempts to move from Cordon to Marshes, typically when I have them target mar_smart_terrain_12_2 and mar_smart_terrain_11_11. The squads will attempt to move from Cordon to Marshes in the general area of the level changer (though I'm aware they use the graph for movement), but then they will appear on the left most side of the marshes map (the upper left corner where that one far off base is). I'm not sure what I can do to remedy this, as I've messed with the alife.ltx a great deal but to no avail. However, it seems that its this level change in specific. Squads enter from Marshes to Cordon kinda correctly (though squads enter Cordon at the bottom behind esc_smart_terrain_3_16, the military base, rather than the tunnel like one would expect). If there is information on editing how the graph is connected between levels I'd love to mess with it and get more accurate locations if possible.

Also, squads going from the Bar to the Trucks Cemetery take forever. I waited a good deal of time but they didn't show up until I set the normal_time_factor in alife.ltx to 0.1, and for obvious reasons that is unacceptable haha. Also squads from Dead City to Limansk take a great deal of time as well, though I guess that could just be simulating the distance traveled.

It got to the point where I wrote level change code for offline squads. They would teleport after a given amount of time to a specified smart terrain near the level changer. However, when I was attempting to teleport them onto the level the player was on, they would go online then stay in their respective levels.

Another offline squad issue while I'm at it: When activating squads that are offline in Agroprom, members of those squads appeared at the village center (where I was) and began fighting there. However, the squad was still shown to be in agroprom on the pda while there were absolutely no squads actually at the village center. I've messed with alife.ltx heavily, and have been trying combinations of vanilla settings with my own modifications. While I'm able to get different results, nothing fixes the issues I'm having (and I wouldn't really expect alife.ltx to fix any of these issues, it seems more of an issue with the game graph).

Sorry to complain so much about the offline alife. I'm about to start digging through open xray myself and poking around, though the scope of the project is a bit daunting to just dive in haha.

User avatar
Alundaio
S.T.A.L.K.E.R.
Posts: 1368
Joined: 26 May 2012, 22:26

Re: More offline squad oddities

Postby Alundaio » 27 Oct 2015, 17:34

You need to use the Level Editor to change graph points. Linked graph point are intentionally on the edges of the map and away from actor Level Changers because it causes a lot of issues with many squads spawning on top of the player.

Alife does simulate the distance and It is possible to lower these in the editor. Maybe if Bangalore reads this and this is something he wants to do then I will patch it in, so that alife travels faster between some levels.

There are other tools to do this, like using acdc to unpack all.spawn then edit the game graph with the Edge Editor tool but there is no way to turn the recompiled all.spawn back into raw level data and is very hacky. Since we released raw SDK stuff it's probably the best solution just to use LE, it's very simple.


As for teleporting randomly and not coming online where they should be, it's possible it's an issue with this code in xr_motivator.script:

Code: Select all

   local id = sobject.id
   local force_set_position
   if (db.offline_objects[id] and db.offline_objects[id].level_vertex_id) then
      force_set_position = level.vertex_position(db.offline_objects[id].level_vertex_id)
   elseif (db.spawned_vertex_by_id[id]) then
      force_set_position = level.vertex_position(db.spawned_vertex_by_id[id])
      db.spawned_vertex_by_id[id] = nil
   elseif (sobject.m_smart_terrain_id ~= 65535) then
      local smart = alife():object(sobject.m_smart_terrain_id)
      if (smart and not smart.disabled) then
         if not (smart.arriving_npc[id]) then
            if (smart.npc_info[id]) then
               if not (smart.npc_info[id].job) then
                  smart:select_npc_job(smart.npc_info[id],true)
               end
               if (smart.npc_info[id].job) then
                  --alun_utils.debug_write(strformat("xr_movtivator: npc=%s job=%s",self.object:name(),smart.npc_info[id].job.section))
                  local smart_task = smart.npc_info[id].job.alife_task
                  force_set_position = smart_task and smart_task:position() or nil
               end
            end
         end
      end
   end

   if (force_set_position) then
      self.object:set_npc_position(force_set_position)
   end


db.offline_objects[id].level_vertex_id

NPCs save their last position before going offline and then force to this position when come online. This is for when the squad comes online all the npcs teleport quickly to their job locations and stuff. Otherwise they will spawn at squad position. What could be happening is when they change levels this data is not erased and they will use position from old level. If this is the problem I will think of a solution. If I recall correctly this data is erased when they select new target but perhaps it should be erased when their last level is not the new level.
"I have a dream that one day this community will rise up and live out the true meaning of its creed: "We hold these truths to be self-evident; that all mods are created equal."

carperbr
Scavenger
Posts: 27
Joined: 15 Oct 2015, 00:44

Re: More offline squad oddities

Postby carperbr » 27 Oct 2015, 17:42

Alright, cool. I can look into editing it myself, doesn't sound like it should be too difficult as long as there are resources on the modding wiki that go over the process of editing a map with the level editor.

I guess my confusion was that there are some linked graph points that are well placed (like the northern point in Cordon where squads come in from marshes works perfectly). Luckily since that point is very well placed I have a great example to work with.

Since this is rather specific to my mod, I'm not sure these edits would be useful for other mods. Mine is a very directed faction war mod similar to Clear Sky, so that is why I am wanting linked graph points to be positioned like they are in Clear Sky. I'll begin working on fixing up the linked graph points to my liking tonight as long as I'm not vastly underestimating its complexity, and if you guys think that its something other people would then that works.

And if the data was erased when a new target is selected (in specified_update or generic_update (those names might not be exactly correct)), assuming you're meaning the generic update when it selects targets based on properties of smart terrains, I've written my own system for spawning etc from the ground up with an expansion system that selects targets for squads. Its possible that issue is simply on my end, and the more I think about it the more likely that seems (when I originally started testing military squads would spawn near the outskirts of the military outpost instead of teleporting to the village center)

User avatar
Alundaio
S.T.A.L.K.E.R.
Posts: 1368
Joined: 26 May 2012, 22:26

Re: More offline squad oddities

Postby Alundaio » 27 Oct 2015, 17:54

carperbr wrote:Alright, cool. I can look into editing it myself, doesn't sound like it should be too difficult as long as there are resources on the modding wiki that go over the process of editing a map with the level editor.

I guess my confusion was that there are some linked graph points that are well placed (like the northern point in Cordon where squads come in from marshes works perfectly). Luckily since that point is very well placed I have a great example to work with.

Since this is rather specific to my mod, I'm not sure these edits would be useful for other mods. Mine is a very directed faction war mod similar to Clear Sky, so that is why I am wanting linked graph points to be positioned like they are in Clear Sky. I'll begin working on fixing up the linked graph points to my liking tonight as long as I'm not vastly underestimating its complexity, and if you guys think that its something other people would then that works.

And if the data was erased when a new target is selected (in specified_update or generic_update (those names might not be exactly correct)), assuming you're meaning the generic update when it selects targets based on properties of smart terrains, I've written my own system for spawning etc from the ground up with an expansion system that selects targets for squads. Its possible that issue is simply on my end, and the more I think about it the more likely that seems (when I originally started testing military squads would spawn near the outskirts of the military outpost instead of teleporting to the village center)


Code: Select all

function sim_squad_scripted:on_reach_target(squad)
   --alun_utils.debug_write("sim_squad_scripted:on_reach_target")
   squad:set_location_types()
    for k in squad:squad_members() do
      if db.offline_objects[k.id] ~= nil then
         db.offline_objects[k.id] = db.offline_objects[k.id] and empty_table(db.offline_objects[k.id])
      end
   end
   SIMBOARD:assign_squad_to_smart(squad, nil)
end


This is the code that should clear out the data when new target is selected. Without this then npcs would spawn in strange places when coming online. Looking at it, throwing in db.spawned_vertex_by_id[k.id] = nil wouldn't hurt.
"I have a dream that one day this community will rise up and live out the true meaning of its creed: "We hold these truths to be self-evident; that all mods are created equal."

carperbr
Scavenger
Posts: 27
Joined: 15 Oct 2015, 00:44

Re: More offline squad oddities

Postby carperbr » 27 Oct 2015, 17:57

:| I'm a little embarrassed I didn't read further into those functions. I make squads keep their current action equal to one so I know when I can activate certain squads (and to simply return early to avoid your own targeting system), so I kinda circumvented that code (pretty hackish I guess). Not sure why I didn't read through those more closely...

Anyways, thank you, you've been very helpful. It will be very easy to reimplement that in the new targeting system I have.

Edit: Just got home from work and added that and a little other stuff from the end of generic_update from sim_squad_scripted. Everythings working.

carperbr
Scavenger
Posts: 27
Joined: 15 Oct 2015, 00:44

Re: More offline squad oddities

Postby carperbr » 28 Oct 2015, 13:05

So I ended up implementing those little modifications and it worked, but I have another issue now that feels like its own special hell. Squads still spawn in really weird places when crossing levels. When the squad enters marshes from cordon while offline, they do it perfectly fine and will show up where you'd expect. Then when i cross over, they teleport to the other end of the map. After which, they will get close enough to switch online then teleport back to that original position, stuck in a perpetual cycle of getting close and then teleporting as far away in that level as possible.

It sounds like its the same issue as I was having before, however I'm not sure why entirely. In my code I have a function that tells a faction to look for an idle squad or create a new one if an idle squad isn't found. Since this is in my own script, I return from specific_update early and am letting my faction update method clear the offline positions. Here is the relevant piece of code:

Code: Select all

   orderSquad.scripted_target = selectedTarget
   orderSquad.assigned_order = true -- Something I use elsewhere in the faction control logic
   
   orderSquad.current_target_id = nil
   orderSquad.current_action = 0
   
   
   orderSquad:on_reach_target(orderSquad) -- Also tried SIMBOARD.smarts_by_names[selectedTarget]:on_reach_target(orderSquad) with same results
   
   if foundSquad == true then
      printf("FOUND SQUAD FOR " .. faction .. ". SENDING TO " .. selectedTarget)
   else
      printf("CREATED SQUAD FOR " .. faction .. ". SENDING TO " .. selectedTarget)
   end


So that should get rid of the weird teleportation issues, and it worked like a charm with squads in escape when I was roaming around that level. But squads from escape started messing up when they moved to marshes. I unfortunately didn't try out your suggestion of db.spawned_vertex_by_id[k.id] = nil in the squad member loop in on_reach_target, do you think that'd be the culprit in this scenario? I don't mess with squads anywhere else than in that one method where I assign them targets.

I'm only saving a table of squad ids that are registered for faction control. Would there be something I need to call on load to get the squads back to where they were originally targeting? I tried saving the assigned target id in the sim_squad_scripted:save_state or whatever and it seemed to work, but maybe that caused more issues than it solved? But then, you would expect squads that travel to marshes from escape while i'm already there to act normal, so I don't think its related to how I load squads and register them with the faction controller.

All squads spawn in the same places as well. When entering through the upper right portion of the map and switching online, they will teleport to the upper left corner of marshes. When entering through the bottom right portion of marshes, they will teleport to where the guide is to take you to the clear sky base. Every time. And that is where they teleport back to when they get close enough to switch online.

User avatar
Alundaio
S.T.A.L.K.E.R.
Posts: 1368
Joined: 26 May 2012, 22:26

Re: More offline squad oddities

Postby Alundaio » 28 Oct 2015, 13:39

Sounds like it's still the issue, do a notepad++ search of db.offline_objects. It is cleared in several places in smart_terrain.script, too.

But in your code, every time they select a new destination you need to call se_target:on_reach_target(self). Basically offline table is only used when NPCs are at a smart terrain doing jobs, since it stores their exact position and active section. When they aren't doing this it needs cleared.

To make sure this is the problem just go into xr_motivator and comment out the force set position line.



current and assigned target should already be saved, were you having issues with them selecting a new target on load?
"I have a dream that one day this community will rise up and live out the true meaning of its creed: "We hold these truths to be self-evident; that all mods are created equal."

carperbr
Scavenger
Posts: 27
Joined: 15 Oct 2015, 00:44

Re: More offline squad oddities

Postby carperbr » 28 Oct 2015, 14:02

Looks like its cleared in se_smart_terrain:select_npc_job and then the se_smart_terrain:on_reach_target which I've already called (i was just testing out sim_squad_scripted:on_reach_target after already trying se_smart_terrain:on_reach_target). Looks like its called when an npc selects a new job and when a job hasn't begun, which in turn is called from switch_to_desired_job and register_npc.

Looks like register_npc is called from sim_squad_scripted:assign-squad_member_to_smart, so I'm going to begin checking to see if thats called anywhere in my code or if something I did caused that not to be called. Hopefully that'll remedy this final issue. Edit: doesn't actually seem like that function is called anywhere so I doubt thats it.

Whenever I set a target I call the se_smart_terrain:on_reach_target, so I feel that the db.offline_objects table for the squad members should be emptied after doing that.

One thing I'm missing from my code currently (can't test, at work) is this little bit:

Code: Select all

   local se_obj
   local sim = alife()
   for k in self:squad_members() do
      se_obj = k.object or k.id and sim:object(k.id)
      if (se_obj) then
         SIMBOARD:setup_squad_and_group(se_obj)
      end
   end


which is called whenever a new target is selected in generic_update. Maybe that has to do with it.

Also, I just saw in sim_squad_scripted:STATE_Write it saved current_target_id, respawn_point_id, respawn_point_prop_section, and smart_id. There is a good chance that that didn't affect anything, I just kinda preemptively added it in. I'm gonna remove it and see if things are normal, they probably will be.

carperbr
Scavenger
Posts: 27
Joined: 15 Oct 2015, 00:44

Re: More offline squad oddities

Postby carperbr » 28 Oct 2015, 19:12

Ok. So heres where I'm at now:

I implemented the se_target:on_reach_target, and I also commented out the xr_motivator.script line:

Code: Select all

   
   if (force_set_position) then
      --self.object:set_npc_position(force_set_position)
   end


The weird behavior still occurs however. But as I said, it only occurs when squads are trying to enter Marshes. Duty squads enter marshes fine from agroprom, csky squads enter cordon fine from marshes, military squads enter cordon fine from darkscape etc.

The following video shows the behavior I'm trying to describe. In the first part, you'll see a stalker squad trying to get to marshes from the nortern portion. They then teleport to near the Clear Sky main base (I was mistaken in that they teleport to the upper left corner it would seem). The second portion of the video (there is an abrupt cut) shows how Clear Sky can enter Cordon correctly, even if I leave the level and re-enter. The squads are being handled by the same code, so its a little weird to me. Maybe this could help zero in on the issue at play? Sorry for the low quality.


Oh, and just to throw it in, I'm running this code when I select a squad and send it to a target:

Code: Select all

   orderSquad.scripted_target = selectedTarget
   orderSquad.assigned_order = true
   
   orderSquad.current_target_id = nil
   orderSquad.current_action = 0
   
    local sim = alife()   
   
   local se_target = sim:object(targetSmart.id)
   
   if se_target then
      se_target:on_reach_target(orderSquad)
   end
   
   --targetSmart:on_reach_target(orderSquad)
   
    local se_obj

    for k in orderSquad:squad_members() do
       se_obj = k.object or k.id and sim:object(k.id)
       if (se_obj) then
         SIMBOARD:setup_squad_and_group(se_obj)
      end
    end

carperbr
Scavenger
Posts: 27
Joined: 15 Oct 2015, 00:44

Re: More offline squad oddities

Postby carperbr » 28 Oct 2015, 21:13

Ok, I got the issue fixed now that I have had the time to test a little more.

Your suggestion of db.spawned_vertex_by_id[k.id] = nil fixed the issue. I changed the se_smart_terrain:on_reach_target function to this and it works like a charm:

Code: Select all

function se_smart_terrain:on_reach_target(squad)
   --alun_utils.debug_write(strformat("%s:on_reach_target %s",self:name(),squad and squad:name()))
   squad:set_location_types(self:name())
   SIMBOARD:assign_squad_to_smart(squad, self.id)
   for k in squad:squad_members() do
      if db.offline_objects[k.id] ~= nil then
         empty_table(db.offline_objects[k.id])
      end
      
      db.spawned_vertex_by_id[k.id] = nil
   end
end


On a side note, is there a way to register one method to be called every game loop? RIght now I'm using the event timer system for the time being, but whenever the device resets it seems that my stuff is taken off the event queue. Its not really that big of an issue to me, just curious. It's probably something stupid on my end.

User avatar
Alundaio
S.T.A.L.K.E.R.
Posts: 1368
Joined: 26 May 2012, 22:26

Re: More offline squad oddities

Postby Alundaio » 29 Oct 2015, 11:36

Okay, cool. I will add this to my code as well. What do you mean by 'device resets'? I can't remember if I made it so the event queue persists through saves or not.
"I have a dream that one day this community will rise up and live out the true meaning of its creed: "We hold these truths to be self-evident; that all mods are created equal."

carperbr
Scavenger
Posts: 27
Joined: 15 Oct 2015, 00:44

Re: More offline squad oddities

Postby carperbr » 29 Oct 2015, 13:41

I had assumed it was the graphics device resetting, as it occurred primarily when I alt-tabbed. Wasn't the issue though, my script kept updating after having alt-tabbed for a while. I'll figure it out.

As a final question, in regards to the linked graph nodes, I was looking around the editor and saw no distance property and have found very little information on the AI map etc short of a tutorial banglore put up on moddb and the other one on the mod wiki. I was working under the assumption that coordinate systems for levels were local, but maybe its not and the distance between graph points are calculated via their real positions? I'm able to see what points are linked together etc and which level they link to, just no distance setting between them. Thanks for all your help.

User avatar
Alundaio
S.T.A.L.K.E.R.
Posts: 1368
Joined: 26 May 2012, 22:26

Re: More offline squad oddities

Postby Alundaio » 29 Oct 2015, 17:14

well maybe they are calculated at build time because I know with edge editor tool you can change the distances. I'm not the LE expert around here so I really can't answer it, I assumed you could.
"I have a dream that one day this community will rise up and live out the true meaning of its creed: "We hold these truths to be self-evident; that all mods are created equal."

carperbr
Scavenger
Posts: 27
Joined: 15 Oct 2015, 00:44

Re: More offline squad oddities

Postby carperbr » 29 Oct 2015, 19:15

I was able to use edge editor to successfully edit the distance between a few levels, so that is working now too. It does seem like your link to edge editor on this forum is 404'd though; I ended up going and getting it from some russian site.

User avatar
Bangalore
Explorer
Posts: 640
Joined: 09 Jun 2012, 19:02
Contact:

Re: More offline squad oddities

Postby Bangalore » 30 Oct 2015, 04:40

carperbr wrote:As a final question, in regards to the linked graph nodes, I was looking around the editor and saw no distance property and have found very little information on the AI map etc short of a tutorial banglore put up on moddb and the other one on the mod wiki. I was working under the assumption that coordinate systems for levels were local, but maybe its not and the distance between graph points are calculated via their real positions? I'm able to see what points are linked together etc and which level they link to, just no distance setting between them. Thanks for all your help.


I have a guess, although i never tested it.
xrAI uses the game_levels.ltx from SDK when it compiles a new all.spawn, and this ltx has an offset value for each map. This is some kind of coordinate system, which shows in numeric form the geographical position of a map on the global map for the offline graph. Second number is 1000 everywhere, which is y, all maps are on the surface. First number is x, third number is z. These offset values are taken into account when xrAI compiles the all.spawn, and i guess it defines the distance of the linked graph points (AI links), when two linked graph points are on two different maps.
You can change this coordinate system in game_levels.ltx, but it will take effect only after you recompiled the all.spawn with xrAI.
"Some sort of pressure must exist; the artist exists because the world is not perfect. Art would be useless if the world were perfect, as man wouldn’t look for harmony but would simply live in it. Art is born out of an ill-designed world."

User avatar
Bangalore
Explorer
Posts: 640
Joined: 09 Jun 2012, 19:02
Contact:

Re: More offline squad oddities

Postby Bangalore » 30 Oct 2015, 04:51

carperbr wrote:The squads will attempt to move from Cordon to Marshes in the general area of the level changer (though I'm aware they use the graph for movement), but then they will appear on the left most side of the marshes map (the upper left corner where that one far off base is). I'm not sure what I can do to remedy this, as I've messed with the alife.ltx a great deal but to no avail.


This is a "cheat" graph point for AI between Marsh and Yantar, i linked these maps to avoid bottlenecks, and to avoid too much squads to spawn behind the actor's back at the Agroprom-Marshes level changer. The actor's level changers and the AI graph point links are on different places, this is an arbitrary decision from the designer. Basically AI link graph points are outside of the accessible area by player, outside of invisible barriers, fences etc., but there are some places where i had to make AI links inside playable area.

If you are not satisfied with the AI links, the best is to use the SDK to modify them, and recompile the all.spawn with xrAI.
"Some sort of pressure must exist; the artist exists because the world is not perfect. Art would be useless if the world were perfect, as man wouldn’t look for harmony but would simply live in it. Art is born out of an ill-designed world."

carperbr
Scavenger
Posts: 27
Joined: 15 Oct 2015, 00:44

Re: More offline squad oddities

Postby carperbr » 30 Oct 2015, 15:54

Maybe, the db.spawned_vertex_by_id[memberID] = nil fixed the crazy teleporting issue from cordon to swamps however. I kinda feel like what it was doing was trying to set the position of the squad relative to that vertex ID, but since it was a vertex ID from Cordon it was messing it all up in swamps.

As for the linked graph points, I kinda wrote up a little cheat to do that which will make it super simple to update the links in the future if you guys edit all.spawn further. I wrote a program in C# that takes in the output from ggtool.pl then splits up the lines and reads in the vertex ids and distance. Then it can either set the distance to a specified value or multiply the distance with some constant (to either lengthen or shorten with an optional min and max), and then outputs a batch file which when ran uses edge editor to edit all of the distances. I guess I could have made my little thing call edge editor from code but I was lazy and wanted to test it all out.

My only issue with the links was just that I wanted a more fast paced simulation to emulate the Clear Sky TFW mod, not so much the positions of them (though I had initially thought the link from cordon to swamps was insane but that was the spawned_vertex_by_id issue).

And yeah I noticed a few links in player areas (like the middle connection from cordon to swamp), but honestly I kind of like how the squads can move a little more freely to other levels than the actor. Adds a good amount of tension to my mod.

carperbr
Scavenger
Posts: 27
Joined: 15 Oct 2015, 00:44

Re: More offline squad oddities

Postby carperbr » 23 Nov 2015, 20:00

Bangalore wrote:
carperbr wrote:As a final question, in regards to the linked graph nodes, I was looking around the editor and saw no distance property and have found very little information on the AI map etc short of a tutorial banglore put up on moddb and the other one on the mod wiki. I was working under the assumption that coordinate systems for levels were local, but maybe its not and the distance between graph points are calculated via their real positions? I'm able to see what points are linked together etc and which level they link to, just no distance setting between them. Thanks for all your help.


I have a guess, although i never tested it.
xrAI uses the game_levels.ltx from SDK when it compiles a new all.spawn, and this ltx has an offset value for each map. This is some kind of coordinate system, which shows in numeric form the geographical position of a map on the global map for the offline graph. Second number is 1000 everywhere, which is y, all maps are on the surface. First number is x, third number is z. These offset values are taken into account when xrAI compiles the all.spawn, and i guess it defines the distance of the linked graph points (AI links), when two linked graph points are on two different maps.
You can change this coordinate system in game_levels.ltx, but it will take effect only after you recompiled the all.spawn with xrAI.


So I ended up testing this just a bit ago. You were indeed correct, game_levels.ltx seems to dictate distances between connected level points along with the graph points local coordinates.

Looking into it and messing around building different all.spawn files, I realized that for the z axis (which is up/down in the coordinates since its basically looking down on a plane) it is centered so that the origin is in the upper left corner. So it seems that, for instance with dark valley, its z coordinate was negated from what it was in Clear Sky, which would explain why squads took so long for them to travel to garbage (basically it was super far off the map compared to garbage). This could also possibly explain why squads sometimes take odd routes (though that could have been a result of edge editor).

So for example, dark valleys offset was: 2735.0, 1000.0, 2845.0 in Clear Sky, whereas in Call of Chernobyl its distance was:
2735.0, 1000.0, -2845.0. This made the distance between dark valley and garbage go from on average 400 units to 5700 or so on average. With the z axis set to -2845, dark valley is treated like it is located north of chernobyl npp which explains the distance between the points on dark valley and garbage.

Right now I'm working on editing the level offsets to match up more closely to Clear Sky. This should alleviate all of the final issues I am having.

Edit: Ahh, I see what happened. It looks like some offsets in CoC's game_levels.ltx are from the CoP game_levels.ltx and some are from the CS game_levels.ltx, which seems like its the reason some level distances are huge. In the CoP game_levels.ltx, the Z coordinate is negated for the CS levels.

User avatar
Bangalore
Explorer
Posts: 640
Joined: 09 Jun 2012, 19:02
Contact:

Re: More offline squad oddities

Postby Bangalore » 27 Jan 2016, 03:28

carperbr wrote:So I ended up testing this just a bit ago. You were indeed correct, game_levels.ltx seems to dictate distances between connected level points along with the graph points local coordinates.


carperbr, can you send me your game_levels.ltx? I'd like to update vanilla CoC spawn's graph to a better one.
My another goal would be to make better map transition points for AI, that players could never see squads disappearing in front of their eyes. It needs to lead out AI map outside of level boundaries.
"Some sort of pressure must exist; the artist exists because the world is not perfect. Art would be useless if the world were perfect, as man wouldn’t look for harmony but would simply live in it. Art is born out of an ill-designed world."

carperbr
Scavenger
Posts: 27
Joined: 15 Oct 2015, 00:44

Re: More offline squad oddities

Postby carperbr » 27 Jan 2016, 15:17

Here you go: https://mega.nz/#!r8wimaYS!_8TD961OO0uA ... w2K6hPlKsw

Distances between bar and garbage are a little odd, as I didn't realize that the one that has a distance of 485 is actually the cheat point in the northern area of the bar. I was planning on going in and editing the distances to reflect this, but its so tedious I've been putting it off for a while haha.

And yeah, I'd say the most noticeable for me is the point connecting Marshes and Cordon in the middle, by esc_smart_terrain_4_9. But thats mainly from the perspective of my mod where level transitioning is happening pretty frequently.


Return to “General Discussion”

Who is online

Users browsing this forum: No registered users and 3 guests

cron