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

render a pev_aiment


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
whosyourdaddy
Senior Member
Join Date: Apr 2008
Old 05-28-2010 , 15:01   render a pev_aiment
Reply With Quote #1

ok when i try to render an entity created it disappears, i notice this happens only when i set the enitity to pev_aiment. any idea why?
whosyourdaddy is offline
unnyquee
Senior Member
Join Date: Jun 2009
Location: Constanta, Romania
Old 05-28-2010 , 15:05   Re: render a pev_aiment
Reply With Quote #2

Show the code, please.
__________________
unnyquee is offline
xPaw
Retired AMX Mod X Moderator
Join Date: Jul 2008
Old 05-28-2010 , 15:06   Re: render a pev_aiment
Reply With Quote #3

The pev_aiment entity is invisible for player who it is aimed to
__________________
xPaw is offline
whosyourdaddy
Senior Member
Join Date: Apr 2008
Old 05-28-2010 , 16:17   Re: render a pev_aiment
Reply With Quote #4

Code:
create_ent(id)
{
		engfunc(EngFunc_SetModel, ent[id], g_ent)
		set_pev(ent[id], pev_classname, "fake")
		set_pev(ent[id], pev_movetype, MOVETYPE_FOLLOW)
		set_pev(ent[id], pev_aiment, id)
		fm_set_entity_visibility(ent[id], 0 )
}

// called to make ent invisible or render it to 100
stock fm_set_entity_visibility(index, visible = 1)
{
	if( !visible )
	{
		fm_set_rendering(index, kRenderFxGlowShell, kRenderNormal, 0)

		return;
	}
	
	fm_set_rendering(index, kRenderFxGlowShell, kRenderNormal, 100 )
}

stock fm_set_rendering(entity, fx = kRenderFxNone, kRender, amount = 16) 
{ 
    
    set_pev(entity, pev_renderfx, fx)
	set_pev(entity, pev_rendermode, kRender)
    set_pev(entity, pev_renderamt, float(amount))
}
whosyourdaddy is offline
Exolent[jNr]
Veteran Member
Join Date: Feb 2007
Location: Tennessee
Old 05-28-2010 , 20:22   Re: render a pev_aiment
Reply With Quote #5

Quote:
Originally Posted by whosyourdaddy View Post
render an entity created it disappears
Quote:
Originally Posted by whosyourdaddy View Post
Code:
create_ent(id)
{
		//...
		fm_set_entity_visibility(ent[id], 0 )
}
You're kidding or just blind?
__________________
No private work or selling mods.
Quote:
Originally Posted by xPaw View Post
I love you exolent!
Exolent[jNr] is offline
whosyourdaddy
Senior Member
Join Date: Apr 2008
Old 05-28-2010 , 21:29   Re: render a pev_aiment
Reply With Quote #6

i have it being called 1 somewhere else in the code, thats when i want it being shown but it just makes it go invis when i try render and when i comment out the render it shows
whosyourdaddy is offline
Drak
Veteran Member
Join Date: Jul 2005
Old 05-29-2010 , 11:42   Re: render a pev_aiment
Reply With Quote #7

Use the flag "EF_NODRAW" to hide it.
__________________
Oh yeah
Drak is offline
Send a message via MSN to Drak
whosyourdaddy
Senior Member
Join Date: Apr 2008
Old 05-29-2010 , 13:47   Re: render a pev_aiment
Reply With Quote #8

my problem tho is rendering it, when i try rendering it when it shows then it completely goes invisable
whosyourdaddy is offline
joropito
AlliedModders Donor
Join Date: Mar 2009
Location: pfnAddToFullPack
Old 05-29-2010 , 17:15   Re: render a pev_aiment
Reply With Quote #9

Try to copy renderamt, renderfx, rendermode, rendercolors from aiment entity.

kRenderFxGlowShell is not the way to make it translucent...
__________________

Divide et vinces
approved plugins | steam account

I don't accept PM for support. Just ask on forums.
If you're looking for private work, PM me.
joropito is offline
Send a message via MSN to joropito
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 10:18.


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