Ok im putting a fence around much of the map to keep from leaving the gameplay are. It is taking much more fence and time than i originally thought. Right now all ive bin doing is duplicating a segment of fence over and over and just putting it at the end of the last duplicate. Im just curiouse if im doing it wrong by making so many small segments of the fence. My map is hilly so i cant just duplicate a large section. Also on a side note, is there some way to make all of my small fence segments one object or are they going to have to stay many? Thanks for any help or pointers.
Use lots of fence segments, so the renderer can auto-skip the ones that won’t be on the screen. If you somehow bake the fence into one model, Unity has to draw the entire thing each frame. Note that in childing they still count as separate fences, for drawing purposes. If you happen to have lots of long, flat areas, it might help the framerate a tiny amount to have a different longFence model.
A trick I’ve used to place lots of small objects is to first make a prefab with maybe 8 of them in an empty, lined up in a generic good way (fences all end-to-end.) Drag one of those out, place and tilt it about right, then make adjustments to the individual ones.
Maybe make another prefab named “cornerFence” where they are pre-positioned sort of cornery, if you make enough corners.
When you’re done with fences, put them all in one empty named “borderFence” to keep them from cluttering up the window. You can always drag them all out again for the final build, if you need to (parenting non-moving objects probably won’t affect frame-rate.)