[SOLVED] Fog and global_ents instance

Avatar
Konke
161 Posts
Posted May 03, 2014
So, as far as I'm concerned I need to have a global_ents instance in my map to be able to release it correctly on Steam Workshop. Let me know if I'm confused. The global ents instance has fog controllers which I'm able to command through the proxy (I'm learning about proxies). So far I've managed to figure out how to active the different fog presets which are in the global ents instance, but what if I would like to configure fog on my own?

I tried to create a fog entity but I guess it's in conflict with the fog entities in the global ents instance. I also tried to set the fog entity to master but that didn't help. Any ideas? Thanks in advance!

Advertisement
Registered users don't see ads! Register now!
Avatar
TeamSpen210
608 Posts
Posted May 03, 2014
Replied 3 hours later
You need to have the PTI ents, so you can trigger the voting screen and play the random cave quotes. It's in "instances/p2editor/global_pti_ents.vmf". Set $disable_pti_audio to 1 to stop Cave's lines from playing, or 0 to keep them. You probably want to keep the lines unless you have some sort of story element to your map. Send it an input (@relay_pti_level_end) when your map is finished.
Avatar
Konke
161 Posts
Posted May 04, 2014
Replied 13 hours later
Ah, my mistake. Perhaps I mixed the global_ents with pti_ents. Yes, I suppose pti_ents is for the map to work with Steam Workshop, and I got the global_ents to get the elevators to work. At least that's what TopHATTwaffle told me to do in his tutorial video.

However, the problem remains. I can't seem to controll fog on my own. Any other suggestions?

Avatar
Konke
161 Posts
Posted May 04, 2014
Replied 34 minutes later
I got the env_fog_controller to work now. I used trigger_multiple instead of fog_volume to trigger it. The only thing now is that the player needs to be inside the fog_volume for the fog to work. That wasn't the case with the fog controllers from the global_ents instance. There I could use a trigger_multiple to active the selected fog and it would still apply once outside of the trigger_multiple.
Avatar
josepezdj
2,386 Posts
Posted May 04, 2014
Replied 3 minutes later
Get rid of the global_ents and just use an env_fog_controller. Name it, let's say '@fog_controller', and now use a logic_auto for example with this output:

- OnMapSpawn > !player > SetFogController > @fog_controller

Also, maybe you are just not noticing the fog. Try lowering the parameter Fog End to 1000 for example, and start to set the desired fog amount you want in your map from there.

Avatar
Konke
161 Posts
Posted May 04, 2014
Replied 39 minutes later

josepezdj wrote:
Get rid of the global_ents and just use an env_fog_controller. Name it, let's say '@fog_controller', and now use a logic_auto for example with this output:

- OnMapSpawn > !player > SetFogController > @fog_controller

Also, maybe you are just not noticing the fog. Try lowering the parameter Fog End to 1000 for example, and start to set the desired fog amount you want in your map from there.

Why should I get rid of the global_ents? Isn't it needed? At least for the starting and ending elevators?

Thanks for the tip, I'll look into the commands! And I always try to see if a new option works by making it extreme, for instance this fog of mine was green and red so I'd see it in action. And with the fog_volume it works but I'd rather see it triggable without the fog_volume. I'll try to see how your commands work! Thanks!

Avatar
greykarel
225 Posts
Posted May 04, 2014
Replied 3 hours later
Global_ents has nothing to do with elevators, it contains the basic global entities needed to adjust the tonemapping and fog for different maps in campaign. You can use it in your map triggering through proxies or just use an env_fog_controler with your own settings which you can turn on/off by triggers.
Avatar
Dafflewoctor
415 Posts
Posted May 04, 2014
Replied 21 minutes later
Using global_ents is totally a preference. Josepezdj suggested that you removed the instance and just used custom fog. Creating your own fog can, if done correctly, have a much more desired effect on the map than the fog global_ents can give it. Sometimes that's not the case and global_ents can look much better.
Avatar
Konke
161 Posts
Posted May 04, 2014
Replied 52 minutes later
Thanks for the replies. So, if I don't want to use the global_ents's fog, I don't see any other reason to have it. I implemented it to my map because a video tutorial told me to, and I can't say I remember why. So, I can just delete the whole global_ents instance, nothing else will happen, will it?
Avatar
Dafflewoctor
415 Posts
Posted May 04, 2014
Replied 4 hours later

Konke wrote:
Thanks for the replies. So, if I don't want to use the global_ents's fog, I don't see any other reason to have it. I implemented it to my map because a video tutorial told me to, and I can't say I remember why. So, I can just delete the whole global_ents instance, nothing else will happen, will it?

If you delete the global_ents instance, you'll need to set up custom fog or else there won't be any in the map. TopHATTwaffle has a great tutorial on it.

Avatar
Konke
161 Posts
Posted May 05, 2014
Replied 20 hours later
Indeed it's a great tutorial. I just had a short conversation with him about the matter to keep the global_ents or not. He said that the global_ents instance contains base entities that most other instances call, like a client/server command. I take it it's good to keep then.

I think I've found a workaround for the fog and it seems to be working. I controll my own fog_controller with a fog volume, and the volume will just have to be over the most part of the map. I'm not sure how official this solution is but at least it's working and I guess that's all that matters.

Avatar
srs bsnss
552 Posts
Posted May 06, 2014
Replied 1 day later
Global ents will save you time down the track with other things. For example:

  • It provides the '@autosave' entity, which is an easy way to save the game via entities (OnTrigger > @autosave > Save).
  • You can change environments, which includes color correction, tonemapping, fog, etc, on the fly very easily.
  • It provides the required entities for choreographed scenes, so that you only need to worry about a logic_choreo_scene entity, as opposed to involving generic_actors.

Basically, it can save you time for other things, outside of fog triggers (although that's its main use). You can get rid of it if you want, though; nothing bad will happen if you don't have it.

Avatar
Konke
161 Posts
Posted May 07, 2014
Replied 1 day later

srs bsnss wrote:
Global ents will save you time down the track with other things. For example:

  • It provides the '@autosave' entity, which is an easy way to save the game via entities (OnTrigger > @autosave > Save).
  • You can change environments, which includes color correction, tonemapping, fog, etc, on the fly very easily.
  • It provides the required entities for choreographed scenes, so that you only need to worry about a logic_choreo_scene entity, as opposed to involving generic_actors.

Basically, it can save you time for other things, outside of fog triggers (although that's its main use). You can get rid of it if you want, though; nothing bad will happen if you don't have it.

Thanks for the great reply! As long as the instance doesn't slow the performance down I think I'll keep it around. I'll try to implement autosaves on a later notice aswell.

Advertisement
Registered users don't see ads! Register now!
Avatar
Konke
161 Posts
Posted Jun 16, 2014
Replied 1 month later
Autosave works fine thanks to you @srs bsnss. My map is getting close to the finnish line.