DghelneshiAims to surpass Fana in post edits.Join Date: 2011-11-01Member: 130634Members, Squad Five Blue, Reinforced - Shadow
The shader files that come with the game are compiled versions, you cannot edit them. The ones here are uncompiled and can be modified with any text editor, the game will automatically compile them on map load if you replace the original one.
Sorry about being a bit of an idiot, but when I go to the dropbox link all the shows up is a load of coding for it, presumably the contents of the fx? I'm quite new to modding this game, and sorry to bother, but is anyone able to give an in-depth guide of how to do this? Specifically issues with the dropbox, and how exactly to make a "new mod" folder?
(I would like to repeat and emphasize the fact that I am an idiot.)
Edit:Just saw a post on the subject. Please disregard.
I dont understand guys... i replaced my "darkvision.fx" but the vision is all screwed up... what have I done wrong?<img src="http://i914.photobucket.com/albums/ac344/m_gaby/2012-11-10_00002.jpg" border="0" class="linked-image" />
<!--quoteo(post=2022524:date=Nov 13 2012, 01:52 PM:name=Vicious Bug)--><div class='quotetop'>QUOTE (Vicious Bug @ Nov 13 2012, 01:52 PM) <a href="index.php?act=findpost&pid=2022524"><{POST_SNAPBACK}></a></div><div class='quotemain'><!--quotec-->I dont understand guys... i replaced my "darkvision.fx" but the vision is all screwed up... what have I done wrong?<img src="http://i914.photobucket.com/albums/ac344/m_gaby/2012-11-10_00002.jpg" border="0" class="linked-image" /><!--QuoteEnd--></div><!--QuoteEEnd-->
twilitebluebug stalkerJoin Date: 2003-02-04Member: 13116Members, NS2 Playtester, Squad Five Blue
edited November 2012
Just made a new version: <a href="http://dl.dropbox.com/u/60032446/minimal%20dark%20vision/DarkVision.fx" target="_blank">http://dl.dropbox.com/u/60032446/minimal%2...n/DarkVision.fx</a>
The mod was tested to work on all official servers.
<!--quoteo(post=2022542:date=Nov 13 2012, 06:12 PM:name=Ryne)--><div class='quotetop'>QUOTE (Ryne @ Nov 13 2012, 06:12 PM) <a href="index.php?act=findpost&pid=2022542"><{POST_SNAPBACK}></a></div><div class='quotemain'><!--quotec-->Reboot your NS2 client.<!--QuoteEnd--></div><!--QuoteEEnd--> Its working now, Thanks for your awsome work guys.
Thanks to this great mod, I am finally able to adjust Alien Vision to my preferences.
Based on twiliteblues shader, I wote my own using time dependend blurring and colour changes. I thought, plain grey scale is just too boring, so I alternate vision within the RGB space spanned by the pixel colour and its greyscale mean value. Furthermore, outline colour intensity and thickness is altered as well periodically. Additionally, I took the freedom to comment the shader code extensively as far as I understood it.
As proof of concept, here is a drastically reduced GIF with some screenshots of ns2_summit. Colour change is of course not so fast. <img src="http://ineluki.rpg-atelier.net/misc/NS2/DarkVision1/DarkVision.gif" border="0" class="linked-image" />
<a href="http://ineluki.rpg-atelier.net/misc/NS2/DarkVision1/DarkVision.fx" target="_blank">Script as download.</a>
I made a somewhat more all-day-usable Alien Vision Shader. This one features: - Insectoide compound eyes using a rhombohedral lattice (instead of a normal hexagonal one) - sonar sight using sound pulses with exponential decay and distance based resolution - importance highlighting for biological and technological compounds
I also made a video to show you how it looks. Make sure to watch in the best resolution to see all the details.
My design goal was to create a more or less natural looking shader which underlines the alien aspect of the khaara. Based on the discussion that alien vision should have a small draw back when used in well lit conditions, I introduced a scheme for rhombohedral compound eyes, which separate in several colour channels. Because of this overlay, alien vision in well lit environments is a bit inferior to normal vision but despite this, textures are shown in all of their glory.
Furthermore, I changed the previous cell shading outlines into some form of sonar. Sound waves are created, propagate through the air and highlight edges. There is a pulse about every second, highlight intensity has a moving maximum as the wave travels through the air and the edge resolution is decreased as a function of distance, so if something is further away, only edges with greater edge contrast (bigger/sharper edges) are highlighted. While not hit, edges are dimmed to a dark gray, so they still give guidance when it's very dark but do not overlay much of the aesthetics.
Finally, I added the common highlighting of biological and technological elements, but this time I did not use blurring but some kind of glow effect on the edges.
For those, who do not want to load a whole video, here are some pictures. In order to keep loading times small, these are JPEGs, but each picture links to its lossless PNG pendant, albeit size is reduced to 75% in any case.
<a href="http://ineluki.rpg-atelier.net/misc/NS2/DarkVision2/ns2_DarkView2_01.png" target="_blank"><img src="http://ineluki.rpg-atelier.net/misc/NS2/DarkVision2/ns2_DarkView2_01.jpg" border="0" class="linked-image" /></a> Snow seen with colour channel bound compound eyes. In the distance, the trailing part of the edge highlighting sonar wave can be seen, but only on edges against the sky.
<a href="http://ineluki.rpg-atelier.net/misc/NS2/DarkVision2/ns2_DarkView2_02.png" target="_blank"><img src="http://ineluki.rpg-atelier.net/misc/NS2/DarkVision2/ns2_DarkView2_02.jpg" border="0" class="linked-image" /></a> A sonar wave travels through a corridor in ns_summit. It is already dark enough that the colour aberrations from the compound eyes hardly bother.
<a href="http://ineluki.rpg-atelier.net/misc/NS2/DarkVision2/ns2_DarkView2_03.png" target="_blank"><img src="http://ineluki.rpg-atelier.net/misc/NS2/DarkVision2/ns2_DarkView2_03.jpg" border="0" class="linked-image" /></a> Pitchblack darkness with a pinch of sonar highlighting.
<a href="http://ineluki.rpg-atelier.net/misc/NS2/DarkVision2/ns2_DarkView2_04.png" target="_blank"><img src="http://ineluki.rpg-atelier.net/misc/NS2/DarkVision2/ns2_DarkView2_04.jpg" border="0" class="linked-image" /></a> That ain't no sunset, that's technology highlighting with a grain of glow while compound eye perception speckles the sky.
<a href="http://pastebin.com/24LEsb7H" target="_blank">Source code can be found here.</a> It is heavily commented, so maybe someone can learn a bit from it. Albeit based on twiliteblue's Dark Vision Mod, I rewrote the whole shader function from scratch and implemented some parts of the algorithm differently. Since I am totally new to shader programming (these two shaders here are the first ones I ever wrote. BIG thanks to twiliteblue for his code from which I learned), feedback is exceedingly welcome.
<!--quoteo(post=2067006:date=Jan 26 2013, 03:36 PM:name=Whosat)--><div class='quotetop'>QUOTE (Whosat @ Jan 26 2013, 03:36 PM) <a href="index.php?act=findpost&pid=2067006"><{POST_SNAPBACK}></a></div><div class='quotemain'><!--quotec-->Would you make one without that coloured overlay? :)
P.S. I think that sonar thing would make a perfect effect for the Observatory scan as opposed to the current circles.<!--QuoteEnd--></div><!--QuoteEEnd-->
I guess, you mean with "coloured overlay" my attempt to simulate compound eyes ? You can do this easily yourself, just remove lines 90 to 96 and change line line 132 into <!--c1--><div class='codetop'>CODE</div><div class='codemain'><!--ec1-->return outputPixel + edge*edgeColor*sonar;<!--c2--></div><!--ec2-->
At the moment I am working on a new version. Main features are: - hexagonal compound eyes - depth of field blurring ... so the aliens are short sighted - anisotropic eye dispersion, so light of different wavelength is refractured differently in different parts of the eye, so you get some anti-focal and some prismatic light spreading when going to the perceptional borders
I guess, I will upload a new version within this week, so stay tuned.
Can someone give me a hint to how to make the shader configurable via some new entries in the graphics options menu ? So one can enable or disable some of the effects or affect their strength ... As I already said, I have absolutely no modding experience.
@twiliteblue .. could you pitch me a sniplet of code for multi-pass pixel shading ? Without that, I guess my shader would end up to be too complex/slow.
Can someone give me a hint to how to make the shader configurable via some new entries in the graphics options menu ? So one can enable or disable some of the effects or affect their strength ... As I already said, I have absolutely no modding experience.
That sounds like quite some work. I'm not sure if there is any interface to add entries to the options menu yet.
You can, however, change the alien vision lua to add new console commands.
@twiliteblue .. could you pitch me a sniplet of code for multi-pass pixel shading ? Without that, I guess my shader would end up to be too complex/slow.
You can look at examples such as Blur.fx in the NS2 shaders directory. I don't have any experience with multi-pass yet.
@twiliteblue Thanks for the tip. I will definitely have a look on this.
Meanwhile I finished my work on version v0.3 of my shader. Thanks to shader model v3.0 I was able to do it without a multi-pass shader. And fortunately my approach turned out to be still fast enough.
At the moment it uses these features:
- short sighted aliens using depth of field technique ( Tiefenunschärfe )
- Insectoide compound eyes using a hexagonal lattice
- Refraction and dispersion for eye vision
- brightness correction in dark spaces
- sonar sight using sound pulses with exponential decay and distance based resolution, rainbow coloured
- importance highlighting for biological and technological compounds
I made a video in which I demonstrate and comment on the several effects of the shader, so I hope you will enjoy it. Took me the most part of today. ^__^
Maybe I'll add some high quality pictures later, but for now the video should be enough. (It's nearly 5:00 am here now.)
I am really looking forward to your comments and suggestions.
@Ineluki80 - Your stuff is awesome, and although it would increase immersion, i feel it might be tough to get used to. People would probably moan as much as usual, especially with all the changes NS2 is going through currently.
@Yuuki - I absolutely love your grayscale vision with slight colouring, Im definitely going to try mess with it using yours as a base, just to see what different colours in place of the blue would look like. Simple and amazing.
Lovely work twilight blue!
I love this image
Do you know this video?
I like the sonar effect in it just like Ineluki80 did.
Also i know you can't do this since it goes beyond shader coding. But it would be nice that alien vision is better/stronger when your in a group to stimulate teamwork.
I think this is really glossy and a bit to bright.
Your screens from crevice where much darker and more awsome.
Here you also have really nice darkness, was the light here on or off?
It would be nice if it's that dark with the lights on.
How can I edit one of your mods simply myself? I really like complete greyscale with green marines, but your dark blue version looks interesting but from screenshots looks like you can't see enemies from too far away?? (also agree the darker version looks easier on the eyes, having the world be bland and enemies bright is kind of what i'm looking for.. I'll try and tweak some of your already modded files to my liking and see if I can get something interesting!
edit: Idt using the workshop version works, you'd have to replace the actual file in your install directory.. not sure why these type of mods aren't whitelisted, it's personal preference (and the default ones generally hurt my eyes) -- does your method on page 1 work? I was doing it differently
Comments
The ones here are uncompiled and can be modified with any text editor, the game will automatically compile them on map load if you replace the original one.
Grab the one off my twitch page and you can edit it with nitepadnotepad ...
(I would like to repeat and emphasize the fact that I am an idiot.)
Edit:Just saw a post on the subject. Please disregard.
Reboot your NS2 client.
The mod was tested to work on all official servers.
Preview:
<img src="http://dl.dropbox.com/u/60032446/minimal%20dark%20vision/dvm.jpg" border="0" class="linked-image" />
Its working now, Thanks for your awsome work guys.
Based on twiliteblues shader, I wote my own using time dependend blurring and colour changes.
I thought, plain grey scale is just too boring, so I alternate vision within the RGB space spanned by the pixel colour and its greyscale mean value.
Furthermore, outline colour intensity and thickness is altered as well periodically.
Additionally, I took the freedom to comment the shader code extensively as far as I understood it.
As proof of concept, here is a drastically reduced GIF with some screenshots of ns2_summit. Colour change is of course not so fast.
<img src="http://ineluki.rpg-atelier.net/misc/NS2/DarkVision1/DarkVision.gif" border="0" class="linked-image" />
<a href="http://ineluki.rpg-atelier.net/misc/NS2/DarkVision1/DarkVision.fx" target="_blank">Script as download.</a>
Tips, tricks, and suggestions are welcome.
I made a somewhat more all-day-usable Alien Vision Shader.
This one features:
- Insectoide compound eyes using a rhombohedral lattice (instead of a normal hexagonal one)
- sonar sight using sound pulses with exponential decay and distance based resolution
- importance highlighting for biological and technological compounds
I also made a video to show you how it looks. Make sure to watch in the best resolution to see all the details.
<center><object width="450" height="356"><param name="movie" value="http://www.youtube.com/v/Q7TNh9Cbngg"></param><embed src="http://www.youtube.com/v/Q7TNh9Cbngg" type="application/x-shockwave-flash" width="450" height="356"></embed></object></center>
My design goal was to create a more or less natural looking shader which underlines the alien aspect of the khaara.
Based on the discussion that alien vision should have a small draw back when used in well lit conditions, I introduced a scheme for rhombohedral compound eyes, which separate in several colour channels. Because of this overlay, alien vision in well lit environments is a bit inferior to normal vision but despite this, textures are shown in all of their glory.
Furthermore, I changed the previous cell shading outlines into some form of sonar. Sound waves are created, propagate through the air and highlight edges. There is a pulse about every second, highlight intensity has a moving maximum as the wave travels through the air and the edge resolution is decreased as a function of distance, so if something is further away, only edges with greater edge contrast (bigger/sharper edges) are highlighted. While not hit, edges are dimmed to a dark gray, so they still give guidance when it's very dark but do not overlay much of the aesthetics.
Finally, I added the common highlighting of biological and technological elements, but this time I did not use blurring but some kind of glow effect on the edges.
For those, who do not want to load a whole video, here are some pictures.
In order to keep loading times small, these are JPEGs, but each picture links to its lossless PNG pendant, albeit size is reduced to 75% in any case.
<a href="http://ineluki.rpg-atelier.net/misc/NS2/DarkVision2/ns2_DarkView2_01.png" target="_blank"><img src="http://ineluki.rpg-atelier.net/misc/NS2/DarkVision2/ns2_DarkView2_01.jpg" border="0" class="linked-image" /></a>
Snow seen with colour channel bound compound eyes. In the distance, the trailing part of the edge highlighting sonar wave can be seen, but only on edges against the sky.
<a href="http://ineluki.rpg-atelier.net/misc/NS2/DarkVision2/ns2_DarkView2_02.png" target="_blank"><img src="http://ineluki.rpg-atelier.net/misc/NS2/DarkVision2/ns2_DarkView2_02.jpg" border="0" class="linked-image" /></a>
A sonar wave travels through a corridor in ns_summit. It is already dark enough that the colour aberrations from the compound eyes hardly bother.
<a href="http://ineluki.rpg-atelier.net/misc/NS2/DarkVision2/ns2_DarkView2_03.png" target="_blank"><img src="http://ineluki.rpg-atelier.net/misc/NS2/DarkVision2/ns2_DarkView2_03.jpg" border="0" class="linked-image" /></a>
Pitchblack darkness with a pinch of sonar highlighting.
<a href="http://ineluki.rpg-atelier.net/misc/NS2/DarkVision2/ns2_DarkView2_04.png" target="_blank"><img src="http://ineluki.rpg-atelier.net/misc/NS2/DarkVision2/ns2_DarkView2_04.jpg" border="0" class="linked-image" /></a>
That ain't no sunset, that's technology highlighting with a grain of glow while compound eye perception speckles the sky.
<a href="http://pastebin.com/24LEsb7H" target="_blank">Source code can be found here.</a> It is heavily commented, so maybe someone can learn a bit from it. Albeit based on twiliteblue's Dark Vision Mod, I rewrote the whole shader function from scratch and implemented some parts of the algorithm differently. Since I am totally new to shader programming (these two shaders here are the first ones I ever wrote. BIG thanks to twiliteblue for his code from which I learned), feedback is exceedingly welcome.
P.S. I think that sonar thing would make a perfect effect for the Observatory scan as opposed to the current circles.
P.S. I think that sonar thing would make a perfect effect for the Observatory scan as opposed to the current circles.<!--QuoteEnd--></div><!--QuoteEEnd-->
I guess, you mean with "coloured overlay" my attempt to simulate compound eyes ? You can do this easily yourself, just remove lines 90 to 96 and change line line 132 into <!--c1--><div class='codetop'>CODE</div><div class='codemain'><!--ec1-->return outputPixel + edge*edgeColor*sonar;<!--c2--></div><!--ec2-->
At the moment I am working on a new version. Main features are:
- hexagonal compound eyes
- depth of field blurring ... so the aliens are short sighted
- anisotropic eye dispersion, so light of different wavelength is refractured differently in different parts of the eye, so you get some anti-focal and some prismatic light spreading when going to the perceptional borders
I guess, I will upload a new version within this week, so stay tuned.
Can someone give me a hint to how to make the shader configurable via some new entries in the graphics options menu ? So one can enable or disable some of the effects or affect their strength ... As I already said, I have absolutely no modding experience.
@twiliteblue .. could you pitch me a sniplet of code for multi-pass pixel shading ? Without that, I guess my shader would end up to be too complex/slow.
You can, however, change the alien vision lua to add new console commands.
You can look at examples such as Blur.fx in the NS2 shaders directory. I don't have any experience with multi-pass yet.
Meanwhile I finished my work on version v0.3 of my shader. Thanks to shader model v3.0 I was able to do it without a multi-pass shader. And fortunately my approach turned out to be still fast enough.
At the moment it uses these features:
- short sighted aliens using depth of field technique ( Tiefenunschärfe )
- Insectoide compound eyes using a hexagonal lattice
- Refraction and dispersion for eye vision
- brightness correction in dark spaces
- sonar sight using sound pulses with exponential decay and distance based resolution, rainbow coloured
- importance highlighting for biological and technological compounds
I made a video in which I demonstrate and comment on the several effects of the shader, so I hope you will enjoy it. Took me the most part of today. ^__^
Well commented source code can be found here.
Maybe I'll add some high quality pictures later, but for now the video should be enough. (It's nearly 5:00 am here now.)
I am really looking forward to your comments and suggestions.
Just for fun, I made a static 256 colour palette pixel shader.
If you want to try it yourself, use @twiliteblue 's Mod and replace the pixel shader function by this.
I hope your mod is better, i miss the old vision
I really like the previous 'Deep Blue' version you made:
The vision makes me feel more Alien so i use to always have it on.
@Ineluki80 - Your stuff is awesome, and although it would increase immersion, i feel it might be tough to get used to. People would probably moan as much as usual, especially with all the changes NS2 is going through currently.
@Yuuki - I absolutely love your grayscale vision with slight colouring, Im definitely going to try mess with it using yours as a base, just to see what different colours in place of the blue would look like. Simple and amazing.
I love this image
Do you know this video?
I like the sonar effect in it just like Ineluki80 did.
Also i know you can't do this since it goes beyond shader coding. But it would be nice that alien vision is better/stronger when your in a group to stimulate teamwork.
I've added a blue alien vision on the first page.
It would be nice if it's that dark with the lights on.
@clankill3r Thanks, I will tone the brightness down a bit.
edit: Idt using the workshop version works, you'd have to replace the actual file in your install directory.. not sure why these type of mods aren't whitelisted, it's personal preference (and the default ones generally hurt my eyes) -- does your method on page 1 work? I was doing it differently