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

Making an entity visible (EF_NODRAW)


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
mottzi
Veteran Member
Join Date: May 2010
Location: Switzerland
Old 03-27-2016 , 04:59   Making an entity visible (EF_NODRAW)
Reply With Quote #1

Hey guys

I'm using this box plugin to create some "zones" that players can walk in.

This question is not really connectet to that plugin, thats why I'm asking here and not in the plugin thread.


Is it somehow possible to make the "zone" visible to the players? I tried glowing it, but this seems to only affect the model of the entity and since the entity is not drawn (EF_NODRAW) nothing will be seen at all.

Im searching for something to glow the mins & max borders of an entity or really anything other to make the box visible.
__________________
Quote:
#define true ((rand() % 2)? true: false) //Happy debugging suckers

Last edited by mottzi; 03-27-2016 at 07:52.
mottzi is offline
Send a message via MSN to mottzi
milutinke
AlliedModders Donor
Join Date: Jun 2012
Location: Serbia
Old 03-27-2016 , 09:11   Re: Making an entity visible (EF_NODRAW)
Reply With Quote #2

PHP Code:
#include < amxmodx >
#include < fakemeta >

#define BLOCK_NAME        "Block"

public plugin_init( ) {
    
register_forwardFM_AddToFullPack"fw_AddToFullPackPost");
}

public 
fw_AddToFullPackPostiHandleiEiEntityiHostiHostFlagsiPlayeriPSet ) {
    if( !
iPlayer && pev_validiEntity ) && is_user_aliveiHost ) ) {
        static 
szClassName32 ];
        
peviEntitypev_classnameszClassNamecharsmaxszClassName ) );

        if( 
equalszClassNameBLOCK_NAME ) ) {
            
set_esiHandleES_RenderFxkRenderFxGlowShell );
            
set_esiHandleES_RenderColor, { 0255} ); // Green
            
set_esiHandleES_RenderModekRenderTransAdd );
            
set_esiHandleES_RenderAmt255 );
        }
    }

PS: It is not tested

Last edited by milutinke; 03-27-2016 at 09:13.
milutinke is offline
Send a message via Skype™ to milutinke
mottzi
Veteran Member
Join Date: May 2010
Location: Switzerland
Old 03-27-2016 , 11:18   Re: Making an entity visible (EF_NODRAW)
Reply With Quote #3

I dont think there is any difference in this case between set_rendering() and using the AddToFullPack approach.
__________________
Quote:
#define true ((rand() % 2)? true: false) //Happy debugging suckers
mottzi is offline
Send a message via MSN to mottzi
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 04:45.


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