Jump to content
Sign in to follow this  
Anthoni

[HELP] After Rebirth Get Bonus Physical resist +3

Recommended Posts

 

function GetChaName_born ( role )
    local cha_name = GetChaDefaultName ( role )
    local cha_lv = GetChaAttr(role, ATTR_LV) 
    local cha_job = GetChaAttr(role, ATTR_JOB)
    local i = CheckBagItem( role, 2235 )    
    if i < 1 then
        SystemNotice( role ,"Please show your proof of rebirth")
        return 0
    end
    local item_empty=IsEquip(role)
    if item_empty==LUA_TRUE then
        SystemNotice(role,"Please place the all items from character's equipment slot into the inventory!")
        return 0    
    end
    local Item_CanGet = GetChaFreeBagGridNum ( role )    
    if Item_CanGet < 5 then
        SystemNotice(role ,"Inventory needs to have at least 5 free slots!")
        UseItemFailed ( role )
        return 0
    end
    local zs1 =TakeItem( role, 0,2235, 1 )
    if zs1==0 then
        SystemNotice ( role ,"Gather Rebirth Stone failed")
        return 0
    end
    local Zs_Exp = GetChaAttr ( role , ATTR_CSAILEXP )
    if Zs_Exp > 0 then
        SystemNotice(role ,"You've already rebirthed")
        return 0
    end
    local QLZX= GetSkillLv ( role, SK_QLZX )
    local cha_skill_num=GetChaAttr(role, ATTR_TP  )
    local clear_skill_num=ClearFightSkill(role)
    cha_skill_num=cha_skill_num+clear_skill_num
    if QLZX == 1 then
        cha_skill_num = cha_skill_num - 1
        AddChaSkill ( role , SK_QLZX , 1 , 1 , 0 )
    end
    SetChaAttr(role, ATTR_TP ,cha_skill_num ) 
    local ap = GetChaAttr( role , ATTR_AP )
    local cha_str = GetChaAttr(role, ATTR_BSTR  ) 
    local cha_dex = GetChaAttr(role, ATTR_BDEX  ) 
    local cha_agi = GetChaAttr(role, ATTR_BAGI  ) 
    local cha_con = GetChaAttr(role, ATTR_BCON ) 
    local cha_sta = GetChaAttr(role, ATTR_BSTA )
    ap=ap+cha_str+cha_dex+cha_agi+cha_con+cha_sta-25
    SetChaAttr(role, ATTR_BSTR ,5 ) 
    SyncChar(role,4)
    SetChaAttr(role, ATTR_BDEX ,5 ) 
    SyncChar(role,4)
    SetChaAttr(role, ATTR_BAGI ,5 ) 
    SyncChar(role,4)
    SetChaAttr(role, ATTR_BCON,5 ) 
    SyncChar(role,4)
    SetChaAttr(role, ATTR_BSTA,5 ) 
    SyncChar(role,4)
    SetChaAttr(role , ATTR_AP,ap  )
    SyncChar(role,4)
    AddSailExp(role, npc , 1 , 1 )
    local sk_add = SK_ZSSL
    AddChaSkill ( role , sk_add , 1 , 1 , 0 )
    PlayEffect( role, 361 )
    Notice("Extreme celebration, "..cha_name.." Rebirth successful. Blessing from the whole server! "..cha_name.." Hope you have a safe journey and everything goes your way!")
    return 1
end


 

Share this post


Link to post
Share on other sites

Share this post


Link to post
Share on other sites

go to Skilleffect.lua and paste this function to the forum.

 

>>    function Skill_Rbmp_Use( role , sklv ) 

Edited by Jones

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Sign in to follow this  

×
×
  • Create New...