SauvegardePlateau = plateau
print(SauvegardePlateau)
deplacement(VP,X1,Y1,X2,Y2) #changes the value in the first "plateau"
dessinpieces()
print(SauvegardePlateau)
Turn=0
if SauvegardePlateau != plateau:
if Joueur==1:
Joueur=2
else:
Joueur=1
at the first "print(SauvegardePlateau)" it gives me the "plateau" as it should do but on the second print it gives me the one that has been changed when i only changed "plateau" and didn't change "SauvegardePlateau"
the aim is to be able to cancel a move, so I need to save the plateau in a variable (SauvegardePlateau) before my main plateau changes but wiredly they both change which means that my "if SauvegardePlateau != plateau" never works
I don't understand why it's doing that, if you could please help me ? Thanks ! (sorry for english errors i'm french)