How can I manage multiple map? Can I make mod raid other faction in other map?

Started by BBream, April 26, 2015, 04:25:18 AM

Previous topic - Next topic

BBream

Hi.

I still find how I can make exploring other map.
I found the method related.

In class Layer_MapList_Load:

        MapInitData.Reset();
        MapInitData.mapToLoad = this.mapName;
        Application.LoadLevel("Gameplay");


In Application:
See also: http://docs.unity3d.com/ScriptReference/Application.LoadLevelAdditive.html

    public static void LoadLevelAdditive(/*Parameter with token 8001174*/string name)
    {
      Application.LoadLevelAsync(name, -1, true, true);
    }


In MapInitData:

  public static class MapInitData
  {
    public static bool startedFromEntry;
    public static string mapToLoad;
    public static string loadedVersion;
    public static int mapSize;
    public static DifficultyDef difficulty;
    public static StorytellerDef chosenStoryteller;
    public static IntVec2 landingCoords;
    public static List<Pawn> colonists;
    public static Faction colonyFaction;
    public static Month startingMonth;
    private static int debug_loadsSinceReset;
...


If I can copy colonist's data and paste other map, then I can make mod for exploring. Anyone have idea or experience?

soltysek

No one try it before but :

You can make static class wchic will hold Traveler data force save of map and load/generate new map after end off travel put data to the same class and force clouse and load old map with data actualization from class ... easiest aproch will be o make it via somekindof vechicle you pack pawns cargo to vechicle despown it to static class and spawn on new map .... after back you just spawn vechicle again from static class . I thing its preety simple :)

rexx1888

time wont pass on your original colony though.

Basically, it can be done, but its really complicated an you will probably need to override a bunch of stuff. if i was coding with the source and compiling it wouldnt be as difficult, so i think its probably on Tynan's list