* Allow adding jeeps and robots to sectors now
* From Lua side, it is now possible to add differing amount of arguments to the function. Minimum required is 3 (sector x & y and amount of admins)
So all of the following examples will work correctly:
- UB_SetNumberJa25EnemiesInSurfaceSector( x, y, ubNumAdmins )
- UB_SetNumberJa25EnemiesInSurfaceSector( x, y, ubNumAdmins, ubNumTroops )
- - UB_SetNumberJa25EnemiesInSurfaceSector( x, y, ubNumAdmins, ubNumTroops,ubNumElites )
- UB_SetNumberJa25EnemiesInSurfaceSector( x, y, ubNumAdmins, ubNumTroops,ubNumElites, ubNumTanks )
- UB_SetNumberJa25EnemiesInSurfaceSector( x, y, ubNumAdmins, ubNumTroops,ubNumElites, ubNumTanks , ubNumJeeps )
- UB_SetNumberJa25EnemiesInSurfaceSector( x, y, ubNumAdmins, ubNumTroops,ubNumElites, ubNumTanks , ubNumJeeps, ubNumRobots )
Lua scripts expect to receive the same profileID value back from l_FindSolderByProfileID() that is supplied to it on the script side. This is a bit suboptimal as we constantly keep searching for the correct soldier on different calls to C++ side with the way it works now.
* Contract duration lines are greyed out if the player lacks funds
*Selecting a mix of AIM and other merc types allows renewing contracts for selected AIM mercs
* Multiselection of only mercs whose contracts are not renewable (IMPs, rebels, etc) will have greyed out contract lines
All the calls where this was used are functionally identical when we just supply UID to the original FindSoldierByProfileID() call with fPlayerMercsOnly set to FALSE
When enemy attacks the starting sector and player is in tactical view. We go from tactical to strategic screen to show the prebattle interface instead of staying in tactical. The game errors on the sector assert when trying to draw the glowing red locator around the sector just before displaying the prebattle interface.
Normally the sector gets set properly when compressing time for the first time in a new game start but due to UB going into playing the intro video, it skips the call to HandleTimeCompressWithTeamJackedInAndGearedToGo() that would eventually set it. Neither can we rely on setting the sector when initiating the prebattle interface since MapScreenHandle() tries to display the locator before the PBI gets initialized.
ContinueDialogue was possible to be called with pSoldier that isn't null but is not valid pointer to MercPtrs array resulting in debugger catching an illegal memory access.
fixes issue #498 where retreating from combat in a sector that has a merc
inbound via the airdrop marker causes combat not to end
the reason this fails is that a the inbound soldier counts as being in
the sector being retreated from, even though he isn't
I add a check for `MercPtrs[i]->bInSector` so this doesn't happen
that way the function doesn't leave early and CheckForEndOfCombatMode is
reached