Skip to content

Commit 2c5afd2

Browse files
committed
remove defaults option for proxies on creation
1 parent c408ff0 commit 2c5afd2

2 files changed

Lines changed: 4 additions & 6 deletions

File tree

CathodeLib/Scripts/CATHODE/CommandsPAK/Components/Composite.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -105,13 +105,13 @@ public VariableEntity AddVariable(string parameter, DataType type)
105105
}
106106

107107
/* Add a new proxy entity */
108-
public ProxyEntity AddProxy(Commands commands, ShortGuid[] hierarchy, bool addDefaultParam = false)
108+
public ProxyEntity AddProxy(Commands commands, ShortGuid[] hierarchy)
109109
{
110110
CommandsUtils.ResolveHierarchy(commands, this, hierarchy, out Composite targetComposite, out string str);
111111
Entity ent = targetComposite.GetEntityByID(hierarchy[hierarchy.Length - 2]);
112112
if (ent.variant != EntityVariant.FUNCTION) return null;
113113

114-
ProxyEntity proxy = new ProxyEntity(hierarchy, ((FunctionEntity)ent).function, addDefaultParam);
114+
ProxyEntity proxy = new ProxyEntity(hierarchy, ((FunctionEntity)ent).function);
115115
proxies.Add(proxy);
116116
return proxy;
117117
}

CathodeLib/Scripts/CATHODE/CommandsPAK/Components/Entity.cs

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -459,18 +459,16 @@ public class ProxyEntity : Entity
459459
public ProxyEntity() : base(EntityVariant.PROXY) { }
460460
public ProxyEntity(ShortGuid shortGUID) : base(shortGUID, EntityVariant.PROXY) { }
461461

462-
public ProxyEntity(ShortGuid[] hierarchy = null, ShortGuid targetType = new ShortGuid(), bool autoGenerateParameters = false) : base(EntityVariant.PROXY)
462+
public ProxyEntity(ShortGuid[] hierarchy = null, ShortGuid targetType = new ShortGuid()) : base(EntityVariant.PROXY)
463463
{
464464
this.function = targetType;
465465
if (hierarchy != null) this.proxy.path = hierarchy;
466-
if (autoGenerateParameters) ParameterUtils.AddAllDefaultParameters(this, null);
467466
}
468-
public ProxyEntity(ShortGuid shortGUID, ShortGuid[] hierarchy = null, ShortGuid targetType = new ShortGuid(), bool autoGenerateParameters = false) : base(shortGUID, EntityVariant.PROXY)
467+
public ProxyEntity(ShortGuid shortGUID, ShortGuid[] hierarchy = null, ShortGuid targetType = new ShortGuid()) : base(shortGUID, EntityVariant.PROXY)
469468
{
470469
this.shortGUID = shortGUID;
471470
this.function = targetType;
472471
if (hierarchy != null) this.proxy.path = hierarchy;
473-
if (autoGenerateParameters) ParameterUtils.AddAllDefaultParameters(this, null);
474472
}
475473

476474
public ShortGuid function; //The "function" value on the entity we're proxying

0 commit comments

Comments
 (0)