Welcome!

Join our community of MMO enthusiasts and game developers! By registering, you'll gain access to discussions on the latest developments in MMO server files and collaborate with like-minded individuals. Join us today and unlock the potential of MMO server development!

Join Today!

[Help] How to change the outline of items ?

Experienced Elementalist
Joined
Jun 5, 2013
Messages
256
Reaction score
163
Hello I would like to change the color that surrounds the items. They are blue by default I would put yellow or green. Thank you for your help.
 
Last edited by a moderator:
Initiate Mage
Joined
Dec 26, 2013
Messages
40
Reaction score
1
void MeshDeferredHighlightRenderable::DoDraw( Renderable* RThis, float distance, const r3dCamera& Cam )
{
D3DPERF_BeginEvent( 0, L"MeshDeferredHighlightRenderable::Draw" );


MeshDeferredHighlightRenderable * This = static_cast<MeshDeferredHighlightRenderable*>( RThis );
r3dMesh* Mesh = This->Mesh;


r3dColor color( r3dColor::white );


r3dRenderer->SetVertexShader( VS_FILLGBUFFER_EXTRUDE_ID );


float factor = r_highlight_thickness->GetFloat();


const float LINE_SATURATE = 2.0f;


if( distance < LINE_SATURATE )
factor *= distance / LINE_SATURATE;


float vsConst[ 4 ] = { factor / Mesh->unpackScale.x, factor / Mesh->unpackScale.y, factor / Mesh->unpackScale.z, 0 };


// float4x3 vExtrudeMatrix : register( c17 );
D3D_V( r3dRenderer->pd3ddev->SetVertexShaderConstantF( 17, vsConst, 1 ) );


r3dPoint3D normal( 0, 1, 0 );


normal.Normalize();


SetFillGBufferConstantPixelShader( r3dColor::blue, 1.0f, normal, 0.0f, 0.0f, r_highlight_glow->GetFloat(), 0.f );


Mesh->DrawMeshSimple( 0 );


D3DPERF_EndEvent();
}
------------------------
And Search
const r3dColor r3dColor::yellow(255,255,0);

const r3dColor r3dColor::yellow(255,255,0);
const r3dColor r3dColor::black(0, 0, 0);
const r3dColor r3dColor::grey(80,80,80);
const r3dColor r3dColor::white(255, 255, 255);
const r3dColor r3dColor::red(255, 0, 0);
const r3dColor r3dColor::green(0, 255, 0);
const r3dColor r3dColor::blue(0, 0, 255);
const r3dColor r3dColor::pink(255, 20, 147); // Add more
 
Upvote 0
Experienced Elementalist
Joined
Jun 5, 2013
Messages
256
Reaction score
163
void MeshDeferredHighlightRenderable::DoDraw( Renderable* RThis, float distance, const r3dCamera& Cam )
{
D3DPERF_BeginEvent( 0, L"MeshDeferredHighlightRenderable::Draw" );


MeshDeferredHighlightRenderable * This = static_cast<MeshDeferredHighlightRenderable*>( RThis );
r3dMesh* Mesh = This->Mesh;


r3dColor color( r3dColor::white );


r3dRenderer->SetVertexShader( VS_FILLGBUFFER_EXTRUDE_ID );


float factor = r_highlight_thickness->GetFloat();


const float LINE_SATURATE = 2.0f;


if( distance < LINE_SATURATE )
factor *= distance / LINE_SATURATE;


float vsConst[ 4 ] = { factor / Mesh->unpackScale.x, factor / Mesh->unpackScale.y, factor / Mesh->unpackScale.z, 0 };


// float4x3 vExtrudeMatrix : register( c17 );
D3D_V( r3dRenderer->pd3ddev->SetVertexShaderConstantF( 17, vsConst, 1 ) );


r3dPoint3D normal( 0, 1, 0 );


normal.Normalize();


SetFillGBufferConstantPixelShader( r3dColor::blue, 1.0f, normal, 0.0f, 0.0f, r_highlight_glow->GetFloat(), 0.f );


Mesh->DrawMeshSimple( 0 );


D3DPERF_EndEvent();
}
------------------------
And Search
const r3dColor r3dColor::yellow(255,255,0);

const r3dColor r3dColor::yellow(255,255,0);
const r3dColor r3dColor::black(0, 0, 0);
const r3dColor r3dColor::grey(80,80,80);
const r3dColor r3dColor::white(255, 255, 255);
const r3dColor r3dColor::red(255, 0, 0);
const r3dColor r3dColor::green(0, 255, 0);
const r3dColor r3dColor::blue(0, 0, 255);
const r3dColor r3dColor::pink(255, 20, 147); // Add more


Thx You Guys :)
 
Upvote 0
Back
Top