Jump to content

ShowUFOsOnMission and other UFO variables


johnnylump

Recommended Posts

Hello,

 

I'm playing around with DefaultGameCore and have implemented a number of changes successfully, but I can't seem to change much when it comes to UFO frequency. (I'd like a lot more of them).

 

Here's what I've put in:

 

ABDUCTION_LURK_PCT=75; increased from 50

SMALL_UFO_LURK_PCT=75; increased from 0

LARGE_UFO_LURK_PCT=75; increased from 50

 

ShowUFOsOnMission=1

AI_TERRORIZE_MOST_PANICKED = 75

LATE_UFO_CHANCE = 100; increased from 50

EARLY_UFO_CHANCE = 100; increased from 50

UFO_LIMIT = 6; increased from 2

UFO_INTERCEPTION_PCT=66

 

All this makes it seem like I should get several UFOs a month, but I'm only getting two (apart from satellite-hunting battleships that appear if I ignore a UFO).

 

Specifically, how does ShowUFOsOnMission work? From what I and others have observed, you won't get abductions in countries where you have s satellite, so how would you ever detect an abductor UFO on a mission in that country?

 

Reading others' posts, they've made it work, so I don't understand what I'm missing. Not clear on what the LURK or LIMIT or INTERCEPTION_PCT variables do, either (and I've read the main defaultgamecore.ini thread).

 

Thanks for any help you folks can provide.

 

Cheers,

JL

Link to comment
Share on other sites

Do you have several scattered satellites? I think they are needed to 'find' the incoming UFOs

 

Thanks for your reply --

 

Well, yes, I've got several, but I'll run some tests tonight with lots of birds up. It seems I'm seeing two a month regardless. And my question stands: How do you ever detect abductors on abductor missions if satellites apparently prevent abductor missions in the country they are assigned to?

Link to comment
Share on other sites

Will try to clarify some.


UFO_INTERCEPTION_PCT is percentage chance that an UFO will require interception.

If set to 0, most UFOs will show on a radar after landing without need for interception. Only exception are crafts going to destroy a satelite, which require interception all the time as their target is in the air.
If set to 100 (or 101 to be sure), all UFOs need to be intercepted first.

There may be a bug, where are some landed crafts labeled as UFO-0 and bypassing this setting. UFO-X where X > 0 were acting right.

Edit: Realized that harvest missions are defined to be always landed so that may be it. It's in XComStrategyGame XGgeoscape function int DetectUFO(XGShip_UFO kUFO) along with setting below.


ShowUFOsOnMission=1 shows UFOs performing abduction and terror missions on the radar. If you shoot down terror mission UFO, the mission will not happen at all. If you shoot down any of abduction mission UFOs, you will be presented with less options when choosing what country to help with the abduction.

Also applies what tsanford01 wrote. Sattelite coverage is needed in order to detect those UFOs.

Edited by Drakous79
Link to comment
Share on other sites

And my question stands: How do you ever detect abductors on abductor missions if satellites apparently prevent abductor missions in the country they are assigned to?

Haven't verified it codewise, but my guess is there is some internal check, that prevents abductions from happening if having 100% satellite coverage. Test with 15 satellites up and see what happens.

Link to comment
Share on other sites

ABDUCTION_LURK_PCT

SMALL_UFO_LURK_PCT

LARGE_UFO_LURK_PCT

 

There is a lot of info in XComGame.upk, class XGOvermind, function DetermineAbductionTactics() and function DetermineUFOTactics().

 

Basically there is iNumLurkers = ([number from the ini] / 100) * [number of alien pods]. There's set minimum of 1 Lurker. Then iNumLurkers is clamped to an interval between iNumLurkers and [number of alien pods]. Next are all pods trialed against MustLurk() and IsBehindUFO and set to tactic XGTactic_Lurk or XGTactic_Patrol.

 

So in theory, the LURK setting isn't how long an UFO lingers around geoscape after a mission. It is setting how many alien pods at the mission site will have lurk tactic assigned. Whatever lurk tactic is...

 

I set all to 500. That would be 500/100*5 (alien groups I had at landing site) = 25. 25 > 1 then iNumLurkes = 25. Clamped between 25 and 5 we get 5. So all groups at my mission site should had lurk tactic assigned. Though I didn't see them behaving different from normal.

 

Edit: Added IsBehindUFO.

Edited by Drakous79
Link to comment
Share on other sites

Great stuff here, thanks. I'll run some tests on the UFO frequencies tonight and report back.

 

Good to know on lurk -- doesn't have anything to do with UFO interceptions. I would guess lurk means you have to enter the alien group's line-of-sight to activate it; otherwise they move around. Perhaps the one required lurker is the boss (outsider/sectoid cmdr / ethereal on UFO levels.

 

And it seems there's an animation for the aliens to call out to each other, so perhaps they activate nearby lurkers on their own.

Link to comment
Share on other sites

ABDUCTION_LURK_PCT

SMALL_UFO_LURK_PCT

LARGE_UFO_LURK_PCT

 

There is a lot of info in XComGame.upk, class XGOvermind, function DetermineAbductionTactics() and function DetermineUFOTactics().

 

Basically there is iNumLurkers = ([number from the ini] / 100) * [number of alien pods]. There's set minimum of 1 Lurker. Then iNumLurkers is clamped to an interval between iNumLurkers and [number of alien pods]. Next are all pods trialed against MustLurk() and set to tactic XGTactic_Lurk or XGTactic_Patrol.

 

So in theory, the LURK setting isn't how long an UFO lingers around geoscape after a mission. It is setting how many alien pods at the mission site will have lurk tactic assigned. Whatever lurk tactic is...

 

I set all to 500. That would be 500/100*5 (alien groups I had at landing site) = 25. 25 > 1 then iNumLurkes = 25. Clamped between 25 and 5 we get 5. So all groups at my mission site should had lurk tactic assigned. Though I didn't see them behaving different from normal.

 

I always was under the impression that it dictates how many alien groups will be stationary instead of moving. But I've never been able to confirm it.

Edited by BlackAlpha
Link to comment
Share on other sites

It's english having more meanings for one word :) Lurk around silently as moving or lurk at one place as hiding. But in this case, it may be hiding, because units already moving are patrolling.

 

If the math was right, I should had all groups hiding at one place, but watched them with AiDebugAi and 2 of them were patrolling. So it's possible, there is defined minimum of patrolling pods.

 

Edit: Overlooked IsBehindUFO. Seems like everything outside UFO are patrollers and the rest is assigned if to hide inside or if to patrol as well.

Edited by Drakous79
Link to comment
Share on other sites

 

 


LATE_UFO_CHANCE = 50; Chance of Aliens sending out a second UFO in the months after you've defeated the base
EARLY_UFO_CHANCE = 50
UFO_LIMIT = 2

UFO_LIMIT appears to be a cap on the # of UFOs that the player can be given in any month - so if the abduction/terror UFOs are enabled, then you will get the chance to see only 2 total, regarldess of "second-chance" UFOs flying around.

...early & late referring to before & after the Alien Base assault mission is completed.

It's set in XGStrategyAI class again. In funtion AIAddNewObjectives() is defined: if the game adds more UFOs than is the cap in DGC, then apply the cap.
if(iNumUFOs > class'XGTacticalGameCore'.default.UFO_LIMIT)
{
iNumUFOs = class'XGTacticalGameCore'.default.UFO_LIMIT;
}
iNumUFOs is used in functions AIAddNewObjectives(), AddLateMission() and AddUFOs.

Function AIAddNewObjectives()
  • By default adds 1 council mission, 1 terror mission, 1 abduction mission and 1 UFO (iNumUFOs = 1) every month. Only exception is no terror mission in the first month.
  • If you looted Hyperwave Beacon (finished Alien Base) then AddLateMission() is executed.
    Else adds 1 more abduction mission and if month is less than three and EARLY_UFO_CHANCE is true (100 and more in DGC) then adds 1 UFO (iNumUFOs + 1)
  • Then it checks for added abductions and if not enough, it adds 1 UFO (iNumUFOs + 1).
  • Then it checks iNumUFOs + 1 against the cap and executes AddUFOs() and AddNewOverseers().

Total of flyers without considering cap, alien base, overseers and early ufo (EU) is 1. With ShowUfosOnMission (SUOM) should be 8. With EU 9 in the first three months.
After assaulting the base total of flyers should stay the same, because EU is substituted with LE (LATE UFO).
Totals with SUOM will decrease over time because of better satellite coverage (Explained below in blue).
Also note that First Blitz from the Second Wave can be applied, where number of abduction sites is affected by eligible abduction targets and DGC setting SW_ABDUCTION_SITES.

Function AddLateMission()

  • If LATE_UFO_CHANCE is true (100 and more in DGC) then adds 1 UFO (iNumUFOs + 1)
    Else chooses from council, terror (if available) or abduction mission (if having enough abduction targets).
  • Interesting is, that if there isn't enough abduction targets (>= 3), abduction mission would not happen. Explains no abduction mission with good satellite coverage after alien base assault.

 

if(arrAbductionTargets.Length >= 3)
{
arrMissions.AddItem(2);
}
Function AddUFOs(int iNumUFOs, out array<XComGame.XGGameData.ECountry> arrVisible)
  • If I got it right, this function updates UFO array with crafts available for mission, subtracts -1 UFO (iNumUFOs - 1) and executes ChooseUFO() every month (except the fourth). Also it executes AddUFOToPool() in the first three months.
  • ChooseUFO() assignes detailed objective (mission, target and date) to UFO and removes assigned mission and date from objectives.
  • AddUFOToPool() adds UFO to Pool array, which serves as pool of available craft types depending on the current month. For an example it defines you won't get battleship in the first month.
  • At the end is a loop that runs until its internal check = iNumUFOs, executing AddUFOToPool() every loop. Also it executes FillUFOPool() if Pool array is empty. And FillDatePool() if Date array is empty.
  • FillUFOPool() fills Pool array with predefined saucers.

Conclusion
The end is a little confusing as references start to fly all over the place. I've continued to get complete picture about iNumUFOs and UFO_LIMIT. Also could get few things wrong so correct me, if you see anything wrong, please. It's late so there may be typos and nonsenses :smile:

Conclusion is that UFO_LIMIT can be possibly used to increase number of flying saucers, if we rework (iNumUFOs > class'XGTacticalGameCore'.default.UFO_LIMIT) conditional to iNumUFOs is less than DGC setting :smile: But I'm not sure, if there would be enough objectives, so this needs testing.

Until then it serves as the cap. Anbar is genius he figured some settings from observations.

Edit: Added info about terror mission not happening in the first month.

Edited by Drakous79
Link to comment
Share on other sites

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...