View Single Post
Bugsy
AMX Mod X Moderator
Join Date: Feb 2005
Location: NJ, USA
Old 12-02-2023 , 22:51   Re: no aim on Freeze Time
Reply With Quote #2

Quote:
Originally Posted by Cuttlas View Post
is there any plugin restricting the player from aiming with rifles on freeze time?

what is the goal? on aim or fy maps, if they have freeze time, some players will aim with rifles at the other team's player, and as soon as freeze time ends, they shoot and kill the poor player

also, it would be perfect, if all players switched to knife on freeze time, so they can not also fix their aims with other weapons on heads!!!
This will prevent zooming during freeze time. Add whatever other weapons you want in the array, in the same format.
PHP Code:

#include <amxmodx>
#include <hamsandwich>

new const Version[] = "0.1";

enum BlockZoomInfo
{
    
HamHook:ForwardID,
    
WeaponName13 ]
}
new 
g_BlockZoomWeapons[][ BlockZoomInfo ] = 
{
    { 
HamHook:"weapon_scout" },
    { 
HamHook:"weapon_awp" }
};

public 
plugin_init()
{
    
register_plugin"No Zoom in FreezeTime" Version "bugsy" );
    
    for ( new 
sizeofg_BlockZoomWeapons ) ; i++ )
    {
        
g_BlockZoomWeapons][ ForwardID ] = RegisterHamHam_Weapon_SecondaryAttack g_BlockZoomWeapons][ WeaponName ]  , "SecondaryAttack" );
    }
    
    
register_event"HLTV" "FreezeTimeStart" "a" "1=0" "2=0" );
    
register_logevent"FreezeTimeEnd" "1=Round_Start" );
}

public 
FreezeTimeStart()
{
    for ( new 
sizeofg_BlockZoomWeapons ) ; i++ )
    {
        
EnableHamForwardg_BlockZoomWeapons][ ForwardID ] );
    }
}

public 
FreezeTimeEnd()
{
    for ( new 
sizeofg_BlockZoomWeapons ) ; i++ )
    {
        
DisableHamForwardg_BlockZoomWeapons][ ForwardID ] );
    }
}

public 
SecondaryAttackiEntity )
{
    return 
HAM_SUPERCEDE;

__________________

Last edited by Bugsy; 12-02-2023 at 22:52.
Bugsy is offline