Jump to content

[X:CE 0.34.2] MeleeVehicles + BurstFire weapon CTD


Policenaut

Recommended Posts

Giving a unit with the MeleeVehicles ability a weapon with BurstFire will cause the game to crash to desktop when the unit gets its turn during ground combat. SingleFire weapons are ok.

To reproduce: Give the lightdrone the MeleeVehicles ability and start a GC mission featuring lightdrones. The game will load fine and your turn will play out ok. During the alien turn it will CTD when the lightdrones gets their turn.

Link to comment
Share on other sites

I require MeleeVehicles for my custom alien units or they get the passiveness bug and one of them uses a burst fire weapon. For now I'm replacing it with a SingleFire weapon instead but a fix, or better, an alternative to MeleeVehicles to fix the passive AI bug for custom alien units would be nice.

Link to comment
Share on other sites

52 minutes ago, Policenaut said:

I require MeleeVehicles for my custom alien units or they get the passiveness bug and one of them uses a burst fire weapon. For now I'm replacing it with a SingleFire weapon instead but a fix, or better, an alternative to MeleeVehicles to fix the passive AI bug for custom alien units would be nice.

Meleevehicles is a melee AI to attack vehicles. It does not created to use it at that way. Did you use my AI at your custom race? Or just take all my AI and delete X-Division part and add yours.

Link to comment
Share on other sites

Using your aiprops wouldn't make any difference. Custom race AI units are not included in the hardcoded AI system that makes the units more aggressive. The passive AI bug is only noticeable if your custom race unit is not accompanied by any of the standard races or a custom race unit with the MeleeVehicles ability (since it gives the unit the hardcoded Reaper AI settings). You have probably not experienced the bug because:

1. Your custom units are accompanied by standard units or MeleeVehicles units. 

2. Your custom units have the MeleeVehicles ability.

To replicate the bug create a new alien race and populate a UFO to only carry that race. Without the MeleeVehicles ability or any standard races to "activate" it, you will notice that they'll often not use their weapons even when practically hugging Xenonauts.

I need to use the MeleeVehicles ability or my units like the suicide bombing slime won't use its weapon properly. With the MeleeVehicles ability it 100% uses its weapon correctly. This also applies to the other custom race units I've made. I understand that the MeleeVehicles ability was not intended for this but it does fix the passive AI bug, the only apparent drawback being this BurstFire bug.

Link to comment
Share on other sites

Something else is broken there, the MeleeVehicles ability only does one thing, which is modify the pathfinding algorithm of melee units so they don't get stuck in front of vehicles. That's it.

It also triggers the same condition as Reapers in the code, and forces the script to Aggressive, regardless of what's set in the aiprops. There aren't more Reaper settings than that.

Link to comment
Share on other sites

I narrowed it down to being the BurstFire + MeleeVehicles combo causing CTD. It would be nice if abilities that makes the unit receive the same conditions as the standard races were added, similar to how MeleeVehicles gives the unit Reaper conditions. This would allow for better AI customization and I wouldn't have to piggyback on MeleeVehicles which isn't intended for non melee units.

Edited by Policenaut
Link to comment
Share on other sites

Again, there are no "standard race conditions" in the code that I can find, except for one Reaper rule. Everything else is controlled via aiprops only. A race with the same aiprops as Caesans is supposed to work 100% the same as actual Caesans.

Since MeleeVehicles is only for a melee alien and BurstFire is ranged, I don't see any point in investigating this.

Link to comment
Share on other sites

7 minutes ago, Solver said:

Again, there are no "standard race conditions" in the code that I can find, except for one Reaper rule. Everything else is controlled via aiprops only. A race with the same aiprops as Caesans is supposed to work 100% the same as actual Caesans.

Since MeleeVehicles is only for a melee alien and BurstFire is ranged, I don't see any point in investigating this.

I have no idea why custom races act passive when not close to standard race/MeleeVehicles units then. Even copy pasting the exact same AIprops settings as standard races still showcases the bug. Oh well, I'll keep using MeleeVehicles as a workaround but settle for SingleFire weapons instead.

Edited by Policenaut
Link to comment
Share on other sites

3 minutes ago, Policenaut said:

I have no idea why custom races act passive when not close to standard race/MeleeVehicles units then. Even copy pasting the exact same AIprops settings as standard races still showcases the bug. Oh well, I'll keep using MeleeVehicles as a workaround but settle for SingleFire weapons instead.

I also have no idea about that, but the bug is probably somewhere in that AI logic then, because there are no other hardcoded race rules.

Link to comment
Share on other sites

@Solver

There is some files at assets folder like groundcombat folder. Is there any use of those files in AI at all?

@Policenaut

This video is a show case for mostly other things but ALL of the races here are custom and there is only 2 black dog with meleevehicle ability, so %95 of the units don't have that. There is no default unit here. It's the aggresive AI i created. As you see, the melee and ranged ones are attacking without problem.

But the hugging but not firing bug is the same we experienced with drones and androns together as both default races of the game. I don't know the problem at your side but as you see, it's working at video.

Link to comment
Share on other sites

I watched this tragedy unfold but I have to step in between this now.

 

29 minutes ago, Policenaut said:

Using your aiprops wouldn't make any difference. Custom race AI units are not included in the hardcoded AI system that makes the units more aggressive. The passive AI bug is only noticeable if your custom race unit is not accompanied by any of the standard races or a custom race unit with the MeleeVehicles ability (since it gives the unit the hardcoded Reaper AI settings). You have probably not experienced the bug because:

1. Your custom units are accompanied by standard units or MeleeVehicles units. 

2. Your custom units have the MeleeVehicles ability.

Rookie, come back when you got the experience to talk.

Ofcourse we did test in every imaginable way. This included this way as well.

I believe its rude when someone offers you his work which he sweat blood and tears for and you didnt even test it.

31 minutes ago, Policenaut said:

To replicate the bug create a new alien race and populate a UFO to only carry that race. Without the MeleeVehicles ability or any standard races to "activate" it, you will notice that they'll often not use their weapons even when practically hugging Xenonauts.

Thats not a custom race problem, this happens for andron units too.

Heres the thing you dont know: Having full TU units and/or xenonaut units with and without TU nearby makes units very passive, but thats true for all races. The codeline which is partly responsible is the CautiousDistance: The distance to a known enemy before the AI starts reserving TU for reaction shots, but its not limited to that.
            -->

You could call it an AI flaw but GJ specifically adressed this problem with an aggressive script enforcement, and maybe things beyond that, and especially for melee untis which go close.

 

38 minutes ago, Policenaut said:

I need to use the MeleeVehicles ability or my units like the suicide bombing slime won't use its weapon properly. With the MeleeVehicles ability it 100% uses its weapon correctly. This also applies to the other custom race units I've made. I understand that the MeleeVehicles ability was not intended for this but it does fix the passive AI bug, the only apparent drawback being this BurstFire bug.

 

 

First of all you dont understand that the MeleeVehicles ability isnt a fix for anything. There is no bug for rapid fire, although its good to know that this doesnt work.

There is no passive AI bug, just a tendency. This kind of behaviour works very well for ranged units waiting behind a corner, and doesnt work for melee units that well or for units with low range, therefore the aggressive tweak enforcement. GJ KNOWS about this.

I mean i dont even want to start on what other tendencies there are ... and you just scraped the top of. Theres is the low accuracy tendency, and we dont call it a bug either ( the X-Division team ).

 

But my point was:

You dont seem to understand that MeleeVehicles AKA Reaper code tweak is just a number tweak on top if the normal AI code. If you figure out EXACTLY what the Reaper Code tweak does you can achieve the same results without the MeleeVehicles ability.

But we dont even know how the general/race/rank values are getting merged. Added and/or replaced seems the most possible ones, but the truth is, we dont know. Its all experience.

 

 

In a nutshell, you simply dont know how to code the AI, and thats all there is to this thread.

The AI file doesnt tell you everything, there are hidden value tweaks, and some descriptions are partly wrong, or do exactly the opposite of what they state, a +/- can change the whole behaviour overall. Basically you cant look at the numbers and guess what it will do, only experience can tell.

There have been several people giving their utmost effort to make a good AI, namely

@TacticalDragon, he gave 6 months of continues work to make an incredible good AI and he even he was not really "finished", but still considers it his life achievment for the xenonauts community. Great KUDOS to inspire many AI modders to do this.

@drages, not much to say here, its self evident. 2 years experience, started as tweaks from @TacticalDragons AI, was improved and abolished, then made completely independend. Between the .30 and .32 patch an new-old merge was performed, which took major insights from TacticalDragons AI into X-Division again, forming an ultimate state which im very happy about as it stand right now.

And here you are crying bug after 1 month.

 

Heres the advice: Once you are capeable of codeing the AI you can produce mostly any result you want, apart from hardcoded things

 

I suggest moving this thread into the XCE General discussion thread as this doesnt qualify as a bug by far.

 

I apologise for my aggressive tone, thats just my style sometimes, but isnt meant badly in any way. I apologise if i offended anybody.

 

16 minutes ago, Policenaut said:

I have no idea why custom races act passive when not close to standard race/MeleeVehicles units then. Even copy pasting the exact same AIprops settings as standard races still showcases the bug. Oh well, I'll keep using MeleeVehicles as a workaround but settle for SingleFire weapons instead.

Uhm ? Well ... i dont even know how to start ... and i dont want to .. im just saying ... if you give an alien an a 30 dmg weapon instead of 60 it will behave completely different even with the exact same AI. The same goes for high TU costs, they are lethal in a lot of ways to the AI.
As far as our experience goes, i wouldnt recommend giving a unit a higher than 45% tu costs for a weapon.

The AI majorly changed with Tu costs ranging from 15 - 30, 30 - 45, 45 - 70 and 70 to 100 percent. All of this tu ranges produce entirely different results with the same AI.

The same goes for weapon damage but is more granualar and comprehensible.

High Tu/Low damage/low accuracy are lethal to the AI behaviour.

 

Every AI is unique to its content environnment. If you want to make new content, set the units stats, set the weapon stats, and then you can start to make an AI for it, and if you change environment values, the behaviour changes as well.

 

24 minutes ago, Solver said:

I also have no idea about that, but the bug is probably somewhere in that AI logic then, because there are no other hardcoded race rules.

Thats what i ve been saying.

 

 

Link to comment
Share on other sites

What does my post count have to do with anything? I've tested many different values in aiprops similar to both the things you did in X-Division and the things the XNT team did and pretty much nothing except adding MeleeVehicles or having standard races around fixed the passivity issues. CautiousDistance and messing with TU did not solve it.

Please stop projecting and going for personal attacks. I tested various things and experienced this bug and wanted to report it to improve the modding capabilities. You can easily replicate this issue and Drages even mentioned that your custom unit only UFOcontents are accompanied with MeleeVehicles units, thus fixing the passivity. The weapon damage/range/TU cost issues you mentioned were also all fixed by adding MeleeVehicles.

MeleeVehicles is a good enough workaround for now for what I have in mind, so no need to focus too much on the AI stuff and instead fix other more critical stuff. I appreciate you guys giving your insight but no need to get so worked up about it. 

Link to comment
Share on other sites

20 minutes ago, Policenaut said:

Drages even mentioned that your custom unit only UFOcontents are accompanied with MeleeVehicles units, thus fixing the passivity.

I did not say that.

Meleevehicle ability added to game just some weeks ago, and i already created many AI's before that. Did you watch the video i linked here? I said they all custom race with 1-2 meleevehicle ability only, and they were not even on battle for long time. This video is a pure example for it. It's the most aggressive AI possible at this game including tactical behavior.

Meleevehicle AI got many flaws as it attacks %90 to civillians and vehicles. As i say again,at my tests, i only saw this with drone and andron AI which both default races at all.

After i saw meleevehicle abilities behavior, i needed to find different ways like making very short ranged units rather then melee ones.

I won't discuss it anymore. I tried to share my experience, my results and visual evidence. It's up to what to get or not. We tried %98 of the possibilities at Xenonauts modding so i just don't want you to lose tons of times with same things. Charon opened tons of topics about modding tricks too. 

Edited by drages
Link to comment
Share on other sites

5 minutes ago, Policenaut said:

What does my post count have to do with anything? I've tested many different values in aiprops similar to both the things you did in X-Division and the things the XNT team did and pretty much nothing except adding MeleeVehicles or having standard races around fixed the passivity issues. CautiousDistance and messing with TU did not solve it.

Nothing :), who mentioned that ?

Im not saying your passive tendency doesnt exist, I AND Solver AND Drages are saying its not a bug. So there is no bug and this thread needs no fix. Its a logic source code thing.

Why do you miss that GJ KNOWS about this ?

Apart from the fact that i dont want Solver to actually touch the AI code :).

10 minutes ago, Policenaut said:

Please stop projecting and going for personal attacks. I tested various things and experienced this bug and wanted to report it to improve the modding capabilities. You can easily replicate this issue and Drages even mentioned that your custom unit only UFOcontents are accompanied with MeleeVehicles units, thus fixing the passivity. The weapon damage/range/TU cost issues you mentioned were also all fixed by adding MeleeVehicles.

What part of "You are too inexperienced to find the sweetspot for the AI" did you not undrestand ? Ah goddamit, nothing personal.

Ok, due to every content environemnt needing its own AI i believe you lack the experience to find the right place to produce the behaviour you want.

Dunno if that makes it better.

13 minutes ago, Policenaut said:

MeleeVehicles is a good enough workaround for now for what I have in mind, so no need to focus too much on the AI stuff and instead fix other more critical stuff.

There is no BUG ! There is no FIX ! :) There is no WORKAROUND.

You are using a scissor to cut stone and then complain it doesnt do the job.

15 minutes ago, Policenaut said:

I appreciate you guys giving your insight but no need to get so worked up about it. 

Ah, im just happy that somebody is actually modding and playing the ball back at me. Its the best thing in the world to work together :). or to yell at somebody. Either of those things.

 

And i didnt do that for you, but every second Solver spends reading what i write instead of finding a solution for a problem which doesnt exist is worth every letter. So we are trying to give insight into this issue for you as well as Solver so he can think about other things :).

Cheers :)

 

Link to comment
Share on other sites

9 minutes ago, drages said:

1-2 meleevehicle ability only

A single unit with the proper AI behaviour, i.e standard race units or units with MeleeVehicles, is enough to "activate", "fix", "cure" the custom race and bypassing the AI passivity bug. 

Nevermind all this, I get the feeling we're just misunderstanding each other, no hard feelings. I have a workaround that works for me and I agree that it might not be worth fiddling too much with the AI and potentially messing it up.

@Solver

If you want to go through with this, I could set up a test mod with some included saves. The workaround is alright though except for the BurstFire CTD but that's acceptable. Might be better to focus effort on other areas.

Link to comment
Share on other sites

5 minutes ago, Policenaut said:

A single unit with the proper AI behaviour, i.e standard race units or units with MeleeVehicles, is enough to "activate", "fix", "cure" the custom race and bypassing the AI passivity bug. 

Does this occur per map, or does it appear to have a range ?

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...