示例#1
0
        public static void HandleChangeDarkLight(MapleCharacter chr, int sourceSkillId)
        {
            LuminousSystem resource = (LuminousSystem)chr.Resource;

            if (sourceSkillId == LuminousBasics.SUNFIRE)
            {
                if (resource.LightLevel > 0)
                {
                    chr.CancelBuffSilent(LuminousBasics.ECLIPSE);
                    DataBuffer.CharacterSkillBuffer[LuminousBasics.SUNFIRE].GetEffect(1).ApplyBuffEffect(chr);
                    resource.LightLevel--;
                    resource.State = LuminousState.Light;
                }
            }
            else if (sourceSkillId == LuminousBasics.ECLIPSE)
            {
                if (resource.DarkLevel > 0)
                {
                    chr.CancelBuffSilent(LuminousBasics.SUNFIRE);
                    DataBuffer.CharacterSkillBuffer[LuminousBasics.ECLIPSE].GetEffect(1).ApplyBuffEffect(chr);
                    resource.DarkLevel--;
                    resource.State = LuminousState.Dark;
                }
            }
            chr.AddCooldown(LuminousBasics.SUNFIRE, 180000);
            chr.AddCooldown(LuminousBasics.ECLIPSE, 180000);
            chr.AddCooldown(LuminousBasics.CHANGE_LIGHT_DARK_MODE, 180000);
        }
示例#2
0
        public static void HandleGaugeGain(MapleCharacter chr, int skillId, int gaugeInc)
        {
            LuminousSystem resource = (LuminousSystem)chr.Resource;
            LuminousState  state    = SkillConstants.GetLuminousSkillState(skillId);

            if (state == LuminousState.Light)
            {
                resource.IncreaseLightGauge(gaugeInc, chr);
            }
            else
            {
                resource.IncreaseDarkGauge(gaugeInc, chr);
            }
            chr.Client.SendPacket(resource.Update());
        }