Re-enable ammobox unload in-place, fixed for fika

This commit is contained in:
Tyfon
2024-07-25 12:25:53 -07:00
parent 458a2df57c
commit e2d51f25d9
3 changed files with 124 additions and 106 deletions

6
R.cs
View File

@@ -872,15 +872,15 @@ public static class R
public class GameWorld(object value) : Wrapper(value)
{
public static Type Type { get; private set; }
private static FieldInfo StashField;
private static FieldInfo TraderControllerField;
public static void InitTypes()
{
Type = typeof(EFT.GameWorld);
StashField = AccessTools.Field(Type, "stashClass");
TraderControllerField = AccessTools.Field(Type, "traderControllerClass");
}
public StashClass Stash { get { return (StashClass)StashField.GetValue(Value); } }
public TraderControllerClass TraderController { get { return (TraderControllerClass)TraderControllerField.GetValue(Value); } }
}
}