I’ve created a class Player which requires a cube (well, gameobject) in its constructor. I have code attached to a cube (a new behaviour script) which runs its update function every frame. In it i can do transform.position etc. How can i write in that function to pass the cube to the player class?
Well that depends how you instantiate your class. Whomever instantiates the player (which if it is a Monobehaviour, you cannot do it yourself).
Better bet would be to expose a property and just set it in Start().