x

Search in
Sort by:

Question Status:

Search help

  • Simple searches use one or more words. Separate the words with spaces (cat dog) to search cat,dog or both. Separate the words with plus signs (cat +dog) to search for items that may contain cat but must contain dog.
  • You can further refine your search on the search results page, where you can search by keywords, author, topic. These can be combined with each other. Examples
    • cat dog --matches anything with cat,dog or both
    • cat +dog --searches for cat +dog where dog is a mandatory term
    • cat -dog -- searches for cat excluding any result containing dog
    • [cats] —will restrict your search to results with topic named "cats"
    • [cats] [dogs] —will restrict your search to results with both topics, "cats", and "dogs"

How to set cull distance on dynamically spawned meshes inside a blueprint?

I have a dungeon generator that spawns some tile blueprints during runtime. The blueprints it spawns are just movable mesh components laid out in various ways. The game can start to slow down pretty a lot as I spawn more but i noticed if the camera is by the edge or these tiles pointing out to nothing the frame rate is fine so i guess the view culling is working it's magic for me there. From this I decided to set up culling using a cull distance volume but it doesn't seem to affect the meshes in the blueprints I spawn and I can't see anywhere else to set the cull distance for these meshes.

So my question is...Is it possible to have meshes inside a blueprint component cull at a certain distance?

Product Version: Not Selected
Tags:
more ▼

asked May 17 '14 at 02:15 AM in Rendering

avatar image

mrcrocker
126 8 20 25

(comments are locked)
10|2000 characters needed characters left
Viewable by all users

1 answer: sort voted first

Hi mrcrocker -

You can set up a distance check between your spawned items and the Player's Pawn which could function as a check condition in order to spawn and again if the player moves outside the set distance you could then destroy the spawned items only to have the return if the player returns. This method could be some what costly as you are running Event Ticks which do the distance calculation from the actor to every possibly spawned component. Without knowing exactly how you are triggering your spawned elements, its hard to say how to best integrate a check like that into your blueprints.

Let me know if I can elaborate further -

Eric Ketchum

more ▼

answered May 19 '14 at 03:22 PM

avatar image

Lovecraft_K ♦♦ STAFF
36.6k 703 260 737

avatar image mrcrocker May 19 '14 at 05:07 PM

Hi Eric,

Thanks for the reply. Because of the way the level is generated I don't think what you suggested would work in this case but it's definitely an interesting idea that I'm sure will come in handy somewhere else down the line.

The type of game I'm making is top down random dungeons so the camera is positioned similar to in the top down template. After play testing it some more I found that the camera view culling alone was actually more than enough to keep a frame rate of 120fps (even with more meshes/blueprints being spawned than the game would actually need). So since the camera won't move in my level I'm good to just leave it as is.

(comments are locked)
10|2000 characters needed characters left
Viewable by all users
Your answer
toggle preview:

Up to 5 attachments (including images) can be used with a maximum of 5.2 MB each and 5.2 MB total.

Follow this question

Once you sign in you will be able to subscribe for any updates here

Answers to this question