Skip to content

Commit

Permalink
Merge branch 'develop'
Browse files Browse the repository at this point in the history
# Conflicts:
#	README.md
#	build.gradle
#	gradle/wrapper/gradle-wrapper.jar
#	gradle/wrapper/gradle-wrapper.properties
#	tcg-clojure/build.gradle
#	tcg-java/build.gradle
  • Loading branch information
bkimminich committed Apr 1, 2019
2 parents 76f3b51 + c45a97b commit f917fd4
Show file tree
Hide file tree
Showing 14 changed files with 21 additions and 78 deletions.
4 changes: 3 additions & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,10 @@ addons:
secure: "BZmcxIDz7oEkm7PGOmZBS7ShRxH/AWL6ktf614qyDrfBA1YFIs/i1dnz39TTRl3kN7WOMu5XhQDDQxz6ZaPDOWOE/HQorQIX2ATiMXaohwZPg3qgjKHN3jtLRlO3JHLpazABOrEBHG0WsK6hIIHUcv+JbHQF0HyP/7a5RGkv4HA="

after_success:
- ./gradlew dependencyCheck --info
- ./gradlew coveralls
- ./gradlew pitest
- ./tcg-js/node_modules/.bin/lcov-result-merger 'tcg-js/coverage/*/lcov.info' 'tcg-js/coverage/lcov_merged.info'
- cd ./tcg-js; cat "./coverage/lcov_merged.info" | ./node_modules/.bin/codeclimate

sudo: false
sudo: false
17 changes: 8 additions & 9 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -51,26 +51,25 @@ When the normal game rules have become too easy/boring you might consider adding
| --- | --- |
| Let players choose to play cards either as immediate damage _Attacks_ (same as cards generally worked in the [Basic Gameplay](#BasicGameplay) rules) or as _Minions_ that are put on the board instead. Minions will use the mana cost of their card as Health and Damage value. Playing a 0 card will create a minion with 1 Health and 0 Damage. | ![Playing Card as Minion](doc/Minions1_PlayingCardAsMinion.png) |
| Health has to be tracked when they receive damage. ||
| Each player can have a _maximum of 3 Minions_ on the board at any given time. | |
| Each player can have a _maximum of 3 Minions_ on the board at any given time. | |
| A Minion will _sleep_ in the turn it was put on the board. | ![Sleeping on first turn](doc/Minions2_SleepingOnFirstTurn.png) |
| In any subsequent turn _each_ Minion can be used _once_ to deal damage to the opponent player or an opponent Minion. | ![Attacking Opponent or enemy Minion](doc/Minions3_AttackingOpponentOrEnemyMinion.png) |
| A Minion fighting another Minion will result in them dealing their damage value to each other simultaneously. | ![Simultaneous Damage](doc/Minions4_SimultaneousDamage.png) |
| Sleeping Minions will defend themselves in the same way when attacked by another Minion. | ![Sleeping Minions fight back](doc/Minions5_SleepingMinionsFightBack.png) |
| Players can choose to play an Attack against a Minion. The attacked Minion will not defend itself in this case, thus the attacking player receives no damage from it. | ![Player fighting Minion](doc/Minions6_PlayerFightingMinion.png) |
| When a Minions health drops to or below zero it is removed from the board. | ![Kill Minion](doc/Minions7_KillMinion.png) |
| When a Minions health drops to or below zero it is removed from the board. | ![Kill Minion](doc/Minions7_KillMinion.png) |

### Miscellaneous

- Let Mana cost and damage dealt be different from each other thus making cheap powerful, expensive mediocre or entirely useless cards possible. This can add a whole new layer of play strategy as some cards might not be desired to be ever played, but eventually have to in order to free your hand for better cards.
- Introduce _Card Drawer_ cards that cost Mana but don't do any damage. Instead they let you draw a given number of cards from your deck. Those cards can be used in the current turn or later on (just as if normally drawn at the beginning of the active player's turn).
- Allow players to create their own decks of 20 cards from a larger _Card Pool_. Let those decks be saved to and loaded from disk before starting a game.

## Static Code Analysis
### Sample Implementation Status

### Java [![Coverage Status](https://coveralls.io/repos/bkimminich/kata-tcg/badge.png?branch=master)](https://coveralls.io/r/bkimminich/kata-tcg?branch=master) [![Dependency Status](https://www.versioneye.com/user/projects/544a3042c310f980320000d1/badge.svg?style=flat)](https://www.versioneye.com/user/projects/544a3042c310f980320000d1)

### Javascript [![Test Coverage](https://codeclimate.com/github/bkimminich/kata-tcg/badges/coverage.svg)](https://codeclimate.com/github/bkimminich/kata-tcg) [![Code Climate](https://codeclimate.com/github/bkimminich/kata-tcg/badges/gpa.svg)](https://codeclimate.com/github/bkimminich/kata-tcg) [![Dependency Status](https://www.versioneye.com/user/projects/544a3040c310f96cf00000fa/badge.svg?style=flat)](https://www.versioneye.com/user/projects/544a3040c310f96cf00000fa)

### Groovy [![Dependency Status](https://www.versioneye.com/user/projects/544a3042c310f90e740000ce/badge.svg?style=flat)](https://www.versioneye.com/user/projects/544a3042c310f90e740000ce)
| Language | Quality Metrics |
| --- | --- |
| Java | [![Coverage Status](https://coveralls.io/repos/bkimminich/kata-tcg/badge.png?branch=master)](https://coveralls.io/r/bkimminich/kata-tcg?branch=master) [![Dependency Status](https://www.versioneye.com/user/projects/544a3042c310f980320000d1/badge.svg?style=flat)](https://www.versioneye.com/user/projects/544a3042c310f980320000d1) |
| JS | [![Test Coverage](https://codeclimate.com/github/bkimminich/kata-tcg/badges/coverage.svg)](https://codeclimate.com/github/bkimminich/kata-tcg) [![Code Climate](https://codeclimate.com/github/bkimminich/kata-tcg/badges/gpa.svg)](https://codeclimate.com/github/bkimminich/kata-tcg) [![Dependency Status](https://www.versioneye.com/user/projects/544a3040c310f96cf00000fa/badge.svg?style=flat)](https://www.versioneye.com/user/projects/544a3040c310f96cf00000fa) |
| Groovy | [![Dependency Status](https://www.versioneye.com/user/projects/544a3042c310f90e740000ce/badge.svg?style=flat)](https://www.versioneye.com/user/projects/544a3042c310f90e740000ce) |

### Clojure [![Dependency Status](https://www.versioneye.com/user/projects/544a3042c310f9bcb5000126/badge.svg?style=flat)](https://www.versioneye.com/user/projects/544a3042c310f9bcb5000126)
8 changes: 7 additions & 1 deletion build.gradle
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
apply plugin: 'jacoco'
apply plugin: 'com.github.kt3k.coveralls'
apply plugin: 'info.solidsoft.pitest'

buildscript {
repositories {
Expand All @@ -8,6 +9,9 @@ buildscript {

dependencies {
classpath 'org.kt3k.gradle.plugin:coveralls-gradle-plugin:2.0.1'
classpath 'org.owasp:dependency-check-gradle:1.3.3'
classpath 'com.github.ben-manes:gradle-versions-plugin:0.11.3'
classpath 'info.solidsoft.gradle.pitest:gradle-pitest-plugin:1.1.10'
}
}

Expand All @@ -16,7 +20,9 @@ repositories {
}

subprojects {
version = '1.6.0'
version = '1.6.1'
apply plugin: 'org.owasp.dependencycheck'
apply plugin: 'com.github.ben-manes.versions'
}

task wrapper(type: Wrapper) {
Expand Down
1 change: 0 additions & 1 deletion settings.gradle
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
include 'tcg-java'
include 'tcg-groovy'
include 'tcg-clojure'
include 'tcg-js'
9 changes: 0 additions & 9 deletions tcg-clojure/.gitignore

This file was deleted.

20 changes: 0 additions & 20 deletions tcg-clojure/build.gradle

This file was deleted.

3 changes: 0 additions & 3 deletions tcg-clojure/doc/intro.md

This file was deleted.

4 changes: 0 additions & 4 deletions tcg-clojure/project.clj

This file was deleted.

9 changes: 0 additions & 9 deletions tcg-clojure/src/main/clojure/de/kimminich/kata/tcg/game.clj

This file was deleted.

14 changes: 0 additions & 14 deletions tcg-clojure/src/test/clojure/de/kimminich/kata/tcg/game_test.clj

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,7 @@
import de.kimminich.kata.tcg.Card;
import de.kimminich.kata.tcg.Move;

import java.util.Comparator;
import java.util.List;
import java.util.Optional;

/**
* This strategy plays the highest affordable cards for attacking. It switches into healing with the lowest possible cards when the players health falls below 20.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,7 @@
import de.kimminich.kata.tcg.Card;
import de.kimminich.kata.tcg.Move;

import java.util.Comparator;
import java.util.List;
import java.util.Optional;

/**
* This strategy plays the highest affordable cards first and only for attacking. No healing is used regardless of the players health.
Expand Down
4 changes: 2 additions & 2 deletions tcg-js/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -3,15 +3,15 @@ buildscript {
jcenter()
}
dependencies {
classpath 'com.moowork.gradle:gradle-node-plugin:0.6'
classpath 'com.moowork.gradle:gradle-node-plugin:0.+'
}
}

apply plugin: 'com.moowork.node'

node {
// Version of node to use.
version = '0.12.3'
version = '4.2.4'

// Base URL for fetching node distributions (change if you have a mirror).
distBaseUrl = 'http://nodejs.org/dist'
Expand Down
2 changes: 1 addition & 1 deletion tcg-js/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "kata-tcg",
"version": "1.5.0",
"version": "1.5.1",
"description": "Sample implementation of the Trading Card Game Kata",
"author": "Bjoern Kimminich",
"private": true,
Expand Down

0 comments on commit f917fd4

Please sign in to comment.