The prices of the two markets affect each other, but the spot market price and the futures price you make have nothing to do with calculating your profit.
If it is futures, if your opening price is 3500/ ton and your hand is 10 ton, then when you close your position, the price is 4300 yuan/ton, and your profit is (4300-3500)× 10=8000 yuan.