Creating custom texture lights

879m

L1: Registered
Nov 21, 2015
2
0
Hey there, I'm trying to make a custom texture light and I've been really struggling. I have tried a lot of things, all of which haven't worked. All the things that I've tried so far will be below. If someone could point me towards a current guide on how to make them or post and show me how that would be much appreciated.

So first, I followed this video:
View: https://www.youtube.com/watch?v=hILEwPBqggg


The part about texture lights begins at 28:00.

Under steamapps/common/team fortress 2/tf I created a lights.rad file, containing "test/color_red 255 0 0 150". Saving, then opening up hammer, applying the texture and compiling the map resulted in no light being cast from the texture. Lights were working in the map as I had a light entity in a different location that was casting light. Also, default texlights do work for me as I used "lights/white001" which worked as intended. I tried changing the '/' to '\' with the same result. I also changed the texture being defined in the lights.rad file to a dev texture, which also didn't work.

For both of these, I used an advanced compile, with "$bsp_exe -game $gamedir $path\$file", "$vis_exe -game $gamedir $path\$file", "$light_exe -game $gamedir $path\$file". This also included the copy file path and run game commands but I don't see how those would affect anything. I also tried adding "-lights lights.rad" to the "$lights.exe" parameters, which didn't work but caused duplicate textlights to be read from lights.rad.

Then I followed this:
View: https://www.youtube.com/watch?v=P3ILjexx0cE


to unpack "tf2_misc_dir.vpk", which contains a lights.rad file that contains settings for the default texlights. I added the line "test/color_red 255 0 0 150" to it and then saved. Upon putting the folder into vpk.exe, no output is created. I didn't stop the program early, I waited until it closed by itself. I tried with a shortcut to vpk.exe, using no shortcut, storing the unpacked .vpk on the desktop, a new folder, putting the shortcut in the same folder as the unpacked .vpk and in a different, and all of these didn't give me an output.

The only time I got a .vpk out of vpk.exe was when I had canceled a copying process early and the files being packed by vpk.exe would have been less than 100mbs in size.

I have also tried unpacking with the package viewer in VIDE, which did the same thing when trying to repack with vpk.exe.

I haven't yet tried messing around with .vmt files of textures because if I can't do stuff with lights.rad there isn't any point.

The only things relevant to making custom texlights that I have found have been years old and useless. So can you please not tell me to follow one of them, unless it actually still works.

This seems like it should be really simple and spending an evening and a morning trying to figure it out hasn't been very enjoyable. As for alternatives to a texlight, I don't see how a light entity could give the sort of lighting I want.

If you want to try and get it working yourself, the vmf can be downloaded here:

http://www.mediafire.com/download/y8hahzf408s4g9q/879m_texlight_help_map.vmf
 

worMatty

Repacking Evangelist
aa
Jul 22, 2014
1,257
999
You need to name it something else, can't be named lights.rad. Then specify it in the VRAD compile line.

dfhn5Ys.jpg


VMF and .rad file used to make the map in the screenshot.
 

879m

L1: Registered
Nov 21, 2015
2
0
Ah thank you, works perfectly now. I'm surprised nothing else mentioned this.
 

Pocket

Half a Lambert is better than one.
aa
Nov 14, 2009
4,694
2,579
I'm pretty sure just popping a custom lights.rad into the /tf/ folder used to work, because everybody used to recommend doing it.