Custom ai class

Lineage2Interlude

Свой человек
Участник
Сообщения
81
Розыгрыши
0
Репутация
0
Реакции
10
Баллы
560
Hello. I am looking for someone who can edit and increase my script from the AI.obj and skilldata (InterludeVanganth)

Код:
class 1 abyss_adrenaline_deamon : default_npc
{
handler:
  EventHandler MENU_SELECTED( fhtml0, talker, ask, reply )
  {
    if( talker == myself.c_ai0 )
    {
      if( ask == -301 )
      {
        if( reply == myself.i_ai1 )
        {
              myself.i_ai0 = 3;
              myself::SetMemoState( talker, 255, 34343434 );
              myself::GiveItem1( talker, 9478, 3 );
........................................................
........................................................
........................................................
 

if I understood correctly
write for nasc GF+ (i'm not worked with Vanganth IT AI), but I think principle is clear

created - buff effect (mass effect)
select dialog ask=1 \ reply=2 - dispel this effect

C#:
    EventHandler CREATED()
    {
        AddUseSkillDesire(myself.sm, @EFFECT_ORI_NAME, @ST_ATTACK, @AMT_MOVE_TO_TARGET, 1000000);
        super;
    }

    EventHandler MENU_SELECTED(talker, ask, reply)
    {
        if(ask == 1 && reply == 2)
        {
            if(GetAbnormalLevel(talker, Skill_GetAbnormalType(@EFFECT_ORI_NAME)) == 1)
            {
                Dispel(talker, Skill_GetAbnormalType(@EFFECT_ORI_NAME))
            }
        }
        super;
    }
 
yea i know about the dispel is on GF :) i am using lagacy extender c4-interlude :)
can i have your skype or discord i cant use pm here?
 
When i remove the despawn everything is ok. But if have despawn its not giving me the debuff only the reward.
Any ideas?

Код:
EventHandler MENU_SELECTED( fhtml0, talker, ask, reply )
{
if( talker == myself.c_ai0 )
{
if( ask == -301 )
{
if( reply == myself.i_ai1 )
{
myself.i_ai0 = 3;
myself::SetMemoState( talker, 255, 34343434 );
myself::GiveItem1( talker, 9478, 3 );
myself::AddUseSkillDesire( talker, @s_protection_skill2, @ST_ATTACK, @AMT_MOVE_TO_TARGET, 1000000 );
myself::Despawn();
}

How i can time here or check for item.
 
When i remove the despawn everything is ok. But if have despawn its not giving me the debuff only the reward.
Any ideas?

Код:
EventHandler MENU_SELECTED( fhtml0, talker, ask, reply )
{
if( talker == myself.c_ai0 )
{
if( ask == -301 )
{
if( reply == myself.i_ai1 )
{
myself.i_ai0 = 3;
myself::SetMemoState( talker, 255, 34343434 );
myself::GiveItem1( talker, 9478, 3 );
myself::AddUseSkillDesire( talker, @s_protection_skill2, @ST_ATTACK, @AMT_MOVE_TO_TARGET, 1000000 );
myself::Despawn();
}

How i can time here or check for item.
AI works async. ,use timers for skill\despawn
 
Yes. you are right i add time and its perfect.
myself::AddTimerEx( 4567, 5000 );


else if ( timer_id == 4567) {
myself::Despawn();
 
Назад
Сверху Снизу