ES3Types added a custom class B containing List<Custom Class A> with custom class A as its type.
In ES3 Window, the message
is displayed, and I tried to set an appropriate value for the argument, but I can't add a custom class A as an argument.This type has no public rapameterless constructors.
To support this type you will need to modify the ES3Type script to use a specific constructor instead of the parameterless constructor.
Assets\Easy Save 3\Types\ES3Type_Map.cs(45,32): error CS7036: There is no argument given that corresponds to the required formal parameter 'configName' of 'Map.Map(string, string, List<Node>, List<Point>)'
Code: Select all
using System;
using UnityEngine;
namespace ES3Types
{
[UnityEngine.Scripting.Preserve]
[ES3PropertiesAttribute("bossNodeName", "configName")]
public class ES3Type_Map : ES3ObjectType
{
public static ES3Type Instance = null;
public ES3Type_Map() : base(typeof(Map.Map)) { Instance = this; }
protected override void WriteObject(object obj, ES3Writer writer)
{
var instance = (Map.Map)obj;
writer.WriteProperty("bossNodeName", instance.bossNodeName, ES3Type_string.Instance);
writer.WriteProperty("configName", instance.configName, ES3Type_string.Instance);
}
protected override void ReadObject<T>(ES3Reader reader, object obj)
{
var instance = (Map.Map)obj;
foreach (string propertyName in reader.Properties)
{
switch (propertyName)
{
case "bossNodeName":
instance.bossNodeName = reader.Read<System.String>(ES3Type_string.Instance);
break;
case "configName":
instance.configName = reader.Read<System.String>(ES3Type_string.Instance);
break;
default:
reader.Skip();
break;
}
}
}
protected override object ReadObject<T>(ES3Reader reader)
{
var instance = new Map.Map("configName", "bossNodeName", );
ReadObject<T>(reader, instance);
return instance;
}
}
public class ES3Type_MapArray : ES3ArrayType
{
public static ES3Type Instance;
public ES3Type_MapArray() : base(typeof(Map.Map[]), ES3Type_Map.Instance)
{
Instance = this;
}
}
}