mirror of
https://github.com/ValveSoftware/source-sdk-2013.git
synced 2025-04-08 11:01:33 +00:00
Added batch files and fixed sound bug
Also added a test map. Applied an ambient_generic bugfix from valve developer community.
This commit is contained in:
parent
220170b958
commit
8743718d0b
43 changed files with 5257 additions and 399 deletions
|
@ -14,4 +14,4 @@ Source Shader Editor
|
|||
Author(s): Msalinas2877
|
||||
Files touched: viewrender.cpp
|
||||
Files added: ShaderEditorSystem.cpp, ShaderEditorSystem.h, SEdit_ModelRender.cpp, SEdit_ModelRender.h, SEdit_ModelRender.h, ISEdit_ModelRender.h, more files that i can't remember
|
||||
Notes: Run with the launch parameter "-shaderedit" to open SSE
|
||||
Notes: Run with the launch parameter "-shaderedit" to open SSE
|
||||
|
|
BIN
sp/game/sdk2013CE/albedo.tga
Normal file
BIN
sp/game/sdk2013CE/albedo.tga
Normal file
Binary file not shown.
After Width: | Height: | Size: 938 KiB |
0
sp/game/sdk2013CE/downloadlists/ep2_background01.lst
Normal file
0
sp/game/sdk2013CE/downloadlists/ep2_background01.lst
Normal file
2
sp/game/sdk2013CE/downloadlists/sdk_vehicles.lst
Normal file
2
sp/game/sdk2013CE/downloadlists/sdk_vehicles.lst
Normal file
|
@ -0,0 +1,2 @@
|
|||
"maps\sdk_vehicles.bsp"
|
||||
"maps\graphs\sdk_vehicles.ain"
|
2
sp/game/sdk2013CE/downloadlists/testbox.lst
Normal file
2
sp/game/sdk2013CE/downloadlists/testbox.lst
Normal file
|
@ -0,0 +1,2 @@
|
|||
"maps\testbox.bsp"
|
||||
"maps\graphs\testbox.ain"
|
BIN
sp/game/sdk2013CE/ep1_gamestats.dat
Normal file
BIN
sp/game/sdk2013CE/ep1_gamestats.dat
Normal file
Binary file not shown.
3
sp/game/sdk2013CE/gamestate.txt
Normal file
3
sp/game/sdk2013CE/gamestate.txt
Normal file
|
@ -0,0 +1,3 @@
|
|||
"GameState"
|
||||
{
|
||||
}
|
BIN
sp/game/sdk2013CE/maps/graphs/testbox.ain
Normal file
BIN
sp/game/sdk2013CE/maps/graphs/testbox.ain
Normal file
Binary file not shown.
BIN
sp/game/sdk2013CE/maps/testbox.bsp
Normal file
BIN
sp/game/sdk2013CE/maps/testbox.bsp
Normal file
Binary file not shown.
BIN
sp/game/sdk2013CE/mapsrc/testbox.bsp
Normal file
BIN
sp/game/sdk2013CE/mapsrc/testbox.bsp
Normal file
Binary file not shown.
21
sp/game/sdk2013CE/mapsrc/testbox.prt
Normal file
21
sp/game/sdk2013CE/mapsrc/testbox.prt
Normal file
|
@ -0,0 +1,21 @@
|
|||
PRT1
|
||||
11
|
||||
18
|
||||
4 0 1 (254 1024 64.023300 ) (254 1024 748 ) (2 1024 748 ) (2 1024 64.023300 )
|
||||
4 1 3 (254 512 64.023300 ) (254 512 748 ) (2 512 748 ) (2 512 64.023300 )
|
||||
4 2 4 (510 0 64 ) (510 0 750 ) (256 0 750 ) (256 0 64 )
|
||||
4 2 3 (256 0 64 ) (256 0 750 ) (256 510 750 ) (256 510 64 )
|
||||
4 3 9 (0 0 64 ) (0 0 750 ) (0 510 750 ) (0 510 64 )
|
||||
4 3 5 (152 0 750 ) (104 0 750 ) (104 0 64 ) (152 0 64 )
|
||||
4 3 4 (256 0 64 ) (256 0 750 ) (152 0 750 ) (152 0 64 )
|
||||
4 3 8 (104 0 750 ) (0 0 750 ) (0 0 64 ) (104 0 64 )
|
||||
4 4 6 (152 -192 168 ) (152 -192 750 ) (152 -80 750 ) (152 -80 168 )
|
||||
4 4 5 (152 0 64 ) (152 -80 64 ) (152 -80 750 ) (152 0 750 )
|
||||
4 4 7 (152 -192 64 ) (152 -510 64 ) (152 -510 750 ) (152 -192 750 )
|
||||
4 5 6 (104 -80 750 ) (104 -80 168 ) (152 -80 168 ) (152 -80 750 )
|
||||
4 5 8 (104 0 64 ) (104 -80 64 ) (104 -80 750 ) (104 0 750 )
|
||||
4 6 8 (104 -192 168 ) (104 -192 750 ) (104 -80 750 ) (104 -80 168 )
|
||||
4 6 7 (104 -192 750 ) (104 -192 168 ) (152 -192 168 ) (152 -192 750 )
|
||||
4 7 8 (104 -192 64 ) (104 -510 64 ) (104 -510 750 ) (104 -192 750 )
|
||||
4 8 10 (0 -510 64 ) (0 -510 750 ) (0 0 750 ) (0 0 64 )
|
||||
4 9 10 (0 0 64 ) (0 0 750 ) (-510 0 750 ) (-510 0 64 )
|
2249
sp/game/sdk2013CE/mapsrc/testbox.vmf
Normal file
2249
sp/game/sdk2013CE/mapsrc/testbox.vmf
Normal file
File diff suppressed because it is too large
Load diff
2249
sp/game/sdk2013CE/mapsrc/testbox.vmx
Normal file
2249
sp/game/sdk2013CE/mapsrc/testbox.vmx
Normal file
File diff suppressed because it is too large
Load diff
BIN
sp/game/sdk2013CE/modelsounds.cache
Normal file
BIN
sp/game/sdk2013CE/modelsounds.cache
Normal file
Binary file not shown.
BIN
sp/game/sdk2013CE/normal.tga
Normal file
BIN
sp/game/sdk2013CE/normal.tga
Normal file
Binary file not shown.
After Width: | Height: | Size: 938 KiB |
|
@ -1,6 +1,7 @@
|
|||
"canvas"
|
||||
{
|
||||
"cfmt_version" "canvasver#002"
|
||||
"cfmt_version" "canvasver#003"
|
||||
"flowgraph_type" "1"
|
||||
"config"
|
||||
{
|
||||
"shadermodel" "1"
|
||||
|
@ -134,13 +135,17 @@
|
|||
"iPreview" "0"
|
||||
"enable_flex" "0"
|
||||
"enable_normal" "0"
|
||||
"enable_normal_compression" "0"
|
||||
"enable_blendweights" "0"
|
||||
"enable_tangentspace" "0"
|
||||
"enable_tangentspace_skinning" "0"
|
||||
"numTexcoords" "1"
|
||||
"numColor" "0"
|
||||
"dTFlag_Texcoords" "2"
|
||||
"dTFlag_Color" "8"
|
||||
"dTFlag_Texcoords_0" "2"
|
||||
"dTFlag_Texcoords_1" "2"
|
||||
"dTFlag_Texcoords_2" "2"
|
||||
"dTFlag_Color_0" "8"
|
||||
"dTFlag_Color_1" "8"
|
||||
}
|
||||
"Node_007"
|
||||
{
|
||||
|
@ -232,6 +237,7 @@
|
|||
"size_x" "50.000000"
|
||||
"size_y" "-17.000000"
|
||||
"iPreview" "1"
|
||||
"flSmartVal0" "0.000000"
|
||||
}
|
||||
"Node_012"
|
||||
{
|
||||
|
@ -273,6 +279,7 @@
|
|||
"size_x" "60.000000"
|
||||
"size_y" "-17.000000"
|
||||
"iPreview" "1"
|
||||
"flSmartVal0" "0.000000"
|
||||
}
|
||||
"Node_015"
|
||||
{
|
||||
|
|
|
@ -0,0 +1,79 @@
|
|||
"postproc_filmgrain"
|
||||
{
|
||||
"vs_name" "postproc_filmgrain_vs30"
|
||||
"ps_name" "postproc_filmgrain_ps30"
|
||||
"shader_filename" "shadereditorui\canvas\postproc_filmgrain.txt"
|
||||
"dump_version" "dumpver#001"
|
||||
"i_sm" "1"
|
||||
"i_cull" "0"
|
||||
"i_ablend" "0"
|
||||
"fl_atestref" "0.500000"
|
||||
"i_dtest" "0"
|
||||
"i_dwrite" "0"
|
||||
"i_srgbw" "0"
|
||||
"i_vfmt_flags" "262401"
|
||||
"i_vfmt_texcoords" "1"
|
||||
"i_vfmt_udata" "0"
|
||||
"i_vfmt_texcoordDim_0" "2"
|
||||
"i_vfmt_texcoordDim_1" "2"
|
||||
"i_vfmt_texcoordDim_2" "2"
|
||||
"i_vlit" "0"
|
||||
"i_vrefract" "1"
|
||||
"identifiers_VS"
|
||||
{
|
||||
"econst_0"
|
||||
{
|
||||
"i_envconstidx" "0"
|
||||
"i_normregister" "0"
|
||||
"i_econstsize" "1"
|
||||
"i_smartcomps" "1"
|
||||
"fl_smartdefault_00" "0.000000"
|
||||
"fl_smartdefault_01" "0.000000"
|
||||
"fl_smartdefault_02" "0.000000"
|
||||
"fl_smartdefault_03" "0.000000"
|
||||
}
|
||||
"econst_1"
|
||||
{
|
||||
"i_envconstidx" "6"
|
||||
"i_normregister" "1"
|
||||
"i_econstsize" "1"
|
||||
"i_smartcomps" "1"
|
||||
"fl_smartdefault_00" "0.000000"
|
||||
"fl_smartdefault_01" "0.000000"
|
||||
"fl_smartdefault_02" "0.000000"
|
||||
"fl_smartdefault_03" "0.000000"
|
||||
}
|
||||
"i_numdcombos" "1"
|
||||
}
|
||||
"identifiers_PS"
|
||||
{
|
||||
"econst_0"
|
||||
{
|
||||
"i_envconstidx" "17"
|
||||
"i_normregister" "0"
|
||||
"i_econstsize" "1"
|
||||
"i_smartcomps" "1"
|
||||
"sz_smartname" "Random33"
|
||||
"fl_smartdefault_00" "0.000000"
|
||||
"fl_smartdefault_01" "10.000000"
|
||||
"fl_smartdefault_02" "0.000000"
|
||||
"fl_smartdefault_03" "0.000000"
|
||||
}
|
||||
"texsamp_0"
|
||||
{
|
||||
"i_sampidx" "0"
|
||||
"i_texmode" "5"
|
||||
"i_cubemap" "0"
|
||||
"i_srgb" "0"
|
||||
}
|
||||
"texsamp_1"
|
||||
{
|
||||
"sz_fallback" "texture_samples\noise_2d"
|
||||
"i_sampidx" "1"
|
||||
"i_texmode" "1"
|
||||
"i_cubemap" "0"
|
||||
"i_srgb" "0"
|
||||
}
|
||||
"i_numdcombos" "1"
|
||||
}
|
||||
}
|
|
@ -1,22 +1,3 @@
|
|||
"shaderlist"
|
||||
{
|
||||
"shader_000" "basetexture_accum"
|
||||
"shader_001" "basetexture_blend"
|
||||
"shader_002" "detail_prop_shader"
|
||||
"shader_003" "downsample_4"
|
||||
"shader_004" "gauss_blur_5_x"
|
||||
"shader_005" "gauss_blur_5_y"
|
||||
"shader_006" "gauss_blur_7_half_aceil_x"
|
||||
"shader_007" "gauss_blur_7_half_aceil_y"
|
||||
"shader_008" "gauss_blur_half_3_x"
|
||||
"shader_009" "gauss_blur_half_3_y"
|
||||
"shader_010" "lightmap_blend_bump_detail"
|
||||
"shader_011" "lightmap_parallax"
|
||||
"shader_012" "model_chromatic_aberration"
|
||||
"shader_013" "model_snowy"
|
||||
"shader_014" "sprite_sun_nodepth"
|
||||
"shader_015" "ssao_calc"
|
||||
"shader_016" "ssao_combine"
|
||||
"shader_017" "ssao_fxaa"
|
||||
"shader_018" "sunrays_calc"
|
||||
}
|
||||
|
|
|
@ -7,154 +7,30 @@
|
|||
"i_cull" "0"
|
||||
"i_ablend" "0"
|
||||
"fl_atestref" "0.500000"
|
||||
"i_dtest" "1"
|
||||
"i_dwrite" "1"
|
||||
"i_srgbw" "1"
|
||||
"i_vfmt_flags" "2359559"
|
||||
"i_vfmt_texcoords" "2"
|
||||
"i_dtest" "0"
|
||||
"i_dwrite" "0"
|
||||
"i_srgbw" "0"
|
||||
"i_vfmt_flags" "262401"
|
||||
"i_vfmt_texcoords" "1"
|
||||
"i_vfmt_udata" "0"
|
||||
"i_vfmt_texcoordDim_0" "2"
|
||||
"i_vfmt_texcoordDim_1" "2"
|
||||
"i_vfmt_texcoordDim_2" "2"
|
||||
"i_vlit" "0"
|
||||
"i_vrefract" "0"
|
||||
"i_vrefract" "1"
|
||||
"identifiers_VS"
|
||||
{
|
||||
"i_numdcombos" "1"
|
||||
}
|
||||
"identifiers_PS"
|
||||
{
|
||||
"combo_0"
|
||||
{
|
||||
"sz_name" "FLASHLIGHT"
|
||||
"i_static" "0"
|
||||
"i_min" "0"
|
||||
"i_max" "1"
|
||||
"i_type" "9"
|
||||
}
|
||||
"combo_1"
|
||||
{
|
||||
"sz_name" "FLASHLIGHTDEPTHFILTERMODE"
|
||||
"i_static" "0"
|
||||
"i_min" "0"
|
||||
"i_max" "2"
|
||||
"i_type" "10"
|
||||
}
|
||||
"combo_2"
|
||||
{
|
||||
"sz_name" "FLASHLIGHTSHADOWS"
|
||||
"i_static" "0"
|
||||
"i_min" "0"
|
||||
"i_max" "1"
|
||||
"i_type" "11"
|
||||
}
|
||||
"combo_3"
|
||||
{
|
||||
"sz_name" "PIXELFOGTYPE"
|
||||
"i_static" "0"
|
||||
"i_min" "0"
|
||||
"i_max" "1"
|
||||
"i_type" "7"
|
||||
}
|
||||
"combo_4"
|
||||
{
|
||||
"sz_name" "WRITEWATERFOGTODESTALPHA"
|
||||
"i_static" "0"
|
||||
"i_min" "0"
|
||||
"i_max" "1"
|
||||
"i_type" "8"
|
||||
}
|
||||
"econst_0"
|
||||
{
|
||||
"i_envconstidx" "11"
|
||||
"i_normregister" "-1"
|
||||
"i_econstsize" "4"
|
||||
"i_smartcomps" "3"
|
||||
"fl_smartdefault_00" "0.000000"
|
||||
"fl_smartdefault_01" "0.000000"
|
||||
"fl_smartdefault_02" "0.000000"
|
||||
"fl_smartdefault_03" "0.000000"
|
||||
}
|
||||
"econst_1"
|
||||
{
|
||||
"i_envconstidx" "7"
|
||||
"i_normregister" "0"
|
||||
"i_econstsize" "1"
|
||||
"i_smartcomps" "1"
|
||||
"fl_smartdefault_00" "0.000000"
|
||||
"fl_smartdefault_01" "0.000000"
|
||||
"fl_smartdefault_02" "0.000000"
|
||||
"fl_smartdefault_03" "0.000000"
|
||||
}
|
||||
"econst_2"
|
||||
{
|
||||
"i_envconstidx" "1"
|
||||
"i_normregister" "1"
|
||||
"i_econstsize" "1"
|
||||
"i_smartcomps" "1"
|
||||
"fl_smartdefault_00" "0.000000"
|
||||
"fl_smartdefault_01" "0.000000"
|
||||
"fl_smartdefault_02" "0.000000"
|
||||
"fl_smartdefault_03" "0.000000"
|
||||
}
|
||||
"econst_3"
|
||||
{
|
||||
"i_envconstidx" "12"
|
||||
"i_normregister" "0"
|
||||
"i_econstsize" "1"
|
||||
"i_smartcomps" "3"
|
||||
"fl_smartdefault_00" "0.000000"
|
||||
"fl_smartdefault_01" "0.000000"
|
||||
"fl_smartdefault_02" "0.000000"
|
||||
"fl_smartdefault_03" "0.000000"
|
||||
}
|
||||
"texsamp_0"
|
||||
{
|
||||
"sz_param" "basetexture2"
|
||||
"sz_fallback" "Lights\White"
|
||||
"i_sampidx" "0"
|
||||
"i_texmode" "1"
|
||||
"i_cubemap" "0"
|
||||
"i_srgb" "1"
|
||||
}
|
||||
"texsamp_1"
|
||||
{
|
||||
"sz_param" "basetexture2"
|
||||
"sz_fallback" "Lights\White"
|
||||
"i_sampidx" "1"
|
||||
"i_texmode" "0"
|
||||
"i_cubemap" "0"
|
||||
"i_srgb" "1"
|
||||
}
|
||||
"texsamp_2"
|
||||
{
|
||||
"sz_fallback" "Lights\White"
|
||||
"i_sampidx" "2"
|
||||
"i_texmode" "3"
|
||||
"i_cubemap" "0"
|
||||
"i_srgb" "1"
|
||||
}
|
||||
"texsamp_3"
|
||||
{
|
||||
"i_sampidx" "3"
|
||||
"i_texmode" "10"
|
||||
"i_cubemap" "0"
|
||||
"i_srgb" "1"
|
||||
}
|
||||
"texsamp_4"
|
||||
{
|
||||
"i_sampidx" "4"
|
||||
"i_texmode" "11"
|
||||
"i_texmode" "5"
|
||||
"i_cubemap" "0"
|
||||
"i_srgb" "0"
|
||||
}
|
||||
"texsamp_5"
|
||||
{
|
||||
"i_sampidx" "5"
|
||||
"i_texmode" "12"
|
||||
"i_cubemap" "0"
|
||||
"i_srgb" "0"
|
||||
}
|
||||
"i_numdcombos" "48"
|
||||
"i_numdcombos" "1"
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,17 +1,17 @@
|
|||
"config"
|
||||
{
|
||||
"preview_visible" "1"
|
||||
"p_x" "1134"
|
||||
"p_y" "500"
|
||||
"p_x" "784"
|
||||
"p_y" "302"
|
||||
"p_sx" "449"
|
||||
"p_sy" "378"
|
||||
"draw_datatypes" "1"
|
||||
"draw_shadows" "1"
|
||||
"draw_all_limits" "0"
|
||||
"compile_preview" "1"
|
||||
"draw_all_limits" "1"
|
||||
"compile_preview" "0"
|
||||
"enable_nodeview_tooltips" "1"
|
||||
"compile_always_full" "0"
|
||||
"compile_auto_publish_to_materials" "1"
|
||||
"compile_auto_publish_to_materials" "0"
|
||||
"precache_auto_reload" "1"
|
||||
"warn_unsaved_changes" "1"
|
||||
"cedit_x" "95"
|
||||
|
|
|
@ -2,6 +2,8 @@
|
|||
// ** auto generated pixelshader **
|
||||
// ********************************
|
||||
|
||||
#define SHADER_EDITOR_2013_COMPILE
|
||||
|
||||
|
||||
// Includes
|
||||
#include "common_ps_fxc.h"
|
||||
|
|
|
@ -2,6 +2,8 @@
|
|||
// ** auto generated vertexshader **
|
||||
// *********************************
|
||||
|
||||
#define SHADER_EDITOR_2013_COMPILE
|
||||
|
||||
|
||||
// Includes
|
||||
#include "common_vs_fxc.h"
|
||||
|
|
45
sp/game/sdk2013CE/shadereditorui/shader_src/filelist.txt
Normal file
45
sp/game/sdk2013CE/shadereditorui/shader_src/filelist.txt
Normal file
|
@ -0,0 +1,45 @@
|
|||
*** generated by shadereditor.dll ***
|
||||
#BEGIN postproc_nightvision_vs30
|
||||
postproc_nightvision_vs30.fxc
|
||||
#DEFINES-D:
|
||||
#DEFINES-S:
|
||||
#SKIP:
|
||||
(defined $HDRTYPE && defined $HDRENABLED && !$HDRTYPE && $HDRENABLED)||(defined $PIXELFOGTYPE && defined $WRITEWATERFOGTODESTALPHA && ( $PIXELFOGTYPE != 1 ) && $WRITEWATERFOGTODESTALPHA)||(defined $LIGHTING_PREVIEW && defined $HDRTYPE && $LIGHTING_PREVIEW && $HDRTYPE != 0)||(defined $LIGHTING_PREVIEW && defined $FASTPATHENVMAPTINT && $LIGHTING_PREVIEW && $FASTPATHENVMAPTINT)||(defined $LIGHTING_PREVIEW && defined $FASTPATHENVMAPCONTRAST && $LIGHTING_PREVIEW && $FASTPATHENVMAPCONTRAST)||(defined $LIGHTING_PREVIEW && defined $FASTPATH && $LIGHTING_PREVIEW && $FASTPATH)||(($FLASHLIGHT || $FLASHLIGHTSHADOWS) && $LIGHTING_PREVIEW)||0
|
||||
#COMMAND:
|
||||
fxc.exe /DTOTALSHADERCOMBOS=1 /DCENTROIDMASK=0 /DNUMDYNAMICCOMBOS=1 /DFLAGS=0x0 /Dmain=main /Emain /Tvs_3_0 /DSHADER_MODEL_VS_3_0=1 /nologo /Foshader.o postproc_nightvision_vs30.fxc>output.txt 2>&1
|
||||
#END
|
||||
*************************************
|
||||
*** generated by shadereditor.dll ***
|
||||
#BEGIN postproc_nightvision_vs30
|
||||
postproc_nightvision_vs30.fxc
|
||||
#DEFINES-D:
|
||||
#DEFINES-S:
|
||||
#SKIP:
|
||||
(defined $HDRTYPE && defined $HDRENABLED && !$HDRTYPE && $HDRENABLED)||(defined $PIXELFOGTYPE && defined $WRITEWATERFOGTODESTALPHA && ( $PIXELFOGTYPE != 1 ) && $WRITEWATERFOGTODESTALPHA)||(defined $LIGHTING_PREVIEW && defined $HDRTYPE && $LIGHTING_PREVIEW && $HDRTYPE != 0)||(defined $LIGHTING_PREVIEW && defined $FASTPATHENVMAPTINT && $LIGHTING_PREVIEW && $FASTPATHENVMAPTINT)||(defined $LIGHTING_PREVIEW && defined $FASTPATHENVMAPCONTRAST && $LIGHTING_PREVIEW && $FASTPATHENVMAPCONTRAST)||(defined $LIGHTING_PREVIEW && defined $FASTPATH && $LIGHTING_PREVIEW && $FASTPATH)||(($FLASHLIGHT || $FLASHLIGHTSHADOWS) && $LIGHTING_PREVIEW)||0
|
||||
#COMMAND:
|
||||
fxc.exe /DTOTALSHADERCOMBOS=1 /DCENTROIDMASK=0 /DNUMDYNAMICCOMBOS=1 /DFLAGS=0x0 /Dmain=main /Emain /Tvs_3_0 /DSHADER_MODEL_VS_3_0=1 /nologo /Foshader.o postproc_nightvision_vs30.fxc>output.txt 2>&1
|
||||
#END
|
||||
*************************************
|
||||
|
||||
*** generated by shadereditor.dll ***
|
||||
#BEGIN postproc_nightvision_ps30
|
||||
postproc_nightvision_ps30.fxc
|
||||
#DEFINES-D:
|
||||
#DEFINES-S:
|
||||
#SKIP:
|
||||
(defined $HDRTYPE && defined $HDRENABLED && !$HDRTYPE && $HDRENABLED)||(defined $PIXELFOGTYPE && defined $WRITEWATERFOGTODESTALPHA && ( $PIXELFOGTYPE != 1 ) && $WRITEWATERFOGTODESTALPHA)||(defined $LIGHTING_PREVIEW && defined $HDRTYPE && $LIGHTING_PREVIEW && $HDRTYPE != 0)||(defined $LIGHTING_PREVIEW && defined $FASTPATHENVMAPTINT && $LIGHTING_PREVIEW && $FASTPATHENVMAPTINT)||(defined $LIGHTING_PREVIEW && defined $FASTPATHENVMAPCONTRAST && $LIGHTING_PREVIEW && $FASTPATHENVMAPCONTRAST)||(defined $LIGHTING_PREVIEW && defined $FASTPATH && $LIGHTING_PREVIEW && $FASTPATH)||(($FLASHLIGHT || $FLASHLIGHTSHADOWS) && $LIGHTING_PREVIEW)||0
|
||||
#COMMAND:
|
||||
fxc.exe /DTOTALSHADERCOMBOS=1 /DCENTROIDMASK=0 /DNUMDYNAMICCOMBOS=1 /DFLAGS=0x0 /Dmain=main /Emain /Tps_3_0 /DSHADER_MODEL_PS_3_0=1 /nologo /Foshader.o postproc_nightvision_ps30.fxc>output.txt 2>&1
|
||||
#END
|
||||
*************************************
|
||||
*** generated by shadereditor.dll ***
|
||||
#BEGIN postproc_nightvision_ps30
|
||||
postproc_nightvision_ps30.fxc
|
||||
#DEFINES-D:
|
||||
#DEFINES-S:
|
||||
#SKIP:
|
||||
(defined $HDRTYPE && defined $HDRENABLED && !$HDRTYPE && $HDRENABLED)||(defined $PIXELFOGTYPE && defined $WRITEWATERFOGTODESTALPHA && ( $PIXELFOGTYPE != 1 ) && $WRITEWATERFOGTODESTALPHA)||(defined $LIGHTING_PREVIEW && defined $HDRTYPE && $LIGHTING_PREVIEW && $HDRTYPE != 0)||(defined $LIGHTING_PREVIEW && defined $FASTPATHENVMAPTINT && $LIGHTING_PREVIEW && $FASTPATHENVMAPTINT)||(defined $LIGHTING_PREVIEW && defined $FASTPATHENVMAPCONTRAST && $LIGHTING_PREVIEW && $FASTPATHENVMAPCONTRAST)||(defined $LIGHTING_PREVIEW && defined $FASTPATH && $LIGHTING_PREVIEW && $FASTPATH)||(($FLASHLIGHT || $FLASHLIGHTSHADOWS) && $LIGHTING_PREVIEW)||0
|
||||
#COMMAND:
|
||||
fxc.exe /DTOTALSHADERCOMBOS=1 /DCENTROIDMASK=0 /DNUMDYNAMICCOMBOS=1 /DFLAGS=0x0 /Dmain=main /Emain /Tps_3_0 /DSHADER_MODEL_PS_3_0=1 /nologo /Foshader.o postproc_nightvision_ps30.fxc>output.txt 2>&1
|
||||
#END
|
||||
*************************************
|
|
@ -0,0 +1,58 @@
|
|||
// ********************************
|
||||
// ** auto generated pixelshader **
|
||||
// ********************************
|
||||
|
||||
#define SHADER_EDITOR_2013_COMPILE
|
||||
|
||||
|
||||
// Includes
|
||||
#include "common_ps_fxc.h"
|
||||
#include "common_vertexlitgeneric_dx9.h"
|
||||
#include "common_lightmappedgeneric_fxc.h"
|
||||
#include "common_flashlight_fxc.h"
|
||||
#include "common_parallax.h"
|
||||
|
||||
|
||||
// Samplers
|
||||
sampler _Sampler_00 : register( s0 );
|
||||
sampler _Sampler_01 : register( s1 );
|
||||
|
||||
// Constants
|
||||
const float2 g_cData_Random33 : register( c16 ); // Random gen
|
||||
|
||||
// Semantic structures
|
||||
struct PS_INPUT
|
||||
{
|
||||
float2 vTexCoord_0 : TEXCOORD0;
|
||||
float2 vTexCoord_2 : TEXCOORD2;
|
||||
};
|
||||
|
||||
struct PS_OUTPUT
|
||||
{
|
||||
float4 vColor_0 : COLOR0;
|
||||
};
|
||||
|
||||
// Entry point
|
||||
PS_OUTPUT main( const PS_INPUT In )
|
||||
{
|
||||
PS_OUTPUT Out;
|
||||
float4 _texLookup_7 = tex2D( _Sampler_00, In.vTexCoord_0 );
|
||||
float3 _var0 = _texLookup_7.rgb;
|
||||
float _var1 = _texLookup_7.a;
|
||||
float2 _var2 = In.vTexCoord_0 * float( 10.000000 );
|
||||
float2 _var3 = In.vTexCoord_0 * In.vTexCoord_2;
|
||||
float _var4 = dot( _var0, float3( 0.300000, 0.590000, 0.110000 ) );
|
||||
float _var5 = tex2D( _Sampler_01, _var2 ).g;
|
||||
_var3 = _var3 + g_cData_Random33;
|
||||
_var5 = round( _var5 );
|
||||
float _var6 = tex2D( _Sampler_01, _var3 ).r;
|
||||
_var5 = _var5 - _var6;
|
||||
_var5 = abs( _var5 );
|
||||
_var5 = _var5 * float( 0.400000 );
|
||||
float3 _var7 = lerp( _var0, _var4, _var5 );
|
||||
float _var8 = _var5 + float( 0.800000 );
|
||||
_var7 = _var7 * _var8;
|
||||
float4 _var9 = float4( _var7, _var1 );
|
||||
Out.vColor_0 = _var9;
|
||||
return Out;
|
||||
}
|
|
@ -0,0 +1,55 @@
|
|||
// *********************************
|
||||
// ** auto generated vertexshader **
|
||||
// *********************************
|
||||
|
||||
#define SHADER_EDITOR_2013_COMPILE
|
||||
|
||||
|
||||
// Includes
|
||||
#include "common_vs_fxc.h"
|
||||
|
||||
|
||||
// Constants
|
||||
const float _g_Time : register( c48 );
|
||||
const float2 _g_TexelSize : register( c49 );
|
||||
|
||||
// Semantic structures
|
||||
struct VS_INPUT
|
||||
{
|
||||
float3 vPos : POSITION;
|
||||
float2 vTexCoord_0 : TEXCOORD0;
|
||||
};
|
||||
|
||||
struct VS_OUTPUT
|
||||
{
|
||||
float4 vProjPos : POSITION;
|
||||
float2 vTexCoord_0 : TEXCOORD0;
|
||||
float2 vTexCoord_1 : TEXCOORD1;
|
||||
float2 vTexCoord_2 : TEXCOORD2;
|
||||
};
|
||||
|
||||
// Entry point
|
||||
VS_OUTPUT main( const VS_INPUT In )
|
||||
{
|
||||
VS_OUTPUT Out;
|
||||
float4 _var0 = float4( In.vPos.x, In.vPos.y, In.vPos.z, 1.000000 );
|
||||
float _var1 = float( 2.000000 ) * _g_Time;
|
||||
float2 _var2 = float( 1.000000 ) / _g_TexelSize;
|
||||
float2 _var3 = _var1.xx;
|
||||
_var2 = _var2 / float( 64.000000 );
|
||||
{
|
||||
float2 center_def = float2( 0.5f, 0.5f );
|
||||
float rot_def = float( 0.0f );
|
||||
float fs = sin( rot_def );
|
||||
float fc = cos( rot_def );
|
||||
float4 row_0 = float4( fc * float2( 0.000100, 0.000100 ).x, -fs * float2( 0.000100, 0.000100 ).x, 0, ( -center_def.x * fc + center_def.y * fs ) * float2( 0.000100, 0.000100 ).x + center_def.x + _var3.x );
|
||||
float4 row_1 = float4( fs * float2( 0.000100, 0.000100 ).y, fc * float2( 0.000100, 0.000100 ).y, 0, ( -center_def.x * fs - center_def.y * fc ) * float2( 0.000100, 0.000100 ).y + center_def.y + _var3.y );
|
||||
_var3.x = dot( float4( In.vTexCoord_0, 0, 1 ), row_0 );
|
||||
_var3.y = dot( float4( In.vTexCoord_0, 0, 1 ), row_1 );
|
||||
}
|
||||
Out.vProjPos = _var0;
|
||||
Out.vTexCoord_0 = In.vTexCoord_0;
|
||||
Out.vTexCoord_1 = _var3;
|
||||
Out.vTexCoord_2 = _var2;
|
||||
return Out;
|
||||
}
|
|
@ -0,0 +1,105 @@
|
|||
// ********************************
|
||||
// ** auto generated pixelshader **
|
||||
// ********************************
|
||||
|
||||
#define SHADER_EDITOR_2013_COMPILE
|
||||
|
||||
|
||||
// Includes
|
||||
#include "common_ps_fxc.h"
|
||||
#include "common_vertexlitgeneric_dx9.h"
|
||||
#include "common_lightmappedgeneric_fxc.h"
|
||||
#include "common_flashlight_fxc.h"
|
||||
#include "common_parallax.h"
|
||||
|
||||
|
||||
// Samplers
|
||||
sampler _Sampler_00 : register( s0 );
|
||||
sampler _Sampler_01 : register( s1 );
|
||||
|
||||
// Constants
|
||||
const float2 g_cData_Random80 : register( c16 ); // Random gen
|
||||
|
||||
// Semantic structures
|
||||
struct PS_INPUT
|
||||
{
|
||||
float2 vTexCoord_0 : TEXCOORD0;
|
||||
float2 vTexCoord_2 : TEXCOORD2;
|
||||
};
|
||||
|
||||
struct PS_OUTPUT
|
||||
{
|
||||
float4 vColor_0 : COLOR0;
|
||||
};
|
||||
|
||||
// Entry point
|
||||
PS_OUTPUT main( const PS_INPUT In )
|
||||
{
|
||||
PS_OUTPUT Out;
|
||||
float2 _var0 = In.vTexCoord_0 * float( 10.000000 );
|
||||
float2 _var1 = In.vTexCoord_0 * In.vTexCoord_2;
|
||||
float2 _var2 = In.vTexCoord_0 - float2( 0.400000, 0.500000 );
|
||||
float2 _var3 = In.vTexCoord_0 - float2( 0.600000, 0.500000 );
|
||||
float3 _var4 = tex2D( _Sampler_00, In.vTexCoord_0 ).rgb;
|
||||
float2 _var5 = In.vTexCoord_0 - float( 0.500000 );
|
||||
float _var6 = tex2D( _Sampler_01, _var0 ).g;
|
||||
_var1 = _var1 + g_cData_Random80;
|
||||
float _var7 = length( _var2 );
|
||||
float _var8 = length( _var3 );
|
||||
float2 _var9 = normalize( _var5 );
|
||||
float _var10 = length( _var5 );
|
||||
_var6 = round( _var6 );
|
||||
float _var11 = tex2D( _Sampler_01, _var1 ).r;
|
||||
_var7 = min( _var7, _var8 );
|
||||
float _var12 = dot( _var9, float2( 1.000000, 0.000000 ) );
|
||||
float _var13 = dot( _var9, float2( 0.000000, 1.000000 ) );
|
||||
_var10 = smoothstep( float( 2.000000 ), float( -10.000000 ), _var10 );
|
||||
_var6 = _var6 - _var11;
|
||||
float _var14 = smoothstep( float( 0.380000 ), float( 0.420000 ), _var7 );
|
||||
_var12 = _var12 * float( 0.500000 );
|
||||
_var13 = _var13 * float( 0.500000 );
|
||||
float _var15 = smoothstep( float( 0.400000 ), float( 0.500000 ), _var7 );
|
||||
float _var16 = smoothstep( float( 1.000000 ), float( 0.100000 ), _var7 );
|
||||
float _var17 = smoothstep( float( 0.350000 ), float( 0.550000 ), _var7 );
|
||||
_var6 = abs( _var6 );
|
||||
_var12 = abs( _var12 );
|
||||
_var13 = abs( _var13 );
|
||||
_var17 = 1.0f - _var17;
|
||||
_var6 = _var6 * float( 0.200000 );
|
||||
_var12 = float( 1.000000 ) - _var12;
|
||||
_var13 = float( 1.000000 ) - _var13;
|
||||
_var6 = _var6 + float( 0.900000 );
|
||||
float2 _var18 = float2( _var12, _var13 );
|
||||
_var6 = lerp( _var6, float( 1.000000 ), _var14 );
|
||||
_var18 = lerp( float( 1.000000 ), _var18, _var15 );
|
||||
{
|
||||
float2 center_def = float2( 0.5f, 0.5f );
|
||||
float rot_def = float( 0.0f );
|
||||
float2 trans_def = float2( 0.0f, 0.0f );
|
||||
float fs = sin( rot_def );
|
||||
float fc = cos( rot_def );
|
||||
float4 row_0 = float4( fc * _var18.x, -fs * _var18.x, 0, ( -center_def.x * fc + center_def.y * fs ) * _var18.x + center_def.x + trans_def.x );
|
||||
float4 row_1 = float4( fs * _var18.y, fc * _var18.y, 0, ( -center_def.x * fs - center_def.y * fc ) * _var18.y + center_def.y + trans_def.y );
|
||||
_var18.x = dot( float4( In.vTexCoord_0, 0, 1 ), row_0 );
|
||||
_var18.y = dot( float4( In.vTexCoord_0, 0, 1 ), row_1 );
|
||||
}
|
||||
float3 _var19 = tex2D( _Sampler_00, _var18 ).rgb;
|
||||
_var4 = lerp( _var4, _var19, _var16 );
|
||||
float _var20 = dot( _var4, float3( 0.300000, 0.590000, 0.110000 ) );
|
||||
float3 _var21 = _var4 * float3( 1.500000, 2.250000, 1.800000 );
|
||||
float _var22 = smoothstep( float( -0.100000 ), float( 0.500000 ), _var20 );
|
||||
float _var23 = smoothstep( float( 0.500000 ), float( 1.000000 ), _var20 );
|
||||
float3 _var24 = _var4 / _var22;
|
||||
_var21 = lerp( _var21, float3( 0.762000, 1.780000, 0.500000 ), _var22 );
|
||||
_var24 = saturate( _var24 );
|
||||
_var21 = lerp( _var21, float3( 0.900000, 1.000000, 0.900000 ), _var23 );
|
||||
float _var25 = dot( _var24, float3( 0.300000, 0.590000, 0.110000 ) );
|
||||
_var21 = _var25 * _var21;
|
||||
_var21 = _var21 * float( 1.400000 );
|
||||
_var21 = lerp( _var21, _var4, _var10 );
|
||||
_var21 = _var6 * _var21;
|
||||
_var21 = _var21 * _var17;
|
||||
float4 _var26 = float4( _var21.x, _var21.y, _var21.z, 1.000000 );
|
||||
Out.vColor_0 = _var26;
|
||||
return Out;
|
||||
}
|
|
@ -0,0 +1,55 @@
|
|||
// *********************************
|
||||
// ** auto generated vertexshader **
|
||||
// *********************************
|
||||
|
||||
#define SHADER_EDITOR_2013_COMPILE
|
||||
|
||||
|
||||
// Includes
|
||||
#include "common_vs_fxc.h"
|
||||
|
||||
|
||||
// Constants
|
||||
const float _g_Time : register( c48 );
|
||||
const float2 _g_TexelSize : register( c49 );
|
||||
|
||||
// Semantic structures
|
||||
struct VS_INPUT
|
||||
{
|
||||
float3 vPos : POSITION;
|
||||
float2 vTexCoord_0 : TEXCOORD0;
|
||||
};
|
||||
|
||||
struct VS_OUTPUT
|
||||
{
|
||||
float4 vProjPos : POSITION;
|
||||
float2 vTexCoord_0 : TEXCOORD0;
|
||||
float2 vTexCoord_1 : TEXCOORD1;
|
||||
float2 vTexCoord_2 : TEXCOORD2;
|
||||
};
|
||||
|
||||
// Entry point
|
||||
VS_OUTPUT main( const VS_INPUT In )
|
||||
{
|
||||
VS_OUTPUT Out;
|
||||
float4 _var0 = float4( In.vPos.x, In.vPos.y, In.vPos.z, 1.000000 );
|
||||
float _var1 = float( 2.000000 ) * _g_Time;
|
||||
float2 _var2 = float( 1.000000 ) / _g_TexelSize;
|
||||
float2 _var3 = _var1.xx;
|
||||
_var2 = _var2 / float( 64.000000 );
|
||||
{
|
||||
float2 center_def = float2( 0.5f, 0.5f );
|
||||
float rot_def = float( 0.0f );
|
||||
float fs = sin( rot_def );
|
||||
float fc = cos( rot_def );
|
||||
float4 row_0 = float4( fc * float2( 0.000100, 0.000100 ).x, -fs * float2( 0.000100, 0.000100 ).x, 0, ( -center_def.x * fc + center_def.y * fs ) * float2( 0.000100, 0.000100 ).x + center_def.x + _var3.x );
|
||||
float4 row_1 = float4( fs * float2( 0.000100, 0.000100 ).y, fc * float2( 0.000100, 0.000100 ).y, 0, ( -center_def.x * fs - center_def.y * fc ) * float2( 0.000100, 0.000100 ).y + center_def.y + _var3.y );
|
||||
_var3.x = dot( float4( In.vTexCoord_0, 0, 1 ), row_0 );
|
||||
_var3.y = dot( float4( In.vTexCoord_0, 0, 1 ), row_1 );
|
||||
}
|
||||
Out.vProjPos = _var0;
|
||||
Out.vTexCoord_0 = In.vTexCoord_0;
|
||||
Out.vTexCoord_1 = _var3;
|
||||
Out.vTexCoord_2 = _var2;
|
||||
return Out;
|
||||
}
|
|
@ -0,0 +1,16 @@
|
|||
bin\dx_proxy.dll
|
||||
..\..\..\..\common\Source SDK Base 2013 Singleplayer\bin\tier0.dll
|
||||
..\..\..\..\common\Source SDK Base 2013 Singleplayer\bin\vstdlib.dll
|
||||
common_fxc.h
|
||||
common_hlsl_cpp_consts.h
|
||||
common_pragmas.h
|
||||
common_ps_fxc.h
|
||||
common_vs_fxc.h
|
||||
common_vertexlitgeneric_dx9.h
|
||||
common_lightmappedgeneric_fxc.h
|
||||
common_flashlight_fxc.h
|
||||
common_parallax.h
|
||||
..\..\..\..\common\Source SDK Base 2013 Singleplayer\bin\shadercompile.exe
|
||||
..\..\..\..\common\Source SDK Base 2013 Singleplayer\bin\shadercompile_dll.dll
|
||||
postproc_nightvision_vs30.fxc
|
||||
postproc_nightvision_ps30.fxc
|
|
@ -2,10 +2,13 @@
|
|||
// ** auto generated pixelshader **
|
||||
// ********************************
|
||||
|
||||
#define SHADER_EDITOR_2013_COMPILE
|
||||
|
||||
// Combos
|
||||
// DYNAMIC: "FLASHLIGHT" "0..1"
|
||||
// STATIC: "FLASHLIGHT" "0..1"
|
||||
// DYNAMIC: "FLASHLIGHTDEPTHFILTERMODE" "0..2"
|
||||
// DYNAMIC: "FLASHLIGHTSHADOWS" "0..1"
|
||||
// DYNAMIC: "NUM_LIGHTS" "0..4"
|
||||
// DYNAMIC: "PIXELFOGTYPE" "0..1"
|
||||
// DYNAMIC: "WRITEWATERFOGTODESTALPHA" "0..1"
|
||||
|
||||
|
@ -19,27 +22,26 @@
|
|||
|
||||
// Samplers
|
||||
sampler _Sampler_00 : register( s0 );
|
||||
sampler _Sampler_01 : register( s1 );
|
||||
sampler _Sampler_02 : register( s2 );
|
||||
sampler _gSampler_Flashlight_Cookie : register( s3 );
|
||||
sampler _gSampler_Flashlight_Depth : register( s4 );
|
||||
sampler _gSampler_Flashlight_Random : register( s5 );
|
||||
sampler _gSampler_Flashlight_Cookie : register( s1 );
|
||||
sampler _gSampler_Flashlight_Depth : register( s2 );
|
||||
sampler _gSampler_Flashlight_Random : register( s3 );
|
||||
|
||||
// Constants
|
||||
const float4x4 g_cFlashlightWorldToTexture : register( c12 );
|
||||
const float4 _g_FogParams : register( c16 );
|
||||
const float3 _g_VecOrig : register( c17 );
|
||||
const float4 g_cFlashlightAttenuationFactors : register( c8 );
|
||||
const float4 g_cFlashlightPos : register( c9 );
|
||||
const float4 g_cShadowTweaks : register( c7 );
|
||||
const float3 g_cAmbientCube[6] : register( c0 );
|
||||
PixelShaderLightInfo g_cLightInfo[3] : register( c6 );
|
||||
|
||||
// Semantic structures
|
||||
struct PS_INPUT
|
||||
{
|
||||
float2 vTexCoord_0 : TEXCOORD0;
|
||||
float2 vTexCoord_1 : TEXCOORD1;
|
||||
float3 vTexCoord_1 : TEXCOORD1;
|
||||
float3 vTexCoord_2 : TEXCOORD2;
|
||||
float3 vTexCoord_3 : TEXCOORD3;
|
||||
float4 vTexCoord_3 : TEXCOORD3;
|
||||
float4 vTexCoord_4 : TEXCOORD4;
|
||||
float4 vColor_0 : COLOR0;
|
||||
};
|
||||
|
@ -53,38 +55,36 @@ struct PS_OUTPUT
|
|||
PS_OUTPUT main( const PS_INPUT In )
|
||||
{
|
||||
PS_OUTPUT Out;
|
||||
float3 _var0 = float3( 0.000000, 0.000000, 0.000000 );
|
||||
float3 _var1 = tex2D( _Sampler_00, In.vTexCoord_0 ).rgb;
|
||||
float3 _var2 = tex2D( _Sampler_01, In.vTexCoord_0 ).rgb;
|
||||
float _var3 = In.vColor_0.w;
|
||||
float _var4 = _g_VecOrig.z;
|
||||
float4 _texLookup_9 = tex2D( _Sampler_00, In.vTexCoord_0 );
|
||||
float3 _var0 = _texLookup_9.rgb;
|
||||
float _var1 = _texLookup_9.a;
|
||||
float3 _var2 = float3( 0.000000, 0.000000, 0.000000 );
|
||||
float _var3 = _g_VecOrig.z;
|
||||
float _var4 = In.vTexCoord_1.z;
|
||||
float _var5 = In.vTexCoord_3.z;
|
||||
float _var6 = In.vTexCoord_4.z;
|
||||
#if ( FLASHLIGHT == 0 )
|
||||
float3 _var7 = tex2D( _Sampler_02, In.vTexCoord_1 ).rgb;
|
||||
_var7 = _var7 * LIGHT_MAP_SCALE;
|
||||
_var0 = _var7;
|
||||
#endif
|
||||
#if ( FLASHLIGHT == 1 )
|
||||
float4 _var8 = mul( float4(In.vTexCoord_3.xyz,1), g_cFlashlightWorldToTexture );
|
||||
float2 _var9 = In.vTexCoord_4.xy;
|
||||
float _var10 = In.vTexCoord_4.w;
|
||||
_var9 = _var9 / _var10;
|
||||
_var9 = _var9 * float( 0.500000 );
|
||||
_var9 = _var9 + float( 0.500000 );
|
||||
float3 _var11 = DoFlashlight( g_cFlashlightPos.xyz, In.vTexCoord_3, _var8, In.vTexCoord_2,
|
||||
float2 _var6 = In.vTexCoord_3.xy;
|
||||
float _var7 = In.vTexCoord_3.w;
|
||||
_var6 = _var6 / _var7;
|
||||
float3 _var8 = DoFlashlight( g_cFlashlightPos.xyz, In.vTexCoord_1, In.vTexCoord_4, In.vTexCoord_2,
|
||||
g_cFlashlightAttenuationFactors.xyz, g_cFlashlightAttenuationFactors.w,
|
||||
_gSampler_Flashlight_Cookie, _gSampler_Flashlight_Depth, _gSampler_Flashlight_Random,
|
||||
FLASHLIGHTDEPTHFILTERMODE, FLASHLIGHTSHADOWS, true,
|
||||
_var9, false, g_cShadowTweaks );
|
||||
_var0 = _var11;
|
||||
_var6, false, g_cShadowTweaks );
|
||||
_var2 = _var8;
|
||||
#endif
|
||||
_var0 = _var0;
|
||||
_var1 = lerp( _var1, _var2, _var3 );
|
||||
_var4 = CalcPixelFogFactor( PIXELFOGTYPE, _g_FogParams, _var4, _var5, _var6 );
|
||||
_var0 = _var0 * _var1;
|
||||
float4 _var12 = float4( _var0.x, _var0.y, _var0.z, 1.000000 );
|
||||
_var12 = FinalOutput( _var12, _var4, PIXELFOGTYPE, TONEMAP_SCALE_LINEAR, true, _var6 );
|
||||
Out.vColor_0 = _var12;
|
||||
#if ( FLASHLIGHT == 0 )
|
||||
float3 _var9 = PixelShaderDoLighting( In.vTexCoord_1, In.vTexCoord_2, float3(0,0,0),
|
||||
false, true, In.vColor_0,
|
||||
g_cAmbientCube, NUM_LIGHTS, g_cLightInfo,
|
||||
false, false, 1.0f );
|
||||
_var2 = _var9;
|
||||
#endif
|
||||
_var2 = _var2;
|
||||
_var3 = CalcPixelFogFactor( PIXELFOGTYPE, _g_FogParams, _var3, _var4, _var5 );
|
||||
_var0 = _var0 * _var2;
|
||||
float4 _var10 = float4( _var0, _var1 );
|
||||
_var10 = FinalOutput( _var10, _var3, PIXELFOGTYPE, TONEMAP_SCALE_LINEAR, true, _var5 );
|
||||
Out.vColor_0 = _var10;
|
||||
return Out;
|
||||
}
|
|
@ -2,28 +2,37 @@
|
|||
// ** auto generated vertexshader **
|
||||
// *********************************
|
||||
|
||||
#define SHADER_EDITOR_2013_COMPILE
|
||||
|
||||
// Combos
|
||||
// DYNAMIC: "COMPRESSED_VERTS" "0..1"
|
||||
// DYNAMIC: "SKINNING" "0..1"
|
||||
// STATIC: "FLASHLIGHT" "0..1"
|
||||
|
||||
// Includes
|
||||
#include "common_vs_fxc.h"
|
||||
|
||||
|
||||
// Constants
|
||||
const float4x4 g_cFlashlightWorldToTexture : register( c48 );
|
||||
|
||||
// Semantic structures
|
||||
struct VS_INPUT
|
||||
{
|
||||
float3 vPos : POSITION;
|
||||
float3 vNormal : NORMAL;
|
||||
float4 vBoneWeights : BLENDWEIGHT;
|
||||
float4 vBoneIndices : BLENDINDICES;
|
||||
float4 vNormal : NORMAL;
|
||||
float2 vTexCoord_0 : TEXCOORD0;
|
||||
float2 vTexCoord_1 : TEXCOORD1;
|
||||
float4 vColor_0 : COLOR0;
|
||||
};
|
||||
|
||||
struct VS_OUTPUT
|
||||
{
|
||||
float4 vProjPos : POSITION;
|
||||
float2 vTexCoord_0 : TEXCOORD0;
|
||||
float2 vTexCoord_1 : TEXCOORD1;
|
||||
float3 vTexCoord_1 : TEXCOORD1;
|
||||
float3 vTexCoord_2 : TEXCOORD2;
|
||||
float3 vTexCoord_3 : TEXCOORD3;
|
||||
float4 vTexCoord_3 : TEXCOORD3;
|
||||
float4 vTexCoord_4 : TEXCOORD4;
|
||||
float4 vColor_0 : COLOR0;
|
||||
};
|
||||
|
@ -32,15 +41,29 @@ struct VS_OUTPUT
|
|||
VS_OUTPUT main( const VS_INPUT In )
|
||||
{
|
||||
VS_OUTPUT Out;
|
||||
float3 _var0 = mul( float4(In.vPos.xyz,1), cModel[0] );
|
||||
float3 _var1 = mul( float4(In.vNormal.xyz,1), cModel[0] );
|
||||
float4 _var2 = mul( float4(_var0.xyz,1), cViewProj );
|
||||
Out.vProjPos = _var2;
|
||||
float3 _var0 = (float3)0;
|
||||
DecompressVertex_Normal( In.vNormal, _var0 );
|
||||
float4 _var1 = float4( 0.000000, 0.000000, 0.000000, 0.000000 );
|
||||
float3 _var2 = (float3)0;
|
||||
float3 _var3 = (float3)0;
|
||||
SkinPositionAndNormal( SKINNING, float4( In.vPos, 1 ), _var0,
|
||||
In.vBoneWeights, In.vBoneIndices,
|
||||
_var2, _var3 );
|
||||
float4 _var4 = mul( float4(_var2.xyz,1), cViewProj );
|
||||
#if ( FLASHLIGHT == 1 )
|
||||
float4 _var5 = mul( float4(_var2.xyz,1), g_cFlashlightWorldToTexture );
|
||||
_var1 = _var5;
|
||||
#endif
|
||||
float4 _var6 = float4( GetVertexAttenForLight( _var2, 0 ),
|
||||
GetVertexAttenForLight( _var2, 1 ),
|
||||
GetVertexAttenForLight( _var2, 2 ),
|
||||
GetVertexAttenForLight( _var2, 3 ) );
|
||||
Out.vProjPos = _var4;
|
||||
Out.vTexCoord_0 = In.vTexCoord_0;
|
||||
Out.vTexCoord_1 = In.vTexCoord_1;
|
||||
Out.vTexCoord_2 = _var1;
|
||||
Out.vTexCoord_3 = _var0;
|
||||
Out.vTexCoord_4 = _var2;
|
||||
Out.vColor_0 = In.vColor_0;
|
||||
Out.vTexCoord_1 = _var2;
|
||||
Out.vTexCoord_2 = _var3;
|
||||
Out.vTexCoord_3 = _var4;
|
||||
Out.vTexCoord_4 = _var1;
|
||||
Out.vColor_0 = _var6;
|
||||
return Out;
|
||||
}
|
BIN
sp/game/sdk2013CE/sound/sound.cache
Normal file
BIN
sp/game/sdk2013CE/sound/sound.cache
Normal file
Binary file not shown.
0
sp/game/sdk2013CE/stats.txt
Normal file
0
sp/game/sdk2013CE/stats.txt
Normal file
BIN
sp/game/sdk2013CE/voice_ban.dt
Normal file
BIN
sp/game/sdk2013CE/voice_ban.dt
Normal file
Binary file not shown.
1
sp/run.bat
Normal file
1
sp/run.bat
Normal file
|
@ -0,0 +1 @@
|
|||
@start /D "%ProgramFiles(x86)%\Steam\steamapps\common\Source SDK Base 2013 Singleplayer" hl2.exe -dev -console -novid -game "%CD%\game\sdk2013CE"
|
1
sp/shaderedit.bat
Normal file
1
sp/shaderedit.bat
Normal file
|
@ -0,0 +1 @@
|
|||
@start /D "%ProgramFiles(x86)%\Steam\steamapps\common\Source SDK Base 2013 Singleplayer\" hl2.exe -dev -console -novid -game "%CD%\game\sdk2013CE" -shaderedit -window -height 720
|
|
@ -1,3 +1,3 @@
|
|||
devtools\bin\vpc.exe /2013 /hl2 /episodic +sdk2013CE /mksln sdk2013ce.sln
|
||||
devtools\bin\vpc.exe /2013 /v /hl2 /episodic +sdk2013CE /mksln sdk2013ce.sln
|
||||
|
||||
pause
|
|
@ -9,6 +9,9 @@
|
|||
//
|
||||
// env_soundscape: controls what sound script an area uses.
|
||||
//
|
||||
// BUGS FIXED (Community Edition):
|
||||
// - Unstoppable sounds
|
||||
// -
|
||||
//=============================================================================//
|
||||
|
||||
#include "cbase.h"
|
||||
|
@ -37,7 +40,7 @@
|
|||
|
||||
//-----------------------------------------------------------------------------
|
||||
// Purpose: Compute a suitable attenuation value given an audible radius
|
||||
// Input : radius -
|
||||
// Input : radius -
|
||||
// playEverywhere - (disable attenuation)
|
||||
//-----------------------------------------------------------------------------
|
||||
#define REFERENCE_dB 60.0
|
||||
|
@ -76,7 +79,7 @@ static soundlevel_t ComputeSoundlevel( float radius, bool playEverywhere )
|
|||
// SEE BELOW (in the typedescription for the class)
|
||||
typedef struct dynpitchvol
|
||||
{
|
||||
// NOTE: do not change the order of these parameters
|
||||
// NOTE: do not change the order of these parameters
|
||||
// NOTE: unless you also change order of rgdpvpreset array elements!
|
||||
int preset;
|
||||
|
||||
|
@ -93,7 +96,7 @@ typedef struct dynpitchvol
|
|||
// Low Frequency Oscillator
|
||||
int lfotype; // 0) off 1) square 2) triangle 3) random
|
||||
int lforate; // 0 - 1000, how fast lfo osciallates
|
||||
|
||||
|
||||
int lfomodpitch; // 0-100 mod of current pitch. 0 is off.
|
||||
int lfomodvol; // 0-100 mod of current volume. 0 is off.
|
||||
|
||||
|
@ -102,7 +105,7 @@ typedef struct dynpitchvol
|
|||
|
||||
int cspincount;
|
||||
|
||||
int pitch;
|
||||
int pitch;
|
||||
int spinupsav;
|
||||
int spindownsav;
|
||||
int pitchfrac;
|
||||
|
@ -122,11 +125,11 @@ typedef struct dynpitchvol
|
|||
|
||||
// presets for runtime pitch and vol modulation of ambient sounds
|
||||
|
||||
dynpitchvol_t rgdpvpreset[CDPVPRESETMAX] =
|
||||
dynpitchvol_t rgdpvpreset[CDPVPRESETMAX] =
|
||||
{
|
||||
// pitch pstart spinup spindwn volrun volstrt fadein fadeout lfotype lforate modptch modvol cspnup
|
||||
{1, 255, 75, 95, 95, 10, 1, 50, 95, 0, 0, 0, 0, 0, 0,0,0,0,0,0,0,0,0,0},
|
||||
{2, 255, 85, 70, 88, 10, 1, 20, 88, 0, 0, 0, 0, 0, 0,0,0,0,0,0,0,0,0,0},
|
||||
// pitch pstart spinup spindwn volrun volstrt fadein fadeout lfotype lforate modptch modvol cspnup
|
||||
{1, 255, 75, 95, 95, 10, 1, 50, 95, 0, 0, 0, 0, 0, 0,0,0,0,0,0,0,0,0,0},
|
||||
{2, 255, 85, 70, 88, 10, 1, 20, 88, 0, 0, 0, 0, 0, 0,0,0,0,0,0,0,0,0,0},
|
||||
{3, 255, 100, 50, 75, 10, 1, 10, 75, 0, 0, 0, 0, 0, 0,0,0,0,0,0,0,0,0,0},
|
||||
{4, 100, 100, 0, 0, 10, 1, 90, 90, 0, 0, 0, 0, 0, 0,0,0,0,0,0,0,0,0,0},
|
||||
{5, 100, 100, 0, 0, 10, 1, 80, 80, 0, 0, 0, 0, 0, 0,0,0,0,0,0,0,0,0,0},
|
||||
|
@ -147,10 +150,10 @@ dynpitchvol_t rgdpvpreset[CDPVPRESETMAX] =
|
|||
{20,255, 75, 97, 90, 10, 1, 50, 90, 1, 40, 50, 0, 0, 0,0,0,0,0,0,0,0,0,0},
|
||||
{21,100, 100, 0, 0, 10, 1, 30, 50, 3, 15, 20, 0, 0, 0,0,0,0,0,0,0,0,0,0},
|
||||
{22,160, 160, 0, 0, 10, 1, 50, 50, 3, 500, 25, 0, 0, 0,0,0,0,0,0,0,0,0,0},
|
||||
{23,255, 75, 88, 0, 10, 1, 40, 0, 0, 0, 0, 0, 5, 0,0,0,0,0,0,0,0,0,0},
|
||||
{24,200, 20, 95, 70, 10, 1, 70, 70, 3, 20, 50, 0, 0, 0,0,0,0,0,0,0,0,0,0},
|
||||
{25,180, 100, 50, 60, 10, 1, 40, 60, 2, 90, 100, 100, 0, 0,0,0,0,0,0,0,0,0,0},
|
||||
{26,60, 60, 0, 0, 10, 1, 40, 70, 3, 80, 20, 50, 0, 0,0,0,0,0,0,0,0,0,0},
|
||||
{23,255, 75, 88, 0, 10, 1, 40, 0, 0, 0, 0, 0, 5, 0,0,0,0,0,0,0,0,0,0},
|
||||
{24,200, 20, 95, 70, 10, 1, 70, 70, 3, 20, 50, 0, 0, 0,0,0,0,0,0,0,0,0,0},
|
||||
{25,180, 100, 50, 60, 10, 1, 40, 60, 2, 90, 100, 100, 0, 0,0,0,0,0,0,0,0,0,0},
|
||||
{26,60, 60, 0, 0, 10, 1, 40, 70, 3, 80, 20, 50, 0, 0,0,0,0,0,0,0,0,0,0},
|
||||
{27,128, 90, 10, 10, 10, 1, 20, 40, 1, 5, 10, 20, 0, 0,0,0,0,0,0,0,0,0,0}
|
||||
};
|
||||
|
||||
|
@ -188,7 +191,7 @@ public:
|
|||
float m_radius;
|
||||
float m_flMaxRadius;
|
||||
soundlevel_t m_iSoundLevel; // dB value
|
||||
dynpitchvol_t m_dpv;
|
||||
dynpitchvol_t m_dpv;
|
||||
|
||||
bool m_fActive; // only true when the entity is playing a looping sound
|
||||
bool m_fLooping; // true when the sound played will loop
|
||||
|
@ -261,7 +264,7 @@ void CAmbientGeneric::Spawn( void )
|
|||
SetSolid( SOLID_NONE );
|
||||
SetMoveType( MOVETYPE_NONE );
|
||||
|
||||
// Set up think function for dynamic modification
|
||||
// Set up think function for dynamic modification
|
||||
// of ambient sound's pitch or volume. Don't
|
||||
// start thinking yet.
|
||||
|
||||
|
@ -302,7 +305,7 @@ void CAmbientGeneric::ComputeMaxAudibleDistance( )
|
|||
return;
|
||||
}
|
||||
|
||||
// Sadly, there's no direct way of getting at this.
|
||||
// Sadly, there's no direct way of getting at this.
|
||||
// We have to do an interative computation.
|
||||
float flGain = enginesound->GetDistGainFromSoundLevel( m_iSoundLevel, m_radius );
|
||||
if ( flGain <= MIN_AUDIBLE_VOLUME )
|
||||
|
@ -311,7 +314,7 @@ void CAmbientGeneric::ComputeMaxAudibleDistance( )
|
|||
return;
|
||||
}
|
||||
|
||||
float flMinRadius = m_radius;
|
||||
float flMinRadius = m_radius;
|
||||
float flMaxRadius = m_radius * 2;
|
||||
while ( true )
|
||||
{
|
||||
|
@ -410,10 +413,13 @@ void CAmbientGeneric::InputFadeOut( inputdata_t &inputdata )
|
|||
|
||||
m_dpv.fadeout = inputdata.value.Float();
|
||||
|
||||
// enforce limits
|
||||
if (m_dpv.fadeout > 100) m_dpv.fadeout = 100;
|
||||
if (m_dpv.fadeout < 0) m_dpv.fadeout = 0;
|
||||
|
||||
|
||||
if (m_dpv.fadeout > 0)
|
||||
// fadeout = 0x6400 / fadeout * rate (rate is 5Hz typically)
|
||||
m_dpv.fadeout = ( 100 << 8 ) / ( m_dpv.fadeout * AMBIENT_GENERIC_UPDATE_RATE );
|
||||
|
||||
SetNextThink( gpGlobals->curtime + 0.1f );
|
||||
|
@ -431,9 +437,13 @@ void CAmbientGeneric::Precache( void )
|
|||
}
|
||||
}
|
||||
|
||||
// if not starting silent
|
||||
if ( !FBitSet (m_spawnflags, SF_AMBIENT_SOUND_START_SILENT ) )
|
||||
{
|
||||
// start the sound ASAP
|
||||
|
||||
// FIXME: BUG? VDC claims that non-start-silent
|
||||
// looping sounds can't be controlled
|
||||
if (m_fLooping)
|
||||
m_fActive = true;
|
||||
}
|
||||
|
@ -453,6 +463,7 @@ void CAmbientGeneric::Activate( void )
|
|||
{
|
||||
if (m_sSourceEntName != NULL_STRING)
|
||||
{
|
||||
// search for source entity
|
||||
m_hSoundSource = gEntList.FindEntityByName( NULL, m_sSourceEntName );
|
||||
if ( m_hSoundSource != NULL )
|
||||
{
|
||||
|
@ -474,12 +485,13 @@ void CAmbientGeneric::Activate( void )
|
|||
}
|
||||
}
|
||||
|
||||
// DIRTY FILTHY HACKS
|
||||
#ifdef PORTAL
|
||||
// This is the only way we can silence the radio sound from the first room without touching them map -- jdw
|
||||
if ( PortalGameRules() && PortalGameRules()->ShouldRemoveRadio() )
|
||||
{
|
||||
if ( V_strcmp( STRING( gpGlobals->mapname ), "testchmb_a_00" ) == 0 ||
|
||||
V_strcmp( STRING( gpGlobals->mapname ), "testchmb_a_11" ) == 0 ||
|
||||
{
|
||||
if ( V_strcmp( STRING( gpGlobals->mapname ), "testchmb_a_00" ) == 0 ||
|
||||
V_strcmp( STRING( gpGlobals->mapname ), "testchmb_a_11" ) == 0 ||
|
||||
V_strcmp( STRING( gpGlobals->mapname ), "testchmb_a_14" ) == 0 )
|
||||
{
|
||||
if ( V_strcmp( STRING( GetEntityName() ), "radio_sound" ) == 0 )
|
||||
|
@ -498,15 +510,15 @@ void CAmbientGeneric::Activate( void )
|
|||
// If we are loading a saved game, we can't write into the init/signon buffer here, so just issue
|
||||
// as a regular sound message...
|
||||
if ( gpGlobals->eLoadType == MapLoad_Transition ||
|
||||
gpGlobals->eLoadType == MapLoad_LoadGame ||
|
||||
gpGlobals->eLoadType == MapLoad_LoadGame ||
|
||||
g_pGameRules->InRoundRestart() )
|
||||
{
|
||||
flags = SND_NOFLAGS;
|
||||
}
|
||||
|
||||
// Tracker 76119: 8/12/07 ywb:
|
||||
|
||||
// Tracker 76119: 8/12/07 ywb:
|
||||
// Make sure pitch and volume are set up to the correct value (especially after restoring a .sav file)
|
||||
flags |= ( SND_CHANGE_PITCH | SND_CHANGE_VOL );
|
||||
flags |= ( SND_CHANGE_PITCH | SND_CHANGE_VOL );
|
||||
|
||||
// Don't bother sending over to client if volume is zero, though
|
||||
if ( m_dpv.vol > 0 )
|
||||
|
@ -546,7 +558,7 @@ void CAmbientGeneric::SetTransmit( CCheckTransmitInfo *pInfo, bool bAlways )
|
|||
}
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
// Purpose:
|
||||
// Purpose:
|
||||
//-----------------------------------------------------------------------------
|
||||
void CAmbientGeneric::UpdateOnRemove( void )
|
||||
{
|
||||
|
@ -566,7 +578,7 @@ void CAmbientGeneric::UpdateOnRemove( void )
|
|||
//-----------------------------------------------------------------------------
|
||||
void CAmbientGeneric::RampThink( void )
|
||||
{
|
||||
int pitch = m_dpv.pitch;
|
||||
int pitch = m_dpv.pitch;
|
||||
int vol = m_dpv.vol;
|
||||
int flags = 0;
|
||||
int fChanged = 0; // false if pitch and vol remain unchanged this round
|
||||
|
@ -588,7 +600,7 @@ void CAmbientGeneric::RampThink( void )
|
|||
m_dpv.pitchfrac -= m_dpv.spindown;
|
||||
|
||||
pitch = m_dpv.pitchfrac >> 8;
|
||||
|
||||
|
||||
if (pitch > m_dpv.pitchrun)
|
||||
{
|
||||
pitch = m_dpv.pitchrun;
|
||||
|
@ -602,7 +614,7 @@ void CAmbientGeneric::RampThink( void )
|
|||
|
||||
// shut sound off
|
||||
SendSound( SND_STOP );
|
||||
|
||||
|
||||
// return without setting m_flNextThink
|
||||
return;
|
||||
}
|
||||
|
@ -643,20 +655,20 @@ void CAmbientGeneric::RampThink( void )
|
|||
m_dpv.vol = vol;
|
||||
m_dpv.volfrac = vol << 8;
|
||||
m_dpv.fadeout = 0; // done with ramp down
|
||||
|
||||
|
||||
// shut sound off
|
||||
SendSound( SND_STOP );
|
||||
|
||||
|
||||
// return without setting m_flNextThink
|
||||
return;
|
||||
}
|
||||
|
||||
if (vol > 100)
|
||||
if (vol > 100)
|
||||
{
|
||||
vol = 100;
|
||||
m_dpv.volfrac = vol << 8;
|
||||
}
|
||||
if (vol < 1)
|
||||
if (vol < 1)
|
||||
{
|
||||
vol = 1;
|
||||
m_dpv.volfrac = vol << 8;
|
||||
|
@ -702,14 +714,14 @@ void CAmbientGeneric::RampThink( void )
|
|||
m_dpv.lfomult = 255;
|
||||
else
|
||||
m_dpv.lfomult = 0;
|
||||
|
||||
|
||||
break;
|
||||
case LFO_RANDOM:
|
||||
if (pos == 255)
|
||||
m_dpv.lfomult = random->RandomInt(0, 255);
|
||||
break;
|
||||
case LFO_TRIANGLE:
|
||||
default:
|
||||
default:
|
||||
m_dpv.lfomult = pos;
|
||||
break;
|
||||
}
|
||||
|
@ -724,7 +736,7 @@ void CAmbientGeneric::RampThink( void )
|
|||
if (pitch > 255) pitch = 255;
|
||||
if (pitch < 1) pitch = 1;
|
||||
|
||||
|
||||
|
||||
fChanged |= (prev != pitch);
|
||||
flags |= SND_CHANGE_PITCH;
|
||||
}
|
||||
|
@ -738,7 +750,7 @@ void CAmbientGeneric::RampThink( void )
|
|||
|
||||
if (vol > 100) vol = 100;
|
||||
if (vol < 0) vol = 0;
|
||||
|
||||
|
||||
fChanged |= (prev != vol);
|
||||
flags |= SND_CHANGE_VOL;
|
||||
}
|
||||
|
@ -748,7 +760,7 @@ void CAmbientGeneric::RampThink( void )
|
|||
// Send update to playing sound only if we actually changed
|
||||
// pitch or volume in this routine.
|
||||
|
||||
if (flags && fChanged)
|
||||
if (flags && fChanged)
|
||||
{
|
||||
if (pitch == PITCH_NORM)
|
||||
pitch = PITCH_NORM + 1; // don't send 'no pitch' !
|
||||
|
@ -756,7 +768,7 @@ void CAmbientGeneric::RampThink( void )
|
|||
CBaseEntity* pSoundSource = m_hSoundSource;
|
||||
if (pSoundSource)
|
||||
{
|
||||
UTIL_EmitAmbientSound(pSoundSource->GetSoundSourceIndex(), pSoundSource->GetAbsOrigin(),
|
||||
UTIL_EmitAmbientSound(pSoundSource->GetSoundSourceIndex(), pSoundSource->GetAbsOrigin(),
|
||||
STRING( m_iszSound ), (vol * 0.01), m_iSoundLevel, flags, pitch);
|
||||
}
|
||||
}
|
||||
|
@ -808,15 +820,15 @@ void CAmbientGeneric::InitModulationParms(void)
|
|||
}
|
||||
|
||||
m_dpv.fadein = m_dpv.fadeinsav;
|
||||
m_dpv.fadeout = 0;
|
||||
|
||||
m_dpv.fadeout = 0;
|
||||
|
||||
if (m_dpv.fadein)
|
||||
m_dpv.vol = m_dpv.volstart;
|
||||
else
|
||||
m_dpv.vol = m_dpv.volrun;
|
||||
|
||||
m_dpv.spinup = m_dpv.spinupsav;
|
||||
m_dpv.spindown = 0;
|
||||
m_dpv.spindown = 0;
|
||||
|
||||
if (m_dpv.spinup)
|
||||
m_dpv.pitch = m_dpv.pitchstart;
|
||||
|
@ -833,8 +845,8 @@ void CAmbientGeneric::InitModulationParms(void)
|
|||
m_dpv.lforate = abs(m_dpv.lforate);
|
||||
|
||||
m_dpv.cspincount = 1;
|
||||
|
||||
if (m_dpv.cspinup)
|
||||
|
||||
if (m_dpv.cspinup)
|
||||
{
|
||||
pitchinc = (255 - m_dpv.pitchstart) / m_dpv.cspinup;
|
||||
|
||||
|
@ -857,8 +869,8 @@ void CAmbientGeneric::InputPlaySound( inputdata_t &inputdata )
|
|||
if (!m_fActive)
|
||||
{
|
||||
//Adrian: Stop our current sound before starting a new one!
|
||||
SendSound( SND_STOP );
|
||||
|
||||
SendSound( SND_STOP );
|
||||
|
||||
ToggleSound();
|
||||
}
|
||||
}
|
||||
|
@ -879,26 +891,34 @@ void CAmbientGeneric::SendSound( SoundFlags_t flags)
|
|||
{
|
||||
char *szSoundFile = (char *)STRING( m_iszSound );
|
||||
CBaseEntity* pSoundSource = m_hSoundSource;
|
||||
if ( pSoundSource )
|
||||
// TODO: Added VDC fixes here, test them
|
||||
if ( pSoundSource != NULL )
|
||||
{
|
||||
if ( flags == SND_STOP )
|
||||
{
|
||||
UTIL_EmitAmbientSound(pSoundSource->GetSoundSourceIndex(), pSoundSource->GetAbsOrigin(), szSoundFile,
|
||||
UTIL_EmitAmbientSound(pSoundSource->GetSoundSourceIndex(), pSoundSource->GetAbsOrigin(), szSoundFile,
|
||||
0, SNDLVL_NONE, flags, 0);
|
||||
m_fActive = false;
|
||||
}
|
||||
else
|
||||
{
|
||||
UTIL_EmitAmbientSound(pSoundSource->GetSoundSourceIndex(), pSoundSource->GetAbsOrigin(), szSoundFile,
|
||||
UTIL_EmitAmbientSound(pSoundSource->GetSoundSourceIndex(), pSoundSource->GetAbsOrigin(), szSoundFile,
|
||||
(m_dpv.vol * 0.01), m_iSoundLevel, flags, m_dpv.pitch);
|
||||
|
||||
// Keep active if looping sound
|
||||
// (fix from Valve Developer Community)
|
||||
if (m_fLooping)
|
||||
m_fActive = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
if ( ( flags == SND_STOP ) &&
|
||||
if ( ( flags == SND_STOP ) &&
|
||||
( m_nSoundSourceEntIndex != -1 ) )
|
||||
{
|
||||
UTIL_EmitAmbientSound(m_nSoundSourceEntIndex, GetAbsOrigin(), szSoundFile,
|
||||
UTIL_EmitAmbientSound(m_nSoundSourceEntIndex, GetAbsOrigin(), szSoundFile,
|
||||
0, SNDLVL_NONE, flags, 0);
|
||||
m_fActive = false;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -917,15 +937,15 @@ void CAmbientGeneric::InputToggleSound( inputdata_t &inputdata )
|
|||
// Purpose: Turns an ambient sound on or off. If the ambient is a looping sound,
|
||||
// mark sound as active (m_fActive) if it's playing, innactive if not.
|
||||
// If the sound is not a looping sound, never mark it as active.
|
||||
// Input : pActivator -
|
||||
// pCaller -
|
||||
// useType -
|
||||
// value -
|
||||
// Input : pActivator -
|
||||
// pCaller -
|
||||
// useType -
|
||||
// value -
|
||||
//-----------------------------------------------------------------------------
|
||||
void CAmbientGeneric::ToggleSound()
|
||||
{
|
||||
// m_fActive is true only if a looping sound is playing.
|
||||
|
||||
|
||||
if ( m_fActive )
|
||||
{// turn sound off
|
||||
|
||||
|
@ -935,12 +955,12 @@ void CAmbientGeneric::ToggleSound()
|
|||
// incremental spinup to max pitch
|
||||
|
||||
if (m_dpv.cspincount <= m_dpv.cspinup)
|
||||
{
|
||||
{
|
||||
int pitchinc;
|
||||
|
||||
// start a new spinup
|
||||
m_dpv.cspincount++;
|
||||
|
||||
|
||||
pitchinc = (255 - m_dpv.pitchstart) / m_dpv.cspinup;
|
||||
|
||||
m_dpv.spinup = m_dpv.spinupsav;
|
||||
|
@ -951,12 +971,12 @@ void CAmbientGeneric::ToggleSound()
|
|||
|
||||
SetNextThink( gpGlobals->curtime + 0.1f );
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
else
|
||||
{
|
||||
m_fActive = false;
|
||||
|
||||
|
||||
// HACKHACK - this makes the code in Precache() work properly after a save/restore
|
||||
m_spawnflags |= SF_AMBIENT_SOUND_START_SILENT;
|
||||
|
||||
|
@ -976,7 +996,7 @@ void CAmbientGeneric::ToggleSound()
|
|||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
else
|
||||
{// turn sound on
|
||||
|
||||
// only toggle if this is a looping sound. If not looping, each
|
||||
|
@ -991,7 +1011,7 @@ void CAmbientGeneric::ToggleSound()
|
|||
// shut sound off now - may be interrupting a long non-looping sound
|
||||
SendSound( SND_STOP ); // stop sound
|
||||
}
|
||||
|
||||
|
||||
// init all ramp params for startup
|
||||
|
||||
InitModulationParms();
|
||||
|
@ -1000,7 +1020,7 @@ void CAmbientGeneric::ToggleSound()
|
|||
|
||||
SetNextThink( gpGlobals->curtime + 0.1f );
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
@ -1020,15 +1040,15 @@ bool CAmbientGeneric::KeyValue( const char *szKeyName, const char *szValue )
|
|||
else if (FStrEq(szKeyName, "pitch"))
|
||||
{
|
||||
m_dpv.pitchrun = atoi(szValue);
|
||||
|
||||
|
||||
if (m_dpv.pitchrun > 255) m_dpv.pitchrun = 255;
|
||||
if (m_dpv.pitchrun < 0) m_dpv.pitchrun = 0;
|
||||
}
|
||||
}
|
||||
// pitchstart
|
||||
else if (FStrEq(szKeyName, "pitchstart"))
|
||||
{
|
||||
m_dpv.pitchstart = atoi(szValue);
|
||||
|
||||
|
||||
if (m_dpv.pitchstart > 255) m_dpv.pitchstart = 255;
|
||||
if (m_dpv.pitchstart < 0) m_dpv.pitchstart = 0;
|
||||
}
|
||||
|
@ -1036,19 +1056,19 @@ bool CAmbientGeneric::KeyValue( const char *szKeyName, const char *szValue )
|
|||
else if (FStrEq(szKeyName, "spinup"))
|
||||
{
|
||||
m_dpv.spinup = atoi(szValue);
|
||||
|
||||
|
||||
if (m_dpv.spinup > 100) m_dpv.spinup = 100;
|
||||
if (m_dpv.spinup < 0) m_dpv.spinup = 0;
|
||||
|
||||
if (m_dpv.spinup > 0)
|
||||
m_dpv.spinup = (101 - m_dpv.spinup) * 64;
|
||||
m_dpv.spinupsav = m_dpv.spinup;
|
||||
}
|
||||
}
|
||||
// spindown
|
||||
else if (FStrEq(szKeyName, "spindown"))
|
||||
{
|
||||
m_dpv.spindown = atoi(szValue);
|
||||
|
||||
|
||||
if (m_dpv.spindown > 100) m_dpv.spindown = 100;
|
||||
if (m_dpv.spindown < 0) m_dpv.spindown = 0;
|
||||
|
||||
|
@ -1063,14 +1083,14 @@ bool CAmbientGeneric::KeyValue( const char *szKeyName, const char *szValue )
|
|||
|
||||
if (m_dpv.volstart > 10) m_dpv.volstart = 10;
|
||||
if (m_dpv.volstart < 0) m_dpv.volstart = 0;
|
||||
|
||||
|
||||
m_dpv.volstart *= 10; // 0 - 100
|
||||
}
|
||||
// legacy fadein
|
||||
else if (FStrEq(szKeyName, "fadein"))
|
||||
{
|
||||
m_dpv.fadein = atoi(szValue);
|
||||
|
||||
|
||||
if (m_dpv.fadein > 100) m_dpv.fadein = 100;
|
||||
if (m_dpv.fadein < 0) m_dpv.fadein = 0;
|
||||
|
||||
|
@ -1082,7 +1102,7 @@ bool CAmbientGeneric::KeyValue( const char *szKeyName, const char *szValue )
|
|||
else if (FStrEq(szKeyName, "fadeout"))
|
||||
{
|
||||
m_dpv.fadeout = atoi(szValue);
|
||||
|
||||
|
||||
if (m_dpv.fadeout > 100) m_dpv.fadeout = 100;
|
||||
if (m_dpv.fadeout < 0) m_dpv.fadeout = 0;
|
||||
|
||||
|
@ -1124,7 +1144,7 @@ bool CAmbientGeneric::KeyValue( const char *szKeyName, const char *szValue )
|
|||
else if (FStrEq(szKeyName, "lforate"))
|
||||
{
|
||||
m_dpv.lforate = atoi(szValue);
|
||||
|
||||
|
||||
if (m_dpv.lforate > 1000) m_dpv.lforate = 1000;
|
||||
if (m_dpv.lforate < 0) m_dpv.lforate = 0;
|
||||
|
||||
|
@ -1171,11 +1191,11 @@ int fSentencesInit = false;
|
|||
// ===================== SENTENCE GROUPS, MAIN ROUTINES ========================
|
||||
|
||||
// given sentence group index, play random sentence for given entity.
|
||||
// returns sentenceIndex - which sentence was picked
|
||||
// Ipick is only needed if you plan on stopping the sound before playback is done (see SENTENCEG_Stop).
|
||||
// returns sentenceIndex - which sentence was picked
|
||||
// Ipick is only needed if you plan on stopping the sound before playback is done (see SENTENCEG_Stop).
|
||||
// sentenceIndex can be used to find the name/length of the sentence
|
||||
|
||||
int SENTENCEG_PlayRndI(edict_t *entity, int isentenceg,
|
||||
int SENTENCEG_PlayRndI(edict_t *entity, int isentenceg,
|
||||
float volume, soundlevel_t soundlevel, int flags, int pitch)
|
||||
{
|
||||
char name[64];
|
||||
|
@ -1241,7 +1261,7 @@ void SENTENCEG_PlaySentenceIndex( edict_t *entity, int iSentenceIndex, float vol
|
|||
}
|
||||
|
||||
|
||||
int SENTENCEG_PlayRndSz(edict_t *entity, const char *szgroupname,
|
||||
int SENTENCEG_PlayRndSz(edict_t *entity, const char *szgroupname,
|
||||
float volume, soundlevel_t soundlevel, int flags, int pitch)
|
||||
{
|
||||
char name[64];
|
||||
|
@ -1274,7 +1294,7 @@ int SENTENCEG_PlayRndSz(edict_t *entity, const char *szgroupname,
|
|||
|
||||
// play sentences in sequential order from sentence group. Reset after last sentence.
|
||||
|
||||
int SENTENCEG_PlaySequentialSz(edict_t *entity, const char *szgroupname,
|
||||
int SENTENCEG_PlaySequentialSz(edict_t *entity, const char *szgroupname,
|
||||
float volume, soundlevel_t soundlevel, int flags, int pitch, int ipick, int freset)
|
||||
{
|
||||
char name[64];
|
||||
|
@ -1298,7 +1318,7 @@ int SENTENCEG_PlaySequentialSz(edict_t *entity, const char *szgroupname,
|
|||
CBaseEntity::EmitSentenceByIndex( filter, ENTINDEX(entity), CHAN_VOICE, sentenceIndex, volume, soundlevel, flags, pitch );
|
||||
return sentenceIndex;
|
||||
}
|
||||
|
||||
|
||||
return -1;
|
||||
}
|
||||
|
||||
|
@ -1311,7 +1331,7 @@ void SENTENCEG_Stop(edict_t *entity, int isentenceg, int ipick)
|
|||
{
|
||||
char buffer[64];
|
||||
char sznum[8];
|
||||
|
||||
|
||||
if (!fSentencesInit)
|
||||
return;
|
||||
|
||||
|
@ -1448,7 +1468,7 @@ int UTIL_EmitGroupnameSuit(edict_t *entity, const char *groupname)
|
|||
}
|
||||
|
||||
// ===================== MATERIAL TYPE DETECTION, MAIN ROUTINES ========================
|
||||
//
|
||||
//
|
||||
// Used to detect the texture the player is standing on, map the
|
||||
// texture name to a material type. Play footstep sound based
|
||||
// on material type.
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
//========= Copyright Valve Corporation, All rights reserved. ============//
|
||||
//
|
||||
// Purpose:
|
||||
// Purpose:
|
||||
//
|
||||
//=============================================================================//
|
||||
|
||||
|
@ -69,15 +69,15 @@ void WaveTrace( char const *wavname, char const *funcname )
|
|||
// Make sure we only show the message once
|
||||
if ( UTL_INVAL_SYMBOL == s_WaveTrace.Find( wavname ) )
|
||||
{
|
||||
DevMsg( "%s directly referenced wave %s (should use game_sounds.txt system instead)\n",
|
||||
DevMsg( "%s directly referenced wave %s (should use game_sounds.txt system instead)\n",
|
||||
funcname, wavname );
|
||||
s_WaveTrace.AddString( wavname );
|
||||
}
|
||||
}
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
// Purpose:
|
||||
// Input : &src -
|
||||
// Purpose:
|
||||
// Input : &src -
|
||||
//-----------------------------------------------------------------------------
|
||||
EmitSound_t::EmitSound_t( const CSoundParameters &src )
|
||||
{
|
||||
|
@ -131,7 +131,7 @@ void Hack_FixEscapeChars( char *str )
|
|||
}
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
// Purpose:
|
||||
// Purpose:
|
||||
//-----------------------------------------------------------------------------
|
||||
class CSoundEmitterSystem : public CBaseGameSystem
|
||||
{
|
||||
|
@ -337,7 +337,7 @@ public:
|
|||
FinishLog();
|
||||
#endif
|
||||
}
|
||||
|
||||
|
||||
void InternalPrecacheWaves( int soundIndex )
|
||||
{
|
||||
CSoundParametersInternal *internal = soundemitterbase->InternalGetParametersForSound( soundIndex );
|
||||
|
@ -392,9 +392,9 @@ public:
|
|||
if ( Q_stristr( soundname, ".wav" ) || Q_strstr( soundname, ".mp3" ) )
|
||||
{
|
||||
g_bPermitDirectSoundPrecache = true;
|
||||
|
||||
|
||||
CBaseEntity::PrecacheSound( soundname );
|
||||
|
||||
|
||||
g_bPermitDirectSoundPrecache = false;
|
||||
return SOUNDEMITTER_INVALID_HANDLE;
|
||||
}
|
||||
|
@ -489,14 +489,14 @@ public:
|
|||
}
|
||||
|
||||
#if !defined( CLIENT_DLL )
|
||||
bool bSwallowed = CEnvMicrophone::OnSoundPlayed(
|
||||
entindex,
|
||||
params.soundname,
|
||||
params.soundlevel,
|
||||
params.volume,
|
||||
ep.m_nFlags,
|
||||
params.pitch,
|
||||
ep.m_pOrigin,
|
||||
bool bSwallowed = CEnvMicrophone::OnSoundPlayed(
|
||||
entindex,
|
||||
params.soundname,
|
||||
params.soundlevel,
|
||||
params.volume,
|
||||
ep.m_nFlags,
|
||||
params.pitch,
|
||||
ep.m_pOrigin,
|
||||
ep.m_flSoundTime,
|
||||
ep.m_UtlVecSoundOrigin );
|
||||
if ( bSwallowed )
|
||||
|
@ -511,16 +511,16 @@ public:
|
|||
#endif
|
||||
|
||||
float st = ep.m_flSoundTime;
|
||||
if ( !st &&
|
||||
if ( !st &&
|
||||
params.delay_msec != 0 )
|
||||
{
|
||||
st = gpGlobals->curtime + (float)params.delay_msec / 1000.f;
|
||||
}
|
||||
|
||||
enginesound->EmitSound(
|
||||
filter,
|
||||
entindex,
|
||||
params.channel,
|
||||
enginesound->EmitSound(
|
||||
filter,
|
||||
entindex,
|
||||
params.channel,
|
||||
params.soundname,
|
||||
params.volume,
|
||||
(soundlevel_t)params.soundlevel,
|
||||
|
@ -564,27 +564,27 @@ public:
|
|||
}
|
||||
#endif // STAGING_ONLY
|
||||
|
||||
if ( ep.m_pSoundName &&
|
||||
( Q_stristr( ep.m_pSoundName, ".wav" ) ||
|
||||
Q_stristr( ep.m_pSoundName, ".mp3" ) ||
|
||||
if ( ep.m_pSoundName &&
|
||||
( Q_stristr( ep.m_pSoundName, ".wav" ) ||
|
||||
Q_stristr( ep.m_pSoundName, ".mp3" ) ||
|
||||
ep.m_pSoundName[0] == '!' ) )
|
||||
{
|
||||
#if !defined( CLIENT_DLL )
|
||||
bool bSwallowed = CEnvMicrophone::OnSoundPlayed(
|
||||
entindex,
|
||||
ep.m_pSoundName,
|
||||
ep.m_SoundLevel,
|
||||
ep.m_flVolume,
|
||||
ep.m_nFlags,
|
||||
ep.m_nPitch,
|
||||
ep.m_pOrigin,
|
||||
bool bSwallowed = CEnvMicrophone::OnSoundPlayed(
|
||||
entindex,
|
||||
ep.m_pSoundName,
|
||||
ep.m_SoundLevel,
|
||||
ep.m_flVolume,
|
||||
ep.m_nFlags,
|
||||
ep.m_nPitch,
|
||||
ep.m_pOrigin,
|
||||
ep.m_flSoundTime,
|
||||
ep.m_UtlVecSoundOrigin );
|
||||
if ( bSwallowed )
|
||||
return;
|
||||
#endif
|
||||
|
||||
if ( ep.m_bWarnOnDirectWaveReference &&
|
||||
if ( ep.m_bWarnOnDirectWaveReference &&
|
||||
Q_stristr( ep.m_pSoundName, ".wav" ) )
|
||||
{
|
||||
WaveTrace( ep.m_pSoundName, "Emitsound" );
|
||||
|
@ -596,20 +596,20 @@ public:
|
|||
Msg( "Sound %s was not precached\n", ep.m_pSoundName );
|
||||
}
|
||||
#endif
|
||||
enginesound->EmitSound(
|
||||
filter,
|
||||
entindex,
|
||||
ep.m_nChannel,
|
||||
ep.m_pSoundName,
|
||||
ep.m_flVolume,
|
||||
ep.m_SoundLevel,
|
||||
ep.m_nFlags,
|
||||
ep.m_nPitch,
|
||||
enginesound->EmitSound(
|
||||
filter,
|
||||
entindex,
|
||||
ep.m_nChannel,
|
||||
ep.m_pSoundName,
|
||||
ep.m_flVolume,
|
||||
ep.m_SoundLevel,
|
||||
ep.m_nFlags,
|
||||
ep.m_nPitch,
|
||||
ep.m_nSpecialDSP,
|
||||
ep.m_pOrigin,
|
||||
NULL,
|
||||
NULL,
|
||||
&ep.m_UtlVecSoundOrigin,
|
||||
true,
|
||||
true,
|
||||
ep.m_flSoundTime,
|
||||
ep.m_nSpeakerEntity );
|
||||
if ( ep.m_pflSoundDuration )
|
||||
|
@ -722,7 +722,7 @@ public:
|
|||
byteflags |= CLOSE_CAPTION_GENDER_MALE;
|
||||
}
|
||||
else if ( gender == GENDER_FEMALE )
|
||||
{
|
||||
{
|
||||
byteflags |= CLOSE_CAPTION_GENDER_FEMALE;
|
||||
}
|
||||
}
|
||||
|
@ -835,7 +835,7 @@ public:
|
|||
bool needsCC = !( iFlags & ( SND_STOP | SND_CHANGE_VOL | SND_CHANGE_PITCH ) );
|
||||
|
||||
float soundduration = 0.0f;
|
||||
|
||||
|
||||
if ( duration || needsCC )
|
||||
{
|
||||
soundduration = enginesound->GetSoundDuration( params.soundname );
|
||||
|
@ -886,9 +886,9 @@ public:
|
|||
char const *wavename = soundemitterbase->GetWaveName( params->GetSoundNames()[ i ].symbol );
|
||||
Assert( wavename );
|
||||
|
||||
enginesound->StopSound(
|
||||
entindex,
|
||||
params->GetChannel(),
|
||||
enginesound->StopSound(
|
||||
entindex,
|
||||
params->GetChannel(),
|
||||
wavename );
|
||||
|
||||
TraceEmitSound( "StopSound: '%s' stopped as '%s' (ent %i)\n",
|
||||
|
@ -938,14 +938,14 @@ public:
|
|||
|
||||
// Loop through all registered microphones and tell them the sound was just played
|
||||
// NOTE: This means that pitch shifts/sound changes on the original ambient will not be reflected in the re-broadcasted sound
|
||||
bool bSwallowed = CEnvMicrophone::OnSoundPlayed(
|
||||
entindex,
|
||||
pSample,
|
||||
soundlevel,
|
||||
volume,
|
||||
flags,
|
||||
pitch,
|
||||
&origin,
|
||||
bool bSwallowed = CEnvMicrophone::OnSoundPlayed(
|
||||
entindex,
|
||||
pSample,
|
||||
soundlevel,
|
||||
volume,
|
||||
flags,
|
||||
pitch,
|
||||
&origin,
|
||||
soundtime,
|
||||
dummyorigins );
|
||||
if ( bSwallowed )
|
||||
|
@ -989,7 +989,7 @@ void ReloadSoundEntriesInList( IFileList *pFilesToReload )
|
|||
}
|
||||
#endif
|
||||
|
||||
void S_SoundEmitterSystemFlush( void )
|
||||
void S_SoundEmitterSystemFlush( void )
|
||||
{
|
||||
#if !defined( CLIENT_DLL )
|
||||
if ( !UTIL_IsCommandIssuedByServerAdmin() )
|
||||
|
@ -1025,7 +1025,7 @@ CON_COMMAND_F( sv_soundemitter_flush, "Flushes the sounds.txt system (server onl
|
|||
|
||||
#if !defined(_RETAIL)
|
||||
|
||||
#if !defined( CLIENT_DLL )
|
||||
#if !defined( CLIENT_DLL )
|
||||
|
||||
#if !defined( _XBOX )
|
||||
|
||||
|
@ -1125,7 +1125,7 @@ static int GamesoundCompletion( const char *partial, char commands[ COMMAND_COMP
|
|||
substring = (char *)partial + strlen( cmdname ) + 1;
|
||||
substringLen = strlen(substring);
|
||||
}
|
||||
|
||||
|
||||
for ( int i = soundemitterbase->GetSoundCount()-1; i >= 0 && current < COMMAND_COMPLETION_MAXITEMS; i-- )
|
||||
{
|
||||
const char *pSoundName = soundemitterbase->GetSoundName( i );
|
||||
|
@ -1149,7 +1149,7 @@ static ConCommand Command_Playgamesound( "playgamesound", Playgamesound_f, "Play
|
|||
|
||||
//-----------------------------------------------------------------------------
|
||||
// Purpose: Non-static override for doing the general case of CPASAttenuationFilter( this ), and EmitSound( filter, entindex(), etc. );
|
||||
// Input : *soundname -
|
||||
// Input : *soundname -
|
||||
//-----------------------------------------------------------------------------
|
||||
void CBaseEntity::EmitSound( const char *soundname, float soundtime /*= 0.0f*/, float *duration /*=NULL*/ )
|
||||
{
|
||||
|
@ -1169,7 +1169,7 @@ void CBaseEntity::EmitSound( const char *soundname, float soundtime /*= 0.0f*/,
|
|||
|
||||
//-----------------------------------------------------------------------------
|
||||
// Purpose: Non-static override for doing the general case of CPASAttenuationFilter( this ), and EmitSound( filter, entindex(), etc. );
|
||||
// Input : *soundname -
|
||||
// Input : *soundname -
|
||||
//-----------------------------------------------------------------------------
|
||||
void CBaseEntity::EmitSound( const char *soundname, HSOUNDSCRIPTHANDLE& handle, float soundtime /*= 0.0f*/, float *duration /*=NULL*/ )
|
||||
{
|
||||
|
@ -1188,11 +1188,11 @@ void CBaseEntity::EmitSound( const char *soundname, HSOUNDSCRIPTHANDLE& handle,
|
|||
}
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
// Purpose:
|
||||
// Input : filter -
|
||||
// iEntIndex -
|
||||
// *soundname -
|
||||
// *pOrigin -
|
||||
// Purpose:
|
||||
// Input : filter -
|
||||
// iEntIndex -
|
||||
// *soundname -
|
||||
// *pOrigin -
|
||||
//-----------------------------------------------------------------------------
|
||||
void CBaseEntity::EmitSound( IRecipientFilter& filter, int iEntIndex, const char *soundname, const Vector *pOrigin /*= NULL*/, float soundtime /*= 0.0f*/, float *duration /*=NULL*/ )
|
||||
{
|
||||
|
@ -1213,11 +1213,11 @@ void CBaseEntity::EmitSound( IRecipientFilter& filter, int iEntIndex, const char
|
|||
}
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
// Purpose:
|
||||
// Input : filter -
|
||||
// iEntIndex -
|
||||
// *soundname -
|
||||
// *pOrigin -
|
||||
// Purpose:
|
||||
// Input : filter -
|
||||
// iEntIndex -
|
||||
// *soundname -
|
||||
// *pOrigin -
|
||||
//-----------------------------------------------------------------------------
|
||||
void CBaseEntity::EmitSound( IRecipientFilter& filter, int iEntIndex, const char *soundname, HSOUNDSCRIPTHANDLE& handle, const Vector *pOrigin /*= NULL*/, float soundtime /*= 0.0f*/, float *duration /*=NULL*/ )
|
||||
{
|
||||
|
@ -1235,10 +1235,10 @@ void CBaseEntity::EmitSound( IRecipientFilter& filter, int iEntIndex, const char
|
|||
}
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
// Purpose:
|
||||
// Input : filter -
|
||||
// iEntIndex -
|
||||
// params -
|
||||
// Purpose:
|
||||
// Input : filter -
|
||||
// iEntIndex -
|
||||
// params -
|
||||
//-----------------------------------------------------------------------------
|
||||
void CBaseEntity::EmitSound( IRecipientFilter& filter, int iEntIndex, const EmitSound_t & params )
|
||||
{
|
||||
|
@ -1260,10 +1260,10 @@ void CBaseEntity::EmitSound( IRecipientFilter& filter, int iEntIndex, const Emit
|
|||
}
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
// Purpose:
|
||||
// Input : filter -
|
||||
// iEntIndex -
|
||||
// params -
|
||||
// Purpose:
|
||||
// Input : filter -
|
||||
// iEntIndex -
|
||||
// params -
|
||||
//-----------------------------------------------------------------------------
|
||||
void CBaseEntity::EmitSound( IRecipientFilter& filter, int iEntIndex, const EmitSound_t & params, HSOUNDSCRIPTHANDLE& handle )
|
||||
{
|
||||
|
@ -1285,8 +1285,8 @@ void CBaseEntity::EmitSound( IRecipientFilter& filter, int iEntIndex, const Emit
|
|||
}
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
// Purpose:
|
||||
// Input : *soundname -
|
||||
// Purpose:
|
||||
// Input : *soundname -
|
||||
//-----------------------------------------------------------------------------
|
||||
void CBaseEntity::StopSound( const char *soundname )
|
||||
{
|
||||
|
@ -1303,8 +1303,8 @@ void CBaseEntity::StopSound( const char *soundname )
|
|||
}
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
// Purpose:
|
||||
// Input : *soundname -
|
||||
// Purpose:
|
||||
// Input : *soundname -
|
||||
//-----------------------------------------------------------------------------
|
||||
void CBaseEntity::StopSound( const char *soundname, HSOUNDSCRIPTHANDLE& handle )
|
||||
{
|
||||
|
@ -1321,9 +1321,9 @@ void CBaseEntity::StopSound( const char *soundname, HSOUNDSCRIPTHANDLE& handle )
|
|||
}
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
// Purpose:
|
||||
// Input : iEntIndex -
|
||||
// *soundname -
|
||||
// Purpose:
|
||||
// Input : iEntIndex -
|
||||
// *soundname -
|
||||
//-----------------------------------------------------------------------------
|
||||
void CBaseEntity::StopSound( int iEntIndex, const char *soundname )
|
||||
{
|
||||
|
@ -1347,11 +1347,11 @@ soundlevel_t CBaseEntity::LookupSoundLevel( const char *soundname, HSOUNDSCRIPTH
|
|||
}
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
// Purpose:
|
||||
// Input : *entity -
|
||||
// origin -
|
||||
// flags -
|
||||
// *soundname -
|
||||
// Purpose:
|
||||
// Input : *entity -
|
||||
// origin -
|
||||
// flags -
|
||||
// *soundname -
|
||||
//-----------------------------------------------------------------------------
|
||||
void CBaseEntity::EmitAmbientSound( int entindex, const Vector& origin, const char *soundname, int flags, float soundtime /*= 0.0f*/, float *duration /*=NULL*/ )
|
||||
{
|
||||
|
@ -1375,6 +1375,7 @@ void UTIL_EmitAmbientSound( int entindex, const Vector &vecOrigin, const char *s
|
|||
}
|
||||
#endif // STAGING_ONLY
|
||||
|
||||
// scripted sentances (start with '!')
|
||||
if (samp && *samp == '!')
|
||||
{
|
||||
int sentenceIndex = SENTENCEG_Lookup(samp);
|
||||
|
@ -1384,7 +1385,7 @@ void UTIL_EmitAmbientSound( int entindex, const Vector &vecOrigin, const char *s
|
|||
Q_snprintf( name, sizeof(name), "!%d", sentenceIndex );
|
||||
#if !defined( CLIENT_DLL )
|
||||
engine->EmitAmbientSound( entindex, vecOrigin, name, vol, soundlevel, fFlags, pitch, soundtime );
|
||||
#else
|
||||
#else
|
||||
enginesound->EmitAmbientSound( name, vol, pitch, fFlags, soundtime );
|
||||
#endif
|
||||
if ( duration )
|
||||
|
@ -1426,14 +1427,14 @@ void CBaseEntity::GenderExpandString( char const *in, char *out, int maxlen )
|
|||
bool CBaseEntity::GetParametersForSound( const char *soundname, CSoundParameters ¶ms, const char *actormodel )
|
||||
{
|
||||
gender_t gender = soundemitterbase->GetActorGender( actormodel );
|
||||
|
||||
|
||||
return soundemitterbase->GetParametersForSound( soundname, params, gender );
|
||||
}
|
||||
|
||||
bool CBaseEntity::GetParametersForSound( const char *soundname, HSOUNDSCRIPTHANDLE& handle, CSoundParameters ¶ms, const char *actormodel )
|
||||
{
|
||||
gender_t gender = soundemitterbase->GetActorGender( actormodel );
|
||||
|
||||
|
||||
return soundemitterbase->GetParametersForSoundEx( soundname, handle, params, gender );
|
||||
}
|
||||
|
||||
|
@ -1452,8 +1453,8 @@ void CBaseEntity::PrefetchScriptSound( const char *soundname )
|
|||
}
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
// Purpose:
|
||||
// Input : *soundname -
|
||||
// Purpose:
|
||||
// Input : *soundname -
|
||||
// Output : float
|
||||
//-----------------------------------------------------------------------------
|
||||
float CBaseEntity::GetSoundDuration( const char *soundname, char const *actormodel )
|
||||
|
@ -1462,11 +1463,11 @@ float CBaseEntity::GetSoundDuration( const char *soundname, char const *actormod
|
|||
}
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
// Purpose:
|
||||
// Input : filter -
|
||||
// *token -
|
||||
// duration -
|
||||
// warnifmissing -
|
||||
// Purpose:
|
||||
// Input : filter -
|
||||
// *token -
|
||||
// duration -
|
||||
// warnifmissing -
|
||||
//-----------------------------------------------------------------------------
|
||||
void CBaseEntity::EmitCloseCaption( IRecipientFilter& filter, int entindex, char const *token, CUtlVector< Vector >& soundorigin, float duration, bool warnifmissing /*= false*/ )
|
||||
{
|
||||
|
@ -1486,9 +1487,9 @@ void CBaseEntity::EmitCloseCaption( IRecipientFilter& filter, int entindex, char
|
|||
}
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
// Purpose:
|
||||
// Input : *name -
|
||||
// preload -
|
||||
// Purpose:
|
||||
// Input : *name -
|
||||
// preload -
|
||||
// Output : Returns true on success, false on failure.
|
||||
//-----------------------------------------------------------------------------
|
||||
bool CBaseEntity::PrecacheSound( const char *name )
|
||||
|
@ -1514,11 +1515,10 @@ bool CBaseEntity::PrecacheSound( const char *name )
|
|||
}
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
// Purpose:
|
||||
// Input : *name -
|
||||
// Purpose:
|
||||
// Input : *name -
|
||||
//-----------------------------------------------------------------------------
|
||||
void CBaseEntity::PrefetchSound( const char *name )
|
||||
{
|
||||
enginesound->PrefetchSound( name );
|
||||
}
|
||||
|
||||
|
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
6
sp/src/msbuild.bat
Normal file
6
sp/src/msbuild.bat
Normal file
|
@ -0,0 +1,6 @@
|
|||
@echo off
|
||||
|
||||
:: Version 12.0
|
||||
%ProgramFiles(x86)%\MSBuild\12.0\Bin\msbuild.exe %cd%\sdk2013ce.sln
|
||||
|
||||
pause
|
Loading…
Reference in a new issue