• Vsro Sql System Arena Registery Count


    - it counts every registration & cancellation in battle arena

    and gives players rewards 

    what you need 

    1. Creat a new column in _Char Called : ArenaReg (INT)
    2. Put this in LogChar

    Use In Case Statement better than IF


    IF (@EventID 239) ---- Arena registration
     
    declare @ArenaRegCount int = (SELECT ArenaReg From SRO_VT_SHARD.dbo._Char Where CharID = @CharID)
      
    BEGIN
                
    IF (@Data1 AND @Data2 BETWEEN 1 AND 2
                
    BEGIN
                Update SRO_VT_SHARD
    .dbo._Char Set ArenaReg ArenaReg +1 Where CharID = @CharID
                END
                
    IF (@Data1 AND @Data2 BETWEEN 1 AND 2
                
    BEGIN
                Update SRO_VT_SHARD
    .dbo._Char Set ArenaReg ArenaReg -1 Where CharID = @CharID
                END

        INSERT INTO SRO_VT_SHARD
    .dbo._CharSkill (CharID,SkillID,EnableVALUES
         
    (@CharID,(CASE
         
    WHEN @ArenaRegCount 10 THEN '34851'
         
    WHEN @ArenaRegCount 50 THEN '34852'
         
    WHEN @ArenaRegCount 80 THEN '34853'
         
    WHEN @ArenaRegCount 110 THEN '34854'
         
    WHEN @ArenaRegCount 150 THEN '34855'
         
    WHEN @ArenaRegCount 250 THEN '34856'
         
    END),1)
         
    END  


    - All Copyrights Reserved to Eslam Galull @galullians.com 2015
  • Twitter

    Like us

    Author Info