Liberty Unleashed

Scripting => Script Help => Topic started by: Maximom on June 04, 2013, 04:34:54 pm

Title: arm
Post by: Maximom on June 04, 2013, 04:34:54 pm
hi when i shot players arm its falled how i can do that? help ?
Title: Re: arm
Post by: SugarD on June 16, 2013, 12:02:36 am
hi when i shot players arm its falled how i can do that? help ?
What do you mean by "its falled"?
Title: Re: arm
Post by: Shadow. on June 16, 2013, 08:35:42 am
SugarD, I think he meant ' it falls ', anyway, you will have to use the .RemoveLimb function.
Title: Re: arm
Post by: Maximom on July 31, 2013, 05:32:07 pm
i cant find .removelimb function
Title: Re: arm
Post by: Ahmed Abouelnas on July 31, 2013, 06:30:15 pm
See There ARE Left Arm And Right Arm
if left arm here is its script

Code: [Select]
g_LocalPlayer <- FindLocalPlayer();

function onClientShot( pPlayer, iWeapon, iBodypart )
{
if ( ( iBodypart == BODYPART_LEFTARM ) && ( iWeapon > 3 ) )
{
g_LocalPlayer.RemoveLimb( BODYPART_LEFTARM );
g_LocalPlayer.Health = 1;
}

return 1;
}

function onClientKill( pPlayer, iWeapon, iBodypart )
{
if ( ( iBodypart == BODYPART_LEFTARM ) && ( iWeapon > 3 ) )
{
BigMessage( "~r~LEFTARMSHOT", 3000, 3 );
}

return 1;
}

function onClientDeath( pKiller, iWeapon, iBodypart )
{
if ( pKiller )
{
if ( ( iBodypart == BODYPART_LEFTARM ) && ( iWeapon > 3 ) )
{
BigMessage( "~r~LEFTARMSHOT", 3000, 3 );
}
}

return 1;
}

if right arm

Code: [Select]
g_LocalPlayer <- FindLocalPlayer();

function onClientShot( pPlayer, iWeapon, iBodypart )
{
if ( ( iBodypart == BODYPART_RIGHTARM ) && ( iWeapon > 3 ) )
{
g_LocalPlayer.RemoveLimb( BODYPART_RIGHTARM );
g_LocalPlayer.Health = 1;
}

return 1;
}

function onClientKill( pPlayer, iWeapon, iBodypart )
{
if ( ( iBodypart == BODYPART_RIGHTARM ) && ( iWeapon > 3 ) )
{
BigMessage( "~r~RIGHTARMSHOT", 3000, 3 );
}

return 1;
}

function onClientDeath( pKiller, iWeapon, iBodypart )
{
if ( pKiller )
{
if ( ( iBodypart == BODYPART_RIGHTARM ) && ( iWeapon > 3 ) )
{
BigMessage( "~r~RIGHTARMSHOT", 3000, 3 );
}
}

return 1;
}

this is most likely to be as headshot.......
if you want it only falls without die
then this for left

Code: [Select]
g_LocalPlayer <- FindLocalPlayer();

function onClientShot( pPlayer, iWeapon, iBodypart )
{
if ( ( iBodypart == BODYPART_LEFTARM ) && ( iWeapon > 3 ) )
{
g_LocalPlayer.RemoveLimb( BODYPART_LEFTARM );
}

return 1;
}

and this for right

Code: [Select]
g_LocalPlayer <- FindLocalPlayer();

function onClientShot( pPlayer, iWeapon, iBodypart )
{
if ( ( iBodypart == BODYPART_RIGHTARM ) && ( iWeapon > 3 ) )
{
g_LocalPlayer.RemoveLimb( BODYPART_RIGHTARM );
}

return 1;
}

sorry for my bad english....
Title: Re: arm
Post by: Mido_Pop on July 31, 2013, 10:03:15 pm
Man Try This >>  8)
Code: [Select]
g_LocalPlayer <- FindLocalPlayer();

function onClientShot( pPlayer, iWeapon, iBodypart )
{
if ( g_LocalPlayer.Immune == false )
{
        g_LocalPlayer.RemoveLimb( BODYPART_LEFTARM );
g_LocalPlayer.RemoveLimb( BODYPART_RIGHTARM );
        g_LocalPlayer.RemoveLimb( BODYPART_LEFTLEG );
        g_LocalPlayer.RemoveLimb( BODYPART_RIGHTLEG );
}

return 1;
}
You Can make
Code: [Select]
g_LocalPlayer.Immune == false True.
Title: Re: arm
Post by: Maximom on August 01, 2013, 11:58:00 am
thank you all