Jump to content
Charon

How does the whole modmerge thing work ?

Recommended Posts

7 hours ago, Solver said:

So you could post those files here and accelerate the process of me looking at them :)

Solver, can you look to the code and can say why melee weapon aliens (like reapers) don't attack vehicles. We need it if it's possible because vehicles are OP against melee ones. (I dont talk about zombify, our melee creatures does direct damage mostly)

Share this post


Link to post
Share on other sites

That's nothing special, it's been known from the beginning, melee weapons cannot target vehicles.

Share this post


Link to post
Share on other sites
10 minutes ago, Solver said:

That's nothing special, it's been known from the beginning, melee weapons cannot target vehicles.

Yes i know it, i just want to know, can you help to activate this option to make them attack vehicles?

Share this post


Link to post
Share on other sites

It's difficult to say. I might test it at some point - just letting them target vehicles wouldn't be a big issue, but I suspect it may cascade into a bunch of problems, primarily related to the fact that vehicles occupy many tiles.

Share this post


Link to post
Share on other sites
1 hour ago, Solver said:

It's difficult to say. I might test it at some point - just letting them target vehicles wouldn't be a big issue, but I suspect it may cascade into a bunch of problems, primarily related to the fact that vehicles occupy many tiles.

I fear that title problem too but it could give a try, because this game coding is really strange at some points..

For example, we did some tests about "secondary weapon" at enemy AI. They did not use it at their turn, but they used secondary weapon at reaction shots and used the sprites of the secondary weapon. It's like they got a side arm just for reaction shots.. :)

and do you work on XCE too by any chance?

Share this post


Link to post
Share on other sites

I'm not working on X:CE right now, my most recent Xenonauts work was to upgrade the forums over a couple of weeks :)

Share this post


Link to post
Share on other sites
10 minutes ago, Solver said:

I'm not working on X:CE right now, my most recent Xenonauts work was to upgrade the forums over a couple of weeks :)

So, do you plan to work XCE in near future?

Share this post


Link to post
Share on other sites

Hey Solver, drages wants to marry you, just say yes please, so we can get this over with and out of my thread.

Share this post


Link to post
Share on other sites

It's possible. If I do, I'll need to post a thread to discuss alien mission modding, as I have some half-finished stuff there, and there's some more unreleased work that has been done for a while, mostly by llunak.

Now let's get out of Charon's thread as he suggests :)

Share this post


Link to post
Share on other sites

You mean me? Not so far, I haven't done X:CE work, but I am keeping this issue in mind.

Share this post


Link to post
Share on other sites

Okay, thx for replying and keeping it on your mind :).

Edited by Charon

Share this post


Link to post
Share on other sites

Im just throwing this out there but it looks like theres no way make a mod that adds actual sound content to existing ones.

<?xml version="1.0"?>
<Sounds>
  <Sound MODMERGEATTRIBUTE="name" MODMERGE="update" name="AirCombatBegins" volume="0.75" group="1" comment="Played when the air combat begins.">
    <Wave MODMERGE="insert">sound/AircombatBegins/AircombatBegins (1).ogg</Wave>
  </Sound>
</Sounds>

produces a 

Wed Nov 16 19:46:44 2016: Xenonauts, version .
Wed Nov 16 19:46:44 2016: Pixel Shader Version: ffff0300
Wed Nov 16 19:46:56 2016: MOD ERROR: An element to insert already exists: Wave
Wed Nov 16 19:46:56 2016: MOD ERROR: Merging XML for sounds.xml from mod mods/x-division 0.99 beta/ failed.

error. Nona does the "Wave" already exist but thats what we want to insert.

I cant "insert" the "name" because it already exists ( name="AirCombatBegins" ). I cant "update" the "name" because then all <Wave> get overwritten as well.

 

Looks like its not working, does anybody have a different oppinion ?

Share this post


Link to post
Share on other sites
1 hour ago, Charon said:

Im just throwing this out there but it looks like theres no way make a mod that adds actual sound content to existing ones.


<?xml version="1.0"?>
<Sounds>
  <Sound MODMERGEATTRIBUTE="name" MODMERGE="update" name="AirCombatBegins" volume="0.75" group="1" comment="Played when the air combat begins.">
    <Wave MODMERGE="insert">sound/AircombatBegins/AircombatBegins (1).ogg</Wave>
  </Sound>
</Sounds>

produces a 


Wed Nov 16 19:46:44 2016: Xenonauts, version .
Wed Nov 16 19:46:44 2016: Pixel Shader Version: ffff0300
Wed Nov 16 19:46:56 2016: MOD ERROR: An element to insert already exists: Wave
Wed Nov 16 19:46:56 2016: MOD ERROR: Merging XML for sounds.xml from mod mods/x-division 0.99 beta/ failed.

error. Nona does the "Wave" already exist but thats what we want to insert.

I cant "insert" the "name" because it already exists ( name="AirCombatBegins" ). I cant "update" the "name" because then all <Wave> get overwritten as well.

 

Looks like its not working, does anybody have a different oppinion ?

Change the modmerge from update to replace and remove the modmerge inside the <wave> element. Then copy paste all the original <wave> elements and add your own as well. It will make your mod overwrite any other mods that edit the same sound though.

Edited by Policenaut

Share this post


Link to post
Share on other sites
2 minutes ago, Policenaut said:

Change the modmerge from update to replace and remove the modmerge inside the <wave> element. Then copy paste all the original <wave> elements and add your own as well. It will make your mod overwrite any other mods that edit the same sound though.

No shit, holmes. Thats what i stated.

1 hour ago, Charon said:

but it looks like theres no way make a mod that adds actual sound content to existing ones.

Its kind of contradicting to a modmerging system. But its ok, i believe llunak and solver have done their best and i can see the improvement over a 100% manual overwriting procedure. So props to @llunak and @Solver for designing this awesome system. Im just hitting the wall wherever i go, but thats ok.

Thx for the try :) @Policenaut

Share this post


Link to post
Share on other sites

Still lets you edit the entry without overwriting the original file so it's not exactly useless. Some files like loadout.xml don't even work with the modmerge system though, at least it's possible to edit sounds without overwriting the original files.

Share this post


Link to post
Share on other sites
Just now, Charon said:

Tested it and it looks to work. This is the code i used


  <Sound MODMERGEATTRIBUTE="name" MODMERGE="update" name="AirCombatBegins" volume="0.6" group="1" comment="Played when the air combat begins.">
    <Wave MODMERGEATTRIBUTE="name" MODMERGE="insert" name="Sound1">sound/AircombatBegins/AircombatBegins (1).ogg</Wave>
    <Wave MODMERGEATTRIBUTE="name" MODMERGE="insert" name="Sound2">sound/AircombatBegins/AircombatBegins (2).ogg</Wave>
    <Wave MODMERGEATTRIBUTE="name" MODMERGE="insert" name="Sound3">sound/AircombatBegins/AircombatBegins (3).ogg</Wave>
  </Sound>

You just have to give individual names to the <Wave>. This can be a bit tiring when doing 400 sounds.

All 3 were playing at the start + the vanila jetenter.ogg too. 1/X propability is likely, where X is is the total number of sounds available.

Sot it IS possible, if you know how. You just need to give the desired code line a name="X" if you want to individually overwrite/update/insert/replace it.

Edited by Charon

Share this post


Link to post
Share on other sites
On 11/17/2016 at 8:52 AM, Policenaut said:

Still lets you edit the entry without overwriting the original file so it's not exactly useless. Some files like loadout.xml don't even work with the modmerge system though, at least it's possible to edit sounds without overwriting the original files.

is there any way to implement one´s own loadouts at all? I even tried to overwrite the original loadout.xml and it still keeps the old one, when starting a new game. That´s weird.. Would a fresh game install and ovewriting the loadout.xml before the first game start help or is it somehow hard coded anyway and vanilla loadouts can´t ever be changed anyway?

edit: my new loadouts.xml was just missing the modmerge="replace" command and now everything is fine. please ignore the above questions

Edited by Casaubon
found the answer

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×