Author Topic: New alien race not spawning in UFOs when expected  (Read 1821 times)

Offline The Martian

  • Commander
  • *****
  • Posts: 754
  • "It implores you to listen to its arguments..."
    • View Profile
New alien race not spawning in UFOs when expected
« on: March 26, 2022, 01:04:14 am »
[OXCE Version: 7.5.7 (v2022-03-07)]

While learning the UFO controlling sections of OpenXcom's .rul files I've been trying to create a new alien race and have been using KiethSomataw99's Murmillo faction suggestion as a template. (The TFTD palette's limited amount of red can be a real pain at times.)

I have encountered a problem that I can't seem to get past, changing the code doesn't seem to produce any effect which makes me think that there is another option to control the race appearance rate that I need to configure or that my code incorrect.

The new units do work in "New Battle" mode from the main menu, however when I adjust the encounter rates in alienMissions: there seems to be almost no effect.

Even at 100% with all other races at 0% I still encounter just Aquatoids & Gillmen with the new race strangely absent.

At first I thought it wasn't working at all but after running a few missions with all races at 0% and the new race at 100% the new race spawned once... then back to Aquatoids & Gillmen for the next missions:

They spawned once (I haven't been able to get it to repeat since then) so 'something' was slightly working, just not as expected.

I'm attaching two .zip files to this post. One with the alienMissions: configured to 100% new faction encounter rate the other to a more balanced encounter rate, both seem produce the same results:
Test-New-Faction V0-1.zip (100% chance version)
Test-New-Faction V0-1.zip (Balanced chance of all races version)
« Last Edit: March 26, 2022, 01:08:09 am by The Martian »

Offline The Reaver of Darkness

  • Commander
  • *****
  • Posts: 1510
    • View Profile
Re: New alien race not spawning in UFOs when expected
« Reply #1 on: March 26, 2022, 05:43:18 am »
Check the races in missionScripts, as they can override the races in alienMissions.

Offline The Martian

  • Commander
  • *****
  • Posts: 754
  • "It implores you to listen to its arguments..."
    • View Profile
Re: New alien race not spawning in UFOs when expected
« Reply #2 on: May 02, 2022, 05:14:33 am »
Thank you that was it.

Code: [Select]
missionScripts:
  - type: gameStart
    missionWeights:
      0:
        STR_ALIEN_PROBE_MISSION: 100
    lastMonth: 0
    targetBaseOdds: 100
    raceWeights:
      0:
        STR_AQUATOID: 100
    startDelay: 120