dsda: disable BOOM demo import for now
passing rngseed didn't fix sync, and passing all the settings is too much work for this release. will support it afterwards. instead just tell the user BOOM demos are not supported
This commit is contained in:
parent
c84d292aa9
commit
0fe3c33c46
|
@ -1,3 +1,5 @@
|
|||
using System.Buffers.Binary;
|
||||
|
||||
using BizHawk.Common.IOExtensions;
|
||||
using BizHawk.Emulation.Common;
|
||||
using BizHawk.Emulation.Cores;
|
||||
|
@ -49,6 +51,7 @@ namespace BizHawk.Client.Common
|
|||
var monstersRespawn = false;
|
||||
var fastMonsters = false;
|
||||
var noMonsters = false;
|
||||
//var rngSeed = 1993U;
|
||||
|
||||
Result.Movie.HeaderEntries[HeaderKeys.Core] = CoreNames.DSDA;
|
||||
Result.Movie.SystemID = VSystemID.Raw.Doom;
|
||||
|
@ -106,6 +109,10 @@ namespace BizHawk.Client.Common
|
|||
}
|
||||
else // Boom territory
|
||||
{
|
||||
Result.Errors.Add($"Found BOOM demo format: v{(int)version}. Importing it is currently not supported.");
|
||||
return;
|
||||
|
||||
/*
|
||||
i++; // skip to signature's second byte
|
||||
var portID = input[i++];
|
||||
i += 4; // skip the rest of the signature
|
||||
|
@ -184,12 +191,10 @@ namespace BizHawk.Client.Common
|
|||
monstersRespawn = input[i++] is not 0;
|
||||
fastMonsters = input[i++] is not 0;
|
||||
noMonsters = input[i++] is not 0;
|
||||
|
||||
var optionsSize = compLevel == DSDA.CompatibilityLevel.MBF21 ? 21 + 25 : 64;
|
||||
i += optionsSize - 9; // subtract the options we already parsed
|
||||
|
||||
if (version == DemoVersion.Boom_2_00)
|
||||
i += 256 - optionsSize;
|
||||
i++; // demo insurance
|
||||
rngSeed = BinaryPrimitives.ReadUInt32BigEndian(input.AsSpan(i, 4));
|
||||
i = 0x4D;
|
||||
*/
|
||||
}
|
||||
|
||||
DSDA.DoomSyncSettings syncSettings = new()
|
||||
|
@ -205,13 +210,14 @@ namespace BizHawk.Client.Common
|
|||
NoMonsters = noMonsters,
|
||||
TurningResolution = turningResolution,
|
||||
RenderWipescreen = false,
|
||||
//RNGSeed = rngSeed,
|
||||
};
|
||||
|
||||
syncSettings.Player1Present = input[i++] is not 0;
|
||||
syncSettings.Player2Present = input[i++] is not 0;
|
||||
syncSettings.Player3Present = input[i++] is not 0;
|
||||
syncSettings.Player4Present = input[i++] is not 0;
|
||||
|
||||
/*
|
||||
if (compLevel >= DSDA.CompatibilityLevel.Boom_Compatibility
|
||||
&& version >= DemoVersion.Boom_2_00)
|
||||
{
|
||||
|
@ -219,7 +225,7 @@ namespace BizHawk.Client.Common
|
|||
var g_maxplayers = 4;
|
||||
i += FUTURE_MAXPLAYERS - g_maxplayers;
|
||||
}
|
||||
|
||||
*/
|
||||
Result.Movie.SyncSettingsJson = ConfigService.SaveWithType(syncSettings);
|
||||
|
||||
var doomController = new DoomControllerDeck(
|
||||
|
|
|
@ -403,7 +403,12 @@ namespace BizHawk.Emulation.Cores.Computers.Doom
|
|||
[Description("How fast the Doom player will run when using the mouse.")]
|
||||
[DefaultValue(1)]
|
||||
public int MouseRunSensitivity { get; set; }
|
||||
|
||||
/*
|
||||
[DisplayName("Initial RNG Seed")]
|
||||
[Description("Boom demos.")]
|
||||
[DefaultValue(1993)]
|
||||
public uint RNGSeed { get; set; }
|
||||
*/
|
||||
[DisplayName("Player 1 Hexen Class")]
|
||||
[Description("The Hexen class to use for player 1. Has no effect for Doom / Heretic")]
|
||||
[DefaultValue(HexenClass.Fighter)]
|
||||
|
@ -441,7 +446,8 @@ namespace BizHawk.Emulation.Cores.Computers.Doom
|
|||
Player3Class = (int)Player3Class,
|
||||
Player4Class = (int)Player4Class,
|
||||
PreventLevelExit = PreventLevelExit ? 1 : 0,
|
||||
PreventGameEnd = PreventGameEnd ? 1 : 0
|
||||
PreventGameEnd = PreventGameEnd ? 1 : 0,
|
||||
//RNGSeed = RNGSeed,
|
||||
};
|
||||
}
|
||||
|
||||
|
|
|
@ -36,6 +36,7 @@ namespace BizHawk.Emulation.Cores.Computers.Doom
|
|||
public int Player4Class;
|
||||
public int PreventLevelExit;
|
||||
public int PreventGameEnd;
|
||||
//public uint RNGSeed;
|
||||
}
|
||||
|
||||
[StructLayout(LayoutKind.Sequential)]
|
||||
|
|
|
@ -283,6 +283,9 @@ ECL_EXPORT int dsda_init(struct InitSettings *settings, int argc, char **argv)
|
|||
break;
|
||||
}
|
||||
|
||||
//if (compatibility_level >= boom_202_compatibility)
|
||||
// rngseed = settings->RNGSeed;
|
||||
|
||||
// Initializing audio
|
||||
I_SetSoundCap();
|
||||
I_InitSound();
|
||||
|
|
|
@ -26,6 +26,7 @@ extern void headlessSetTickCommand(int playerId, int forwardSpeed, int strafingS
|
|||
extern void headlessGetMapName(char *outString);
|
||||
extern void headlessSetSaveStatePointer(void *savePtr, int saveStateSize);
|
||||
extern size_t headlessGetEffectiveSaveSize();
|
||||
extern unsigned int rngseed;
|
||||
|
||||
// Video
|
||||
extern void headlessUpdateVideo();
|
||||
|
@ -140,6 +141,7 @@ struct InitSettings
|
|||
int Player4Class;
|
||||
int PreventLevelExit;
|
||||
int PreventGameEnd;
|
||||
//unsigned int RNGSeed;
|
||||
} __attribute__((packed));
|
||||
|
||||
struct PackedPlayerInput
|
||||
|
|
Loading…
Reference in New Issue