Fix rewards

This commit is contained in:
Daniel Saukel 2016-02-20 14:45:31 +01:00
parent f58063a3b2
commit b0324f9da8

View File

@ -521,13 +521,11 @@ public class DPlayer {
}
// Belohnung
if ( !isInTestMode()) {// Nur wenn man nicht am Testen ist
if (gameWorld.getGame().getType().hasRewards()) {
if (finished) {
if (gameWorld.getGame() != null) {
if (gameWorld.getGame().getType().hasRewards()) {
for (Reward reward : gameWorld.getConfig().getRewards()) {
reward.giveTo(player);
}
for (Reward reward : gameWorld.getConfig().getRewards()) {
reward.giveTo(player);
}
}