Search in sources :

Example 1 with G_PARAMS

use of main.content.values.parameters.G_PARAMS in project Eidolons by IDemiurge.

the class CreationHelper method getRequiredValues.

public static List<VALUE> getRequiredValues(Entity t, boolean extended) {
    AT_OBJ_TYPE TYPE = (AT_OBJ_TYPE) t.getOBJ_TYPE_ENUM();
    List<VALUE> list = new ArrayList<>();
    for (VALUE l : ContentManager.getValuesForType(t.getOBJ_TYPE(), false)) {
        if (extended) {
            if (l.isLowPriority()) {
                continue;
            }
            list.add(l);
        } else if (l.isHighPriority()) {
            if (!(l instanceof G_PROPS)) {
                if (!(l instanceof G_PARAMS)) {
                    list.add(l);
                }
            }
        }
    }
    switch(TYPE) {
        case TASK:
            list.add(AT_PARAMS.GLORY);
            list.add(AT_PARAMS.TIME_ESTIMATED);
            break;
        case DAY:
        case DIRECTION:
        case GOAL:
        case SESSION:
    }
    if (TYPE.getChildValue() != null) {
        list.add(TYPE.getChildValue());
    }
    if (TYPE.getParentValue() != null) {
        list.add(TYPE.getParentValue());
    }
    if (TYPE.getGroupingKey() != G_PROPS.GROUP) {
        list.add(TYPE.getGroupingKey());
    }
    if (TYPE.getSubGroupingKey() != G_PROPS.GROUP) {
        list.add(TYPE.getSubGroupingKey());
    }
    return list;
}
Also used : ArrayList(java.util.ArrayList) VALUE(main.content.VALUE) G_PROPS(main.content.values.properties.G_PROPS) G_PARAMS(main.content.values.parameters.G_PARAMS)

Aggregations

ArrayList (java.util.ArrayList)1 VALUE (main.content.VALUE)1 G_PARAMS (main.content.values.parameters.G_PARAMS)1 G_PROPS (main.content.values.properties.G_PROPS)1