Raised This Month: $32 Target: $400
 8% 

Decal index


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
kadet.89
Veteran Member
Join Date: Nov 2012
Location: Serbia
Old 08-02-2015 , 07:06   Decal index
Reply With Quote #1

I'm trying to setup a TE decal:

PHP Code:
ITempEntsSystem tesystem servertools->GetTempEntsSystem();
int decalid engine->PrecacheDecal("materials/decals/redglowfade.vtf"true);
tesystem->Decal(filter0.0, &g_Trace.endpos, &g_Trace.startpos0g_Trace.hitboxdecalid );
//engine->StaticDecal(g_Trace.endpos, decalid ,0,decalid ,true); //doesn't work too 
But PrecacheDecal returns incorrect index. I get this:

I also tried to use different materials and PrecacheModel, but with no success

it seems that I should use
PHP Code:
IDecalEmitterSystem *decalsystem NULL// decals_subrect.txt
...
int index decalsystem->GetDecalIndexForNamedecalName ); 
how can I get the decalsystem pointer?

Last edited by kadet.89; 08-02-2015 at 08:09.
kadet.89 is offline
Send a message via Skype™ to kadet.89
psychonic

BAFFLED
Join Date: May 2008
Old 08-02-2015 , 08:57   Re: Decal index
Reply With Quote #2

I believe that the path needs to be relative to the materials folder.

engine->PrecacheDecal("decals/redglowfade.vtf"
psychonic is offline
kadet.89
Veteran Member
Join Date: Nov 2012
Location: Serbia
Old 08-02-2015 , 11:53   Re: Decal index
Reply With Quote #3

Thank you, it works
kadet.89 is offline
Send a message via Skype™ to kadet.89
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:34.


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