Raised This Month: $ Target: $400
 0% 

Debuging Entagle Rots Ultimate


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Author Message
StormZone
BANNED
Join Date: Nov 2008
Location: [RO]Hunedoara/Petrosani
Old 10-09-2009 , 15:48   Debuging Entagle Rots Ultimate
Reply With Quote #1

This is an uwc3 Ultimate
Normal when presing the bind for this skill a beeping should here and the first enemy you aim should be entagled.
But it doesent and in the console apears "unknown command wcentagle"
wcentagle = is the bind required for this ultimate.

now the log tell us this.
Code:
L 10/07/2009 - 13:16:32: Start of error session.
L 10/07/2009 - 13:16:32: Info (map "fy_snow") (file "addons/amxmodx/logs/error_20091007.log")
L 10/07/2009 - 13:16:32: [AMXX] Displaying debug trace (plugin "uwc3.amxx")
L 10/07/2009 - 13:16:32: [AMXX] Run time error 4: index out of bounds 
L 10/07/2009 - 13:16:32: [AMXX]    [0] tasks.inl::searchtarget (line 1724)
L 10/07/2009 - 13:16:32: [AMXX]    [1] ultimates.inl::Ult_Entangle (line 1425)
L 10/07/2009 - 13:16:33: [AMXX] Displaying debug trace (plugin "uwc3.amxx")
L 10/07/2009 - 13:16:33: [AMXX] Run time error 4: index out of bounds 
L 10/07/2009 - 13:16:33: [AMXX]    [0] tasks.inl::searchtarget (line 1724)
L 10/07/2009 - 13:16:33: [AMXX]    [1] ultimates.inl::Ult_Entangle (line 1425)
This is the task code for this ultimate
PHP Code:
/* Entangle Roots */
public Task_Destroy_Roots args[] )
{
    
remove_entity args[0] );
}

public 
searchtarget(parm[2])
{
    new 
id parm[0];
    new 
enemyzbody;
    
get_user_aiming(id,enemyz,body);

    if ( 
Util_Is_Valid_Playerid ) && Util_Is_Valid_Playerenemyz) && ( enemyz != id ) && Util_NotSame_Team id enemyz ) && is_user_alive id ) && is_user_alive enemyz ) )
    {

        if ( 
Util_Is_Valid_Playerenemyz ) || (!temp_immunity[enemyz] && Util_IsPlayer_Immune enemyz)  ) )
        {
            
temp_immunity[enemyz] = true;
            if ( 
Util_Should_Msg_Clientenemyz ) )
            {
                
client_print enemyzprint_chat"%L"enemyz"ULTIMATE_ENGANGLE_RESISTANT"MOD );
            }

            new 
iparm[2];
            
iparm[0] = enemyz;
            
copyiparm[1], 31"Entangling roots" );
            
set_task 5.0"Task_Reset_Immunity"TASK_RESET_IMMUNITY enemyziparm);
        }

        if ( !
stunned[enemyz] && playeritem[enemyz]!=IMMUNITY && !hasblink[enemyz] && !temp_immunity[enemyz] )
        {
            
issearching[id]=false;
            
ultimateused[id]=true;
            
icon_controller(id);

            if ( 
Util_Should_Msg_Clientid ) )
            {
                if ( 
file_exists "sound/warcraft3/entanglingrootstarget1.wav" ) == )
                {
                    
emit_sound idCHAN_ITEM"warcraft3/entanglingrootstarget1.wav"1.0ATTN_NORM0PITCH_NORM );
                }
                else
                {
                    if ( 
file_exists "sound/weapons/cbar_hitbod3.wav" ) == )
                    {
                        
emit_sound id,CHAN_ITEM"weapons/cbar_hitbod3.wav"1.0ATTN_NORM0PITCH_NORM );
                    }
                }
            }

            new 
Float:speed get_user_maxspeedenemyz );
            if( 
Util_Is_Valid_Playerenemyz ) )
            {
                if(
speed 1.0 && speed != oldSpeed[enemyz] )
                {
                    
oldSpeed[enemyz] = speed;
                }
            }

            new 
waitparm[6];
            
waitparm[0]=enemyz;
            
waitparm[1]=100;
            
waitparm[5]=floatround(speed);
            
set_user_maxspeed(enemyz,1.0);
            
Task_Entangle_Stop(waitparm);

            
stunned[enemyz]=true;
            new 
cooldownparm[1];
            
cooldownparm[0]=id;
            
set_taskCVAR_ENTANGLE_COOLDOWN,"cooldown",50+id,cooldownparm,1);
        }
        else
        {

            if( 
Util_Is_Valid_Playerid ) )
            {
                
issearching[id]=true;
                
icon_controller(id);
            }

            new 
counter parm[1];

            while (
counter >= 0)
            {
                
counter -= 10;
                if (
counter==0)
                    
emit_sound(id,CHAN_ITEM"turret/tu_ping.wav"1.0ATTN_NORM0PITCH_NORM);
            }

            --
parm[1]

            if (
parm[1]>&& get_user_health(id)>0)
            {
                
set_task(0.1"searchtarget"200+idparm2);
            }
            else
            {
                
issearching[id]=false;
                
icon_controller(id);
            }
        }
    }

    return 
PLUGIN_CONTINUE
}

public 
Task_Entangle_Stop parm[6] )
{
    new 
id=parm[0];
    new 
origin[3];
    
get_user_origin idorigin );

    if ( 
origin[0] == parm[2] && origin[1] == parm[3] && origin[2] == parm[4] )
    {
        new 
normalspeed parm[5];
        new 
resetparm[2];
        
resetparm[0] = id;
        
resetparm[1] = normalspeed;
        
set_task float parm[1]/10 ), "reset_maxspeed"TASK_RESET_MAXSPEED id resetparm);

        new 
entangleparm[2];
        
entangleparm[0] = parm[0];
        
entangleparm[1] = parm[1];
        
Event_Entangle entangleparm );
    }
    else
    {
        
parm[2] = origin[0];
        
parm[3] = origin[1];
        
parm[4] = origin[2];
        
set_task 0.1"Task_Entangle_Stop"TASK_ENTANGLE_STOPparm);
    }

    return 
PLUGIN_CONTINUE;

and this is the Ultimate code
PHP Code:
/* Entengle roots */
public Ult_Entangle id 


    if ( !
Ult_Can_Use idSKILLIDX_ENTANGLE ) )  
    { 
        return 
PLUGIN_HANDLED;  
    } 

    if ( 
is_user_alive id ) && Util_Is_Valid_Playerid ) ) 
    { 
        if( !
issearching[id] && !ultimateused[id] ) 
        { 
            new 
parm[2];  
            
parm[0] = id
            
parm[1] = ULTIMATESEARCHTIME;  
            
searchtarget parm ); 
        } 
    }  

    return 
PLUGIN_HANDLED;  

Here are the files to.
PS we are triing to fix this over one moth and cant figure it out.Please help us.
Attached Files
File Type: rar source files.rar (24.9 KB, 54 views)
StormZone is offline
Send a message via Yahoo to StormZone Send a message via Skype™ to StormZone
 


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 22:36.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode