Jump to content

Debug Mode: create a mission on the Geoscape?


hairlessorphan

Recommended Posts

Unfortunately, I needed it on the Geoscape.

 

The problem was I was getting reports that my mod (which fixes the squad selection screen when you have more than 6 units) was causing the VIP to not spawn. So I needed to do the actual Squad Selection process on a VIP mission.

 

It appears that the problem is because the spawn points on the map are 3x3, which means a maximum of 9 units. If you set your squad size to 9, the VIP can't fit in the spawn point and won't spawn. If you set your squad size to 10 or higher, your squad won't fit in the spawn point, and they'll get plopped down on the map in some random location.

Link to comment
Share on other sites

Oh that's annoying, it doesn't seem to want to generate a VIP mission after all that - it seems to always pick "destroy relay".

The code doesn't appear to be hard coded to that mission type so it's probably something more subtle.

 

If you've not read through it yet, SpawnVIPWithXComSquad() in XComTacticalMissionManager.uc looks like a relevant starting point:

    // find a spot with the squad and spawn the unit
    ParcelManager = `PARCELMGR;
    ParcelManager.SoldierSpawn.GetValidFloorLocations(SpawnLocations);
    foreach SpawnLocations(SpawnLocation)
    {
        if(WorldData.IsPositionOnFloorAndValidDestination(SpawnLocation))
        {
            // put the unit here
            WorldData.GetFloorTileForPosition(SpawnLocation, SpawnTile);
            Unit = CreatePawnCommon(NewGameState, SpawnTile, 0);
            break;
        }
    }

Also looks like there's a SpawnMission console command, implemented in XComTacitcalHeadquartersCheatManager.uc:

exec function SpawnMission(name MissionSourceName, name MissionRewardName, optional name ExtraMissionRewardName)

Going by the names in DefaultMissions.ini, this might work (I tried a bunch of different combinations, scanned and had a rescue scientist mission come up)

 

spawnmission MissionSource_Council Reward_Scientist

Link to comment
Share on other sites

 

If you've not read through it yet, SpawnVIPWithXComSquad() in XComTacticalMissionManager.uc looks like a relevant starting point:

 

 

Hmm. I wonder if I can coax it to spawn the VIP outside the spawn point...

 

The problem isn't really the VIP, it's the squad size. For squad sizes > 9, the game can't find a valid spawn point at all, and it just plops the squad down wherever. This might be on an unpathable tile, and the squad member wouldn't be able to move. Lots of bad things could happen.

 

For right now, there's an advisory on the mod to not use squad sizes greater than 8.

 

But you know what, this tactical manager snippet makes me want to make a mod to allow you to split your team in half and spawn them in two different locations...

 

I bet that would cause a lot of problems with the enemy pack spawning, but it might be worth it...

Link to comment
Share on other sites

  • Recently Browsing   0 members

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