- Home /
trading card game question with board element
Hi,
I am trying to do a card game with some "board" element.
I have a gamemanager Object that spawns a board of 10*10 gameobject, and cards object that take his attributes from a xml.
when game starts I instantiate 5blank template (the deck) and at run time I assing a sprite and the text from xml. When i click on draw card, it instantiate a blank card and populate with attributes from xml and so on.
Im at this point. I am struiggling for hints on... what to do next. Im ok with OOP since i used mainly with java web.
What is the best way to organize cards on hands and to drop a card on my board of cube GameObject.
For now, I have the following issues:
I have added a script to camera that with a raycast 2D find every object with tag name Card and move around, I dunno if it's the best way. There are better way to handle movement? For example OnMouseUp on card?
I dunno how to stick card object to my hand.
To place the card on the board I've come up with using 2 colliders both on each cube and on each card. When 2 collider collide, the card is stick to the center of the cube of the board. But I have also a problem on where to put the onCollision method, on cube? on card?
Furthermore since my card has 2d collider and my cube has box collider they seems not to interact.
Could someone help me or point me to some tutorials? Thanks a lot.
Your answer
Follow this Question
Related Questions
A little hand with a Card Game 0 Answers
How do I add new instances of a object into a list? 1 Answer
Playing Cards With Special Shrinking & Twisting Effects 1 Answer
How to create set of cards? 1 Answer
Trading Card Game 5 Answers