It is currently 26 Apr 2024, 23:03
   
Text Size

MenuItem_HowToPlay.java Update

Post MTG Forge Related Programming Questions Here

Moderators: timmermac, Blacksmith, KrazyTheFox, Agetian, friarsol, CCGHQ Admins

MenuItem_HowToPlay.java Update

Postby Chris H. » 03 Sep 2009, 01:53

I have spent some time with the MenuItem_HowToPlay.java file. The file is fairly simple and I was able to add additional material. I discovered the escape sequence by accident. I think that I have figured them out except for \b.

When the How To Play window opens the following information will now be displayed. I will wait awhile before I submit this material to Dennis. I want to see if anyone comes up with additional ideas to add and I want to give Dennis a chance to concentrate on other matters.

EDIT:

additional material added in a later message.
Last edited by Chris H. on 07 Sep 2009, 23:34, edited 1 time in total.
User avatar
Chris H.
Forge Moderator
 
Posts: 6320
Joined: 04 Nov 2008, 12:11
Location: Mac OS X Yosemite
Has thanked: 644 times
Been thanked: 643 times

Re: MenuItem_HowToPlay.java Update

Postby silly freak » 03 Sep 2009, 08:15

which escapes do you mean? \b can either mean the backspace character, or in regular expressions a word boundary. i guess you meant the first?

I have a suggestion for the abilities section:

Code: Select all
Abilities

1.  There are three kinds of abilities: Activated, triggered, and static
    Activated abilities contain a colon that separates cost and effect, these can be played any time you could play an instant.
An example is Elvish Piper's ability. That cost also contains the tap symbol.  For creatures only, abilities containing the tap- or untap symbol can be played starting the turn after the creature came into play.
Another common cost for an activated ability is sacrificing the card. You do that by putting it into your graveyard. Such abilities can only be played once.
    Triggered abilities aren't played, they simply trigger when their condition occurs. An example is Angel of Mercy: You don't play the ability, but gain 3 life when it comes into play.
    Static abilities are neither played, nor do they trigger. The still have an effect for as long as they are in play. An example is Glorious Anthem. There is no condition or cost, your creatures are just stronger.
Also, we should consider using battlefield and such, and "specific abilities" should maybe be "keyword abilities".

this thing fits perfectly in my current work, internationalization. that way, the text isn't hard coded and can be changed and translated without recompiling
___

where's the "trust me, that will work!" switch for the compiler?
Laterna Magica - blog, forum, project, 2010/09/06 release!
silly freak
DEVELOPER
 
Posts: 598
Joined: 26 Mar 2009, 07:18
Location: Vienna, Austria
Has thanked: 93 times
Been thanked: 25 times

Re: MenuItem_HowToPlay.java Update

Postby Chris H. » 03 Sep 2009, 14:31

Thank you for the additional material. :D And, yes, I was curious about the backspace form of the escape sequence \b.

Currently MenuItem_HowToPlay.java uses a StringBuffer and appends text to the string. I also have similar ideas about improving the UI. I would like to see a Preferences window with choices that we could make that would then be saved to a file. One of the preferences could be a choice of language.

I have to take small steps at the moment. I am a jr. coder trainee at this time. It is nice to have a few goals in mind for the future. I hope to graduate from kindergarten and advance to first grade at a some point. :lol:

The How To Play window will now be display:

EDIT:

additional material added in a later message.
Last edited by Chris H. on 07 Sep 2009, 23:34, edited 1 time in total.
User avatar
Chris H.
Forge Moderator
 
Posts: 6320
Joined: 04 Nov 2008, 12:11
Location: Mac OS X Yosemite
Has thanked: 644 times
Been thanked: 643 times

Re: MenuItem_HowToPlay.java Update

Postby apthaven » 03 Sep 2009, 14:32

More stuff to add for beginner players:

Code: Select all
Morph - A creature with morph can be played by usually paying 3 mana of any color and be treated as a 2/2 creature with no abilities rather than playing the creature's actual cost. This creature is placed face down in the battlefield and can be flipped face up anytime for as long as you pay its morph cost which is indicated on the card. Once flipped face up the card is treated as the original card, the one that you would normally play with its original cost.

Legendary - Legendary cards are powerful cards that can be either creatures, enchantments or artifacts. These cards can only exist once in the battlefield, and if another copy of the legendary card is played, all copies of the card are destroyed and sent to the graveyard.

Hybrid Cards - Hybrid cards are unique in their casting cost as seen in the card. Instead of seeing a single color per mana symbol, these cards have 2 colors per mana symbol indicating that the player has the choice of playing either of the two. There are also cases where in numbers and colors are combined together in one mana symbol, which indicates that either colorless or colored mana can be paid for each symbol. Hybrid cards are treated as two colors and as such can be said to be multicolored.

Multicolored Cards - This cards are slightly different in hybrid cards, as they require two or more different colors of mana, which may or not be in a single mana symbol. An example would be a card like Lightning Helix which requires one red and one white mana to be played.
"I am a man and real men do not consume pink beverages. Get thee gone woman, and bring me something brown." - Jace Wayland
apthaven
Tester
 
Posts: 242
Joined: 20 Jun 2009, 12:34
Has thanked: 0 time
Been thanked: 1 time

Re: MenuItem_HowToPlay.java Update

Postby Chris H. » 03 Sep 2009, 16:31

Ah, thank you. This is great. :)

We now have enough information that I decided that it was necessary to increase the height of the How to Play window by 10 additional rows.

The How To Play window will now be display:

EDIT:

additional material added in a later message.
Last edited by Chris H. on 07 Sep 2009, 23:35, edited 1 time in total.
User avatar
Chris H.
Forge Moderator
 
Posts: 6320
Joined: 04 Nov 2008, 12:11
Location: Mac OS X Yosemite
Has thanked: 644 times
Been thanked: 643 times

Re: MenuItem_HowToPlay.java Update

Postby mtgrares » 03 Sep 2009, 18:14

Chris and apthaven, thanks for the update.

I hate downloading a game and find out that it doesn't have a few basic instructions so I could play through it. Probably 95% of the people that download MTG Forge know how to play it, but I'm sure that the other 5% are happy to read through the instructions. In the readme I suggest that people download Magic's demo which is pretty good and got me hooked on Magic to begin with.
mtgrares
DEVELOPER
 
Posts: 1352
Joined: 08 Sep 2008, 22:10
Has thanked: 3 times
Been thanked: 12 times

Re: MenuItem_HowToPlay.java Update

Postby Chris H. » 03 Sep 2009, 18:53

mtgrares wrote:Chris and apthaven, thanks for the update.
You are welcome.

I remembered the questions that were asked by several people this year. Some of the new material covers:

You play "matches" against the computer as a set of "best two out of three" games.

The new quest mode and I included the info that you provided about what the difficulty setting will change in the game.

A description for the Resizable Game Area & Stack AI Land check boxes.

I think that people new to forge will likely welcome this additional info.
User avatar
Chris H.
Forge Moderator
 
Posts: 6320
Joined: 04 Nov 2008, 12:11
Location: Mac OS X Yosemite
Has thanked: 644 times
Been thanked: 643 times

Re: MenuItem_HowToPlay.java Update

Postby Huggybaby » 04 Sep 2009, 01:00

This isn't the proper topic perhaps, but since you're talking about helping beginners:

What I would REALLY like in forge quest mode is a pre-made deck to begin with. I could tweak from there after playing a round, but starting from scratch is not appealing to me. Is that possible?
User avatar
Huggybaby
Administrator
 
Posts: 3207
Joined: 15 Jan 2006, 19:44
Location: Finally out of Atlanta
Has thanked: 701 times
Been thanked: 594 times

Re: MenuItem_HowToPlay.java Update

Postby apthaven » 04 Sep 2009, 09:25

@mtgrares: Welcome. Really glad to help ;)



Huggybaby wrote:What I would REALLY like in forge quest mode is a pre-made deck to begin with. I could tweak from there after playing a round, but starting from scratch is not appealing to me. Is that possible?
A starter deck would be a good idea. A newly introduced friend of mine to magic, had a slightly difficult time dealing with those randomly generated decks when he first played Forge, so it would be best if a starter deck would teach him the basics just like in the real magic card game. I guess he had to learn the hard way.

A starter deck would probably have easy to use creatures, not overly complicated with basic effects like a couple of keywords.... something that would win a player the first few games he plays.
"I am a man and real men do not consume pink beverages. Get thee gone woman, and bring me something brown." - Jace Wayland
apthaven
Tester
 
Posts: 242
Joined: 20 Jun 2009, 12:34
Has thanked: 0 time
Been thanked: 1 time

Re: MenuItem_HowToPlay.java Update

Postby Chris H. » 04 Sep 2009, 12:54

Huggybaby wrote:This isn't the proper topic perhaps, but since you're talking about helping beginners:
I hope that people will understand, I would like to move this to a separate message thread which I have started at:

Pre-made deck for Quest Mode
User avatar
Chris H.
Forge Moderator
 
Posts: 6320
Joined: 04 Nov 2008, 12:11
Location: Mac OS X Yosemite
Has thanked: 644 times
Been thanked: 643 times

Re: MenuItem_HowToPlay.java Update

Postby Huggybaby » 04 Sep 2009, 16:08

No problemo, thank you.
User avatar
Huggybaby
Administrator
 
Posts: 3207
Joined: 15 Jan 2006, 19:44
Location: Finally out of Atlanta
Has thanked: 701 times
Been thanked: 594 times

Re: MenuItem_HowToPlay.java Update

Postby Chris H. » 07 Sep 2009, 23:39

I have made another addition. This one covers how you can play a quick game by using either the "Generate Deck" or the "Random" options.

The How To Play window will now be display:

Code: Select all
How to Play  -  (Revised: September 2009.)


Introduction

1.  This game is similar to many other trading card games.  You start out with 20 life and your goal is to reduce your opponents life to zero by attacking with your creatures.  The game will end when your life or the computer's life is reduced to zero.  You play "matches" against the computer as a set of "best two out of three" games.

2.  You use land to pay for spells.  You can play one land a turn.

3.  Each land produces a different magical energy.  This magical energy is shortened to one letter on cards.

    Forests make G
    Swamps make B
    Plains make W
    Islands make U
    Mountains make R

4.  Each non-land card has a name and a cost.  The cost looks like this "2GG" A cost like that would require two Forest lands and two other lands.  The number 2 can be paid for by any land.  A cost like "R", would require a Mountain land.

5.  Creature cards stay in play and can attack on the turn AFTER they are played.  A creature's attack and defense is shown like 2/4 meaning that the creature has an attack power of 2 and a defense of 4.  If this creature receives 4 damage it is put into the graveyard.

6.  When you attack with your creatures the computer has a chance to block with his creatures.  When you attack you "tap" your creatures by turning them sideways.  Your creatures will untap during your next turn.  When you block, only untapped creatures can block.  Usually a creature cannot attack and block during the same turn.

7.  Sorcery and Instant cards have an effect on the game. After you play any card it goes on the stack to the left, click OK and the stack will clear.  Sorcery cards can only be played during your turn and when the stack is empty.  Instant cards can be played at any time and are more versatile.

8.  If a card has a target, you get to choose that target.  If the target is a player, click on that player's life points.

9.  When you mulligan, the cards in your hand are shuffled into you deck and you are given 1 less card.


Legendary Cards

Legendary cards are powerful cards that can be either creatures, enchantments, lands, artifacts or planeswalkers.  These cards can only exist once in the battlefield, and if another copy of the legendary card is played, all copies of the card are destroyed and sent to the graveyard.


Planeswalkers

There are 6 planeswalkers (Ajani Goldmane; Liliana Vess; Garruk Wildspeaker; Chandra Nalaar; Nicol Bolas; Elspeth, Knight-Errant) and they have specific rules for their special abilities.

You can only use one ability a turn.  A planeswalker can be attacked, but you can also block with your creatures.  For each 1 damage a planeswalker receives, you remove 1 counter.  When a planeswalker doesn't have any counters, it goes to the graveyard.


Hybrid Mana and Multicolored Cards

1.  Hybrid Mana Cards are unique in their casting cost as seen in the card.  Instead of seeing a single color per mana symbol, these cards have 2 colors per mana symbol indicating that the player has the choice of playing either of the two.  There are also cases where numbers and colors are combined together in one mana symbol, which indicates that either colorless or colored mana can be paid for each symbol.  Hybrid cards are treated as two colors and as such can be said to be multicolored.

2.  Multicolored Cards are slightly different than hybrid mana cards, as they require two or more different colors of mana, which may or not be in a single mana symbol.  An example would be a card like Lightning Helix which requires one red and one white mana to be played.


Game Types

1.  In Constructed Deck mode you can use any of the cards to make your deck.  To make a constructed deck, from the Deck Editor select "New Deck – Constructed".  A list of all the cards will be displayed.

2.  In Sealed Deck mode you are given 75 cards and you have to make your deck from just those cards.

3.  In Booster Draft mode you select 1 card at a time and then make your deck from just those cards.  After you are done drafting you have to type in a filename, then go to the Deck Editor and from the menu select "Open Deck - Draft" and find the filename.  This will allow you to construct your deck.  You can then play against the other 7 computer opponents that were drafting with you.

4.  In Quest Mode you start out with 275 cards, 200 are Basic Lands. As you complete matches in your quest you will win more cards.  In easy mode you get more cards after every game, whether you win or lose.  Your goal is to become world champion.  Once you reach the end of your quest you can continue to play additional matches and win even more cards or you can start a new quest at anytime.

At the Quest Options screen you will be given a choice of four different difficulty levels.  These difficulty levels control:

1)   the length of the quest in matches,
2)   the hardness of the AI deck that you will face as an opponent,
3)   the number of wins or loses needed to get more cards,
4)   the number of wins needed to advance a player to the next rank.


Quick Games

There may be occasions where you only have a few minutes to play a quick game or two.  At the top of the New Game window you will see the three different game types with radio buttons.  Click on the Constructed (Easy) button and it will become highlighted.

In the middle area of the New Game window you will see two menus, one labeled "Your Deck" and the other "Opponent".  For a quick game you should select the "Generate Deck" or the "Random" option for both you and the computer.

1.  The "Generate Deck" option creates a 2 color deck.  This option randomly picks cards and sometimes your mana curve may be too high.

2.  The "Random" option will randomly select one of the constructed decks that appear in the two deck menus.  You either construct these decks in the Deck Editor or you imported a .deck file from the Deck Editor.

If you select the "Random" option and click on the "Start Game" button and the match fails to begin … well, this happens if you fail to have any constructed decks saved to your all-decks2 file.  You should choose the "Generate Deck" option instead.


Resizable Game Area & Stack AI Land

1.  The "Resizable Game Area" check box should be set to on if your monitor will display more than 1024 x 768 pixels.  The window containing the Battlefield and the informational displays will fill the entire screen.

2.  The "Stack AI Land" option will make the computer a more difficult opponent to beat.  The computer will draw non-land cards from it's library after it has drawn enough lands to cover the cost of it's spells.  Set the check box to on for a stronger opponent and set the check box to off for a weaker opponent.

At times, you may notice that when you click the "Start Game" button that the match fails to begin.  In this case you should turn the "Stack AI Land" option to off.


Abilities

There are three kinds of abilities: Activated, Triggered, and Static.

1.  Activated abilities contain a colon that separates cost and effect, these can be played any time you could play an instant.  An example is Elvish Piper's ability.  That cost also contains the tap symbol.  For creatures only, abilities containing the tap- or untap symbol can be played starting the turn after the creature came into play.  Another common cost for an activated ability is sacrificing the card.  You do that by putting it into your graveyard.  Such abilities can only be played once.

2.  Triggered abilities aren't played, they simply trigger when their condition occurs.  An example is Angel of Mercy: You don't play the ability, but gain 3 life when it comes into play.

3.  Static abilities are neither played, nor do they trigger.  They still have an effect for as long as they are in play.  An example is Glorious Anthem.  There is no condition or cost, your creatures are just stronger.


Keyword Abilities

1.  Flying:  Creatures with flying are harder to block.  Only creatures with flying or reach can block other flyers.

2.  Haste:  Haste lets a creature attack or use any abilities immediately during this turn.

3.  Fear:  Creatures with fear can only be blocked by artifact or black creatures.  Creatures with fear are harder to block.

4.  Cycling:  When you cycle a card you pay some cost like 2 and then you discard that card, and then draw a new card.  Cycling helps make your deck more versatile.

5.  Vigilance:  This means that the creature will not tap when attacking.  This creature can both attack and block during the same turn.

6.  Trample:  If you use 2/1 creature to block an attacking 3/4 creature with trample, you will still receive 2 damage because the 3/4 trampled over your 2/1 creature.  Trample damage is calculated by (attack - blocker's defense), in this case 3-1 which is 2.

7.  Deathtouch:  When a creatures with deathtouch deals damage to a creature, that creature is destroyed.

8.  Defender:  Creatures with defender can not attack, they can only block another attacker.

9.  First Strike and Double Strike:  Creatures with first strike deals their combat damage first.  Creatures with double strike deals their combat damage first, and then deals their combat damage a second time during the combat damage step.

10.  Flash:  You can play a creature with flash anytime that you can play an Instant.

11.  Landwalk:  Allows your creature to attack without being blocked if your opponent controls the appropriate land type.

12.  Lifelink:  With lifeline you gain life equal to the amount of damage dealt.

13.  Protection:  Can not be damaged, blocked or targeted by sources that match the protection type.

14.  Reach:  Creatures with reach can block flying creatures.

15.  Shroud:  Permanents with shroud can not be targeted by abilities or spells.

16.  RegenerateRegenerate is an ability that some creatures have which prevents them from being destroyed and put into the graveyard.  When you regenerate a creature, it acts like a shield until end of turn.

17.  Morph:  A creature with morph can be played by usually paying 3 mana of any color and be treated as a 2/2 creature with no abilities rather than playing the creature's actual cost.  This creature is placed face down in the battlefield and can be flipped face up anytime as long as you pay its morph cost which is indicated on the card.  Once flipped face up the card is treated as the original card, the one that you would normally play with its original-full casting cost.
Last edited by Chris H. on 08 Sep 2009, 20:37, edited 1 time in total.
User avatar
Chris H.
Forge Moderator
 
Posts: 6320
Joined: 04 Nov 2008, 12:11
Location: Mac OS X Yosemite
Has thanked: 644 times
Been thanked: 643 times

Re: MenuItem_HowToPlay.java Update

Postby Chris H. » 07 Sep 2009, 23:49

apthaven wrote:A starter deck would be a good idea. A newly introduced friend of mine to magic, had a slightly difficult time dealing with those randomly generated decks when he first played Forge, so it would be best if a starter deck would teach him the basics just like in the real magic card game. I guess he had to learn the hard way.

A starter deck would probably have easy to use creatures, not overly complicated with basic effects like a couple of keywords.... something that would win a player the first few games he plays.
At one time Rares started to produce a tutorial. The tutorials and some documentation were split off of the frequent forge beta releases and are available on the google site:

03-03-more docs.zip -> more documentation and a tutorial

The tutorials and it's documentation are fairly simple and they could use some additional material. I quess it is just another example of one of the areas where someone could pitch in and help the forge project move forward. :mrgreen:
User avatar
Chris H.
Forge Moderator
 
Posts: 6320
Joined: 04 Nov 2008, 12:11
Location: Mac OS X Yosemite
Has thanked: 644 times
Been thanked: 643 times

Re: MenuItem_HowToPlay.java Update

Postby mtgrares » 10 Sep 2009, 19:07

Thanks I'll post them.
mtgrares
DEVELOPER
 
Posts: 1352
Joined: 08 Sep 2008, 22:10
Has thanked: 3 times
Been thanked: 12 times

Re: MenuItem_HowToPlay.java Update

Postby DennisBergkamp » 10 Sep 2009, 20:20

This stuff looks great Chris. Feel free to submit the code (once you're finished with it), and I'll merge it into the next version :)
User avatar
DennisBergkamp
AI Programmer
 
Posts: 2602
Joined: 09 Sep 2008, 15:46
Has thanked: 0 time
Been thanked: 0 time

Next

Return to Developer's Corner

Who is online

Users browsing this forum: No registered users and 104 guests


Who is online

In total there are 104 users online :: 0 registered, 0 hidden and 104 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: No registered users and 104 guests

Login Form