Jump to content
  • 0

Special Time Buff for VIP


crazyshock

Question

Hi , I'm trying to set up a special time for players who are vip.

I've made the field in characters for VIP, and added in L2pcinstance.

Ok..

 

My problem is anytime you need to do the comparison and check if the player is or is not vip.

By the time I did this setting in Config.java, but I'm not getting through to see if the player.isVip == True, shows no error, but when you start the server would not start.

        ENABLE_VIP_DURATION = Boolean.parseBoolean(COSettings.getProperty("VipTempoCustom", "True"));
                                   
                                   
                                    L2PcInstance player = null;
         
                                    if (ENABLE_VIP_DURATION && player.isVip())
                                   {
                                       String[] propertySplit = COSettings.getProperty("SkillVipDuration", "").split(";");
                                        SKILL_DURACAO = new TIntIntHashMap(propertySplit.length);
                                        for (String skill : propertySplit)
                                       {
                                           String[] skillSplit = skill.split(",");
                                           if (skillSplit.length != 2)
                                             _log.warning(StringUtil.concat("[skillVipDuration]: invalid config property -> SkillDurationList \"", skill, "\""));
                                            else
                                            {
                                                try
                                                {
                                                    SKILL_DURACAO.put(Integer.parseInt(skillSplit[0]), Integer.parseInt(skillSplit[1]));
                                                }
                                                catch (NumberFormatException nfe)
                                                {
                                                    if (!skill.isEmpty())
                                                    {
                                                        _log.warning(StringUtil.concat("[skillVipDuration]: invalid config property -> SkillList \"", skillSplit[0], "\"", skillSplit[1]));
                                                    }
                                                }
                                            }
                                        }
                                    }
                                    

Link to comment
Share on other sites

Recommended Posts

Guest
This topic is now closed to further replies.


×
×
  • Create New...

AdBlock Extension Detected!

Our website is made possible by displaying online advertisements to our members.

Please disable AdBlock browser extension first, to be able to use our community.

I've Disabled AdBlock