Raised This Month: $51 Target: $400
 12% 

Prometheus (Enhanced Hostages)


Post New Thread Reply   
 
Thread Tools Display Modes
hoboman
Senior Member
Join Date: Jul 2007
Old 03-25-2008 , 16:37   Re: Prometheus (Enhanced Hostages)
Reply With Quote #61

Quote:
Originally Posted by XxAvalanchexX View Post
hoboman: The original CS hostage models have all of the animation sequences from the scientists in Half-Life (give or take one), which goes up into the hundreds. It looks like most of the Hostitron models only have 37 sequences (which is probably all that is normally used by CS), and the kneeling animation that I use is not included in those. So the crouch animation is not going to work with those.

cs1.6: Try redownloading, it should be fixed.
thank you for answering my question four months later, that was really helpful
__________________
hoboman is offline
XxAvalanchexX
Veteran Member
Join Date: Oct 2004
Location: abort73.com
Old 03-25-2008 , 19:47   Re: Prometheus (Enhanced Hostages)
Reply With Quote #62

Thanks for reading my answer four months later.

Since I was replying anyway to help out cs1.6 I thought that I might as well let you know why it wasn't working instead of forever ignoring you.
__________________
No longer around. Thanks your support, everyone! As always:
THIS ONES FOR YOU
3000 PTS
XxAvalanchexX is offline
iknowiz58
Member
Join Date: Sep 2006
Old 04-25-2008 , 09:20   Re: Prometheus (Enhanced Hostages)
Reply With Quote #63

if we use cs1.6 hostages in cz would this plugin work? from reading what is being mentioned here is it because cz bots dont have the animation squences required?
__________________

iknowiz58 is offline
redboyke
Member
Join Date: May 2008
Old 05-28-2008 , 22:57   Re: Prometheus (Enhanced Hostages)
Reply With Quote #64

is it possible to fix the sound of the hostages when they are walking(footsteps)?
cause when you enable this plugin there is no (footsteps)sound anymore when the hostages walk around.
redboyke is offline
XxAvalanchexX
Veteran Member
Join Date: Oct 2004
Location: abort73.com
Old 05-28-2008 , 23:17   Re: Prometheus (Enhanced Hostages)
Reply With Quote #65

Sorry for the super late reply, iknowiz58: The problem isn't the animations but the AI code.

redboyke: I'm not sure why there are no footstep sounds, so I don't know of a fix. Sorry.
__________________
No longer around. Thanks your support, everyone! As always:
THIS ONES FOR YOU
3000 PTS
XxAvalanchexX is offline
redboyke
Member
Join Date: May 2008
Old 06-01-2008 , 19:08   Re: Prometheus (Enhanced Hostages)
Reply With Quote #66

Quote:
Originally Posted by XxAvalanchexX View Post
Sorry for the super late reply, iknowiz58: The problem isn't the animations but the AI code.

redboyke: I'm not sure why there are no footstep sounds, so I don't know of a fix. Sorry.
i think you made the hostages float or something
cause you can see hostages fly 1cm in the air instead of on the floor.

maybe it is possible for hostages to be on the ground and make them float when person that touched them touches the ladder
and remove the float again when they hit the floor

for the ducking basicly same thing make them float when the persons duck and unfloat again when player isnt ducked
i dunno anything about this but im just trying to give you ideas

Last edited by redboyke; 06-01-2008 at 19:14.
redboyke is offline
~Neko
Junior Member
Join Date: Oct 2008
Old 10-23-2008 , 19:12   Re: Prometheus (Enhanced Hostages)
Reply With Quote #67

I look the videos,,,, nice work !
__________________
~Neko is offline
Old 04-10-2009, 13:25
1337
This message has been deleted by 1337. Reason: it was not this plugin's problem
TankU
Member
Join Date: Jun 2011
Old 12-28-2011 , 08:03   Re: Prometheus (Enhanced Hostages)
Reply With Quote #68

The Plugin is loadet, but the Hostages-IQ is still < 0
They cant climbe or duck ...

Any one an Idea?

THX

ps: after changing the hostage models (female Pack) the Plugin works perfectly.
Greate Plugin. Now it makes funn to rescue the hostages (bevor the Plugin i had to kill them *lol* )

Last edited by TankU; 12-28-2011 at 10:44. Reason: Problem solved
TankU is offline
leonard19941
Veteran Member
Join Date: Jun 2011
Old 06-07-2012 , 14:58   Re: Prometheus (Enhanced Hostages)
Reply With Quote #69

Prometheus

PHP Code:
/* Plugin generated by AMXX-Studio */

#include <amxmodx>
#include <amxmisc>
#include <cstrike>
#include <fakemeta>
#include <fakemeta_util>
#include <hamsandwich>

#define VERSION "0.14"

#define OFFSET_HOSTAGE_KILLS        217    // kills for mp_hostagepenalty

#define PLAYER_MAX_SAFE_FALL_SPEED    500.0    // exact (OLD: 488.5)
#define PLAYER_FATAL_FALL_SPEED        960.0    // not exact (OLD: 988.5)
#define DAMAGE_FOR_FALL_SPEED        100.0    // (PLAYER_FATAL_FALL_SPEED - PLAYER_MAX_SAFE_FALL_SPEED)

// animation defines
#define ANIM_KNEEL_HOS    126
#define ANIM_KNEEL_SCI    127
#define FRAME_RATE    3.0

// storage containers
#define WAS_DUCKING    pev_iuser1
#define ON_LADDER    pev_iuser2
#define ANIMATING    pev_iuser3
#define LAST_TOUCHER    pev_iuser4
#define ANIM_FRAME    pev_fuser1
#define FALL_VELOCITY    pev_fuser2
#define CUSTOM_WALL    pev_iuser1

// ladder defines
#define MAX_LADDERS    16
#define DIR_NONE    -1
#define DIR_EAST    0
#define DIR_NORTH    1
#define DIR_WEST    2
#define DIR_SOUTH    3

new iLadderIndexMAX_LADDERS ], iLadderDirectionMAX_LADDERS ];

new 
Float:fLadderMinsMAX_LADDERS ][ ], Float:fLadderMaxsMAX_LADDERS ][ ], Float:fLadderOriginMAX_LADDERS ][ ];

new 
iLadderNumiClassName10 ], Float:fJumpTime33 ];

new 
g_pCvarClimbSpeedg_pCvarCanDuckg_pCvarDirLaddersg_pCvarFallDmgg_pCvarDoorDistg_pCvarFallPenaltyg_pCvarJumpDelayg_pCvarJumpSpeed;

new 
mp_hostagepenalty;

new 
g_iMsgTextMsg;

public 
plugin_init( )
{
    
register_plugin"Prometheus"VERSION"Avalanche" );

    
g_pCvarClimbSpeed register_cvar"Hostage_Climb_Speed""256.0" );
    
g_pCvarCanDuck register_cvar"Hostage_can_Duck""1" );
    
g_pCvarDirLadders register_cvar"Hostage_Directional_Ladders""1" );
    
g_pCvarFallDmg register_cvar"Hostage_Fall_Damage""1.0" );
    
g_pCvarDoorDist register_cvar"Hostage_Use_Door_Distance""64.0" );
    
g_pCvarFallPenalty register_cvar"Hostage_Fall_Penalty""1" );
    
g_pCvarJumpDelay register_cvar"Hostage_Jump_Delay""0.25" );
    
g_pCvarJumpSpeed register_cvar"Hostage_Jump_Speed""256.0" );
    
    
mp_hostagepenalty get_cvar_pointer"mp_hostagepenalty" );

    new 
iMod16 ];
    
get_modnameiMod15 );

    if( !
equaliMod"cstrike" ) )
    {
        
log_amx"Prometheus cannot run in %s!"iMod);
        
pause"ad" );
        return;
    }

    if( !
fm_find_ent_by_class1"hostage_entity" ) )
        return;
    
    
register_forwardFM_AddToFullPack,"Fw_AddToFullPack");

    
RegisterHamHam_Think"hostage_entity""Fw_Think");
    
RegisterHamHam_Touch"hostage_entity""Fw_Touch");
    
RegisterHamHam_Player_Jump"player""Fw_PlayerJump");
    
    
g_iMsgTextMsg get_user_msgid"TextMsg" );
    
    
set_task0.1"plugin_cfg" );

    new 
iEnti;
    while( ( 
iEnt fm_find_ent_by_classiEnt,"func_ladder" ) ) != )
    {
        
iLadderIndexiLadderNum ] = iEnt;
        
peviEntpev_absminfLadderMinsiLadderNum ] );
        
peviEntpev_absmaxfLadderMaxsiLadderNum ] );

        for( 
i=0i<3i++ ) fLadderOriginiLadderNum ][ ] = ( fLadderMinsiLadderNum ][ ] + fLadderMaxsiLadderNum ][ ]) * 0.5;

        
iLadderDirectioniLadderNum ] = get_ladder_directioniLadderNum );
        
        if( ++
iLadderNum >= MAX_LADDERS)
            break; 
    }
}

public 
plugin_cfg( )
{
    new 
location_cfg33 ];
    
get_configsdirlocation_cfgcharsmaxlocation_cfg ) );
    
server_cmd"exec %s/prometheus.cfg"location_cfg );
    
server_exec( );
}

public 
get_ladder_directionladder )
{
    new 
eIlluseWallFloat:fAbsMin], Float:fAbsMax];

    while( ( 
eIllus fm_find_ent_by_classeIllus"func_illusionary" ) ) != )
    {
        
eWall fm_create_entity"func_wall" );

        
set_peveWallpev_solidSOLID_BSP );
        
set_peveWallpev_movetypeMOVETYPE_PUSH );

        
set_peveWallpev_modelindexpeveIlluspev_modelindex ) );
        
peveIlluspev_absminfAbsMin );
        
peveIlluspev_absmaxfAbsMax );
        
engfuncEngFunc_SetSizeeWallfAbsMinfAbsMax );

        
set_peveWallCUSTOM_WALL);
    }

    new 
iTr;
    new 
Float:flFractionFloat:fStart], Float:fGoal], Float:fEnd], Float:fDistances];

    
fStart fLadderOriginladder ];
    
fStart] = fLadderMinsladder ][ ];

    
fGoal fLadderOriginladder ];
    
fGoal] += ( fLadderMaxsladder ][ ]-fLadderMinsladder ][ ] ) * 2.0;

    
engfuncEngFunc_TraceLinefStartfGoal0ladderiTr );
    
get_tr2iTrTR_flFractionflFraction );
    
get_tr2iTrTR_vecEndPosfEnd );

    if( 
flFraction == 1.0 || get_tr2iTrTR_StartSolid ) ) fDistancesDIR_EAST ] = 4096.0;
    
    else
        
fDistancesDIR_EAST ] = vector_distancefLadderOriginladder ], fEnd );

    
fStart fLadderOriginladder ];
    
fStart] = fLadderMinsladder ][ ];

    
fGoal fLadderOriginladder ];
    
fGoal] += ( fLadderMaxsladder ][ ]-fLadderMinsladder ][ ] ) * 2.0;

    
engfuncEngFunc_TraceLinefStartfGoal0ladderiTr );
    
get_tr2iTrTR_flFractionflFraction );
    
get_tr2iTrTR_vecEndPosfEnd );

    if( 
flFraction == 1.0 || get_tr2iTrTR_StartSolid ) ) fDistancesDIR_NORTH ] = 4096.0;
    
    else
        
fDistancesDIR_NORTH ] = vector_distancefLadderOriginladder ], fEnd );

    
fStart fLadderOriginladder ];
    
fStart] = fLadderMaxsladder ][ ];

    
fGoal fLadderOriginladder ];
    
fGoal] -= ( fLadderMaxsladder ][ ]-fLadderMinsladder ][ ] ) * 2.0;

    
engfuncEngFunc_TraceLinefStartfGoal0ladderiTr );
    
get_tr2iTrTR_flFractionflFraction );
    
get_tr2iTrTR_vecEndPosfEnd );

    if( 
flFraction == 1.0 || get_tr2iTrTR_StartSolid ) ) fDistancesDIR_WEST ] = 4096.0;
    
    else
        
fDistancesDIR_WEST ] = vector_distancefLadderOriginladder ], fEnd );

    
fStart fLadderOriginladder ];
    
fStart] = fLadderMaxsladder ][ ];

    
fGoal fLadderOriginladder ];
    
fGoal] -= ( fLadderMaxsladder ][ ]-fLadderMinsladder ][ ] ) * 2.0;

    
engfuncEngFunc_TraceLinefStartfGoal0ladderiTr );
    
get_tr2iTrTR_flFractionflFraction );
    
get_tr2iTrTR_vecEndPosfEnd );

    if( 
flFraction == 1.0 || get_tr2iTrTR_StartSolid ) ) fDistancesDIR_SOUTH ] = 4096.0;
    
    else
        
fDistancesDIR_SOUTH ] = vector_distancefLadderOriginladder ], fEnd );

    new 
iiClosestDir DIR_NONE;
    for( 
i=0i<4i++ )
    {
        if( 
fDistances] >= 4096.0 )
            continue;

        if( 
iClosestDir == DIR_NONE || fDistances] <= fDistancesiClosestDir ] )
            
iClosestDir i;
    }

    
eWall 0;
    while( ( 
eWall fm_find_ent_by_classeWall"func_wall" ) ) != )
        if( 
peveWallCUSTOM_WALL ) )
            
fm_remove_entityeWall );

    return 
iClosestDir;
 }

public 
Fw_AddToFullPackes_handleeenthosthostflagsplayerpSet )
{
    static 
iModel];

    if( 
player || !pev_valident ) )
        return 
FMRES_IGNORED;

    
peventpev_classnameiClassName);

    if( 
iClassName] != 'h' || iClassName] != 'o' || iClassName] != 's' || iClassName] != 't' )
        return 
FMRES_IGNORED;

    if( 
peventANIMATING ) && !peventpev_deadflag ) )
    {
        new 
Float:fFrame;
        
peventANIM_FRAMEfFrame );

        
set_eses_handleES_FramefFrame );
        
set_eses_handleES_FrameRate0.0 );

        
peventpev_modeliModel);
        
set_eses_handleES_Sequence, ( iModel] == 's' ) ? ANIM_KNEEL_SCI ANIM_KNEEL_HOS );

        return 
FMRES_HANDLED;
    }

    return 
FMRES_IGNORED;
}

public 
Fw_Thinkent )
{
    static 
Float:hOrigin];

    if( 
peventpev_deadflag ) )
    {
        
reset_hostageent );
        return 
FMRES_IGNORED;
    }

    new 
iLeader cs_get_hostage_follent );
    
peventpev_originhOrigin );

    
hOrigin] += 36.0;
    new 
bool:bHeadSpace is_monster_hull_vacantenthOrigin );
    
hOrigin] -= 36.0;

    new 
iFallDmgDeath hostage_fall_aientiLeaderget_pcvar_floatg_pCvarFallDmg ) );

    if( !
iLeader )
    {
        
set_peventpev_movetypeMOVETYPE_STEP );
        
set_peventON_LADDER0);

        if( 
peventWAS_DUCKING ) && !bHeadSpace )
            return 
FMRES_IGNORED;

        
set_peventWAS_DUCKING);

        
set_peventpev_minsFloat:{ -10.0, -10.00.0 } );
        
set_peventpev_maxsFloat:{ 10.010.062.0 } );

        if( 
peventANIMATING ) )
        {
            new 
Float:fFrame;
            
peventANIM_FRAMEfFrame );

            if( 
fFrame FRAME_RATE 0.0 )
                
set_peventANIM_FRAMEfFrame-FRAME_RATE );
            else
            {
                
set_peventANIM_FRAME0.0 );
                
set_peventANIMATING);
            }
        }

        return 
FMRES_IGNORED;
    }

    if( 
iFallDmgDeath )
        return 
FMRES_IGNORED;

    new 
Float:fDoorDist get_pcvar_floatg_pCvarDoorDist ), Float:fClimbSpeed get_pcvar_floatg_pCvarClimbSpeed ), Float:fJumpDelay get_pcvar_floatg_pCvarJumpDelay );

    if( 
fDoorDist 0.0 )
        
hostage_door_aientiLeaderhOriginfDoorDist );
    
    if( 
get_pcvar_numg_pCvarCanDuck ) )
        
hostage_duck_aientiLeaderbHeadSpace );
        
    if( 
fClimbSpeed 0.0 )
        
hostage_ladder_aientiLeaderhOriginfClimbSpeed );
        
    if( 
fJumpDelay 0.0 )
        
hostage_jump_aientiLeaderfJumpDelay );

    return 
FMRES_IGNORED;
}

hostage_door_aientleaderFloat:hOrigin], Float:maxDist )
{
    static 
Float:lOrigin[3], Float:vecEndPos];
    
pevleaderpev_originlOrigin );

    new 
iPtr;
    
engfuncEngFunc_TraceLinehOriginlOriginDONT_IGNORE_MONSTERSentiPtr );

    new 
iHit get_tr2iPtrTR_pHit );

    if( 
iHit <= || iHit == leader || !pev_validiHit ) )
        return;

    
get_tr2iPtrTR_vecEndPosvecEndPos );

    if( 
vector_distancehOriginvecEndPos ) > maxDist )
        return;

    
peviHitpev_classnameiClassName);

    if( !
equaliClassName,"func_door" ) )
        return;

    
peviHitpev_targetnameiClassName);

    if( 
iClassName] )
        return;

    
dllfuncDLLFunc_TouchiHitent );
    return;
}

hostage_fall_aientleaderFloat:dmgModifier )
{
    static 
Float:fVelocity];

    if( 
dmgModifier <= 0.0 )
        return 
0;

    if( !
is_user_aliveleader ) )
    {
        new 
iLastToucher peventLAST_TOUCHER );

        if( 
is_user_aliveiLastToucher ) )
            
leader iLastToucher;
        else
            
leader 0;
    }

    new 
Float:fFallVelocity;
    
peventFALL_VELOCITYfFallVelocity );

    if( 
fFallVelocity PLAYER_MAX_SAFE_FALL_SPEED && ( peventpev_flags ) & FL_ONGROUND ) )
    {
        new 
Float:fFallDamageFloat:fHealthiFallPenalty get_pcvar_numg_pCvarFallPenalty );
        
peventpev_healthfHealth );

        
fFallVelocity -= PLAYER_MAX_SAFE_FALL_SPEED;
        
fFallDamage floatfloatroundfFallVelocity DAMAGE_FOR_FALL_SPEED dmgModifier ) );

        if( 
iFallPenalty && leader )
        {
            new 
Float:fPrice;

            if( 
fFallDamage fHealth fPrice fHealth 0.055;
            
            else
                
fPrice fFallDamage 0.055;

            if( 
fHealth fFallDamage <= 0.0 )
                
fPrice *= 2.0;

            
fPrice floatfloatroundfPrice 10.0 ) * 10 );
            
cs_set_user_moneyleaderclampcs_get_user_moneyleader ) - floatroundfPrice ), 016000 ) );
        }

        if( 
fHealth floatfloatroundfFallDamage ) ) <= 0.0 )
        {
            if( 
iFallPenalty && leader )
            {
                static 
uName32 ], uAuthId32 ], uTeam10 ];
                
get_user_nameleaderuNamecharsmaxuName ) );
                
get_user_authidleaderuAuthIdcharsmaxuAuthId ) );
                
get_user_teamleader,  uTeamcharsmax(  uTeam ) );

                
log_message("^"%s<%i><%s><%s>^" triggered ^"Killed_A_Hostage^""uNameget_user_useridleader ), uAuthIduTeam );

                
emessage_beginMSG_ONEg_iMsgTextMsg, { 00}, leader );
                
ewrite_byte);
                
ewrite_string"#Killed_Hostage" );
                
emessage_end( );

                new 
iHostagePenalty get_pcvar_nummp_hostagepenalty );
                if( 
iHostagePenalty )
                {
                    new 
iHostageKills get_pdata_intleaderOFFSET_HOSTAGE_KILLS);

                    if( 
iHostageKills >= iHostagePenalty )
                        
server_cmd"kick #%i"get_user_useridleader ) );
                    else
                        
set_pdata_intleaderOFFSET_HOSTAGE_KILLSiHostageKills 1);
                }
            }

            
fm_fakedamageent"worldspawn"4096.0);
            
set_peventpev_deadflagDEAD_DEAD );
            
reset_hostageent );

            return 
1;
        }
        else
        {
            if( 
iFallPenalty && leader )
            {
                
emessage_beginMSG_ONEg_iMsgTextMsg, { 00}, leader );
                
ewrite_byte);
                
ewrite_string"#Injured_Hostage" );
                
emessage_end( );
            }

            
set_peventpev_healthfHealth fFallDamage );
        }

        
set_peventFALL_VELOCITYfFallVelocity );
    }
    else
    {
        
peventpev_velocityfVelocity );
        
set_peventFALL_VELOCITYfVelocity] * -1.0 );
    }

    return 
0;
}

hostage_duck_aientleaderbool:headSpace )
{
    if( 
pevleaderpev_flags ) & FL_DUCKING )
    {
        if( !
peventWAS_DUCKING ) )
        {
            
set_peventWAS_DUCKING);
            
set_peventANIMATING);
            
set_peventANIM_FRAME0.0 );
        }

        new 
Float:fFrame;
        
peventANIM_FRAMEfFrame );

        if( 
fFrame FRAME_RATE 35.0 )
            
set_peventANIM_FRAMEfFrame FRAME_RATE );
        else
        {
            
set_peventANIM_FRAME35.0 );

            
set_peventpev_minsFloat:{ -10.0, -10.00.0 } );
            
set_peventpev_maxsFloat:{ 10.010.032.0 } );
        }
    }
    else
    {
        if( !
peventWAS_DUCKING ) || headSpace )
        {
            
set_peventpev_minsFloat:{ -10.0, -10.00.0 } );
            
set_peventpev_maxsFloat:{ 10.010.062.0 } );

            if( 
peventWAS_DUCKING ) )
            {
                
set_peventANIMATING);
                
set_peventWAS_DUCKING);
            }

            if( 
peventANIMATING ) )
            {
                new 
Float:fFrame;
                
peventANIM_FRAMEfFrame );

                if( 
fFrame FRAME_RATE 0.0 )
                    
set_peventANIM_FRAMEfFrame-FRAME_RATE );
                else
                {
                    
set_peventANIM_FRAME0.0 );
                    
set_peventANIMATING);
                }
            }
        }
    }
}

hostage_ladder_aientleaderFloat:hOrigin], Float:climbSpeed )
{
    static 
Float:lOrigin], Float:lMins], Float:fGoal], Float:fAbsMin], Float:fAbsMax], Float:fNewVelocity], Float:fComparison];

    new 
iDirLadders get_pcvar_numg_pCvarDirLadders );

    
pevleaderpev_originlOrigin );
    
pevleaderpev_minslMins );

    new 
iOnLadder peventON_LADDER );
    if( 
iOnLadder )
    {
        if( 
hOrigin] > fLadderMaxsiOnLadder-][ ] )
        {
            
get_speed_vectorhOriginlOrigin256.0fNewVelocity );

            
set_peventpev_movetypeMOVETYPE_FLY );
            
set_peventpev_velocityfNewVelocity );

            
set_peventON_LADDER);
            return;
        }
            
    }

    if( 
hOrigin] >= lOrigin]+lMins]-4.0 )
    {
        
set_peventpev_movetypeMOVETYPE_STEP );
        return;
    }

    
peventpev_absminfAbsMin );
    
peventpev_absmaxfAbsMax );

    new 
iFloat:fDistiTouchingLadder = -1;
    for( 
i=0i<iLadderNumi++ )
    {
        
fDist get_box_distancefAbsMinfAbsMaxfLadderMins], fLadderMaxs] );

        if( 
fDist 24.0 )
            continue;

        if( 
fLadderOrigin][ ] > lOrigin] )
            continue;

        if( !
iDirLadders || iLadderDirection] == DIR_NONE )
        {
            
iTouchingLadder i;
            break;
        }

        switch( 
iLadderDirection] )
        {
            case 
DIR_EAST:
            {
                if( 
hOrigin] > fLadderMins][ ])
                    continue;
            }
            case 
DIR_NORTH:
            {
                if( 
hOrigin] > fLadderMins][ ] )
                    continue;
            }
            case 
DIR_WEST:
            {
                if( 
hOrigin] < fLadderMaxs][ ] )
                    continue;
            }
            case 
DIR_SOUTH:
            {
                if( 
hOrigin] < fLadderMaxs][ ] )
                    continue;
            }
        }

        
iTouchingLadder i;
        break;
    }

    
set_peventON_LADDERiTouchingLadder+);

    if( 
iTouchingLadder == -)
    {
        
set_peventpev_movetypeMOVETYPE_STEP );
        return;
    }

    
fGoal fLadderOriginiTouchingLadder ];

    if( 
iDirLadders && iLadderDirection] != DIR_NONE )
    {
        switch( 
iLadderDirection] )
        {
            case 
DIR_EASTfGoal] = fLadderMinsiTouchingLadder ][ ] - 16.0;
            
            case 
DIR_NORTHfGoal] = fLadderMinsiTouchingLadder ][ ] - 16.0;
            
            case 
DIR_WESTfGoal] = fLadderMaxsiTouchingLadder ][ ] + 16.0;
            
            case 
DIR_SOUTHfGoal] = fLadderMaxsiTouchingLadder ][ ] + 16.0;
        }
    }

    
fComparison fGoal;
    
fComparison] = hOrigin];
    
    if( 
vector_distancehOriginfComparison ) > 12.0 fGoal] = fLadderMinsiTouchingLadder ][ ] + 8.0;

    else
    {
        if( 
iDirLadders && iLadderDirection] != DIR_NONE fGoal] = fLadderMaxsiTouchingLadder ][ ] + 32.0;
        
        else
            
fGoal] = fLadderMaxsiTouchingLadder ][ ] + 512.0;
    }

    
get_speed_vectorhOriginfGoalclimbSpeedfNewVelocity );

    
set_peventpev_movetypeMOVETYPE_FLY );
    
set_peventpev_velocityfNewVelocity );
}

hostage_jump_aientleaderFloat:jumpDelay )
{
    new 
Float:fCurrent get_gametime( );

    if( 
fJumpTimeleader ] && fCurrent fJumpTimeleader ] < jumpDelay 0.05 && fCurrent fJumpTimeleader ] + jumpDelay )
    {
        if( 
peventpev_flags ) & FL_ONGROUND )
        {
            static 
Float:fVelocity];
            
peventpev_velocityfVelocity );
            
fVelocity] += get_pcvar_floatg_pCvarJumpSpeed );
            
set_peventpev_velocityfVelocity );
        }
    }
}

public 
Fw_Touchtouchedtoucher )
{
    if( 
touched <= || toucher <= || !pev_validtouched ) || !pev_validtoucher ) )
        return 
FMRES_IGNORED;

    if( !
is_user_alivetoucher ) )
    {
        new 
iOwner pevtoucherpev_owner );

        if( 
is_user_aliveiOwner ) ) toucher iOwner;
        
        else
            
toucher 0;
    }

    if( 
toucher set_pevtouchedLAST_TOUCHERtoucher );

    return 
FMRES_IGNORED;
}

public 
fw_PlayerJumpid )
{
      if( !( 
pevidpev_oldbuttons ) & IN_JUMP ) && ( pevidpev_flags ) & FL_ONGROUND ) )
          
fJumpTimeid ] = get_gametime( );
      
      return 
HAM_IGNORED;
}

reset_hostageent )
{
    
set_peventWAS_DUCKING);
    
set_peventON_LADDER);
    
set_peventLAST_TOUCHER);
    
set_peventANIMATING);
    
set_peventANIM_FRAME0.0 );
    
set_peventFALL_VELOCITY0.0 );
    
set_peventpev_movetypeMOVETYPE_STEP );
    
set_peventpev_minsFloat:{ -10.0, -10.00.0 } );
    
set_peventpev_maxsFloat:{ 10.010.062.0 } );
}

stock get_speed_vector( const Float:origin1], const Float:origin2], Float:speedFloat:new_velocity] )
{
    
new_velocity] = origin2] - origin1];
    
new_velocity] = origin2] - origin1];
    
new_velocity] = origin2] - origin1];
    new 
Float:fNum floatsqrootspeed*speed / ( new_velocity]*new_velocity] + new_velocity]*new_velocity] + new_velocity]*new_velocity] ) );
    
new_velocity] *= fNum;
    
new_velocity] *= fNum;
    
new_velocity] *= fNum;

    return 
1;
}

stock bool:is_monster_hull_vacantent, const Float:origin] )
{
    new 
iTr 0;
    
engfuncEngFunc_TraceMonsterHullentoriginorigin0entiTr );

    if( !
get_tr2iTrTR_StartSolid ) && !get_tr2iTrTR_AllSolid ) && get_tr2iTrTR_InOpen ) )
        return 
true;
        
    return 
false;
}

stock Float:get_box_distanceFloat:mins1], Float:maxs1], Float:mins2], Float:maxs2] )
{
    new 
Float:fDistance], iFloat:maxFloat:min;

    for( 
i=0i<3i++ )
    {
        
min mins1];
        
max maxs2];

        if( 
min max )
        {
            
fDistance] = min max;
            continue;
        }

        
min mins2];
        
max maxs1];

        if( 
min max fDistance] = min max;
    }

    return 
floatsqrootfDistance] * fDistance] + fDistance] * fDistance] + fDistance] * fDistance] );

Attached Files
File Type: sma Get Plugin or Get Source (amx_prometheus.sma - 598 views - 19.1 KB)
File Type: cfg prometheus.cfg (1.5 KB, 153 views)
__________________
leonard19941 is offline
c0rrupt
Junior Member
Join Date: Dec 2007
Location: Maryland
Old 04-06-2013 , 22:40   Re: Prometheus (Enhanced Hostages)
Reply With Quote #70

plugin is dead and no longer works from the cs update... anyone else?

Quote:
L 04/06/2013 - 217:51: Info (map "cs_assault_upc") (file "addons/amxmodx/logs/error_20130406.log")
L 04/06/2013 - 217:51: [HAMSANDWICH] Failed to retrieve vtable for "hostage_entity", hook for "Fw_Think" not active.
L 04/06/2013 - 217:51: [AMXX] Run time error 10 (plugin "prometheus.amxx") (native "RegisterHam") - debug not enabled!
L 04/06/2013 - 217:51: [AMXX] To enable debug mode, add "debug" after the plugin name in plugins.ini (without quotes).
no work =[
__________________

Last edited by c0rrupt; 04-06-2013 at 23:17.
c0rrupt is offline
Reply



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 05:08.


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