Code Monkey home page Code Monkey logo

Comments (16)

tracktwo avatar tracktwo commented on August 21, 2024

Is this mission type a 'regular' rescue mission or a LW-modified rescue mission? The mission type will be RescueVIPVehicle_LW if it's one of the custom ones, and it could be that some of the mission code related to team-swapping of civilians and whatever else it needs to do may have changed in WotC and will be broken in the LW-modified map. I'd suggest trying a tactical quicklaunch of a standard rescue vehicle mission and see if that works, and also one of the modified mission and see if it doesn't.

This is some of (IMHO) the worst part of modding xcom2 missions. A lot of the logic is buried inside the maps themselves in kismet, and there is not really a great way I could find to be able to diff the maps to figure out what has actually changed in them. Several of the DLCs changed the maps heavily and all of sudden all the missions we wrote had bugs and we had to go back and figure out what had changed in them and apply the changes to our versions. WotC no doubt massively changed these missions, so even if a lot of the LW custom ones look like they work correctly most of the time, they probably all contain bugs related to whatever wotc added in kismet. E.g. they may not work correctly with sitreps and stuff like that (but that's just a guess, I don't know what they put in kismet in wotc). If faction soldiers have different templates from 'normal' soldiers than one thing that is almost certainly broken is anything in the lw missions that triggers off a 'soldier' doing something if you use a faction solder instead (like rescuing a civilian, for example).

One thing to do as a start would maybe be to disable all the LW-modified versions of standard missions in X2MissionSet_LW. The LW variants of vanilla missions are only lightly modified, but I don't recall exactly what needed to be changed in them. Probably reinforcements logic, for the most part, so these missions would get regular reinforcements if using the regular mission script. It's likely a lot simpler to just port the reinforcement changes (or whatever else change in them) by changing the wotc map than trying to port the wotc changes into the lw map.

from lwotc.

pledbrook avatar pledbrook commented on August 21, 2024

Robojumper had this information on WOTC Kismet/map changes:

Vanilla mission kismet: One kismet for each mission type, tons of boilerplate kismet
WotC mission kismet: More individual sub-systems, specialized by placing variables into the "main" mission kismet
The only vanilla subsystem was the reinforcements subsystem, WotC has a lot more. Unit/loss-tracking etc, things to remove VO boilerplate etc

Looks like I'll have to learn about Kismet among all the other things I need to learn! I think you may be right about using the WOTC maps, especially as there are more of them now, with different mission types. That should be easier once I understand how all these pieces interact/hang together.

from lwotc.

tracktwo avatar tracktwo commented on August 21, 2024

Yep. Hopefully the WotC ones are more modular. And that comment jogged my memory a bit - the reinforcements wasn't too bad because it was already a subsystem, like RJ said. But changing the mission timers did. IIRC they were all hardcoded in each map in vanilla. Hopefully WotC has extracted that out as well, and I suspect it may have to support beta strike better.

Even with the subsystems, having the variables hardcoded in each mission subsystem makes them harder to customize, e.g. by difficulty level, or to have them change programmatically in response to other things, like infiltration level, or to allow abilities to change them. It's tougher to 'call into' kismet or alter kismet variables from uscript, it's a lot simpler to go the other way.

In general the less stuff you put in Kismet the better, as it's so much harder to work with. Even in places where it's unavoidable, it's often better to extract the logic as much as possible out to uscript classes, and just have the kismet call into it rather than trying to implement the logic in kismet itself. I did most/all of the mission changes myself, so I do understand those systems fairly well, at least the pre-wotc versions.

from lwotc.

Xymanek avatar Xymanek commented on August 21, 2024

But changing the mission timers did. IIRC they were all hardcoded in each map in vanilla. Hopefully WotC has extracted that out as well

I'm not sure about LW2 implementation but in WOTC the timers are normal XCGS objects which can be modified from UC and kismet (I think that's how LW2 did it as well?). Furthermore, they implemented a system for suspending the timer which is invoked when a chosen is engaged

from lwotc.

pledbrook avatar pledbrook commented on August 21, 2024

Can confirm that the Vanilla/WOTC mission type is fine, but the LW one is borked as far as the civilian VIP goes. I'll try to familiarise myself with maps, mission types, and objectives and have a stab at fixing this.

from lwotc.

tracktwo avatar tracktwo commented on August 21, 2024

I took a quick peek at the rescue mission to see if I can see what's going on, and definitely there are changes that will be necessary here. For that, there is good news and bad news.

The bad news first - Just about all the LW2 missions are going to need a significant overhaul. At least the ones that are mods of vanilla missions, but the custom ones will almost certainly need some work too (esp. retaliation style ones).

The good news is that the new mission structure that RJ mentioned looks to be much cleaner and more mod friendly. Some of the key systems that LW2 had to mod all in each of these default missions (mission timers and reinforcements in particular) have been completely offloaded into common subsequences and shared between the mission maps rather than being copied and pasted into each one. I don't know if there are going to be particular assumptions still made in those maps that need to be redone or if the lw2 subsystems can be completely implemented without touching the main mission scripts, but if the latter that's fantastic news.

As a concrete example, the vip rescue handling used to be hardcoded right in the rescue mission map. Now it's in the common subsequence UMS_MissionCore that has common bits and pieces across multiple missions. In particular the key sequence here is Remote Event X2 GameState "UMS_AddVIPToXComTeam". It contains two nodes, and in vanilla it only had one. There's Swap Teams, which already exists and LW2 handles, but also Set Group For Unit which is new and I am not familiar with, and sets the unit to the "Primary Initiative Group". That could be the missing piece.

The RescueVIP mission has sub-maps for the subsystems this mission type uses, see XComMissionDefs.ini. It has UMS_BasicMissionTimer to handle the timer, UMS_TriggeredReinforcements to handle RNFs, and UMS_PreplacedEvacHandler to handle the evac zone. All of these systems were modded in LW2 to support the new logic, so if they can be implemented as new subsequences then modding those vanilla missions is (with some luck) as easy as altering the config files to use the new ones instead of the wotc subsystems.

from lwotc.

Xymanek avatar Xymanek commented on August 21, 2024

but also Set Group For Unit which is new and I am not familiar with, and sets the unit to the "Primary Initiative Group". That could be the missing piece.

In WOTC they introduced an "initiative" system - the turn order is now done in "pods" instead of teams - XCOM is one big pod

from lwotc.

pledbrook avatar pledbrook commented on August 21, 2024

@Xymanek Is that to handle the Lost and the Chosen? Or is it for ADVENT/alien pods?

from lwotc.

pledbrook avatar pledbrook commented on August 21, 2024

Also, am I blind? I can't find a rescue VIP map under my /XCOM 2/XCom2-WarOfTheChosen/XComGame/Content directory. Is that because it no longer has a dedicated map? Sorry, all this umap stuff is very new.

from lwotc.

Xymanek avatar Xymanek commented on August 21, 2024

well, lost are their own team so they don't need this change. Chosen on the other hand are on alien team but go after other aliens, so yes, they need this change. Furthermore, there are 2 skirmisher abilities which allows them to take actions during enemy turns which also require this change

from lwotc.

pledbrook avatar pledbrook commented on August 21, 2024

OK, found that map and similar ones in .../XCOM 2 War of the Chosen SDK/XComGame/Content/DLC/TLE/XCOM_2/Maps/Missions. I'm wondering whether Firaxis enjoy messing us around 😄 Don't know why they'd be moved to the Tactical Legacy Pack directory.

from lwotc.

pledbrook avatar pledbrook commented on August 21, 2024

@tracktwo To see whether I've understood this: is the idea that I could reuse the vanilla/WOTC mission maps, like Obj_RescueVIP.umap, in the LW mission definitions and then attach custom versions of UMS_TriggeredReinforcements, UMS_BasicMissionTimer, etc. to those mission definitions?

from lwotc.

tracktwo avatar tracktwo commented on August 21, 2024

@pledbrook That's the idea, yeah. Those subsystems UMS_* define events with particular names that the main mission maps call, so any LW replacements would need to fit exactly the same interfaces that are already in the main mission, or the main mission will need to be altered too.

from lwotc.

pledbrook avatar pledbrook commented on August 21, 2024

I'm wondering whether it's possible to switch to the WOTC BasicMissionTimer.umap. Not only can you provide a base timer for each mission type within config, sitreps can adjust the timer. Perhaps we can create a sitrep that adjusts timers based on map size? I don't know if that would preclude other sitreps though.

from lwotc.

pledbrook avatar pledbrook commented on August 21, 2024

This is fixed, but I want to complete #22 and add in the continuous reinforcements before pushing. When that's done, I'll close the issue.

from lwotc.

pledbrook avatar pledbrook commented on August 21, 2024

Rescue VIP was fixed by using the vanilla WOTC mission map (the one containing the Kismet). Jailbreak and others were fixed by updating the Kismet directly to assign rebels/civilians to XCOM's initiative group.

from lwotc.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.