Class BaseAchievementConfig

java.lang.Object
com.deco2800.game.entities.configs.achievements.BaseAchievementConfig

public class BaseAchievementConfig
extends java.lang.Object
Defines a basic set of achievement properties stored in achievement config file (achievements.json) to be loaded by Achievement Factory
  • Field Summary

    Fields 
    Modifier and Type Field Description
    int bonus  
    ConditionConfig condition  
    java.lang.String iconPath  
    java.lang.String message  
    java.lang.String name  
    java.lang.String type  
    boolean unlocked  
  • Constructor Summary

    Constructors 
    Constructor Description
    BaseAchievementConfig()  
  • Method Summary

    Modifier and Type Method Description
    java.util.Map<java.lang.String,​java.lang.Integer> getConditionMap()
    Returns a mapping of the achievement name and value for easy processing This makes it very easy to iterate through all the properties and fetch the values, and saves a lot of technical debt.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details

  • Constructor Details

  • Method Details

    • getConditionMap

      public java.util.Map<java.lang.String,​java.lang.Integer> getConditionMap()
      Returns a mapping of the achievement name and value for easy processing This makes it very easy to iterate through all the properties and fetch the values, and saves a lot of technical debt. In simple words, a mapping of member variables and values of the 'ConditionConfig' object is returned by this function.
      Returns:
      conditionProps mapping of condition name and associated value