Raised This Month: $ Target: $400
 0% 

addtofullpack doesn't work right


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Hunter-Digital
Veteran Member
Join Date: Aug 2006
Location: In the Game [ro]
Old 03-17-2009 , 05:38   addtofullpack doesn't work right
Reply With Quote #1

PHP Code:
public fw_addtofullpack(es_handleeenthosthostflagsplayerpSet)
{
    if(!
player || !is_user_alive(host) || iTeam == || bVision[host] == false)
        return 
FMRES_IGNORED
 
    set_es
(es_handleES_EffectsEF_BRIGHTLIGHT)
 
    return 
FMRES_IGNORED

The problem is when I turn my "nightvision" on (so that the brightlight will "spawn" on me) I can se other player's light also, even if they do NOT have it activated... how can I sepparate this ? for the brightlight to appear only to that player and only HIS brightlight to see ?
__________________
Hunter-Digital is offline
TheRadiance
Senior Member
Join Date: Nov 2007
Location: Kazakhstan
Old 03-17-2009 , 08:20   Re: addtofullpack doesn't work right
Reply With Quote #2

This is a working script, but with opened nightvision it's very hard to see this BRIGHTLIGHT, try to use another effect:
PHP Code:
#include < amxmodx >
#include < fakemeta >

#define VERSION "1.0"

new g_iNvg33 ]

public 
plugin_init()
{
    
register_plugin"Brightlight"VERSION"Hunter-Digital" )
    
register_event"NVGToggle""EventNvgToggle""be" )
    
register_forwardFM_AddToFullPack"ForwardAddToFullPackPost")
}

public 
EventNvgToggleid )
    
g_iNvgid ] = read_data)

public 
ForwardAddToFullPackPostes_handleeenthosthostflagsplayerpSet )
{
    if ( !
player || !is_user_alivehost ) || !g_iNvghost ] )
        return 
FMRES_IGNORED

    
if ( ent != host )
        
set_es(es_handleES_EffectsEF_BRIGHTLIGHT )

    return 
FMRES_IGNORED

TheRadiance is offline
Send a message via ICQ to TheRadiance
SchlumPF*
Veteran Member
Join Date: Mar 2007
Old 03-17-2009 , 08:54   Re: addtofullpack doesn't work right
Reply With Quote #3

"but with opened nightvision it's very hard to see this BRIGHTLIGHT, try to use another effect:"

PHP Code:
new g_bNightVision[33];

// ...

register_clcmd"nightvision""cmdNightVision" );

// ...

public cmdNightVisionplr )
{
    
g_bNightVision[plr] = !g_bNightVision[plr];
    return 
PLUGIN_HANDLED;

__________________
SchlumPF* is offline
Send a message via ICQ to SchlumPF*
Hunter-Digital
Veteran Member
Join Date: Aug 2006
Location: In the Game [ro]
Old 03-17-2009 , 09:06   Re: addtofullpack doesn't work right
Reply With Quote #4

It's actually reverse, the ent must be equal to the host for this thing to work as I need it to, thanks for the boost :}

also thanks anyway schlumpf, I already am blocking the original nightvision
__________________
Hunter-Digital 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 08:51.


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