Jump to content

Tyler

Members
  • Posts

    7
  • Joined

  • Last visited

Posts posted by Tyler

  1. <skill.h>

    After:

     ALL_SONKRAN,

    Added this:

    MG_EARTHBOLT = 700,

    <skill.c>

    In int skill_attack, added this:

    if (!(flag&2) &&
     (
      skillid == MG_COLDBOLT || skillid == MG_FIREBOLT || skillid == MG_LIGHTNINGBOLT || skillid == MG_EARTHBOLT
    

    In int skill_castend_damage_id, after:

    case MG_LIGHTNINGBOLT:

    Added this:

    case MG_EARTHBOLT:

    Changed:

    case HVAN_CAPRICE: //[blackhole89]
    {
    int ran=rnd()%4;
    int sid = 0;
    switch(ran)
    {
    case 0: sid=MG_COLDBOLT; break;
    case 1: sid=MG_FIREBOLT; break;
    case 2: sid=MG_LIGHTNINGBOLT; break;
    //case 3: sid=WZ_EARTHSPIKE; break;
    case 3: sid=MG_EARTHBOLT; break;
    }
    skill_attack(BF_MAGIC,src,src,bl,sid,skilllv,tick,flag|SD_LEVEL);
    }
    break;

    Changed:

    case SA_AUTOSPELL:
    clif_skill_nodamage(src,bl,skillid,skilllv,1);
    if(sd)
    clif_autospell(sd,skilllv);
    else {
    int maxlv=1,spellid=0;
    static const int spellarray[4] = { MG_COLDBOLT,MG_FIREBOLT,MG_LIGHTNINGBOLT,MG_EARTHBOLT };

    In int skill_castend_id changed:

    if(ud->skillid != SA_CASTCANCEL  &&
     !(ud->skillid == SO_SPELLFIST && (sd && (sd->skillid_old == MG_FIREBOLT || sd->skillid_old == MG_COLDBOLT || sd->skillid_old == MG_LIGHTNINGBOLT || sd->skillid_old == MG_EARTHBOLT))) ) {// otherwise handled in unit_skillcastcancel()
    if( ud->skilltimer != tid ) {
    ShowError("skill_castend_id: Timer mismatch %d!=%d!\n", ud->skilltimer, tid);
    ud->skilltimer = INVALID_TIMER;
    return 0;
    }

    In int skill_autospell changed:

    if(skillid==MG_NAPALMBEAT) maxlv=3;
    else if(skillid==MG_COLDBOLT || skillid==MG_FIREBOLT || skillid==MG_LIGHTNINGBOLT || skillid==MG_EARTHBOLT){

    In int skill_stasis_check

    After:

    case SL_KAITE:

    Added:

    case MG_EARTHBOLT:

    <battle.c>

    After:

    case MG_LIGHTNINGBOLT: {
    struct status_change *sc = status_get_sc(src);
    if ( sc && sc->count ) {
    if ( sc->data[sC_SPELLFIST] && (!sd || !sd->state.autocast) ) {
    skillratio += (sc->data[sC_SPELLFIST]->val4 * 100) + (sc->data[sC_SPELLFIST]->val2 * 100) - 100;
    ad.div_ = 1;
    ad.flag = BF_WEAPON|BF_SHORT;
    ad.type = 0;
    }
    if( sc->data[sC_GUST_OPTION] )
    skillratio += skillratio * sc->data[sC_GUST_OPTION]->val2 / 100;
    }
    }
    break;

    Added this:

    case MG_EARTHBOLT: {
    struct status_change *sc = status_get_sc(src);
    if ( sc && sc->count ) {
    if ( sc->data[sC_SPELLFIST] && (!sd || !sd->state.autocast) ) {
    skillratio += (sc->data[sC_SPELLFIST]->val4 * 100) + (sc->data[sC_SPELLFIST]->val2 * 100) - 100;
    ad.div_ = 1;
    ad.flag = BF_WEAPON|BF_SHORT;
    ad.type = 0;
    }
    }
    }

    MY IDEA:

    I'd like to do a bolt skill type using the earth element. With the effect of EARTH SPIKE skill, I'd like a bolt to hit 9 times just like the others bolt skills casting this effect 9 times too.

    It's possible? Or in other case just casting 1 time the effect and 9 hits skill.

  2. What is the best ID for new entries for customized skills, in this tutorial (http://rathena.org/wiki/Custom_skill) which is very old, the author says that the best entry is the 545, but the entry 545 is already being used.

    So I search on the file <skill.h> ID's and discovered that the last ID used skill is the skill ALL_SOKRAN (ID: 699). KN_CHARGEATK is the next entry (ID: 1001).

    So I followed the tutorial 'customized skills' and create the ability MG_EARTHBOLT for my server with the ID: 700.

    So the skill is shown in game but it is only in passive mode, I can't use that.

    So I think the problem is with ID's, does anyone know the best entry?

  3. And where can I see the ID's available to create a custom skill?

    Because to me the ID 700 was completely empty and could be used in the SRC.

    I have seen no signs of future skills there.

    Because soon appear on 1001's of other ID skills. So how could I know?

×
×
  • Create New...