Ok, so I have a code in which there are 2 separate classes, that have two similar functions that react with each other in a similar way, but the first class's function seems to not want to work because it uses variables from the second class, which hasnt been defined yet. Any thoughts on how to remedy this problem?
One data object cannot refer to another data object unless it is declared first. B's members must be known beforehand before A's members refer to them. Forward declaring B, as I first assumed, will not solve your problem. What you're asking cannot be done.