So i'm into a personal project (haha it is definitely way more of what i know i can do -skill/knowledge wise-, but this is kind of the point), if you ever played Magic: The gathering (through magic workstation) or recently Hearthstone you can get the idea of what i want to do (not as fancy as Hearthstone though, just... better looking than mws).
I have no plans for AI or such, i want it to be open, as in the user does what he wants, no forced rules by the system or anything, everything is completely manual (just like in magic workstation).
Starting off with the GUI since i have honestly no idea about how to manage a really dynamical gui (moving components), then with the network stuff since i have a better understand about that(or at least i think).
starting with the most dynamical part of the GUI: moving cards and larger card preview.
so i've made my class for cards which is a JPanel and paint the cards on it, i can move it around playing with the setLocation but i have a serious problem, everytime i add another card (another Jpanel) i have to revalidate the jframe and that resets the locations. I know this is because of the Layout but i can't just remove it or else it won't add more components later on (obviously haha), so i have no idea how to approach this.
Can someone tell me what to do about that?
TL;DR version: I'm playing with the setLocation property of some components and everytime i add another component (in run time) i have to revalidate and it resets the locations, how can i stop that from happening?