Commit Graph

15 Commits (2733516cb9cdad7ac4cef98b819d4d01846e5c66)

Author SHA1 Message Date
Leandro Doctors 2733516cb9 Organize imports 2020-01-16 08:21:24 +08: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
lodici 19e246b490 remove unused method parameter in GameLoader. 2017-06-19 13:01:26 +01:00
melvinzhang c8f1262b45 remove trailing space from java code 2015-12-31 18:54:52 +08:00
lodici 668a676ef7 Update load saved game to cater for multiple directories (see discussion at end of issue #500). 2015-11-14 11:11:39 +00:00
melvinzhang 40a08b434b remove unnecessary game parameter from createPermanent 2015-05-22 11:05:34 +08:00
melvinzhang 201018db2a replace player and source from getArtificialOptions, getArtificialChoiceResults, and getPlayerChoiceResults 2015-05-16 09:41:33 +08:00
lodici fbe61b36ae rename MagicPlayerDefinition to DuelPlayerConfig. 2015-04-19 20:21:25 +01:00
melvinzhang 7c82eac981 add factory method 'create' to AiProfile and HumanProfile 2015-04-19 09:37:13 +08: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 37ab9d56a2 replace call to setDifficulty and setAIs with MagicPlayerDefinition constructor that takes a player profile 2015-04-04 21:46:33 +08:00
lodici 923e105c18 Since the game state save code is only really aimed at test games can let system decide on player avatar. 2015-02-15 02:33:21 +00:00
melvinzhang 320b6e6bf9 remove sound from MagicGame constructor 2014-11-29 21:00:45 +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