Please or Register to create posts and topics.

What is "instances" in custom maps and how to use it?

Hello,

I'm new at this forum, so maybe i have a lot to ask. A thing i want to ask is some maps i downloaded are included with an "instances" folder. I knew nothing about this. What is this folder? What is the effects to the map? How to use/install it?

Thanks in advance

Instances are little prefabrications saved as vmf files with the logic set up and it's own parameters and IO system, so you don't have to remake complex stuff like droppers. Outputs are shown in a dropdown menu when you type "instance" but you should know how they work, so look it up on the VDC or look at solarchronus's channel on YouTube for how to make or use them. You don't need them to play maps. Those are for whoever wants to use them. They are placed in your steam/steamapps/portal 2/SDK_content/maps/instances.

If you just want to play the maps, they don't do anything. They only matter if you're building or editing a map. :)

Falsi sumus crusto!

Instances are; as ysihbarr mentioned; pre-made vmfs.

They offer you an easy way to put stuff in your map, as mentioned, they're great for cubedroppers for example. You only have to make one once and you can just put it in any map, valve even added a lot of useful instances to the game by default!

This makes mapping a lot faster and easier. An additional advantage is that if you change the instance it is automatically updated throughout all maps that use that instance. That means; you don't have to apply that change to all the different places where you used that instance. Just re-compiling the same map with the same vmf but with a different instance will give the updated instance!

To use them create a func_instance; browse to the appropriate vmf and load it.
Make sure to give the instance a fixup name and once you want to give input/output to the instance all valid options should be avaiable.

Some articles about the topic in the Wiki:

- Instance

- Working with instances

- Func_instance

... it's all about searching ;)

ImageImageImageImageImageuseful tools and stuff here on TWP :thumbup:
[spoiler]ImageImageImageImageImage[/spoiler]
Lpfreaky90 wrote:
Instances are; as ysihbarr mentioned; pre-made vmfs.

They offer you an easy way to put stuff in your map, as mentioned, they're great for cubedroppers for example. You only have to make one once and you can just put it in any map, valve even added a lot of useful instances to the game by default!

This makes mapping a lot faster and easier. An additional advantage is that if you change the instance it is automatically updated throughout all maps that use that instance. That means; you don't have to apply that change to all the different places where you used that instance. Just re-compiling the same map with the same vmf but with a different instance will give the updated instance!

To use them create a func_instance; browse to the appropriate vmf and load it.
Make sure to give the instance a fixup name and once you want to give input/output to the instance all valid options should be avaiable.

Thank you for the explanation!
Cheers

also; please put hammer related questions in the hammer and modding category.
I did it now :)