Skip to content
Beta: this is a preview of the new SplitScreen.Me. Data may be reset before launch.

Dungeon Siege III · handler “DungeonSiegeIII”

Version 3

Release notes

added UI option for number of players per instance.

Released
Size
1.4 KB
Downloads
130
Check
Verified
SHA-256
ebbe582a9c3f1ac85cb21ee4d1a01f13e5620d2f5ab603fd3ca5b0ba0ce77b07
Download v3 (.nc)All versions

Files 1

PathSize
handler.js5.0 KB

handler.js

Plain text
Hub.Handler.Version = 3; // Released at https://hub.splitscreen.me/ on Thu Jul 23 2020 00:24:40 GMT+0000 (UTC).
Hub.Handler.Id = "h7XpXxzsmNkKDgm9x";
Hub.Maintainer.Name = "Talos91";
Hub.Maintainer.Id = "eeL7HAz8zJovChWw4";

var answers1 = ["No", "Yes"];
Game.AddOption("2 players per intance?", "If yes launch only two horizontal or vertical instances.", "Native", answers1);

Game.FileSymlinkExclusions = ["steam_api.dll", "steam_appid.txt", "steam_interfaces.txt", "winmm.dll", "xinput1_3.dll"];
Game.FileSymlinkCopyInstead = ["config.ini", "engine.ini"];
Game.KillMutex = ["onyx"];
Game.NeedsSteamEmulation = false;
Game.UseGoldberg = true;
Game.UseSteamStubDRMPatcher = true;
Game.HandlerInterval = 100;
Game.SymlinkExe = false;
Game.SymlinkGame = true;
Game.SymlinkFolders = true;
Game.SupportsKeyboard = false;
Game.ExecutableName = "dungeon siege iii.exe";
Game.SteamID = "39160";
Game.GUID = "Dungeon Siege III";
Game.GameName = "Dungeon Siege III";
Game.MaxPlayers = 4;
Game.MaxPlayersOneMonitor = 4;
Game.LauncherTitle = "";
Game.SupportsPositioning = true;
Game.HideTaskbar = false;
Game.Hook.ForceFocus = true;
Game.Hook.ForceFocusWindowName = "Dungeon Siege III";
Game.Hook.DInputEnabled = false;
Game.Hook.DInputForceDisable = true;
Game.Hook.XInputEnabled = true;
Game.Hook.XInputReroute = false;
Game.Hook.CustomDllEnabled = false;
Game.XInputPlusDll = ["xinput1_3.dll"];
Game.FakeFocus = true;
Game.HookFocus = true;
Game.PauseBetweenStarts = 25;

Game.Play = function() {
  var savePath = (Context.SavePath = Context.GetFolder(Nucleus.Folder.InstancedGameFolder) + "\\config.ini");
  Context.ModifySaveFile(savePath, savePath, Nucleus.SaveType.INI, [
    new Nucleus.IniSaveInfo("Engine.Render", "full_screen", 0),
    new Nucleus.IniSaveInfo("Engine.Render", "support_aspect_ratio_4_3", true),
    new Nucleus.IniSaveInfo("Engine.Render", "support_aspect_ratio_16_10", true),
    new Nucleus.IniSaveInfo("Engine.Render", "support_aspect_ratio_custom", true)
  ]);

  var savePath = (Context.SavePath = Context.GetFolder(Nucleus.Folder.InstancedGameFolder) + "\\engine.ini");
  Context.ModifySaveFile(savePath, savePath, Nucleus.SaveType.INI, [
    new Nucleus.IniSaveInfo("Engine.Render", "full_screen", 0),
    new Nucleus.IniSaveInfo("Engine.Render", "window_width", Context.Width),
    new Nucleus.IniSaveInfo("Engine.Render", "window_height", Context.Height),
    new Nucleus.IniSaveInfo("Engine.Render", "support_aspect_ratio_4_3", true),
    new Nucleus.IniSaveInfo("Engine.Render", "support_aspect_ratio_16_10", true),
    new Nucleus.IniSaveInfo("Engine.Render", "support_aspect_ratio_custom", true)
  ]);

  var savePath = Context.GetFolder(Nucleus.Folder.Documents) + "\\My Games\\Dungeon Siege III\\user.ini";
  Context.ModifySaveFile(savePath, savePath, Nucleus.SaveType.INI, [
    new Nucleus.IniSaveInfo("Engine.Render", "full_screen", 0),
    new Nucleus.IniSaveInfo("Engine.Render", "window_width", Context.Width),
    new Nucleus.IniSaveInfo("Engine.Render", "window_height", Context.Height),
    new Nucleus.IniSaveInfo("Engine.Render", "support_aspect_ratio_4_3", true),
    new Nucleus.IniSaveInfo("Engine.Render", "support_aspect_ratio_16_10", true),
    new Nucleus.IniSaveInfo("Engine.Render", "support_aspect_ratio_custom", true)
  ]);

  var interfaces = Context.GetFolder(Nucleus.Folder.InstancedGameFolder) + "\\steam_interfaces.txt";
  var lines = [
    "SteamUser014",
    "SteamFriends008",
    "SteamUtils005",
    "SteamMatchMaking008",
    "SteamMatchMakingServers002",
    "STEAMUSERSTATS_INTERFACE_VERSION009",
    "STEAMAPPS_INTERFACE_VERSION004",
    "SteamNetworking004",
    "STEAMREMOTESTORAGE_INTERFACE_VERSION004",
    "SteamClient010",
    "SteamContentServer002",
    "SteamGameServer010",
    "SteamMasterServerUpdater001",
    "SteamGameServerStats001"
  ];

  Context.WriteTextFile(interfaces, lines);

  var native = Context.Options["Native"];

  if (Context.PlayerID == 0) {
    if (native == "Yes") {
      var savePath = Context.GetFolder(Nucleus.Folder.InstancedGameFolder) + "\\XinputPlus.ini";
      Context.ModifySaveFile(savePath, savePath, Nucleus.SaveType.INI, [
        new Nucleus.IniSaveInfo("ControllerNumber", "Controller1", "1"),
        new Nucleus.IniSaveInfo("ControllerNumber", "Controller2", "2"),
        new Nucleus.IniSaveInfo("ControllerNumber", "Controller3", "0"),
        new Nucleus.IniSaveInfo("ControllerNumber", "Controller4", "0")
      ]);
    }
  }
  if (Context.PlayerID == 1) {
    if (native == "Yes") {
      var savePath = Context.GetFolder(Nucleus.Folder.InstancedGameFolder) + "\\XinputPlus.ini";
      Context.ModifySaveFile(savePath, savePath, Nucleus.SaveType.INI, [
        new Nucleus.IniSaveInfo("ControllerNumber", "Controller1", "3"),
        new Nucleus.IniSaveInfo("ControllerNumber", "Controller2", "4"),
        new Nucleus.IniSaveInfo("ControllerNumber", "Controller3", "0"),
        new Nucleus.IniSaveInfo("ControllerNumber", "Controller4", "0")
      ]);
    }
  }
  if (native == "No") {
  }
};