It is currently 29 Apr 2024, 02:59
   
Text Size

Implementing Cards

by BetaSteward

Moderators: North, BetaSteward, noxx, jeffwadsworth, JayDi, TheElk801, LevelX, CCGHQ Admins

Implementing Cards

Postby MoonKnight » 17 Jan 2013, 04:31

Hi I was just curious on how I could go about implementing cards myself. I know quite a bit of Java and instead of always asking for cards to be implemented is it possible I could start doing a few on my own?

I would appreciate just a smidgen of guidance on going about this.

Thank you so much.

MoonKnight
MoonKnight
 
Posts: 43
Joined: 19 Sep 2011, 19:40
Has thanked: 1 time
Been thanked: 2 times

Re: Implementing Cards

Postby LevelX » 17 Jan 2013, 09:07

MoonKnight wrote:Hi I was just curious on how I could go about implementing cards myself. I know quite a bit of Java and instead of always asking for cards to be implemented is it possible I could start doing a few on my own?

I would appreciate just a smidgen of guidance on going about this.

Thank you so much.

MoonKnight
Install (or use if already installed on your pc) latest Java SE JDK 6.xx and an IDE (e.g. NetBeans 7.2)and checkout with the IDE the MAGE projects at https://github.com/magefree/mage.git.

Git and Maven are included (in a limited way) to Netbeans. So it's probably not neccessary to install them separately as long as you doing the common things.

If you are able to successfully build and run mage on your pc (set up works :D ), you can start to code some new cards. To get write access to the project send your created code to North or noxx. They decide who gets write access to the project.

If you have specific questions during the set up of your system, feel free to ask here again.

JAVA SE JDK
http://www.oracle.com/technetwork/java/javase/downloads/jdk6u38-downloads-1877406.html
Netbeans IDE
http://netbeans.org/community/releases/72/

PS: On the project wiki pages are also some hints/advices for developers.
https://github.com/magefree/mage/wiki
User avatar
LevelX
DEVELOPER
 
Posts: 1677
Joined: 08 Dec 2011, 15:08
Has thanked: 174 times
Been thanked: 374 times

Re: Implementing Cards

Postby jeffwadsworth » 17 Jan 2013, 17:56

It appears that the latest release of Netbeans fixes an irritating issue.
Attachments
fix.jpg
jeffwadsworth
Super Tester Elite
 
Posts: 1171
Joined: 20 Oct 2010, 04:47
Location: USA
Has thanked: 287 times
Been thanked: 69 times

Re: Implementing Cards

Postby MoonKnight » 18 Jan 2013, 21:01

Thank you guys so much for so much help. The code is a lot to take in all at once haha...is there any possible way I could create my own cards for the time being just to get a feel for things. I only want them on my personal mage so I can see if what I'm doing is right. Just practice cards to get a feel for things?

Is that possible?
MoonKnight
 
Posts: 43
Joined: 19 Sep 2011, 19:40
Has thanked: 1 time
Been thanked: 2 times

Re: Implementing Cards

Postby LevelX » 18 Jan 2013, 22:30

MoonKnight wrote:Thank you guys so much for so much help. The code is a lot to take in all at once haha...is there any possible way I could create my own cards for the time being just to get a feel for things. I only want them on my personal mage so I can see if what I'm doing is right. Just practice cards to get a feel for things?

Is that possible?
As long as you haven't committed your changes by git, all your work is only in your personal mage. So I would say it's not just possible but it's the only thing you can do. :D
Only if you have write access to the git repository and commit your changes, they will go the common MAGE source code.
User avatar
LevelX
DEVELOPER
 
Posts: 1677
Joined: 08 Dec 2011, 15:08
Has thanked: 174 times
Been thanked: 374 times

Re: Implementing Cards

Postby MoonKnight » 18 Jan 2013, 23:20

Haha alright then! Will I ahve access to all the databases I need to import?

(eg: import java.util.UUID; import mage.Constants; import mage.Constants.CardType;
import mage.Constants.Rarity;...etc.)
MoonKnight
 
Posts: 43
Joined: 19 Sep 2011, 19:40
Has thanked: 1 time
Been thanked: 2 times

Re: Implementing Cards

Postby LevelX » 19 Jan 2013, 00:31

MoonKnight wrote:Haha alright then! Will I ahve access to all the databases I need to import?

(eg: import java.util.UUID; import mage.Constants; import mage.Constants.CardType;
import mage.Constants.Rarity;...etc.)
Yes, you can import the complete MAGE source, build the projects and run your local version of MAGE on your pc.

On the wiki site it's described to clone the complete MAGE source to your local repository.
https://github.com/magefree/mage/wiki/Developer-Getting-Started
User avatar
LevelX
DEVELOPER
 
Posts: 1677
Joined: 08 Dec 2011, 15:08
Has thanked: 174 times
Been thanked: 374 times

Re: Implementing Cards

Postby MoonKnight » 19 Jan 2013, 02:31

That is super helpful thank you so much. I am a bit confused (sorry, bear with me I haven't used NetBeans before to download repositories) on how to use the url to get them. When I place it in the box it then asks me for a password and won't connect. Am I doing something wrong? Probably am haha
MoonKnight
 
Posts: 43
Joined: 19 Sep 2011, 19:40
Has thanked: 1 time
Been thanked: 2 times

Re: Implementing Cards

Postby LevelX » 19 Jan 2013, 08:00

MoonKnight wrote:That is super helpful thank you so much. I am a bit confused (sorry, bear with me I haven't used NetBeans before to download repositories) on how to use the url to get them. When I place it in the box it then asks me for a password and won't connect. Am I doing something wrong? Probably am haha
Here are the steps, how to clone the MAGE project with Netbeans.

Menu: Team->Git->Clone

GitClone01.jpg


GitClone02.jpg
GitClone02.jpg (6.93 KiB) Viewed 4896 times


GitClone03.jpg

traget directory and name can be set to the value you like on your system
User avatar
LevelX
DEVELOPER
 
Posts: 1677
Joined: 08 Dec 2011, 15:08
Has thanked: 174 times
Been thanked: 374 times

Re: Implementing Cards

Postby North » 19 Jan 2013, 12:00

You'll definitely want to use our tools for generating the base class for cards. It is in the Utils directory. You need to have perl installed to use it. I think it's all in those wiki pages.

What there isn't is the location to our card tracking tool: http://ct-magefree.rhcloud.com/

Use that to search for cards with similar behavior. Note that when searching for ability text the following character is used as a placeholder for anything: %. I found it very easy to get into developing cards by example and there are a lot of them that can be implemented like this.

I bet you'll find yourself ready to submit cards in no time.
North
DEVELOPER
 
Posts: 93
Joined: 15 May 2011, 08:20
Has thanked: 8 times
Been thanked: 15 times

Re: Implementing Cards

Postby MoonKnight » 19 Jan 2013, 14:43

you all have been so helpful. Thank you so much for taking the time to answer my questions.
MoonKnight
 
Posts: 43
Joined: 19 Sep 2011, 19:40
Has thanked: 1 time
Been thanked: 2 times

Re: Implementing Cards

Postby MoonKnight » 19 Jan 2013, 21:22

In the Developer Getting Started Wiki it says to install the Text-Template from the Perl Package Manager but there is no such package in the listings?
MoonKnight
 
Posts: 43
Joined: 19 Sep 2011, 19:40
Has thanked: 1 time
Been thanked: 2 times

Re: Implementing Cards

Postby LevelX » 19 Jan 2013, 22:45

MoonKnight wrote:In the Developer Getting Started Wiki it says to install the Text-Template from the Perl Package Manager but there is no such package in the listings?
I normally don't use the perl tools, so I'm not familiar with it.

I guess this is a link to the lib you need:
http://cpansearch.perl.org/src/MJD/Text-Template-1.45/lib/Text/Template.pm
User avatar
LevelX
DEVELOPER
 
Posts: 1677
Joined: 08 Dec 2011, 15:08
Has thanked: 174 times
Been thanked: 374 times

Re: Implementing Cards

Postby Kratos Aurion » 10 Feb 2016, 17:35

https://github.com/magefree/mage/wiki/Developer-Getting-Started wrote:2. Start NetBeans and clone the code repository from there: Team -> Git -> Clone.
this is the URL for the repository: https://github.com/magefree/mage.git/
I always get the error message "Cannot connect to repository at https://github.com/magefree/mage.git/".
Kratos Aurion
 
Posts: 15
Joined: 11 May 2014, 14:08
Has thanked: 0 time
Been thanked: 0 time

Re: Implementing Cards

Postby LevelX » 10 Feb 2016, 22:41

Kratos Aurion wrote:
https://github.com/magefree/mage/wiki/Developer-Getting-Started wrote:2. Start NetBeans and clone the code repository from there: Team -> Git -> Clone.
this is the URL for the repository: https://github.com/magefree/mage.git/
I always get the error message "Cannot connect to repository at https://github.com/magefree/mage.git/".
Firewall or Proxy?
User avatar
LevelX
DEVELOPER
 
Posts: 1677
Joined: 08 Dec 2011, 15:08
Has thanked: 174 times
Been thanked: 374 times

Next

Return to XMage

Who is online

Users browsing this forum: Bing [Bot] and 160 guests


Who is online

In total there are 161 users online :: 1 registered, 0 hidden and 160 guests (based on users active over the past 10 minutes)
Most users ever online was 4143 on 23 Jan 2024, 08:21

Users browsing this forum: Bing [Bot] and 160 guests

Login Form