private void ThiefSkill(NecClient client, int skillId, int targetId)
        {
            int skillBase = skillId / 1000;

            if (!_server.SettingRepository.SkillBase.TryGetValue(skillId, out SkillBaseSetting skillBaseSetting))
            {
                Logger.Error($"Getting SkillBaseSetting from skillid [{skillId}]");
                int            errorCode = -1;
                RecvSkillExecR execFail  = new RecvSkillExecR(errorCode, 0, 0);
                Router.Send(execFail, client);
                return;
            }

            if (skillBase > 114300 && skillBase < 114399)
            {
                Trap(client, skillId, skillBaseSetting);
                return;
            }
            else if (skillBase == 114607)
            {
                Stealth(client, skillId, skillBaseSetting);
                return;
            }

            RecvSkillExecR execSuccess =
                new RecvSkillExecR(0, skillBaseSetting.CastingCooldown, skillBaseSetting.RigidityTime);

            Router.Send(execSuccess, client);
            ThiefSkill thiefSkill =
                (ThiefSkill)Server.Instances.GetInstance((uint)client.Character.activeSkillInstance);

            thiefSkill.SkillExec();
        }
        private void Trap(NecClient client, int skillId, SkillBaseSetting skillBaseSetting)
        {
            Logger.Debug($"skillId : {skillId}");
            if (!int.TryParse($"{skillId}".Substring(1, 5), out int skillBase))
            {
                Logger.Error($"Creating skillBase from skillid [{skillId}]");
                int            errorCode = -1;
                RecvSkillExecR execFail  = new RecvSkillExecR(errorCode, 0, 0);
                Router.Send(execFail, client);
                return;
            }

            if (!int.TryParse($"{skillId}".Substring(1, 7), out int effectBase))
            {
                Logger.Error($"Creating skillBase from skillid [{skillId}]");
                int            errorCode = -1;
                RecvSkillExecR execFail  = new RecvSkillExecR(errorCode, 0, 0);
                Router.Send(execFail, client);
                return;
            }

            bool isBaseTrap = TrapTask.baseTrap(skillBase);

            effectBase += 1;
            if (!_server.SettingRepository.EoBase.TryGetValue(effectBase, out EoBaseSetting eoBaseSetting))
            {
                Logger.Error($"Getting EoBaseSetting from effectBase [{effectBase}]");
                int            errorCode = -1;
                RecvSkillExecR execFail  = new RecvSkillExecR(errorCode, 0, 0);
                Router.Send(execFail, client);
                return;
            }

            if (!_server.SettingRepository.EoBase.TryGetValue(effectBase + 1, out EoBaseSetting eoBaseSettingTriggered))
            {
                Logger.Error($"Getting EoBaseSetting from effectBase+1 [{effectBase + 1}]");
                int            errorCode = -1;
                RecvSkillExecR execFail  = new RecvSkillExecR(errorCode, 0, 0);
                Router.Send(execFail, client);
                return;
            }

            RecvSkillExecR execSuccess =
                new RecvSkillExecR(0, skillBaseSetting.CastingCooldown, skillBaseSetting.RigidityTime);

            Router.Send(execSuccess, client);

            // ToDo  verify trap parts available and remove correct number from inventory
            TrapStack trapStack = (TrapStack)Server.Instances.GetInstance((uint)client.Character.activeSkillInstance);
            Trap      trap      = new Trap(skillBase, skillBaseSetting, eoBaseSetting, eoBaseSettingTriggered);

            _server.Instances.AssignInstance(trap);
            Logger.Debug($"trap.InstanceId [{trap.InstanceId}]  trap.Name [{trap._name}]  skillId[{skillId}]");
            trapStack.SkillExec(trap, isBaseTrap);
            Vector3 trapPos = new Vector3(client.Character.X, client.Character.Y, client.Character.Z);
        }
        private void Stealth(NecClient client, int skillId, SkillBaseSetting skillBaseSetting)
        {
            float cooldown = 0.0F;

            Logger.Debug($"IsStealthed [{client.Character.IsStealthed()}]");
            if (client.Character.IsStealthed())
            {
                cooldown = skillBaseSetting.CastingCooldown;
            }
            RecvSkillExecR execSuccess = new RecvSkillExecR(0, cooldown, skillBaseSetting.RigidityTime);

            Router.Send(execSuccess, client);

            Stealth stealth = (Stealth)Server.Instances.GetInstance((uint)client.Character.activeSkillInstance);

            stealth.SkillExec();
        }
        private void MageSkill(NecClient client, int skillId, int targetId)
        {
            if (!_server.SettingRepository.SkillBase.TryGetValue(skillId, out SkillBaseSetting skillBaseSetting))
            {
                Logger.Error($"Getting SkillBaseSetting from skillid [{skillId}]");
                int            errorCode = -1;
                RecvSkillExecR execFail  = new RecvSkillExecR(errorCode, 0, 0);
                Router.Send(execFail, client);
                return;
            }

            RecvSkillExecR execSuccess =
                new RecvSkillExecR(0, skillBaseSetting.CastingCooldown, skillBaseSetting.RigidityTime);

            Router.Send(execSuccess, client);

            Spell spell = (Spell)Server.Instances.GetInstance((uint)client.Character.activeSkillInstance);

            spell.SkillExec();
        }