I need some help regarding 3D Skyboxes.

Discussion in 'Mapping Questions & Discussion' started by Kazagin, Aug 19, 2009.

  1. Kazagin

    Kazagin L3: Member

    Messages:
    130
    Positive Ratings:
    9
    My map is getting close to being done, so I decided that I'd start work on the detailing.
    The first thing I did was try to make a Skybox...
    It didn't go completely as planned.

    I followed [ame="http://forums.tf2maps.net/showthread.php?t=116"]this[/ame] guide, and I managed to screw it up... :facepalm:

    My 3D Skybox was going to be something simple, an extension of the water surrounding my map (it's an island, by the way) with some odds and ends floating around.

    To achieve the effect I was going for, I copied my water brush (the 1:16 one that was being used as reference), made it about three times as big, and deleted the original one from the Skybox.
    Currently, my 3D Skybox is nothing but a big water brush which I hope will simulate the appearance of an ocean.

    I copied my brushes, pasted them outside the 2D Skybox, shrank them down to 1:16 size, copied the mini-water brush, deleted everything else, pasted the mini-water brush, made it bigger, and put a Skybox brush around it.

    When I compiled and ran it, the water was invisible.
    It registered that there was water, but I could not see it.
    As a matter of fact, nothing that is fully submerged in the water shows up.

    Is there anything I could have forgotten to do that would have caused this?
     
  2. An Icy Mouse

    aa An Icy Mouse

    Messages:
    205
    Positive Ratings:
    34
    You didnt run vvis, or you have a leak, or another error causing vvis not ro tun.

    Make 100% sure you have no leaks (map>load pointfile to find them) and then once vvis has run your water will show up.

    (this is covered in the stickies and common mistakes btw, shame on you for not looking there)
     
    • Thanks Thanks x 1
  3. Kazagin

    Kazagin L3: Member

    Messages:
    130
    Positive Ratings:
    9
    Sorry about not checking the stickies. :(
    I remembered "Interlopers" when I checked the sticky. I checked the compile log and found this: make_triangles:calc_triangle_representation: cannot convert
    It says that it can be caused by bad displacements or models.
    I didn't change any displacements and the only model I added since the last compile was the Swamp Theme's Buoy.

    Here's my compile log:

    ** Executing...
    ** Command: "c:\program files (x86)\steam\steamapps\kazagin\sourcesdk\bin\orangebox\bin\vbsp.exe"
    ** Parameters: -game "c:\program files (x86)\steam\steamapps\kazagin\team fortress 2\tf" "C:\Program Files (x86)\Steam\SteamApps\kazagin\sourcesdk_content\tf\mapsrc\Almost_done7"

    Valve Software - vbsp.exe (May 19 2009)
    2 threads
    materialPath: c:\program files (x86)\steam\steamapps\kazagin\team fortress 2\tf\materials
    Loading C:\Program Files (x86)\Steam\SteamApps\kazagin\sourcesdk_content\tf\mapsrc\Almost_done7.vmf
    Brush 47322, Side 1: duplicate plane
    Brush 47322, Side 2: duplicate plane
    Brush 47322, Side 3: duplicate plane
    Brush 47322, Side 4: duplicate plane
    Brush 47322, Side 5: duplicate plane
    Brush 47322, Side 6: duplicate plane
    Brush 47322, Side 7: duplicate plane
    Brush 47322, Side 57: duplicate plane
    Brush 47322, Side 58: duplicate plane
    Brush 47322, Side 59: duplicate plane
    Brush 47322, Side 60: duplicate plane
    Brush 47322, Side 61: duplicate plane
    Brush 47322, Side 62: duplicate plane
    Brush 47322, Side 63: duplicate plane
    Patching WVT material: maps/almost_done7/egypt/sand_grass_blend_01_wvt_patch
    fixing up env_cubemap materials on brush sides...
    ProcessBlock_Thread: 0...1...2...3...4...5...6...7...8...9...10 (0)
    ProcessBlock_Thread: 0...1...2...3...4...5...6...7...8...9...10 (0)
    Processing areas...done (0)
    Building Faces...done (1)
    Chop Details...done (0)
    Find Visible Detail Sides...done (0)
    Merging details...done (0)
    FixTjuncs...
    PruneNodes...
    WriteBSP...
    done (0)
    writing C:\Program Files (x86)\Steam\SteamApps\kazagin\sourcesdk_content\tf\mapsrc\Almost_done7.prt...Building visibility clusters...
    done (0)
    Creating default LDR cubemaps for env_cubemap using skybox materials:
    skybox/sky_hydro_01*.vmt
    ! Run buildcubemaps in the engine to get the correct cube maps.
    Creating default HDR cubemaps for env_cubemap using skybox materials:
    skybox/sky_hydro_01*.vmt
    ! Run buildcubemaps in the engine to get the correct cube maps.
    Finding displacement neighbors...
    Found a displacement edge abutting multiple other edges.
    Finding lightmap sample positions...
    Displacement Alpha : 0...1...2...3...4...5...6...7...8...9...10
    Building Physics collision data...
    done (1) (28870 bytes)
    Placing detail props : 0...1...2...3...4...5...6...7...8...9...10
    Water found with no water_lod_control entity, creating a default one.
    Compacting texture/material tables...
    Reduced 338 texinfos to 214
    Reduced 22 texdatas to 20 (550 bytes to 437)
    Writing C:\Program Files (x86)\Steam\SteamApps\kazagin\sourcesdk_content\tf\mapsrc\Almost_done7.bsp
    12 seconds elapsed
    45.544853 53.568756 0.000000
    45.544853 48.266350 0.000000
    45.544853 58.391907 0.000000
    22.698223 59.145172 0.000000
    make_triangles:calc_triangle_representation: Cannot convert
    45.544853 53.568756 0.000000
    45.544853 48.266350 0.000000
    45.544853 58.391907 0.000000
    22.698223 59.145172 0.000000
    make_triangles:calc_triangle_representation: Cannot convert
    45.544853 53.568756 0.000000
    45.544853 48.266350 0.000000
    45.544853 58.391907 0.000000
    22.698223 59.145172 0.000000
    make_triangles:calc_triangle_representation: Cannot convert

    ** Executing...
    ** Command: "c:\program files (x86)\steam\steamapps\kazagin\sourcesdk\bin\orangebox\bin\vvis.exe"
    ** Parameters: -game "c:\program files (x86)\steam\steamapps\kazagin\team fortress 2\tf" -fast "C:\Program Files (x86)\Steam\SteamApps\kazagin\sourcesdk_content\tf\mapsrc\Almost_done7"

    Valve Software - vvis.exe (May 19 2009)
    fastvis = true
    2 threads
    reading c:\program files (x86)\steam\steamapps\kazagin\sourcesdk_content\tf\mapsrc\Almost_done7.bsp
    reading c:\program files (x86)\steam\steamapps\kazagin\sourcesdk_content\tf\mapsrc\Almost_done7.prt
    43 portalclusters
    109 numportals
    BasePortalVis: 0...1...2...3...4...5...6...7...8...9...10 (0)
    Optimized: 0 visible clusters (0.00%)
    Total clusters visible: 1765
    Average clusters visible: 41
    Building PAS...
    Average clusters audible: 41
    visdatasize:858 compressed from 688
    writing c:\program files (x86)\steam\steamapps\kazagin\sourcesdk_content\tf\mapsrc\Almost_done7.bsp
    0 seconds elapsed

    ** Executing...
    ** Command: "c:\program files (x86)\steam\steamapps\kazagin\sourcesdk\bin\orangebox\bin\vrad.exe"
    ** Parameters: -game "c:\program files (x86)\steam\steamapps\kazagin\team fortress 2\tf" -noextra "C:\Program Files (x86)\Steam\SteamApps\kazagin\sourcesdk_content\tf\mapsrc\Almost_done7"

    Valve Software - vrad.exe SSE (May 19 2009)

    Valve Radiosity Simulator
    2 threads
    [Reading texlights from 'lights.rad']
    [34 texlights parsed from 'lights.rad']

    Loading c:\program files (x86)\steam\steamapps\kazagin\sourcesdk_content\tf\mapsrc\Almost_done7.bsp
    Setting up ray-trace acceleration structure... Done (11.12 seconds)
    5352 faces
    15704065 square feet [2261385472.00 square inches]
    78 Displacements
    3740103 Square Feet [538574848.00 Square Inches]
    5352 patches before subdivision
    245246 patches after subdivision
    sun extent from map=0.087156
    sun extent from map=0.087156
    3 direct lights
    BuildFacelights: 0...1...2...3...4...5...6...7...8...9...10 (49)
    BuildVisLeafs: 0...1...2...3...4...5...6...7...8...9...10 (145)
    transfers 15238602, max 1432
    transfer lists: 116.3 megs
    GatherLight: 0...1...2...3...4...5...6...7...8...9...10 (0)
    Bounce #1 added RGB(49282, 48789, 19185)
    GatherLight: 0...1...2...3...4...5...6...7...8...9...10 (0)
    Bounce #2 added RGB(61394, 50057, 25773)
    GatherLight: 0...1...2...3...4...5...6...7...8...9...10 (0)
    Bounce #3 added RGB(4288, 3237, 1034)
    GatherLight: 0...1...2...3...4...5...6...7...8...9...10 (0)
    Bounce #4 added RGB(4062, 2436, 666)
    GatherLight: 0...1...2...3...4...5...6...7...8...9...10 (0)
    Bounce #5 added RGB(319, 179, 35)
    GatherLight: 0...1...2...3...4...5...6...7...8...9...10 (1)
    Bounce #6 added RGB(291, 130, 19)
    GatherLight: 0...1...2...3...4...5...6...7...8...9...10 (0)
    Bounce #7 added RGB(24, 10, 1)
    GatherLight: 0...1...2...3...4...5...6...7...8...9...10 (0)
    Bounce #8 added RGB(22, 7, 1)
    GatherLight: 0...1...2...3...4...5...6...7...8...9...10 (1)
    Bounce #9 added RGB(2, 1, 0)
    GatherLight: 0...1...2...3...4...5...6...7...8...9...10 (0)
    Bounce #10 added RGB(2, 0, 0)
    GatherLight: 0...1...2...3...4...5...6...7...8...9...10 (0)
    Bounce #11 added RGB(0, 0, 0)
    Build Patch/Sample Hash Table(s).....Done<0.3535 sec>
    FinalLightFace: 0...1...2...3...4...5...6...7...8...9...10 (30)
    FinalLightFace Done
    0 of 0 (0% of) surface lights went in leaf ambient cubes.
    ThreadComputeLeafAmbient: 0...1...2...3...4...5...6...7...8...9...10 (29)
    Writing leaf ambient...done
    Ready to Finish

    Object names Objects/Maxobjs Memory / Maxmem Fullness
    ------------ --------------- --------------- --------
    models 3/1024 144/49152 ( 0.3%)
    brushes 68/8192 816/98304 ( 0.8%)
    brushsides 611/65536 4888/524288 ( 0.9%)
    planes 1274/65536 25480/1310720 ( 1.9%)
    vertexes 5368/65536 64416/786432 ( 8.2%)
    nodes 2158/65536 69056/2097152 ( 3.3%)
    texinfos 214/12288 15408/884736 ( 1.7%)
    texdata 20/2048 640/65536 ( 1.0%)
    dispinfos 78/0 13728/0 ( 0.0%)
    disp_verts 22542/0 450840/0 ( 0.0%)
    disp_tris 39936/0 79872/0 ( 0.0%)
    disp_lmsamples 1654346/0 1654346/0 ( 0.0%)
    faces 5352/65536 299712/3670016 ( 8.2%)
    hdr faces 0/65536 0/3670016 ( 0.0%)
    origfaces 387/65536 21672/3670016 ( 0.6%)
    leaves 2162/65536 69184/2097152 ( 3.3%)
    leaffaces 5537/65536 11074/131072 ( 8.4%)
    leafbrushes 2450/65536 4900/131072 ( 3.7%)
    areas 3/256 24/2048 ( 1.2%)
    surfedges 23753/512000 95012/2048000 ( 4.6%)
    edges 12040/256000 48160/1024000 ( 4.7%)
    LDR worldlights 2/8192 176/720896 ( 0.0%)
    HDR worldlights 0/8192 0/720896 ( 0.0%)
    leafwaterdata 2/32768 24/393216 ( 0.0%)
    waterstrips 55/32768 550/327680 ( 0.2%)
    waterverts 0/65536 0/786432 ( 0.0%)
    waterindices 795/65536 1590/131072 ( 1.2%)
    cubemapsamples 0/1024 0/16384 ( 0.0%)
    overlays 0/512 0/180224 ( 0.0%)
    LDR lightdata [variable] 8545468/0 ( 0.0%)
    HDR lightdata [variable] 0/0 ( 0.0%)
    visdata [variable] 858/16777216 ( 0.0%)
    entdata [variable] 4318/393216 ( 1.1%)
    LDR ambient table 2162/65536 8648/262144 ( 3.3%)
    HDR ambient table 2162/65536 8648/262144 ( 3.3%)
    LDR leaf ambient 10938/65536 306264/1835008 (16.7%)
    HDR leaf ambient 2162/65536 60536/1835008 ( 3.3%)
    occluders 0/0 0/0 ( 0.0%)
    occluder polygons 0/0 0/0 ( 0.0%)
    occluder vert ind 0/0 0/0 ( 0.0%)
    detail props [variable] 1/12 ( 8.3%)
    static props [variable] 1/57986 ( 0.0%)
    pakfile [variable] 106660/0 ( 0.0%)
    physics [variable] 28870/4194304 ( 0.7%)
    physics terrain [variable] 37958/1048576 ( 3.6%)

    Level flags = 0

    Total triangle count: 11446
    Writing c:\program files (x86)\steam\steamapps\kazagin\sourcesdk_content\tf\mapsrc\Almost_done7.bsp
    4 minutes, 29 seconds elapsed

    ** Executing...
    ** Command: Copy File
    ** Parameters: "C:\Program Files (x86)\Steam\SteamApps\kazagin\sourcesdk_content\tf\mapsrc\Almost_done7.bsp" "c:\program files (x86)\steam\steamapps\kazagin\team fortress 2\tf\maps\Almost_done7.bsp"


    ** Executing...
    ** Command: c:\program files (x86)\steam\steam.exe
    ** Parameters: -applaunch 440 -game "c:\program files (x86)\steam\steamapps\kazagin\team fortress 2\tf" +map "Almost_done7"
     
  4. Terr

    aa Terr Cranky Coder

    Messages:
    1,591
    Positive Ratings:
    405
    I wouldn't worry about that one unless you've tried everything else... even some of Valve's SDK releases do that, I've found one or two bugged models which--no matter how often I delete and add them from scratch--cause the error.

    Fix the red stuff. Maybe bad vertex editing. If you edit a vertex, you can't have two adjacent faces that are in the same plane.

    I don't have Hammer where I am right now, so I can't give you 100% tested answers, but the following diagram may help.

    [​IMG]

    P.S.: How do you get 63 sides to a single brush anyway?
     
    • Thanks Thanks x 1
    Last edited: Aug 19, 2009
  5. BlueDarkness

    BlueDarkness L1: Registered

    Messages:
    26
    Positive Ratings:
    2
    Wait, so what exactly does your 3D Skybox look like?

    From what you wrote I can only guess the following:

    You didn't actually create your 3D skybox outside the original, but around it?
    Your 3D skybox has no floor(?) which might be why you can't see the water.
    You did not specify in your post whether or not you used the sky_camera entity.

    My main guess is the second. While working on a map I made a water brush that was not surrounded by any sort of land and it caused the water to disappear ingame.

    Anyway hope my questions helped. I might be wrong, but that's ok! :D
     
    • Thanks Thanks x 1
  6. Kazagin

    Kazagin L3: Member

    Messages:
    130
    Positive Ratings:
    9
    I surrounded the water with "nodraw", and that didn't help.
    Also, when I fly to the Skybox In-Game using Noclip, I find myself inside a giant version of my volcano. (Which is where 0,0,0 and my Sky_camera are.)

    Sorry for going off topic, but my computer crashed while starting up TF2 after a compile and now I get an error "c:\program files (x86)\steam\steamapps\kazagin\team fortress2\tf\gameinfo.txt is not a valid format." when I try to open up Hammer.
    Can anyone tell me how to fix that? I tried restarting my computer, that didn't work.
     
  7. Altaco

    Altaco L7: Fancy Member

    Messages:
    485
    Positive Ratings:
    121
    The skybox should be surrounded with toolsskybox texture, not nodraw.

    Also the sky_camera doesn't go at 0,0,0 in your MAP, it goes where 0,0,0 would be in your 3d skybox if it were your map, if I'm making sense.
     
    • Thanks Thanks x 1
  8. Kazagin

    Kazagin L3: Member

    Messages:
    130
    Positive Ratings:
    9
    I knew I did something wrong.
    Once I get Hammer back up and running, I'll re-do my Skybox.
    Thanks everyone. :D
    Also, Altaco, my 3D Skybox consists of a tools/skybox brush (hollowed) with a water brush fenced in with nodraw.
    I was pretty foggy on the details... My bad. :facepalm:
     
  9. Kazagin

    Kazagin L3: Member

    Messages:
    130
    Positive Ratings:
    9
    That's it, Hammer is trying to make me mad.
    I followed the guide TO THE LETTER and my Skybox water still won't show up!
    I made the water nearly as big as the original map so that it would look like a never-ending ocean.
    Why? Why isn't my 3D Skybox showing up?
    EDIT: I forgot to mention that TF2 crashes if I try to "noclip" into the Skybox...
     
    Last edited: Aug 21, 2009
  10. Steff0o

    Steff0o L6: Sharp Member

    Messages:
    295
    Positive Ratings:
    115
    Found it

    Never use fastvis this is the problem...

    Edit: vvis and vrad must both run at normal to compile water
     
    • Thanks Thanks x 1
    Last edited: Aug 21, 2009
  11. grazr

    aa grazr Old Man Mutant Ninja Turtle

    Messages:
    5,436
    Positive Ratings:
    3,564
    Huh, i never realised. I'm inclined to double check this as i'm pretty sure i've managed a fast compile and got water to render.
     
    • Thanks Thanks x 1
  12. Steff0o

    Steff0o L6: Sharp Member

    Messages:
    295
    Positive Ratings:
    115
    oh, then it was that they only had to run
    i have srcsdk not available right no so i cant check
     
    • Thanks Thanks x 1
  13. potatocubed

    potatocubed L1: Registered

    Messages:
    21
    Positive Ratings:
    7
    You can definitely get water to render with fast vvis. I've never once run a normal-speed vvis, but I can see the sloshy wet stuff just fine.

    What it does need to render, I think, is a cubemap entity? Perhaps the 3D skybox needs a cubemap entity of its own.
     
    • Thanks Thanks x 1
  14. Steff0o

    Steff0o L6: Sharp Member

    Messages:
    295
    Positive Ratings:
    115
    does it have a underground texture beneath the water?
    becausew you can look trough it
     
    • Thanks Thanks x 1
  15. A Boojum Snark

    aa A Boojum Snark Toraipoddodezain Mazahabado

    Messages:
    4,769
    Positive Ratings:
    5,531
    What's the exact name of the water material you are using.
     
    • Thanks Thanks x 1
  16. Kazagin

    Kazagin L3: Member

    Messages:
    130
    Positive Ratings:
    9
    I can't get in to Source SDK right now (Game is currently unavailable) but I remember that it is the "expensive" water from 2Fort.
    Also, I got the normal (Not in the Skybox) water to compile, but my 3D Skybox water still isn't showing up.
     
  17. Kazagin

    Kazagin L3: Member

    Messages:
    130
    Positive Ratings:
    9
    Ok, Hammer is back up and running.
    The name of the water I'm using (both in my 3D Skybox and in the game-world)
    is "water/water_2fort_expensive"
     
  18. Waif

    Waif L7: Fancy Member

    Messages:
    413
    Positive Ratings:
    125
    As the others said, make sure a ground brush is below the water in the skybox, aand don't use expensive water either as it hurts fps too much.
     
    • Thanks Thanks x 1
  19. Kazagin

    Kazagin L3: Member

    Messages:
    130
    Positive Ratings:
    9
    Is there a "3D Skybox for Dummies" guide anywhere?
    I hope so, because I can not get my 3D Skybox to work properly.

    I can get the Skybox Water to show up, but only when I'm INSIDE the 3D Skybox.
    Any other time, it won't show up.

    Why is this happening? What am I missing? How do I get water in my 3D Skybox to work?

    Also, my water IS in a ground brush.
    I have a water_lod_control thing and everything!

    Update: I tried putting a Skybox Model (The Cargo-ship from Granary) in my Skybox, and it won't show up unless I'm inside the 3D Skybox.

    Double Update: As a last-ditch effort, I opened CP_Granary in Hammer, and I figured out what was going wrong! :D
    I was using the "2D Skybox" texture to make the Game World's Skybox. (The one surrounding the actual map)
    I re-made the Main-Map's Skybox using the "tools/Skybox" texture, not the "tools/skybox2d" texture and it works! :D
    Thanks, everyone.
     
    Last edited: Aug 23, 2009