Skip to content

Commit 5f1649e

Browse files
committed
Set the EditorID in the GameSetting/Global convenience calls
1 parent 5e42e20 commit 5f1649e

6 files changed

Lines changed: 24 additions & 4 deletions

File tree

Mutagen.Bethesda.Fallout4/Extensions/GameSettingsGroupMixin.cs

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@ public static GameSettingBool AddNewBool(this IGroup<GameSetting> gameSettings,
1818
var ret = new GameSettingBool(
1919
gameSettings.SourceMod.GetNextFormKey(editorId),
2020
gameSettings.SourceMod.GameRelease.ToFallout4Release());
21+
ret.EditorID = editorId;
2122
gameSettings.Add(ret);
2223
return ret;
2324
}
@@ -36,6 +37,7 @@ public static GameSettingFloat AddNewFloat(this IGroup<GameSetting> gameSettings
3637
var ret = new GameSettingFloat(
3738
gameSettings.SourceMod.GetNextFormKey(editorId),
3839
gameSettings.SourceMod.GameRelease.ToFallout4Release());
40+
ret.EditorID = editorId;
3941
gameSettings.Add(ret);
4042
return ret;
4143
}
@@ -54,6 +56,7 @@ public static GameSettingInt AddNewInt(this IGroup<GameSetting> gameSettings, st
5456
var ret = new GameSettingInt(
5557
gameSettings.SourceMod.GetNextFormKey(editorId),
5658
gameSettings.SourceMod.GameRelease.ToFallout4Release());
59+
ret.EditorID = editorId;
5760
gameSettings.Add(ret);
5861
return ret;
5962
}
@@ -72,6 +75,7 @@ public static GameSettingString AddNewShort(this IGroup<GameSetting> gameSetting
7275
var ret = new GameSettingString(
7376
gameSettings.SourceMod.GetNextFormKey(editorId),
7477
gameSettings.SourceMod.GameRelease.ToFallout4Release());
78+
ret.EditorID = editorId;
7579
gameSettings.Add(ret);
7680
return ret;
7781
}

Mutagen.Bethesda.Fallout4/Extensions/GlobalGroupMixin.cs

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@ public static GlobalBool AddNewBool(this IGroup<Global> globals, string editorId
1818
var ret = new GlobalBool(
1919
globals.SourceMod.GetNextFormKey(editorId),
2020
globals.SourceMod.GameRelease.ToFallout4Release());
21+
ret.EditorID = editorId;
2122
globals.Add(ret);
2223
return ret;
2324
}
@@ -36,6 +37,7 @@ public static GlobalFloat AddNewFloat(this IGroup<Global> globals, string editor
3637
var ret = new GlobalFloat(
3738
globals.SourceMod.GetNextFormKey(editorId),
3839
globals.SourceMod.GameRelease.ToFallout4Release());
40+
ret.EditorID = editorId;
3941
globals.Add(ret);
4042
return ret;
4143
}
@@ -54,6 +56,7 @@ public static GlobalInt AddNewInt(this IGroup<Global> globals, string editorId)
5456
var ret = new GlobalInt(
5557
globals.SourceMod.GetNextFormKey(editorId),
5658
globals.SourceMod.GameRelease.ToFallout4Release());
59+
ret.EditorID = editorId;
5760
globals.Add(ret);
5861
return ret;
5962
}
@@ -72,6 +75,7 @@ public static GlobalShort AddNewShort(this IGroup<Global> globals, string editor
7275
var ret = new GlobalShort(
7376
globals.SourceMod.GetNextFormKey(editorId),
7477
globals.SourceMod.GameRelease.ToFallout4Release());
78+
ret.EditorID = editorId;
7579
globals.Add(ret);
7680
return ret;
7781
}

Mutagen.Bethesda.Oblivion/Extensions/GameSettingGroupMixIn.cs

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@ public static GameSettingFloat AddNewFloat(this IGroup<GameSetting> gameSettings
1818
var ret = new GameSettingFloat(
1919
gameSettings.SourceMod.GetNextFormKey(editorId),
2020
gameSettings.SourceMod.GameRelease.ToOblivionRelease());
21+
ret.EditorID = editorId;
2122
gameSettings.Add(ret);
2223
return ret;
2324
}
@@ -36,6 +37,7 @@ public static GameSettingInt AddNewInt(this IGroup<GameSetting> gameSettings, st
3637
var ret = new GameSettingInt(
3738
gameSettings.SourceMod.GetNextFormKey(editorId),
3839
gameSettings.SourceMod.GameRelease.ToOblivionRelease());
40+
ret.EditorID = editorId;
3941
gameSettings.Add(ret);
4042
return ret;
4143
}
@@ -54,7 +56,8 @@ public static GameSettingString AddNewShort(this IGroup<GameSetting> gameSetting
5456
var ret = new GameSettingString(
5557
gameSettings.SourceMod.GetNextFormKey(editorId),
5658
gameSettings.SourceMod.GameRelease.ToOblivionRelease());
59+
ret.EditorID = editorId;
5760
gameSettings.Add(ret);
5861
return ret;
5962
}
60-
}
63+
}

Mutagen.Bethesda.Oblivion/Extensions/GlobalGroupMixIn.cs

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@ public static GlobalFloat AddNewFloat(this IGroup<Global> globals, string editor
1818
var ret = new GlobalFloat(
1919
globals.SourceMod.GetNextFormKey(editorId),
2020
globals.SourceMod.GameRelease.ToOblivionRelease());
21+
ret.EditorID = editorId;
2122
globals.Add(ret);
2223
return ret;
2324
}
@@ -36,6 +37,7 @@ public static GlobalInt AddNewInt(this IGroup<Global> globals, string editorId)
3637
var ret = new GlobalInt(
3738
globals.SourceMod.GetNextFormKey(editorId),
3839
globals.SourceMod.GameRelease.ToOblivionRelease());
40+
ret.EditorID = editorId;
3941
globals.Add(ret);
4042
return ret;
4143
}
@@ -54,7 +56,8 @@ public static GlobalShort AddNewShort(this IGroup<Global> globals, string editor
5456
var ret = new GlobalShort(
5557
globals.SourceMod.GetNextFormKey(editorId),
5658
globals.SourceMod.GameRelease.ToOblivionRelease());
59+
ret.EditorID = editorId;
5760
globals.Add(ret);
5861
return ret;
5962
}
60-
}
63+
}

Mutagen.Bethesda.Skyrim/Extensions/GameSettingGroupMixIn.cs

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@ public static GameSettingFloat AddNewFloat(this IGroup<GameSetting> gameSettings
1818
var ret = new GameSettingFloat(
1919
gameSettings.SourceMod.GetNextFormKey(editorId),
2020
gameSettings.SourceMod.GameRelease.ToSkyrimRelease());
21+
ret.EditorID = editorId;
2122
gameSettings.Add(ret);
2223
return ret;
2324
}
@@ -36,6 +37,7 @@ public static GameSettingInt AddNewInt(this IGroup<GameSetting> gameSettings, st
3637
var ret = new GameSettingInt(
3738
gameSettings.SourceMod.GetNextFormKey(editorId),
3839
gameSettings.SourceMod.GameRelease.ToSkyrimRelease());
40+
ret.EditorID = editorId;
3941
gameSettings.Add(ret);
4042
return ret;
4143
}
@@ -54,7 +56,8 @@ public static GameSettingString AddNewShort(this IGroup<GameSetting> gameSetting
5456
var ret = new GameSettingString(
5557
gameSettings.SourceMod.GetNextFormKey(editorId),
5658
gameSettings.SourceMod.GameRelease.ToSkyrimRelease());
59+
ret.EditorID = editorId;
5760
gameSettings.Add(ret);
5861
return ret;
5962
}
60-
}
63+
}

Mutagen.Bethesda.Skyrim/Extensions/GlobalGroupMixIn.cs

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@ public static GlobalFloat AddNewFloat(this IGroup<Global> globals, string editor
1818
var ret = new GlobalFloat(
1919
globals.SourceMod.GetNextFormKey(editorId),
2020
globals.SourceMod.GameRelease.ToSkyrimRelease());
21+
ret.EditorID = editorId;
2122
globals.Add(ret);
2223
return ret;
2324
}
@@ -36,6 +37,7 @@ public static GlobalInt AddNewInt(this IGroup<Global> globals, string editorId)
3637
var ret = new GlobalInt(
3738
globals.SourceMod.GetNextFormKey(editorId),
3839
globals.SourceMod.GameRelease.ToSkyrimRelease());
40+
ret.EditorID = editorId;
3941
globals.Add(ret);
4042
return ret;
4143
}
@@ -54,7 +56,8 @@ public static GlobalShort AddNewShort(this IGroup<Global> globals, string editor
5456
var ret = new GlobalShort(
5557
globals.SourceMod.GetNextFormKey(editorId),
5658
globals.SourceMod.GameRelease.ToSkyrimRelease());
59+
ret.EditorID = editorId;
5760
globals.Add(ret);
5861
return ret;
5962
}
60-
}
63+
}

0 commit comments

Comments
 (0)