Raised This Month: $ Target: $400
 0% 

Counter-Strike 1.3


Post New Thread Reply   
 
Thread Tools Display Modes
Arkshine
AMX Mod X Plugin Approver
Join Date: Oct 2005
Old 09-26-2010 , 06:08   Re: Counter-Strike 1.3
Reply With Quote #11

About :

Code:
public OrpheuHookReturn:onKickBack(obj, Float:upBase, Float:latBase, Float:upMod, Float:latMod, Float:upMax, Float:latMax, dirChange) {
/*
	client_print(0, print_chat, "upBase: %f, latBase: %f, upMod: %f, latMod: %f, upMax: %f, latMax: %f, dirChange: %d", upBase, latBase, upMod, latMod, upMax, latMax, dirChange);
	// client_print(0, print_chat, "yay");
	
	OrpheuSetParam(1, 0.0);
	OrpheuSetParam(2, 0.0);
	OrpheuSetParam(3, 0.0);
	OrpheuSetParam(4, 0.0);
	OrpheuSetParam(5, 0.0);
	OrpheuSetParam(6, 0.0);
*/
	
	return OrpheuIgnored;
}
I know it's not used but, "obj" is the weapon index. That's not a hook from CGamerules class or CHalfLifeMutliplay. And param should start to 2. ;)
__________________
Arkshine is offline
kielor
Senior Member
Join Date: Jan 2009
Location: Russia, Novosibirsk
Old 09-26-2010 , 10:00   Re: Counter-Strike 1.3
Reply With Quote #12

I know it's gay but better to set maxspeed to 0.0 instead of 1000000.0... nvm, but as for me it's better =)
__________________
try using +karma if i helped you...
kielor is offline
Send a message via ICQ to kielor Send a message via Skype™ to kielor
aportner
Member
Join Date: Nov 2004
Old 09-26-2010 , 14:03   Re: Counter-Strike 1.3
Reply With Quote #13

Quote:
Originally Posted by Arkshine View Post
I know it's not used but, "obj" is the weapon index. That's not a hook from CGamerules class or CHalfLifeMutliplay. And param should start to 2. ;)
haha oops I'm dumb. Fixed!

Quote:
Originally Posted by kielor View Post
I know it's gay but better to set maxspeed to 0.0 instead of 1000000.0... nvm, but as for me it's better =)
Makes sense! Fixed!
__________________
Andrew "dook" Portner
moNstrous: CS Gone Bad (Over 1 million views!) http://www.thefunny.org/cs
aportner is offline
lazarev
Veteran Member
Join Date: Sep 2008
Old 09-27-2010 , 05:08   Re: Counter-Strike 1.3
Reply With Quote #14

pistols are innacurate for me
lazarev is offline
aportner
Member
Join Date: Nov 2004
Old 09-27-2010 , 14:36   Re: Counter-Strike 1.3
Reply With Quote #15

Quote:
Originally Posted by lazarev View Post
pistols are innacurate for me
Try setting cl_lw to 0. With cl_lw set to 1, the client predicts where the bullets are going, ignoring where the server says they actually went. So if you change the server logic for bullet position with cl_lw set to 1, it'll still look like nothing has changed on the client. To test, I usually change the map to de_nuke and try to break the vents or the windows while jumping.
__________________
Andrew "dook" Portner
moNstrous: CS Gone Bad (Over 1 million views!) http://www.thefunny.org/cs
aportner is offline
lazarev
Veteran Member
Join Date: Sep 2008
Old 09-28-2010 , 10:18   Re: Counter-Strike 1.3
Reply With Quote #16

Quote:
Originally Posted by aportner View Post
Try setting cl_lw to 0. With cl_lw set to 1 ... jumping.
thanks for info!

For pistols: You could do:
PHP Code:
set_pdata_floatweaponId621.0// m_flAccuracy = 62; 
instead of setting velocity & flags
Also you forgot to check for FL_ONGROUND value:/

Last edited by lazarev; 09-28-2010 at 10:26.
lazarev is offline
Arkshine
AMX Mod X Plugin Approver
Join Date: Oct 2005
Old 09-28-2010 , 11:55   Re: Counter-Strike 1.3
Reply With Quote #17

bad idea.
__________________
Arkshine is offline
ConnorMcLeod
Veteran Member
Join Date: Jul 2006
Location: France (95)
Old 09-28-2010 , 11:56   Re: Counter-Strike 1.3
Reply With Quote #18

Quote:
Originally Posted by lazarev View Post
For pistols: You could do:
PHP Code:
set_pdata_floatweaponId621.0// m_flAccuracy = 62; 
instead of setting velocity & flags
Also you forgot to check for FL_ONGROUND value:/
Correct.
From my "i aim good" plugin version :
PHP Code:
public Pistol_PrimaryAttack_PreiPistol )
{
    if( 
get_weapon_shotsfirediPistol ) <= )
    {
        new 
id get_weapon_owneriPistol )
        if( 
g_bAimGoodArena || HasUserGoodAimid ) )
        {
            
set_weapon_accuracy(iPistol1.0)
            
#if defined NO_RECOIL
                
pev(idpev_punchangleg_flPunchAngle)
                
EnableHamForwardg_iHhWeaponPrimaryAttackPost[get_weapon_idiPistol )] )
            
#endif
        
}
    }
}

public 
Glock_PrimaryAttack_PreiGlock )
{
    if( 
get_weapon_shotsfirediGlock ) <= || get_glock_burst(iGlock) )
    {
        new 
id get_weapon_owneriGlock )
        if( 
g_bAimGoodArena || HasUserGoodAimid ) )
        {
            
set_weapon_accuracy(iGlock1.0)
            
#if defined NO_RECOIL
                
pev(idpev_punchangleg_flPunchAngle)
                
EnableHamForwardg_iHhWeaponPrimaryAttackPostCSW_GLOCK18 ] )
            
#endif
        
}
    }
}

public 
Smgs_PrimaryAttack_PreiSmg )
{
    if( 
get_weapon_clip(iSmg) > )
    {
        new 
id get_weapon_owner(iSmg)
        if( 
g_bAimGoodArena || HasUserGoodAimid ) )
        {
            
set_weapon_accuracy(iSmg0.0)
            
#if defined NO_RECOIL
                
pev(idpev_punchangleg_flPunchAngle)
                
EnableHamForwardg_iHhWeaponPrimaryAttackPost[get_weapon_idiSmg )] )
            
#endif
        
}
    }
}

#if defined NO_RECOIL
    
public Pistol_Smgs_PrimaryAttack_PostiWeapon )
    {
        
set_pev(get_weapon_owneriWeapon ), pev_punchangleg_flPunchAngle)
        
DisableHamForwardg_iHhWeaponPrimaryAttackPost[get_weapon_idiWeapon )] )
    }
#endif 
Problem is that it would set accuracy to perfect, when this plugin only want to set it as it is when you are on ground.
__________________
- tired and retired -

- my plugins -
ConnorMcLeod is offline
Arkshine
AMX Mod X Plugin Approver
Join Date: Oct 2005
Old 09-28-2010 , 12:15   Re: Counter-Strike 1.3
Reply With Quote #19

No, that's not entirely correct. If you don't set the flag/velocity you will still use the value for when you are not in the ground, and just forcing m_flAccuracy to 1.0 you won't see much difference. I would personally prefer to hook the *Fire() function and setting on the fly the value to the one when you are in the ground.
__________________
Arkshine is offline
ConnorMcLeod
Veteran Member
Join Date: Jul 2006
Location: France (95)
Old 09-28-2010 , 12:18   Re: Counter-Strike 1.3
Reply With Quote #20

Quote:
Originally Posted by Arkshine View Post
I would personally prefer to hook the *Fire() function and setting on the fly the value to the one when you are in the ground.
With orpheu you can, and you hook exactly what is needed, no need to hook pre and post and set nack properties.
But then you would need 1 callback per pistol type, or to check pistol type in callback.
That would still be better.
__________________
- tired and retired -

- my plugins -
ConnorMcLeod 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 03:57.


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