0 votes

I am a complete newcomer to everything (Godot, game design, coding in general), and I decided for my first larger project to try designing a program involving 2d cards.

I'd like to have a scene where player sees one card face down. When clicking on the face down card, a random card is invisibly chosen, an animation plays flipping the card over, and the card face is revealed. This is just for starters, as I'd eventually want to have scenes with multiple card containers displaying the card face down, and a random draw and flip animation for each card slot.

I have been soaking up as much as I can and while I may have bit off more than I can chew, I'm committed to just learning as I go even if I'm failing horribly. At this point I cannot find any GitHub projects plugins, or tutorials related to card games in Godot to help me find what type of node I should be using for my animations. I have been trying to use AnimatedSprite, storing multiple animations in one node, and trying to figure out how to call an individual animation at random, but either I'm just too new to the scripting or I'm using the wrong node type.

What would the node tree structure look like for this scene, and what node would I be loading the card sprites into?

edit: I also forgot to mention(just in case it changes what I should be using) that I'd like to also display unique text for each card, text that describes the current visible card. This is for the one card at a time scene, but also for an 'info' button to look at individual cards whenever player wants to understand how a card works.

asked Apr 24 in Engine by collectivenectar (15 points)

1 Answer

+1 vote
Best answer

You shouldn't need any fancy node types. You can get creative with AnimatedSprite and AnimationPlayer to create a flip animation


answered Apr 25 by nathanwfranke (106 points)
selected Apr 27 by collectivenectar

Thank you. Do I need to create one node for each card face?

For each instance of a card, yes. For each type of card, you can make inherited scenes or different animations.

Welcome to Godot Engine Q&A, where you can ask questions and receive answers from other members of the community.

Please make sure to read How to use this Q&A? before posting your first questions.