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 can I save map at runtime in Blueprints?

I have a problem, guys. I made a building system wich works pretty well, but how can I save the map in blueprints at runtime? Keep in mind that the objects are placed at runtime in the world and they are not already placed. So, I don't do anything if I save their location. Please, help!

Product Version: UE 4.13
Tags:
more ▼

asked Mar 07 '17 at 09:21 PM in Blueprint Scripting

avatar image

Midsoft Games
41 1 3 10

avatar image jaidendc Sep 19 '18 at 09:34 PM

were you able to save the whole map?

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

1 answer: sort voted first

You need to make a Save Game for this case. Create a struct with the world transform and the actor type and everything else you need. When you want to save your map, you need to fill an array in your Save Game with these structs and save it.

To load the map you need to load the Save Game on start and spawn the actors according to the array you got from your Save Game.

more ▼

answered Mar 07 '17 at 10:37 PM

avatar image

SteffM
407 12 3 20

avatar image Althaen Mar 07 '17 at 11:02 PM

They should also save the name of the level they want to save as a string in the Save Game. Use the Get Current Level Name node to get the value.

avatar image SteffM Mar 07 '17 at 11:58 PM

Or use the Level name as the name for the Save Game, so you always can check for every Level if a Save Game exists and if yes, load it automatically without the need to specify a Name for each Level.

avatar image Midsoft Games Mar 08 '17 at 07:49 AM

Thanks a lot guys! I will try that and I will let you know.

avatar image Midsoft Games Mar 08 '17 at 10:04 PM

I tried what you said, but I got stuck at the part with spawning them. Can you explain a little more in detail? Bucause the Spawn Actor from class node spawns one object type. And if I place two or more objects using my building system...it won't work. Can you make a test project of what you meant and send it to me, please? And don't do a complex building system because that's not the point. Just make a line trace by channel and spawn a cube at the impact point of the line trace. Thanks! :)

(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