buildCircuit() {
        var subcircuitScope = scopeList[this.id];
        loadScope(this.localScope, this.data);
        this.localScope.name = this.data.name;
        this.lastUpdated = this.localScope.timeStamp;
        updateSimulationSet(true);
        updateCanvasSet(true);

        if (this.savedData == undefined) {
            this.leftDimensionX = 0;
            this.upDimensionY = 0;
            this.rightDimensionX = subcircuitScope.layout.width;
            this.downDimensionY = subcircuitScope.layout.height;
            for (var i = 0; i < subcircuitScope.Output.length; i++) {
                var a = new Node(
                    subcircuitScope.Output[i].layoutProperties.x,
                    subcircuitScope.Output[i].layoutProperties.y,
                    1,
                    this,
                    subcircuitScope.Output[i].bitWidth
                );
                a.layout_id = subcircuitScope.Output[i].layoutProperties.id;
                this.outputNodes.push(a);
            }
            for (var i = 0; i < subcircuitScope.Input.length; i++) {
                var a = new Node(
                    subcircuitScope.Input[i].layoutProperties.x,
                    subcircuitScope.Input[i].layoutProperties.y,
                    0,
                    this,
                    subcircuitScope.Input[i].bitWidth
                );
                a.layout_id = subcircuitScope.Input[i].layoutProperties.id;
                this.inputNodes.push(a);
            }
        }
    }
loads the subcircuit and draws all the nodes