LackeyCCG

LackeyCCG Forum => Plugins & Plugin Creation Forum => Topic started by: Seagrove on January 25, 2013, 02:58:24 PM

Title: How do you make a discard button?
Post by: Seagrove on January 25, 2013, 02:58:24 PM
I thought I had to right click and choose move to top of discard pile, but then I realized you can click and drag.  Is there a way to make a button to do it?
Title: Re: How do you make a discard button?
Post by: mathman1550 on January 25, 2013, 05:45:14 PM
There is a way to make a button to discard from one specific location to the discard pile. For example, if you want to discard the top card of the deck and wanted to call the button "mill", then you would add the following line to your plugininfo file in the plugin:
GENERALFUNCTION2:"TRANSFERCARD"   "mill"   1   -1   1   T   -1   2   T

If you want to discard a specific card from the table or from your hand you are going to have to use one of the methods you already know about because you can not tell the button which card you want to discard in each circumstance.
Title: Re: How do you make a discard button?
Post by: Seagrove on January 26, 2013, 12:58:43 PM
Thanks for your response.  I meant to make a hotkey to do it.  I was wondering if you can make it so i select a card or cards and press delete to send selected card(s) to the discard.
Title: Re: How do you make a discard button?
Post by: mathman1550 on January 27, 2013, 10:03:26 AM
I know you can assign hotkeys to do most anything that you can make a button do, but I don't think that moving a selected card or group of cards to a specific zone is possible as the program stands.