Jump to content
  • 0
Sign in to follow this  
kifu21

Spider web working like ankle snare

Question

Need help on this one

It seems its not working 

        case UNT_ANKLESNARE:
        case UNT_MANHOLE:
        case UNT_SPIDERWEB:
            if( sg->val2 == 0 && tsc && (sg->unit_id == UNT_ANKLESNARE || bl->id != sg->src_id) ) {
                int sec = skill->get_time2(sg->skill_id,sg->skill_lv);
                if( status->change_start(ss,bl,type,10000,sg->skill_lv,sg->group_id,0,0,sec, SCFLAG_FIXEDRATE) ) {
                    const struct TimerData* td = tsc->data[type]?timer->get(tsc->data[type]->timer):NULL;
                    if( td )
                        sec = DIFF_TICK32(td->tick, tick);
                    if( sg->unit_id == UNT_MANHOLE || battle_config.skill_trap_type || !map_flag_gvg2(src->bl.m) ) {
                        unit->movepos(bl, src->bl.x, src->bl.y, 0, 0);
                        clif->fixpos(bl);
                    }
                    sg->val2 = bl->id;
                } else
                    sec = 3000; //Couldn't trap it?
                if( sg->unit_id == UNT_ANKLESNARE ) {
                    clif->skillunit_update(&src->bl);
                    /**
                     * If you're snared from a trap that was invisible this makes the trap be
                     * visible again -- being you stepped on it (w/o this the trap remains invisible and you go "WTF WHY I CANT MOVE")
                     * bugreport:3961
                     **/
                    clif->changetraplook(&src->bl, UNT_ANKLESNARE);
                }
                sg->limit = DIFF_TICK32(tick,sg->tick)+sec;
                sg->interval = -1;
                src->range = 0;
            }
            break;

Share this post


Link to post
Share on other sites

0 answers to this question

Recommended Posts

There have been no answers to this question yet

Join the conversation

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

Guest
Answer this question...

×   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.

Loading...
Sign in to follow this  

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.