Commit Graph

8 Commits (2733516cb9cdad7ac4cef98b819d4d01846e5c66)

Author SHA1 Message Date
Leandro Doctors 2733516cb9 Organize imports 2020-01-16 08:21:24 +08:00
Ada Joule d213884dc2 Add Saga mechanic (#1564)
* Add AtBeginOfFirstMainPhaseTrigger and adding lore counter to saga

* Make add counter trigger more generic

* Change begin main phase trigger to Saga-specific

* Add magic.data.RomanToInt

* Add chapter parsing to ARG

* Add SagaChapterTrigger

* Add chapter ability to MagicAbility

* Add lore counter mechanic to Saga card definiton

* Add Saga sacrifice state-based action

* Fix import

* Fix getPendingTriggers

* Add History of Benalia

* Fix adding ETB trigger

* Remove AtBeginningOfFirstMainPhaseTrigger.Saga, Add counters directly in MagicMainPhase.executeBeginStep()

* Remove null case from RomanToInt

* Revert "Remove AtBeginningOfFirstMainPhaseTrigger.Saga, Add counters directly in MagicMainPhase.executeBeginStep()"

This reverts commit d8e5d1f253ab7b54f401f4151b44d39ee927f44c.

* Move isSaga method to IRenderableCard
2018-05-04 14:17:55 +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
melvinzhang 35f423b263 add casting condition to legendary sorceries, closes #1536 2018-04-05 20:21:52 +08:00
lodici 0cbf1879c2 CardCanvas will display greyscale card image if card is invalid (see deck tiled cards screen). 2017-07-12 07:25:32 +01:00
lodici 15e999b557 Update tryDownloadingImage() to work only with IRenderableCard. 2016-10-12 19:53:28 +01:00
lodici 7d893ff28d update getImageType() to work only with IRenderableCard. 2016-10-12 19:53:28 +01:00
lodici 79ae406b44 relocate IRenderableCard into magic.model. 2016-10-06 12:26:58 +01:00