Leandro Doctors
2733516cb9
Organize imports
2020-01-16 08:21:24 +08:00
Bilbo
22a1471424
Add "card test" mode that tests all cards in a predefined scenario.
2019-12-06 23:04:39 +01:00
Martin Petricek
bd5ae5fd7a
Refactoring ( #1543 )
...
* Fix typos.
* Remove unnecessary boxing/unboxing.
* Replace traditional 'for' loops with 'foreach' loops.
* Replace explicit types with <> (diamonds) where they can be inferred.
* Collapse identical catch branches.
* Replace statement lambda with expression lambda for short statements.
* Remove unnecessary imports.
* Replace some lambdas with Comparator.comparing
* Replace Runnables with lambdas.
* Use addAll instead of adding whole collection manually.
* Simplify boolean expressions.
* Remove redundant 'else'.
* Simplify some boolean conditions that are always true or false.
* Inline redundant local variables.
* Remove extraneous semicolons.
* Fix Javadoc errors.
* Replace anonymous classes with lambdas.
* Replace chain of 'if's with switch.
* Remove delaration of exception that is never thrown.
* Use String/StringBuilder properly.
2018-04-08 08:59:14 +08:00
ShawnieBoy
e9e6dcc857
enable addToLibrary without int to match other methods
2016-02-17 21:32:08 +00:00
ShawnieBoy
56d83791a7
add addToGraveyard method without int to match other methods
2016-02-10 11:20:54 +00:00
ShawnieBoy
db63200e3b
remove duplication in TestGameBuilder
2016-01-29 17:47:54 +00:00
ShawnieBoy
719d09285d
enable TestGameBuilder to not require amount for addCardToHand
2016-01-29 17:17:39 +00:00
melvinzhang
c8f1262b45
remove trailing space from java code
2015-12-31 18:54:52 +08:00
melvinzhang
40a08b434b
remove unnecessary game parameter from createPermanent
2015-05-22 11:05:34 +08:00
melvinzhang
22a0e6a48d
replace TokenCardDefinitions.get with CardDefinitions.getToken
2015-05-09 12:23:03 +08:00
lodici
fbe61b36ae
rename MagicPlayerDefinition to DuelPlayerConfig.
2015-04-19 20:21:25 +01:00
lodici
89438aa3da
run :: Netbeans -> Refactor -> Inspect and Transform... -> Organize imports ::
...
on all classes in magic.test package.
2015-04-19 19:57:32 +01:00
lodici
22bc9445ed
remove unused MagicPlayerDefinition import from test classes.
2015-04-19 19:49:26 +01:00
melvinzhang
7c82eac981
add factory method 'create' to AiProfile and HumanProfile
2015-04-19 09:37:13 +08:00
melvinzhang
4e1133a41f
rename MagicGame.checkState to checkStatePutTriggers
2015-04-18 22:17:05 +08:00
melvinzhang
b141750f09
add call to checkState to put items on stack
2015-04-18 22:17:05 +08:00
melvinzhang
1fd44c6fd6
use name() of Enum as player name instead of toString()
2015-04-18 17:47:20 +08:00
ShawnieBoy
f8e8df8e8e
add additional constructors for createPermanent() - can omit permanent count if '1', and omit tapped boolean if untapped
2015-04-15 20:10:32 +01:00
ShawnieBoy
7fb8c0eb27
add suggested createDuel() constructor to specify AI
2015-04-15 17:53:54 +01:00
ShawnieBoy
6d0757342a
refactor MagicPlayTokenAction -> PlayTokenAction
2015-04-14 13:45:01 +01:00
ShawnieBoy
aa51ef8f1b
refactor MagicPlayCardFromStackAction -> PlayCardFromStackAction
2015-04-14 13:08:00 +01:00
lodici
bfb498b257
rename HumanPlayer to HumanProfile.
2015-04-05 14:50:40 +01:00
lodici
6bfa6a0784
rename AiPlayer to AiProfile.
2015-04-05 14:48:12 +01:00
melvinzhang
6572be00a8
remove constructor of MagicPlayerDefinition that does not use PlayerProfile
2015-04-05 16:22:52 +08:00
melvinzhang
95627f0cfe
both MagicPlayCardAction and MagicPlayTokenAction takes into account replacement of MagicSpellCardEvent by making use of event from MagicCardOnstack
2015-01-24 17:18:22 +08:00
melvinzhang
bf3f05671e
convert line endings to LF
2014-11-07 20:09:48 +08:00
lodici
0fea74e72a
New save game feature that can save game state to detail compatible with test scenarios.
2014-11-07 11:26:02 +00:00
melvin
64368e1b9a
remove extraneous whitespace
2013-06-24 09:33:35 +08:00
melvin
f1b27c586c
convert to UNIX line endings
2013-04-13 10:32:25 +08:00
melvin
313bf5c6ae
replace cast with asSubclass
2012-10-27 11:50:24 +08:00
melvin
5c198179dc
convert tab to four spaces
2012-08-26 16:46:26 +08:00
melvin
161e3d5675
convert CardDefinitions and TokenCardDefinitions to a static class
2011-11-23 13:49:13 +08:00
wait321
29a431b99b
moved token definitions to tokens.txt
2011-10-16 08:12:06 -07:00
melvin
780eea2bd9
minimize accessibility
2011-09-11 20:12:18 +08:00
melvin
92eaecee9e
removed redundant modifiers, added final annotation
2011-09-08 17:23:22 +08:00
melvin
be38ef3ece
made getGame abstract
2011-09-06 21:13:50 +08:00
melvin
d4bb115cfc
remove null check for cardDefinition, initalized lastPermanent to MagicPermanent.NONE instead of null
2011-09-04 14:42:17 +08:00
melvin
57beae6a8e
replaced import * with single class import statements
2011-08-31 14:08:53 +08:00
melvin
850d01d3d1
optimized import statements with IntelliJ
2011-08-10 23:28:35 +08:00
melvin
f59ba1d693
documented each try block for more systematic exception handling
2011-08-06 10:49:03 +08:00
melvin
51181c43b5
replaced new RuntimeException(ex.getMessage()) with new RuntimeException(ex)
2011-08-03 22:47:43 +08:00
melvin
8d32fde337
replaced Exception with specific subclass
2011-08-03 14:54:24 +08:00
melvin
36d70eea9f
removed empty lines
2011-07-05 10:47:51 +08:00
melvin
27ccec8657
made capitalization of error messages more consistent
2011-06-24 10:46:35 +08:00
melvin
2f27745ddc
removed some empty lines
2011-06-16 15:05:35 +08:00
melvin
d9c6e6bfa0
show ERROR! on error
2011-06-08 11:52:48 +08:00
melvin
e28a880536
added exception handling
2011-05-27 12:56:55 +08:00
melvin
c19540bbe5
each test game is now a separate class, set property testGame=ClassName to start with this game, for eg. -DtestGame=TestNPH
2011-05-27 11:17:53 +08:00
melvin
a128a93c9d
made it possible to setup multiple test games, test games are activated by name
2011-05-26 12:02:55 +08:00
ubeefx
336f429638
Added sound effects to game.
2011-04-24 17:12:21 +00:00