aliens

Author Topic: [Solved] issues upgrading my mod to newer OXCE  (Read 7605 times)

Offline new_civilian

  • Commander
  • *****
  • Posts: 725
    • View Profile
[Solved] issues upgrading my mod to newer OXCE
« on: November 12, 2019, 12:08:32 pm »
Pardon me if this has been fixed in the newer versions, but I am still using 5.4.1 as it has everything I need and i do not want to update my giant personal mod.
Anyway, I found a tiny bug with spawned units:

If a small ufo crashes and all aliens are killed, you get an auto-recovery message AND you get the spawned turrets of your craft delivered home. I had them set to fixedweapon but the game still delivers the turrets home.

Its not a big issue, but I sure was surprised to see the turrets in my inventory--- ;D

Sadly I could not take them with me on a mission.
« Last Edit: February 11, 2023, 10:56:13 pm by Meridian »

Offline krautbernd

  • Commander
  • *****
  • Posts: 1108
    • View Profile
Re: Recovery of spawned units.
« Reply #1 on: November 12, 2019, 01:38:37 pm »
I had them set to fixedweapon but the game still delivers the turrets home.
fixedweapon only defines if the weapon can be dropped, not whether the unit itself is recoverable.

You might want to have a look at the ruleset reference.

Offline Meridian

  • Global Moderator
  • Commander
  • *****
  • Posts: 9099
    • View Profile
Re: Recovery of spawned units.
« Reply #2 on: November 12, 2019, 01:43:16 pm »
Also, whatever issues you have with nightly OXC/OXCE, it can be solved within 15 minutes tops.
No reason not to upgrade.

Offline ohartenstein23

  • Commander
  • *****
  • Posts: 1933
  • Flamethrowers fry cyberdisk circuits
    • View Profile
Re: Recovery of spawned units.
« Reply #3 on: November 12, 2019, 02:24:01 pm »
Do the spawner items have "recover: false" on them? If they don't, then that's just normal item recovery for the items on the mapBlock, and can be solved at the mod level. If they do, then it's a code issue that needs to be checked.

Edit: I'm not able to replicate this behavior. What mod were you playing, and do you have a save just before the mission?
« Last Edit: November 12, 2019, 03:01:05 pm by ohartenstein23 »

Offline new_civilian

  • Commander
  • *****
  • Posts: 725
    • View Profile
Re: Recovery of spawned units.
« Reply #4 on: November 14, 2019, 02:00:19 pm »
Yes all objects (spawner and spawn) have the recoverable: false setting. I only added the fixedweapon entry to make EXTRA sure.
I am using my own personal mod and sadly i do not have a savegame.
The bug is VERY elusive as you need an auto-recovery for it to make it appear, sorry about that.

Somewhat related:

If you make an equippable tank and give it on a mission e.g a auto-cannon with e.g incendiary rounds loaded and return with 3 (or X) shots of 6 left, you will receive 3 (or X) full clips of whatever ammo is listed FIRST in the items section of your auto-cannon, not necessary the incendiary ammo, but the FIRST entry. I have to admit I abused that recently by starting with a weapon i only had one clip for and farmed/harvested the free ammo then... ::)

Those are not really dreadful bugs, but I wanted to contribute a bit to your excellent(what an understatement) work.

And yes I know it isn't that difficult to upgrade, but I am very LAZY atm...  ::) :-[
« Last Edit: November 14, 2019, 02:17:08 pm by new_civilian »

Offline ohartenstein23

  • Commander
  • *****
  • Posts: 1933
  • Flamethrowers fry cyberdisk circuits
    • View Profile
Re: Recovery of spawned units.
« Reply #5 on: November 14, 2019, 02:34:08 pm »
I haven't been able to reproduce the recovery bug by making a mod to test the auto-recovery on the latest OXCE. Bug reports aren't really helpful on older versions when we can't be sure when and whether the bug was fixed.

The ammo loading issue isn't a bug, this is the intended behavior for vanilla HWPs - the 30 rounds of tank/cannon ammo turns into 1 clip of 30 for the battle. Then if you fire 3 rounds, the 27/30 clip gets recovered as 27 separate items. In order for "normal" recovery of ammo from a non-soldier unit, you need to set the clipSize on the weapon equal to the clipSize on the ammo.

Offline Meridian

  • Global Moderator
  • Commander
  • *****
  • Posts: 9099
    • View Profile
Re: Recovery of spawned units.
« Reply #6 on: November 14, 2019, 02:54:23 pm »
The ammo loading issue isn't a bug, this is the intended behavior for vanilla HWPs - the 30 rounds of tank/cannon ammo turns into 1 clip of 30 for the battle. Then if you fire 3 rounds, the 27/30 clip gets recovered as 27 separate items. In order for "normal" recovery of ammo from a non-soldier unit, you need to set the clipSize on the weapon equal to the clipSize on the ammo.

He complained about recovery a different ammo type than loaded.

Which is also not a bug, but an OpenXcom feature... HWPs support only 1 ammo type.

Offline new_civilian

  • Commander
  • *****
  • Posts: 725
    • View Profile
Re: Recovery of spawned units.
« Reply #7 on: November 15, 2019, 11:59:08 am »
Ok, many thanks for the clarification and the clipsize thing, I will edit the files accordingly.
Aaaand I decided to update my mod to the newest exe in the coming days/weeks/months.  :)

edit:

Ok make that never, the amount of required restructuring and number-changing is insane. Why did you actually remove the ability to use high numbers, i mean: The whole thing worked.  ???
Never change a winning team is my motto.

Anyway, if I ever gonna use 6.1.1 it will be for a entirely new personal mod or for playing WH40k only. I will stick to my beloved and working 5.4.1 installation for my "old" personal mod.
« Last Edit: November 19, 2019, 01:39:20 pm by new_civilian »

Offline luke83

  • Commander
  • *****
  • Posts: 1559
    • View Profile
    • openxcommods
Re: Recovery of spawned units.
« Reply #8 on: November 22, 2019, 04:39:23 am »
Just lie to it and reserve more numbers/memory for your mod, no number changes required then  :P
« Last Edit: November 22, 2019, 04:41:46 am by luke83 »

Offline Meridian

  • Global Moderator
  • Commander
  • *****
  • Posts: 9099
    • View Profile
Re: Recovery of spawned units.
« Reply #9 on: November 22, 2019, 10:18:16 am »
Aaaand I decided to update my mod to the newest exe in the coming days/weeks/months.  :)

edit:
Ok make that never, the amount of required restructuring and number-changing is insane. Why did you actually remove the ability to use high numbers, i mean: The whole thing worked.  ???
Never change a winning team is my motto.

You can tell OXCE (same for OXC) to allow higher numbers for your mod with just one line of code, see here: https://openxcom.org/forum/index.php/topic,6586.msg119558.html#msg119558

PS: it was changed, because it DIDN'T work... conflicts between mods were happening often when using indices above 1000. Also, it wastes memory.

PS2: once again, no matter what issues you have, I can fix it in 15 minutes or less; if you still have issues upload your mod and I will upload a fixed version for you.
« Last Edit: November 22, 2019, 10:20:27 am by Meridian »

Offline luke83

  • Commander
  • *****
  • Posts: 1559
    • View Profile
    • openxcommods
Re: Recovery of spawned units.
« Reply #10 on: November 22, 2019, 11:26:22 am »
@MERIDIAN, How do you renumber the items so quickly, i have been avoiding the issue as it sounds painful to manually fix? If you have a Quick solution, once i am closer to going public (which is only a few weeks away), perhaps you could work your magic for me also  ;)

Offline Meridian

  • Global Moderator
  • Commander
  • *****
  • Posts: 9099
    • View Profile
Re: Recovery of spawned units.
« Reply #11 on: November 22, 2019, 12:12:11 pm »
@MERIDIAN, How do you renumber the items so quickly, i have been avoiding the issue as it sounds painful to manually fix? If you have a Quick solution, once i am closer to going public (which is only a few weeks away), perhaps you could work your magic for me also  ;)

I don't, I just increase index limit, if there are too many of them.

I'm only saying that making a mod run on oxce 6.1.1 is a matter of minutes... and cleanup can be done later.

Offline luke83

  • Commander
  • *****
  • Posts: 1559
    • View Profile
    • openxcommods
Re: Recovery of spawned units.
« Reply #12 on: November 22, 2019, 12:13:56 pm »
Right, no problem, i thought you had some magic script that worked out what was used and re-numbered everything :)

Online Solarius Scorch

  • Global Moderator
  • Commander
  • *****
  • Posts: 11728
  • WE MUST DISSENT
    • View Profile
    • Nocturmal Productions modding studio website
Re: Recovery of spawned units.
« Reply #13 on: November 23, 2019, 01:30:15 pm »
Eh, renumbering everything sounds like relaxing chill time. 8)

Offline luke83

  • Commander
  • *****
  • Posts: 1559
    • View Profile
    • openxcommods
Re: Recovery of spawned units.
« Reply #14 on: November 23, 2019, 09:19:54 pm »
Personally, i would rather rub Deep Heat on my private parts but hey, each to there own :)

https://www.deepheat.com.au/