mirror of
https://github.com/MirrorNetworking/Mirror.git
synced 2024-11-18 02:50:32 +00:00
Remove unnecesary lists from WeaverLists
This commit is contained in:
parent
8dbf46720e
commit
9889ed4f9c
@ -22,17 +22,6 @@ public static void Process(ModuleDefinition moduleDef)
|
||||
if (Weaver.WeaveLists.generateContainerClass != null)
|
||||
{
|
||||
moduleDef.Types.Add(Weaver.WeaveLists.generateContainerClass);
|
||||
moduleDef.ImportReference(Weaver.WeaveLists.generateContainerClass);
|
||||
|
||||
foreach (MethodDefinition f in Weaver.WeaveLists.generatedReadFunctions)
|
||||
{
|
||||
moduleDef.ImportReference(f);
|
||||
}
|
||||
|
||||
foreach (MethodDefinition f in Weaver.WeaveLists.generatedWriteFunctions)
|
||||
{
|
||||
moduleDef.ImportReference(f);
|
||||
}
|
||||
}
|
||||
|
||||
Console.WriteLine(" ProcessSitesModule " + moduleDef.Name + " elapsed time:" + (DateTime.Now - startTime));
|
||||
|
@ -98,7 +98,6 @@ public static MethodReference GetReadFunc(TypeReference variableReference)
|
||||
static void RegisterReadFunc(TypeReference typeReference, MethodDefinition newReaderFunc)
|
||||
{
|
||||
readFuncs[typeReference.FullName] = newReaderFunc;
|
||||
Weaver.WeaveLists.generatedReadFunctions.Add(newReaderFunc);
|
||||
|
||||
Weaver.WeaveLists.ConfirmGeneratedCodeClass();
|
||||
Weaver.WeaveLists.generateContainerClass.Methods.Add(newReaderFunc);
|
||||
|
@ -14,9 +14,6 @@ class WeaverLists
|
||||
// getter functions that replace [SyncVar] member variable references. dict<field, replacement>
|
||||
public Dictionary<FieldDefinition, MethodDefinition> replacementGetterProperties = new Dictionary<FieldDefinition, MethodDefinition>();
|
||||
|
||||
public List<MethodDefinition> generatedReadFunctions = new List<MethodDefinition>();
|
||||
public List<MethodDefinition> generatedWriteFunctions = new List<MethodDefinition>();
|
||||
|
||||
public TypeDefinition generateContainerClass;
|
||||
|
||||
// amount of SyncVars per class. dict<className, amount>
|
||||
|
@ -22,7 +22,6 @@ public static void Register(TypeReference dataType, MethodReference methodRefere
|
||||
static void RegisterWriteFunc(TypeReference typeReference, MethodDefinition newWriterFunc)
|
||||
{
|
||||
writeFuncs[typeReference.FullName] = newWriterFunc;
|
||||
Weaver.WeaveLists.generatedWriteFunctions.Add(newWriterFunc);
|
||||
|
||||
Weaver.WeaveLists.ConfirmGeneratedCodeClass();
|
||||
Weaver.WeaveLists.generateContainerClass.Methods.Add(newWriterFunc);
|
||||
|
Loading…
Reference in New Issue
Block a user