Skip to content
NightFox edited this page Jan 18, 2024 · 20 revisions

Where to get the information from

  • Get surface id via r_infotool 1, or via newbspguy (debug info panel face id item or CTRL+C for selected faces).
  • You can get entity id through through newbspguy (debug info panel entity id item).

Patches are located in modname/luchiki/maps/mapname.patch where modname is the name of the mod (valve for HL), mapname is the name of the target map. Examples are in ref/vk/data/valve/luchiki.

The format is similar to Format of PBR materials, only the keys are different.

You can reload on-the-fly patches via the rt_debug_reload_patches command. You can key in, for example bind g rt_debug_reload_patches.

Features list

Change normal smoothing threshold for the map
{
"_xvk_smoothing_threshold" "50" // angle in degrees, default 45
}
Add normal smoothing for all entity faces
{
"_xvk_ent_id" "id" // target entity, there can be multiple id's with a space
"_xvk_smooth_entire_model" "1" // smooth all faces of the entity
}
Add normal smoothing for faces
{
"_xvk_smoothing_group" "id id" // target faces, can be a set of ids with a space
}
Remove normal smoothing completely for a face near its neighbors
{
"_xvk_smoothing_excluded "id" // target faces, can be a set of ids with a space
}
Remove normal smoothing between faces
{
"_xvk_smoothing_excluded_pairs" "id id" // target faces, can be a set of ids with a space
}
Change texture on the edge
{
"_xvk_surface_id" "id" // target edge, can be a set of ids with a space
"_xvk_material" "materialname" // or existing map texture name
}
Change texture of an entity to a material
{
"_xvk_ent_id" "id"
"_xvk_map_material" "from_texture to_material" // or "from_texture1 to_material1 from_texture2 to_material2"
}
Change texture coordinates on an edge (scale, offset, rotation)
{
"_xvk_surface_id" "id" // target edge, can be a set of ids with a space
"_xvk_tex_rotate" "90" // keep in mind that rotation is not centered and we need to correct the offset after it.
"_xvk_tex_offset" "100 100"
"_xvk_tex_scale" "1 1"
}
Add or change the emissive of texture
{
"_xvk_surface_id" "id" // target edge, can be a set of ids with a space
"_light" "R G B V"
}
Remove edge
{
"_xvk_surface_id" "id" // target edge, can be a set of ids with a space
}
// Alternatively, you can specify an empty texture via "_xvk_texture" ""
Remove all sky surfaces
{
"_xvk_remove_all_sky_surfaces" "1"
}
Add entity
{
"classname" "light" // instead of light it can be any of halflife.fgd, but right now only light sources are supported
"key" "value" // the desired keys to be assigned to the entity
}
Change entity
{
"_xvk_ent_id" "id" // target entity, some light source, could be multiple ids with a space
"_light" "R G B V" // overwrite the light parameters with your own
"origin" "X Y Z" // change the entity's position
}
Change sun solid angle
{
"_xvk_ent_id" "id" // target light_environment entity, could be multiple ids with a space
"_xvk_solid_angle" "V" // angle in steradians (adjusts the blurring of shadows from light_environment)
}
Move the func-brush entity
{
"_xvk_ent_id" "id" // target entity, there can be multiple id's with a space
"origin" "X Y Z" // change the entity's position (relative)
}
Remove entity
{
"_xvk_ent_id" "id" // target entity, there can be multiple id's with a space
}
Change the radius of the light source to pass through the interfering edges
{
"_xvk_ent_id" "id" // the target entity of the light, there can be multiple id's with a space
"_xvk_radius" "100" // radius value, the "radius" key will be ignored (see #259)
}
Change rendermode
{
"_xvk_ent_id" "id" // the target entity, there can be multiple id's with a space
"rendermode" "0" // number of rendermode (0: "Normal", 1: "Color", 2: "Texture", 3: "Glow", 4: "Solid", 5: "Additive")
}
Clone this wiki locally