Skip to content

Commit

Permalink
Starfield ALCH parsed
Browse files Browse the repository at this point in the history
  • Loading branch information
Noggog committed Nov 13, 2023
1 parent ce2fde0 commit 90a26c2
Show file tree
Hide file tree
Showing 12 changed files with 3,727 additions and 206 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ Functions can then be written that take in `INamed`, allowing any record that ha
- Armor
- Book
- Container
- Ingestible
- KeywordFormComponent
- MagicEffect
- MiscItem
Expand All @@ -42,6 +43,7 @@ Functions can then be written that take in `INamed`, allowing any record that ha
- Container
- DestructionStage
- HeadPart
- Ingestible
- LegendaryItem
- LeveledItem
- MiscItem
Expand All @@ -66,6 +68,7 @@ Functions can then be written that take in `INamed`, allowing any record that ha
- FormList
- FullNameComponent
- HeadPart
- Ingestible
- Keyword
- MagicEffect
- MiscItem
Expand Down Expand Up @@ -108,6 +111,7 @@ Functions can then be written that take in `INamed`, allowing any record that ha
- BendableSpline
- Book
- Container
- Ingestible
- LegendaryItem
- LeveledItem
- MiscItem
Expand All @@ -133,6 +137,7 @@ Functions can then be written that take in `INamed`, allowing any record that ha
- Weapon
### IWeightValue
- Book
- Ingestible
## Concrete Classes to Interfaces
### AcousticSpace
- IObjectBounded
Expand Down Expand Up @@ -197,6 +202,12 @@ Functions can then be written that take in `INamed`, allowing any record that ha
### HeadPart
- IModeled
- INamed
### Ingestible
- IKeyworded
- IModeled
- INamed
- IObjectBounded
- IWeightValue
### Keyword
- IKeywordCommon
- INamed
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,7 @@ public StarfieldAspectInterfaceMapping()
Armor_Registration.Instance,
Book_Registration.Instance,
Container_Registration.Instance,
Ingestible_Registration.Instance,
KeywordFormComponent_Registration.Instance,
MagicEffect_Registration.Instance,
MiscItem_Registration.Instance,
Expand All @@ -68,6 +69,7 @@ public StarfieldAspectInterfaceMapping()
Container_Registration.Instance,
DestructionStage_Registration.Instance,
HeadPart_Registration.Instance,
Ingestible_Registration.Instance,
LegendaryItem_Registration.Instance,
LeveledItem_Registration.Instance,
MiscItem_Registration.Instance,
Expand All @@ -93,6 +95,7 @@ public StarfieldAspectInterfaceMapping()
FormList_Registration.Instance,
FullNameComponent_Registration.Instance,
HeadPart_Registration.Instance,
Ingestible_Registration.Instance,
Keyword_Registration.Instance,
MagicEffect_Registration.Instance,
MiscItem_Registration.Instance,
Expand Down Expand Up @@ -130,6 +133,7 @@ public StarfieldAspectInterfaceMapping()
FormList_Registration.Instance,
FullNameComponent_Registration.Instance,
HeadPart_Registration.Instance,
Ingestible_Registration.Instance,
Keyword_Registration.Instance,
MagicEffect_Registration.Instance,
MiscItem_Registration.Instance,
Expand Down Expand Up @@ -181,6 +185,7 @@ public StarfieldAspectInterfaceMapping()
FormList_Registration.Instance,
FullNameComponent_Registration.Instance,
HeadPart_Registration.Instance,
Ingestible_Registration.Instance,
Keyword_Registration.Instance,
MagicEffect_Registration.Instance,
MiscItem_Registration.Instance,
Expand Down Expand Up @@ -211,6 +216,7 @@ public StarfieldAspectInterfaceMapping()
FormList_Registration.Instance,
FullNameComponent_Registration.Instance,
HeadPart_Registration.Instance,
Ingestible_Registration.Instance,
Keyword_Registration.Instance,
MagicEffect_Registration.Instance,
MiscItem_Registration.Instance,
Expand All @@ -234,6 +240,7 @@ public StarfieldAspectInterfaceMapping()
AudioOcclusionPrimitive_Registration.Instance,
Book_Registration.Instance,
Container_Registration.Instance,
Ingestible_Registration.Instance,
LeveledItem_Registration.Instance,
MiscItem_Registration.Instance,
ObjectEffect_Registration.Instance,
Expand Down Expand Up @@ -273,6 +280,7 @@ public StarfieldAspectInterfaceMapping()
dict[typeof(IWeightValue)] = new InterfaceMappingResult(true, new ILoquiRegistration[]
{
Book_Registration.Instance,
Ingestible_Registration.Instance,
});
dict[typeof(IWeightValueGetter)] = dict[typeof(IWeightValue)] with { Setter = false };
InterfaceToObjectTypes = dict;
Expand Down
3 changes: 3 additions & 0 deletions Mutagen.Bethesda.Starfield/Mutagen.Bethesda.Starfield.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -2089,6 +2089,9 @@
<Compile Include="Records\Major Records\HeadPart.cs">
<DependentUpon>HeadPart.xml</DependentUpon>
</Compile>
<Compile Include="Records\Major Records\Ingestible.cs">
<DependentUpon>Ingestible.xml</DependentUpon>
</Compile>
<Compile Include="Records\Major Records\Keyword.cs">
<DependentUpon>Keyword.xml</DependentUpon>
</Compile>
Expand Down
19 changes: 19 additions & 0 deletions Mutagen.Bethesda.Starfield/Records/Major Records/Ingestible.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
namespace Mutagen.Bethesda.Starfield;

public partial class Ingestible
{
[Flags]
public enum MajorFlag
{
Medicine = 0x2000_0000
}

[Flags]
public enum Flag
{
NoAutoCalc = 0x0000_0001,
FoodItem = 0x0000_0002,
Medicine = 0x0001_0000,
Poison = 0x0002_0000,
}
}
33 changes: 32 additions & 1 deletion Mutagen.Bethesda.Starfield/Records/Major Records/Ingestible.xml
Original file line number Diff line number Diff line change
@@ -1,7 +1,38 @@
<?xml version="1.0" encoding="us-ascii"?>
<Loqui xmlns="http://tempuri.org/LoquiSource.xsd">
<Object name="Ingestible" recordType="ALCH" objType="Record" baseClass="StarfieldMajorRecord">
<Object name="Ingestible" recordType="ALCH" objType="Record" baseClass="StarfieldMajorRecord" majorFlag="true" >
<Fields>
<RefDirect name="ObjectBounds" refName="ObjectBounds" nullable="False" />
<Float name="ODTY" recordType="ODTY" unknown="true" />
<RefDirect name="ObjectPlacementDefaults" refName="ObjectPlacementDefaults" />
<RefDirect name="Transforms" refName="Transforms" />
<RefList name="Components" refName="AComponent" />
<ByteArray name="XALG" recordType="XALG" unknown="true" />
<String name="Name" recordType="FULL" translated="Normal" />
<List name="Keywords" counterRecType="KSIZ" recordType="KWDA">
<FormLink refName="Keyword" />
</List>
<RefDirect name="Model" refName="Model" />
<RefDirect name="PickupSound" refName="SoundReference" recordType="PUSH" />
<RefDirect name="DropdownSound" refName="SoundReference" recordType="PDSH" />
<RefDirect name="CraftingSound" recordType="CUSH" refName="SoundReference" />
<String name="Description" recordType="DESC" nullable="False" translated="DL" />
<RefList name="Resources" refName="ItemResource" recordType="CVPA" />
<List name="ComponentDisplayIndices" recordType="CDIX">
<UInt8 />
</List>
<Float name="Weight" recordType="DATA" nullable="false" />
<Data recordType="ENIT">
<Fields>
<UInt32 name="Value" />
<Enum name="Flags" enumName="Ingestible.Flag" byteLength="4" />
<FormLink name="Addiction" refName="Spell" />
<Float name="AddictionChance" />
<RefDirect name="ConsumeSound" refName="SoundReference" />
</Fields>
</Data>
<String name="AddictionName" recordType="DNAM" translated="Normal" />
<RefList name="Effects" refName="Effect" nullable="False" />
</Fields>
<LinkInterface>IStaticTarget</LinkInterface>
<LinkInterface>IItem</LinkInterface>
Expand Down
Loading

0 comments on commit 90a26c2

Please sign in to comment.