Jump to content


Photo

My first map questions & work in progress

newbiequestions duh

231 replies to this topic

#26 nbohr1more

nbohr1more

    Darkmod PR, Wordsmith

  • Development Role
  • PipPipPipPipPip
  • 7425 posts

Posted 09 January 2017 - 05:49 PM

I'm not quite sure that this is really correct. By default, the projection image should be the image you actually see the light casting on a surface (in all six directions), and the falloff is either an image (which normally only need one row of pixels) or a function. I think most lights are using the latter and a linear function for the falloff.

 

 

Well, time to argue with Rich_is_Bored then:

 

701px-LT_Projectedlight.png

This has been the conventional wisdom at Doom3world.org and other Doom 3 mod sites for over a decade now.


Please visit TDM's IndieDB site and help promote the mod:

http://www.indiedb.c...ds/the-dark-mod

(Yeah, shameless promotion... but traffic is traffic folks...)

#27 Springheel

Springheel

    Creative Director (retired)

  • Admin
  • 36015 posts

Posted 09 January 2017 - 05:59 PM

When I put a single light with a basic round falloff inside a room, the same round falloff is visible on every surface, walls, ceilings and floors.  But when you use a different texture you can see it's not quite the case:

 

 

 

Attached Thumbnails

  • newjob_2017-01-09_17.58.02.jpg
  • newjob_2017-01-09_18.01.51.jpg

  • Judith and Spooks like this
Posted Image

#28 Obsttorte

Obsttorte

    Scripting guru, Mapper

  • Active Developer
  • PipPipPipPip
  • 4818 posts

Posted 09 January 2017 - 06:12 PM

Most light materials doesn't even define a falloff image, allthough I've read that there is a default one used then. I have to take a close look to see how it works, but the interaction shader does not obviously reflect one of both possibilities.

 

EDIT: Nbohr is right. Almost five years of mapping and finally I understood how lighting works  :( Will spend the rest of the evening crushing my head against the wall


  • nbohr1more likes this
FM's: Builder Roads, Old Habits, Old Habits Rebuild
WIP's: Several. Although after playing Thief 4 I really wanna make a city mission.
Mapping and Scripting: Apples and Peaches
Sculptris Models and Tutorials: Obsttortes Models
My wiki articles: Obstipedia
Let's Map TDM YouTube playlist: ObstlerTube
Texture Blending in DR: DR ASE Blend Exporter

End of shameless self promotion.

#29 Judith

Judith

    Member

  • Member
  • PipPip
  • 396 posts

Posted 09 January 2017 - 06:29 PM

 

 

Wow, I'm speechless right now :o that's tons of useful information, Biker! I kinda wish I had sent you something better than this crappy stuff, but you managed to make so much out of it anyway! Thanks for your time, and congrats on the map, it looks very promising. Quality wise it's the the level I'm aiming at in the future.

 

As for the doorway and room sizes, I used what I typically apply to T3/UT3 mapping: 64 x 128 is a size of typical doorway there, as the player collision model is around 48x 48 x 96. I don't know typical measurements in DR yet, but I'll find that out eventually.

 

Edit: Re: lights:

 

In my case a default light with biground1 texture looks like this:

image.jpg

 

While the same light using falloff_exp1 looks as it should:

image.jpg


Edited by Judith, 09 January 2017 - 06:56 PM.

  • nbohr1more likes this

#30 VanishedOne

VanishedOne

    Advanced Member

  • Member
  • PipPipPip
  • 719 posts

Posted 09 January 2017 - 07:10 PM

As for the doorway and room sizes, I used what I typically apply to T3/UT3 mapping: 64 x 128 is a size of typical doorway there, as the player collision model is around 48x 48 x 96. I don't know typical measurements in DR yet, but I'll find that out eventually.

http://wiki.thedarkm...n_of_Game_Units

http://wiki.thedarkm...Min,_Stats,_etc


Some things I'm repeatedly thinking about...

- louder scream when you're dying


#31 rich_is_bored

rich_is_bored

    Advanced Member

  • Member
  • PipPipPip
  • 833 posts

Posted 10 January 2017 - 01:11 AM

The reason something like big_round looks the same on all 6 sides of a room is because the center of the walls are closer to the source of the light than the corners. It's very hard to convey what is ultimately volumetric data in a 2D illustration.



#32 demagogue

demagogue

    Mod hero

  • Active Developer
  • PipPipPipPipPip
  • 5136 posts

Posted 10 January 2017 - 03:55 AM

Re: positive geometry and approaches to building, especially outdoor city and nature areas, after studying a lot of maps in DR, I find the best approach is to make large 5-10 sided boxes (fitting maybe 3-6 building facades. Something in the order of 20'-30' high and 30'x60' wide or whatever, plus or minus. 4 sides is ok but boxy) with bottleneck kiss points opening into other boxes which avoid long lines of sight through both boxes (so e.g. tunnels or right angles are useful to close the connecting portal quickly when you pass through. Or just have them at good angles so you never see through 2 of them).

One easy way to make such a box BTW is to draw out a large rectangular box in DR, then hit cntl+n, where n is the number of sides while it's selected. Then stretch out the box to the shape you want, and push the "make room" button to hollow it out so you can build inside. Then copy and paste walls to allow you to separate skybox, make "doorways" between boxes, etc. A slower way is just making angled walls for each side by hand.

You can make big detailed areas if you plan well. It's all about containing geometry and strategic placement of portals to close off areas efficiently.
  • Judith likes this
Posted Image

#33 Judith

Judith

    Member

  • Member
  • PipPip
  • 396 posts

Posted 10 January 2017 - 02:51 PM

I tried making my first custom material, I'm getting the hang of it. I'll probably create one .mtr file per material, because debugging anything with more than a few definitions in one file would be a pain for a GL code newbie like me. I could probably paste it all into one file later?

 

Since I'm using all those for myself, I kinda skipped the folder structure and used the naming convention I'm used to (_d, _n, _s), and it was nice that DR didn't complain about that at all. Having everything in textures/myfolder is also nice and quick. Putting textures into .pk4 every time I change something is not :) But, I can either use MindTex, as Biker suggested (Crazybump is still 100 bucks :o), or just preview textures in 3dsmax or Blender first.

 

By the way, since .pk4s are basically zip files, have you thought about supporting other compression formats? .7z was pretty efficient with Deadly Shadows maps, and I see that it handles Darkmod missions pretty well too. Volta and the Stone is a 100 mb zip file vs. 80 mb when compressed with 7zip, IMO that might be worth looking into.


Edited by Judith, 10 January 2017 - 02:52 PM.


#34 Obsttorte

Obsttorte

    Scripting guru, Mapper

  • Active Developer
  • PipPipPipPip
  • 4818 posts

Posted 10 January 2017 - 02:54 PM

You do not need to compress your files during mapping. Compression is only applied when shipping the files/mission.

 

Having a higher compression would be nice. But as most coding things, it will take its time to find its way into the code (if ever).


FM's: Builder Roads, Old Habits, Old Habits Rebuild
WIP's: Several. Although after playing Thief 4 I really wanna make a city mission.
Mapping and Scripting: Apples and Peaches
Sculptris Models and Tutorials: Obsttortes Models
My wiki articles: Obstipedia
Let's Map TDM YouTube playlist: ObstlerTube
Texture Blending in DR: DR ASE Blend Exporter

End of shameless self promotion.

#35 Melan

Melan

    Contest Winner, Wordsmith

  • Campaign Dev
  • PipPipPipPip
  • 4330 posts

Posted 10 January 2017 - 03:17 PM

Why not use NJob instead of Crazybump? It is free, fast, and functional. Makes great normals most of the time.


Come the time of peril, did the ground gape, and did the dead rest unquiet 'gainst us. Our bands of iron and hammers of stone prevailed not, and some did doubt the Builder's plan. But the seals held strong, and the few did triumph, and the doubters were lain into the foundations of the new sanctum. -- Collected letters of the Smith-in-Exile, Civitas Approved

#36 Judith

Judith

    Member

  • Member
  • PipPip
  • 396 posts

Posted 10 January 2017 - 03:23 PM

You're absolutely right Melan, and I'm using njob most of the time. It's the material preview I need, so I don't have to jump into the game every time I tweak something.

 

Also, I must be doing something wrong, because I have my .pk4 package in the main TDM folder, so I can see my textures and materials in the DR.

 

Edit: Oh, now I get it, I had to set up a path in a Mod (fs_game) to maps/myfolder for my stuff to appear in media browser. Whew, that will speed things up a bit.


Edited by Judith, 10 January 2017 - 03:28 PM.


#37 nbohr1more

nbohr1more

    Darkmod PR, Wordsmith

  • Development Role
  • PipPipPipPipPip
  • 7425 posts

Posted 10 January 2017 - 03:40 PM

Yep:

 

http://forums.thedar...older-settings/

 

Not sure why this isn't stickied.

 

Also, if you want realtime previews of your changes:

 

1) Open The Dark Mod in Windowed Mode

2) Make a placeholder material

3) Edit images that this placeholder points to

4) invoke reloadDecls in the console

5) invoke r_materialOverride "textures/darkmod/<your_material_name>"

6) When you make changes to the images, invoke reloadDecls to update

 

7) invoke r_materialOverride "" when you're done to disable the override


  • Judith likes this
Please visit TDM's IndieDB site and help promote the mod:

http://www.indiedb.c...ds/the-dark-mod

(Yeah, shameless promotion... but traffic is traffic folks...)

#38 Judith

Judith

    Member

  • Member
  • PipPip
  • 396 posts

Posted 10 January 2017 - 03:47 PM

Now that will speed things up, thank you! I couldn't update textures with the game running before, because of the .pk4 package (write protected by the system itself when used by the game). Well, this thread has a "duh" tag for a reason ;)


Edited by Judith, 10 January 2017 - 03:51 PM.


#39 Springheel

Springheel

    Creative Director (retired)

  • Admin
  • 36015 posts

Posted 10 January 2017 - 03:55 PM

reloaddecls will reload material files in real time.  reloadimages will be needed to see any changes to image files (and doesn't work with .dds, unfortunately).

 

And yes, TDM doesn't care about how many files there are for materialshaders...you can dump them all in one file once you're sure they're the way you want, or leave them in dozens.


  • Judith likes this
Posted Image

#40 Bikerdude

Bikerdude

    Mod hero

  • Active Developer
  • PipPipPipPipPip
  • 18086 posts

Posted 10 January 2017 - 03:56 PM

  • I tried making my first custom material, I'm getting the hang of it. I'll probably create one .mtr file per material, I could probably paste it all into one file later?
  • Since I'm using all those for myself, I kinda skipped the folder structure and used the naming convention I'm used to (_d, _n, _s), and it was nice that DR didn't complain about that at all. Having everything in textures/myfolder is also nice and quick. Putting textures into .pk4 every time I change something is not :) But, I can either use MindTex, as Biker suggested (Crazybump is still 100 bucks :o), or just preview textures in 3dsmax or Blender first.
  • Thats how I started doing it, and yes
  • Its actually not that hard and I can help you with the folder structure as you go. The startpack that you get from the wiki contains a number of the std/required folders - http://www.bloodgate...ms/startmap.pk4


#41 Bikerdude

Bikerdude

    Mod hero

  • Active Developer
  • PipPipPipPipPip
  • 18086 posts

Posted 10 January 2017 - 04:46 PM

http://forums.thedar...older-settings/

 

Not sure why this isn't stickied.

Good point, pinned!



#42 nbohr1more

nbohr1more

    Darkmod PR, Wordsmith

  • Development Role
  • PipPipPipPipPip
  • 7425 posts

Posted 10 January 2017 - 05:32 PM

reloaddecls will reload material files in real time.  reloadimages will be needed to see any changes to image files (and doesn't work with .dds, unfortunately).

 

And yes, TDM doesn't care about how many files there are for materialshaders...you can dump them all in one file once you're sure they're the way you want, or leave them in dozens.

 

If I'm reading the code correctly:

 

https://github.com/s...DeclManager.cpp

 

reloadDecls is a master reload command that calls the root "reload" command for all other reload types and should

cover images too.

 

I know I fiddled with this here:

 

http://forums.thedar...-14#entry395194

 

I never tested DDS so perhaps it will work better with reloadDecls?


Please visit TDM's IndieDB site and help promote the mod:

http://www.indiedb.c...ds/the-dark-mod

(Yeah, shameless promotion... but traffic is traffic folks...)

#43 Springheel

Springheel

    Creative Director (retired)

  • Admin
  • 36015 posts

Posted 10 January 2017 - 07:53 PM

I can't speak to what the code says, but I know how it works in practice.  reloaddecls does not reload .tga files.  reloadimages does.  Neither will reload .dds files.


Posted Image

#44 Judith

Judith

    Member

  • Member
  • PipPip
  • 396 posts

Posted 11 January 2017 - 03:47 AM

I spent a lot of time dealing with .dds textures in T3Ed, I'll gladly stick to .tga this time.



#45 Obsttorte

Obsttorte

    Scripting guru, Mapper

  • Active Developer
  • PipPipPipPip
  • 4818 posts

Posted 11 January 2017 - 04:46 AM

From the performance point of view dds should be the better choice, although I can't say how much the performance benefits from it. Using tga is more convenient, though.


  • Judith likes this
FM's: Builder Roads, Old Habits, Old Habits Rebuild
WIP's: Several. Although after playing Thief 4 I really wanna make a city mission.
Mapping and Scripting: Apples and Peaches
Sculptris Models and Tutorials: Obsttortes Models
My wiki articles: Obstipedia
Let's Map TDM YouTube playlist: ObstlerTube
Texture Blending in DR: DR ASE Blend Exporter

End of shameless self promotion.

#46 Judith

Judith

    Member

  • Member
  • PipPip
  • 396 posts

Posted 11 January 2017 - 05:16 AM

I might do the conversion later, if it helps with performance. I have an older laptop with 2,5 GHz CPU and GF 740M, that should be enough for initial tests. I generally assume that should have 60 fps everywhere, on both desktop PC and laptop, and any drops bigger than 5 fps need troubleshooting.


Edited by Judith, 11 January 2017 - 05:20 AM.


#47 Bikerdude

Bikerdude

    Mod hero

  • Active Developer
  • PipPipPipPipPip
  • 18086 posts

Posted 11 January 2017 - 05:35 AM

As you have an nVidia cpu you will be fine, you will only start seeing a slow down on the very largest maps.

Regarding .DDS and .TGA files, your better getting into the habit of working with them from the get go. So from a workflow perspective, when it comes time to alpha or beta test the map you can copy and convert the textures folder into .DDS - I can help you with that.

#48 Judith

Judith

    Member

  • Member
  • PipPip
  • 396 posts

Posted 11 January 2017 - 09:00 AM

After some headache (the game didn't detect my textures, only editor did) I managed to get it right. reloadimages indeed works with TGAs and it's faster than texture tweaks in external software.



#49 Bikerdude

Bikerdude

    Mod hero

  • Active Developer
  • PipPipPipPipPip
  • 18086 posts

Posted 11 January 2017 - 09:24 AM

You will need to convert to .DDS before you release the map though.

#50 Springheel

Springheel

    Creative Director (retired)

  • Admin
  • 36015 posts

Posted 11 January 2017 - 11:55 AM

Regarding .DDS and .TGA files, your better getting into the habit of working with them from the get go

 

 

Why?


Posted Image



Reply to this topic



  


0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users