Facebook Twitter YouTube Frictional Games | Forum | Privacy Policy | Dev Blog | Dev Wiki | Support | Gametee


Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Removing blue glow around items?
Streetboat Offline
Posting Freak

Posts: 1,099
Threads: 40
Joined: Mar 2011
Reputation: 56
#1
Removing blue glow around items?

Hello all, I pose a question which could ultimately affect the immersion within my game by a great deal. I would like to remove the blue glow around items that can be picked up. The reason I want to do this is purely for immersion reasons; it's annoying to be looking at a wall of tools and telepathically know which one belongs in your inventory by turning off your lantern and looking for the blue glow. I want the player to look for his items.

I imagine this is something I would need to edit in a config file as part of a full conversion? I just looked at those files and found a bunch of interesting things (did you know you can easily change every single sanity event, how fast you move, or even how much you weigh?), but the blue glow around items eluded me. Just wondering if anyone else has looked into this! I searched and came up with 10 pages of nothing. Sad

Thanks everyone!

[Image: signature-2.png]
(This post was last modified: 01-03-2012, 04:43 PM by Streetboat.)
01-03-2012, 06:19 AM
Find
Apjjm Offline
Is easy to say

Posts: 496
Threads: 18
Joined: Apr 2011
Reputation: 52
#2
RE: Removing blue glow around items?

If there isn't a setting available for it. However, if you are doing a full conversion you can use a custom resources file to override where the game looks for the "shaders" directory, and hence override "game_object_flash_frag.glsl" - which is responsible for the glowing effect on an object (Note that an object will still get the blue-outline when moused over as that is a different effect). You can just replace it with something like:
////////////////////////////////////////////////////////
// Object flash - Fragment Shader
//
// Makes a nice flash effect around objects.
////////////////////////////////////////////////////////
#version 120
varying vec3 gvNormal;

uniform sampler2D aDiffuse;
@define sampler_aDiffuse 0

uniform float afColorMul;

void main()
{
    gl_FragColor = texture2D(aDiffuse, gl_TexCoord[0].xy) * 0;
}

In other words:
1) Make a custom resources.cfg
2) Make a copy of the shaders directory - put it in your full conversion's folder
3) Remove the existing shaders info from resources.cfg - make it point to your new folder
4) Edit the files to suit

This will remove the highlighting on the object, but not the rim-light when you mouse over it.
(This post was last modified: 01-03-2012, 03:33 PM by Apjjm.)
01-03-2012, 03:31 PM
Find
Acies Offline
Posting Freak

Posts: 1,643
Threads: 60
Joined: Feb 2011
Reputation: 73
#3
RE: Removing blue glow around items?

A full conversion is required. I started snooping around in the graphics folder, but couldn't find anything there. I believe you need to edit the file located here:
Amnesia - The Dark Descent\redist\shaders\game_object_flash_frag.glsl

Opening it in notepad++ brings up this snippet of code:
Spoiler below!


////////////////////////////////////////////////////////
// Object flash - Fragment Shader
//
// Makes a nice flash effect around objects.
////////////////////////////////////////////////////////
#version 120
varying vec3 gvNormal;

uniform sampler2D aDiffuse;
@define sampler_aDiffuse 0

uniform float afColorMul;

void main()
{
float fRimLight = dot(gvNormal, vec3(0.0, 0.0, -1.0));
fRimLight = 1.0 - abs(fRimLight);

gl_FragColor = texture2D(aDiffuse, gl_TexCoord[0].xy) * vec4(0.5, 0.5, 1.0, 0.0) * fRimLight * afColorMul;
}


I am no "coder", but I'm guessing that setting:
gl_FragColor = texture2D(aDiffuse, gl_TexCoord[0].xy) * vec4(0.5, 0.5, 1.0, 0.0) * fRimLight * afColorMul;

"vec4(0.5, 0.5, 1.0, 0.0)" =
"vec4(0.0, 0.0, 0.0, 0.0)"

Would display black/"no color".

Good luck :>


[Image: mZiYnxe.png]


01-03-2012, 03:35 PM
Find
Streetboat Offline
Posting Freak

Posts: 1,099
Threads: 40
Joined: Mar 2011
Reputation: 56
#4
RE: Removing blue glow around items?

Thanks, folks! Vastly helpful. Smile

[Image: signature-2.png]
01-03-2012, 04:43 PM
Find
Your Computer Offline
SCAN ME!

Posts: 3,456
Threads: 32
Joined: Jul 2011
Reputation: 235
#5
RE: Removing blue glow around items?

If the issue is based on the player being able to tell what item to choose due intuitive visuals, then you might also want to remove or overwrite the pick-up cursor icon.

Tutorials: From Noob to Pro
01-03-2012, 09:07 PM
Website Find
Statyk Offline
Schrödinger's Mod

Posts: 4,390
Threads: 72
Joined: Sep 2011
Reputation: 241
#6
RE: Removing blue glow around items?

I'm not helping here, but curious... Will people still know that its an object able to be picked up? What are you using it for?
01-03-2012, 09:09 PM
Find




Users browsing this thread: 3 Guest(s)