mirror of
https://github.com/mcMMO-Dev/mcMMO.git
synced 2024-11-23 05:36:46 +01:00
Added some missing config items
This commit is contained in:
parent
d141a28747
commit
1d62f8b177
@ -695,31 +695,7 @@ public class AdvancedConfig extends AutoUpdateConfigLoader {
|
|||||||
/* Interaction Settings */
|
/* Interaction Settings */
|
||||||
public boolean doesNotificationUseActionBar(NotificationType notificationType)
|
public boolean doesNotificationUseActionBar(NotificationType notificationType)
|
||||||
{
|
{
|
||||||
String key = "";
|
return config.getBoolean("Skills.FeedBack.ActionBarNotifications."+notificationType.toString(), true);
|
||||||
|
|
||||||
switch(notificationType)
|
|
||||||
{
|
|
||||||
case XP_GAIN:
|
|
||||||
key = "ExperienceGain";
|
|
||||||
break;
|
|
||||||
case LEVEL_UP_MESSAGE:
|
|
||||||
key = "LevelUp";
|
|
||||||
break;
|
|
||||||
case SUBSKILL_MESSAGE:
|
|
||||||
key = "SubSkillInteraction";
|
|
||||||
break;
|
|
||||||
case SUBSKILL_UNLOCKED:
|
|
||||||
key = "SubSkillUnlocked";
|
|
||||||
break;
|
|
||||||
case TOOL:
|
|
||||||
key = "ToolReady";
|
|
||||||
break;
|
|
||||||
case SUPER_ABILITY:
|
|
||||||
key = "SuperAbilityInteraction";
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
|
|
||||||
return config.getBoolean("Skills.FeedBack.ActionBarNotifications."+key, true);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
@ -4,6 +4,7 @@ import com.gmail.nossr50.config.AdvancedConfig;
|
|||||||
import com.gmail.nossr50.datatypes.interactions.NotificationType;
|
import com.gmail.nossr50.datatypes.interactions.NotificationType;
|
||||||
import com.gmail.nossr50.datatypes.player.McMMOPlayer;
|
import com.gmail.nossr50.datatypes.player.McMMOPlayer;
|
||||||
import com.gmail.nossr50.datatypes.skills.PrimarySkill;
|
import com.gmail.nossr50.datatypes.skills.PrimarySkill;
|
||||||
|
import com.gmail.nossr50.datatypes.skills.SubSkillType;
|
||||||
import com.gmail.nossr50.datatypes.skills.subskills.AbstractSubSkill;
|
import com.gmail.nossr50.datatypes.skills.subskills.AbstractSubSkill;
|
||||||
import com.gmail.nossr50.datatypes.skills.subskills.interfaces.InteractType;
|
import com.gmail.nossr50.datatypes.skills.subskills.interfaces.InteractType;
|
||||||
import com.gmail.nossr50.datatypes.skills.subskills.interfaces.Interaction;
|
import com.gmail.nossr50.datatypes.skills.subskills.interfaces.Interaction;
|
||||||
@ -172,6 +173,16 @@ public class InteractionManager {
|
|||||||
return subSkillList;
|
return subSkillList;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public static boolean hasSubSkill(String name)
|
||||||
|
{
|
||||||
|
return getAbstractByName(name) != null;
|
||||||
|
}
|
||||||
|
|
||||||
|
public static boolean hasSubSkill(SubSkillType subSkillType)
|
||||||
|
{
|
||||||
|
return hasSubSkill(subSkillType.getNiceNameNoSpaces(subSkillType));
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Returns the associative map which contains all registered interactions
|
* Returns the associative map which contains all registered interactions
|
||||||
* @return the interact register
|
* @return the interact register
|
||||||
|
@ -580,7 +580,7 @@ public class TextComponentFactory {
|
|||||||
{
|
{
|
||||||
if(Permissions.isSubSkillEnabled(player, subSkillType))
|
if(Permissions.isSubSkillEnabled(player, subSkillType))
|
||||||
{
|
{
|
||||||
if(InteractionManager.getInteractRegister().get(subSkillType.getNiceNameNoSpaces(subSkillType)) == null)
|
if(!InteractionManager.hasSubSkill(subSkillType))
|
||||||
textComponents.add(TextComponentFactory.getSubSkillTextComponent(player, subSkillType));
|
textComponents.add(TextComponentFactory.getSubSkillTextComponent(player, subSkillType));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -17,11 +17,15 @@ Skills:
|
|||||||
Feedback:
|
Feedback:
|
||||||
# Turning these to false will have them printed in chat instead
|
# Turning these to false will have them printed in chat instead
|
||||||
ActionBarNotifications:
|
ActionBarNotifications:
|
||||||
|
AbilityOff: true
|
||||||
|
LevelRequirementNotMet: true
|
||||||
|
AbilityCoolDown: true
|
||||||
LevelUps: true
|
LevelUps: true
|
||||||
ToolReady: true
|
ToolReady: true
|
||||||
SubSkillInteraction: true
|
SubSkillInteraction: true
|
||||||
SubSkillUnlocked: true
|
SubSkillUnlocked: true
|
||||||
SuperAbilityInteraction: true
|
SuperAbilityInteraction: true
|
||||||
|
SuperAbilityAlertOthers: true
|
||||||
ExperienceGain: true
|
ExperienceGain: true
|
||||||
General:
|
General:
|
||||||
Ability:
|
Ability:
|
||||||
|
Loading…
Reference in New Issue
Block a user