Added weight to GangMemberTask construction call

Added hackWeight: 100 to GangMember Task construction call to prevent error messages from the constructor checks. 
Since we only compare with roughlyIs() this will have no impact on functionality
This commit is contained in:
Florian Schöffl
2022-08-25 11:08:33 +02:00
committed by GitHub
parent ccbca5c38c
commit 0c93764ef8
+1 -1
View File
@@ -554,7 +554,7 @@ function gangMember(ctx: NetscriptContext, m: unknown): GangMember {
}
function gangTask(ctx: NetscriptContext, t: unknown): GangMemberTask {
if (!roughlyIs(new GangMemberTask("", "", false, false, {}), t))
if (!roughlyIs(new GangMemberTask("", "", false, false, { hackWeight: 100 }), t))
throw makeRuntimeErrorMsg(ctx, `task should be a GangMemberTask.`);
return t as GangMemberTask;
}