Automating custom settings in a custom campaign


(taw_m0nsta) #21

Thanks! Will look at it. In your screenshot it shows that the building still has a shadow, and the building in the background is a bit too light, I gues that will look better with 100% black fog from an better distance.


(taw_m0nsta) #22

Yeah found them, and managed to give the trojan the same lights aswel.
There are just 2 thing with the lights, and 1 is the light softness.

When you are in the armadillo driving towards a wall and its close enough, the lights get visble from nothing till full brightness (its on or off). while the hog light is much smoother, like a smooth fade. Any idea how to fix this?

Can anyone describe what these next values/settings do? The last 4 values define the position of the lights.

lightDef {
joint “cam_2”
lightType “standard”
color ( 6 6 6 )
group 0
noSelfShadow
shader “lights/headlights1b”
right ( 0 720 0 )
up ( 0 0 320 )
target ( 916 0 -16 )
offset ( -32 0 0 )
}

Doom3 seems to have more options (not sure if they are relevant to this)
noShadows // This light doesn’t cast shadows
forceShadows // fog, blend, and ambient lights don’t cast shadows by default. This forces them to cast shadows
noPortalFog // This fog volume won’t ever consider a portal fogged out
fogLight // Option to fill with fog from viewer instead of light from center
blendLight // Perform simple blending of the projection, instead of interacting with bumps and textures
ambientLight // An ambient light has non-directional bump mapping and no specular
lightFalloffImage <map> // specifies the image to use for the third axis of projected light volumes

Second thing is the minimum required distance for the lights to become visible on walls, lets say 5 meter. Any idea to extend that up to 10 or 20 meters?


(taw_m0nsta) #23

Maybe it needs an extra image/layer to create some fog?


(taw_m0nsta) #24

Don’t mind me talking to myself here.
What about making a bright black sun with a darkgray fog? (isNight 1 isn’t really working out, missing shadows under bridges and stuff)


(Dthy) #25

This thread should be re-named ‘m0nsta’s crazy ramblings’


(taw_m0nsta) #26

Suggestion accepted. :smiley:


(Susefreak) #27

[QUOTE=taw_m0nsta;379784]Yeah found them, and managed to give the trojan the same lights aswel.
Can anyone describe what these next values/settings do? The last 4 values define the position of the lights.

lightDef {
joint “cam_2”
lightType “standard”
color ( 6 6 6 )
group 0
noSelfShadow
shader “lights/headlights1b”
right ( 0 720 0 )
up ( 0 0 320 )
target ( 916 0 -16 )
offset ( -32 0 0 )
}
[/QUOTE]
1: Joint
Basically joint defines the place on the vehicle like in this example:

exitDef {
    joint   "exit_left_1"
}

Here it defines where you exit, in this it is exit at the left at the first door.

2: LightType
There are two options:

  • Standard, which toggles the light if the atmosphere is set to nightmode (don’t know the corresponding switch for nightmode in the atmospheres)
  • Brake, where the light will be lit if you hit the brakes

3: Color
Basically defines the light color. Don’t know the exact colour coding schem tho.

4: Group
You can group lights, eg headlights and mistlights, group needs to be a number

5:Noselfshadow
Explains itself doesn’t it?

6: Shader
Defines the shader

7: Right, up, target, offset
I believe those have to do with a vector, not completely sure how it works

I guess target is what you need to extend your lights range.


(taw_m0nsta) #28

Progression so far without using networkspawn/local stuff. If its too dark, you can simply brighten up your settings. I wanne make the lights stand out more, and add extra lights to the map. The only way if found doing that is by… another cfg. Its really a bummer that for some reason some settings do not seem to work without manually doing it.

Example of some code for adding extra lights by a .cfg written by |RR|SlippytheWeasel

//Main GDF Base Lights
setviewpos 10306.83 -11227.94 1543.55 355.32 -354.79 0.00
networkspawn light
setviewpos 9706.61 -11653.41 1480.5 88.91 -353.12 0.00
networkspawn light
setviewpos 9706.61 -11653.41 1480.5 266.21 -0.70 0.00
networkspawn light
setviewpos 9103.16 -11235.48 1543.56 178.52 -358.60 0.00

(Ashog) #29

damn, i want, i want!

i just freaking want to try this

amazing shots!


(taw_m0nsta) #30

Could anyone explain the fallowing?

I’m hunting the spawn light settings, for example ‘spawn light’ and ‘spawn light_interior’. This should create data like:

setviewpos

9103.16 = x
-11235.48 = y
1543.56 = z
178.52 = yaw = ?
-358.60 = pitch = ?
0.00 = roll = ?

The positions and settings could help me to figure out to make small modifications by extra lights into the map. Maybe mr SlippytheWeasel could explain how to write these settings to a file? I have read tutorial how to do it somewhere, but sadly I forgot to bookmark.

Here’s just an example what SlippytheWeasel was doing also:

So after my atmosphere file and sky images are optimized for darkness pretty well, sadly there isn’t a moonlight (still trying to figure out something to keep shadows of buildings), I took this building where you finish your MCP route:

And added some lights:

These new lights create shadows. Pretty sweet!

:slight_smile:

So, I guess by having these light location data, I should be able to script my own .tga lights and .mtr files, and add colored lights, and add more texture.


(Dthy) #31

Looks nice, but the light in the 3rd picture looks a tad to intense. A dimmer light would create a better feel imo.


(Ashog) #32

looks ok to me


(Violator) #33

Looks really good :slight_smile: Only one thing is that there should ideally be a light source to explain where the light is coming from (light fittings / bulbs etc.) where its been added indoors.


(Ashog) #34

it would have been needed when the new game was released back then, but now it’s 4 y/o and we know all the maps and things, so why caring to put in objects…
If even it is possible to place additional objects by scripting (like Chris did place the transmitter object to ATW3), I guess it is a nightmare to place all the lamps on all maps by hand (from what I remember he mentioned one needs to experimentally by error/success process find the exact 3D coordinates for object locations)…


(Violator) #35

But I need it done NAOW!! :smiley: It is possible to add in models via script but it would be pretty tedious.


(taw_m0nsta) #36

It indeed probably takes a lot of time to add the lights and a real light object. So far I havn’t touched any map to script light into… Actually thinking of a custom map, which is a lot small smaller.

This is how the light should data looks lights once its in a .entities script. (copy/past from refinery.entities)

{
	"light_radius"	"92 52 200"
	"projected"	"1"
	"light_target"	"0 0 -240"
	"light_up"	"0 -208 0"
	"light_right"	"-192 0 0"
	"light_origin"	"1872 1472 244"
	"texture"	"lights/squarelight"
	"maxVisDist"	"1024"
	"_color"	"1 0.86 0.71"
	"_overbright"	"1.00000"
	"noshadows"	"1"
	"drawSpec"	"medium"
	"name"	"<maps/references/refinery/civilian_building4>/torchy_light_11"
	"classname"	"light"
	"light_rotation"	"0 -1 0 1 0 0 0 0 1"
}

I am trying to figure out what all these values mean… :rolleyes:
And how I can duplicatie a light and add my own coordinates (from the location data I got from the adding ‘spawn lights’).
Pfff… Its probably easier if somebody makes a new fun ma, ads my atmosphere and just uses a lot of extra lights.


(Violator) #37

Best not to figure it all out but use this - http://wiki.splashdamage.com/index.php/Ambient_Light_Editor for ambient lights and the Light Editor (in editworld) for light entities.

An idea might be to work out where something is in a map say Refinery, then use editworld to build up your lighting using the point you worked out as a reference and offset with help from the prefabs that come with the SDK.


(.Chris.) #38
{
	"light_radius"	"92 52 200" //Size in game units of the light volume X,Y,Z.
	"projected"	"1" //Spot light? 0 = normal light 1 = spot light.
	"light_target"	"0 0 -240" //distance from the light origin of the target of the spot light.
	"light_up"	"0 -208 0" //Not sure
	"light_right"	"-192 0 0" //Not sure
	"light_origin"	"1872 1472 244" //world coordinates of the light.
	"texture"	"lights/squarelight" //material used for the light.
	"maxVisDist"	"1024" //distance from which the light is not longer visible.
	"_color"	"1 0.86 0.71" //Colour
	"_overbright"	"1.00000" //Overbright value, 1 = default.
	"noshadows"	"1" //Creates shadows? 0 = yes 1 = No.
	"drawSpec"	"medium" //Can define which machine spec is needed to draw the light, medium means low machine spec wont draw this.
	"name"	"<maps/references/refinery/civilian_building4>/torchy_light_11" //Just the entity name.
	"classname"	"light" //Entity type.
	"light_rotation"	"0 -1 0 1 0 0 0 0 1" //Rotation, cant remember why there is 9 numbers compared to the 3 in editor.
}

(taw_m0nsta) #39

Every time I open a .world file from sdk/maps/ in the editWorld I get this error, and then closes the SDK. Are the textures locked or something? My gosh… something tells me I should start with tutorial 001…



(taw_m0nsta) #40

I just did this first tutorial: http://www.youtube.com/watch?v=SVr4xiDBACw&feature=related
After compiling it as well in ‘base\maps’ as ‘base\maps\references\darkroom’


writing to: C:\Program Files\Steam\steamapps\common\enemy territory quake wars\base\maps\references\darkroom\darkroom.world
Saved maps/references/darkroom/darkroom.world in 0.00602537 seconds
--- StartWorldCompile ---
    6 total world brushes
    0 total bad brushes
    0 total world patches
    0 total world models
    0 total references
    4 entities
    0 bot entities
    0 total detail models
    0 LOD entities
    0 Imposter entities
   24 planes
    0 areaportals
    0 BSP-generating models
size: ( -128 -128 -64 ) to ( 128 128 64 )
renderable size: ( -128 -128 -64 ) to ( 128 128 64 )
----- WriteOutputFile -----
Writing maps/references/darkroom/darkroom.procb
writing to: C:\Program Files\Steam\steamapps\common\enemy territory quake wars\base\maps\references\darkroom\darkroom.procb
0 total shadow triangles
0 total shadow verts
writing maps/references/darkroom/darkroom.entities
writing to: C:\Program Files\Steam\steamapps\common\enemy territory quake wars\base\maps\references\darkroom\darkroom.entities
writing maps/references/darkroom/darkroom.bot_entities
writing to: C:\Program Files\Steam\steamapps\common\enemy territory quake wars\base\maps\references\darkroom\darkroom.bot_entities
-----------------------
Compile completed in 00
writing maps/references/darkroom/darkroom.cm
writing to: C:\Program Files\Steam\steamapps\common\enemy territory quake wars\base\maps\references\darkroom\darkroom.cm
writing maps/references/darkroom/darkroom.cmb
writing to: C:\Program Files\Steam\steamapps\common\enemy territory quake wars\base\maps\references\darkroom\darkroom.cmb
collision data:
     1 models
     8 vertices (0 kB)
    13 edges (0 kB)
     6 polygons (0 kB)
    24 polygon edges (0 kB)
     6 brushes (0 kB)
    36 brush planes (0 kB)
     0 nodes (0 kB)
     6 polygon refs (0 kB)
     6 brush refs (0 kB)
     4 internal edges
     0 sharp edges
    30 contained polygons removed
     0 polygons merged
     2 kB total memory used
-------------------------------------
Created collision map in 00
Compile finished.


and entering ‘devmap darkroom’ just like the tutorial shows, the console returns:
"User Map Start Denied ‘Unknown Campaign ‘darkroom’’.

I made .pk4 file of all the darkroom files and tried it agian, but the game as well in ‘WinXP > Steam > ETQW’, WinXP > SDK > ETQW and by OSX > CD > ETQW show the same error.

I know the map is very minimal, but it still should be able to play right?