public void cardGotClicked(baseCard clickedCard) { var userInput = GetNode <UserInput>("/root/UserInput"); GD.Print("hand: ", clickedCard, " got clicked"); userInput.CallDeferred("cardGotClicked", this, clickedCard); }
//input handling of baseCard Child public void cardGotClicked(baseCard clickedCard) { var userInput = GetNode <UserInput>("/root/UserInput"); GD.Print("hand: ", clickedCard, " got clicked"); if (session.currentPhase == session.Phase.PLAY) { userInput.CallDeferred("cardGotClicked", this, clickedCard); } }
public void cardGotClicked(Node where, baseCard what) { if (where is player_hand) { GD.Print(what, " got clicked in player hand"); if (currentSession.currentPhase == session.Phase.PLAY && where.Name == "player_hand") { //hardcode to player1 currentSession.player.Rpc("handToField", what.cardId); } } }
public void playCardOnSubjugator(baseCard card) { GetNode("slots").GetNode("slot2").AddChild(card); }
public void playCardOnField(baseCard card) { GetNode("slots").GetNode("slot1").AddChild(card); }
//takes playerRole and corresponding slot and assign card //game field is not responsible about how player_data gets assigned public void updateSlot(string player, string slot, baseCard card) { GetNode(player).GetNode("slots").GetNode(slot).AddChild(card); }
public void addCardToHand(baseCard newCard) { AddChild(newCard); arrangeHandCards(); }