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"

What variable to use with Map Name/ Level name?

Does any one know what variable these noob should use to save Map Name( Level Name (LV1, LV2, LV3 ETC..) For instance for Player location I would obiviously use Player Location node for Velocity I would Player Velocity node but What do you use for Map Name. Would it be Get current level and if so what type of variable goes with MapName. I gues Name variable but I thought I seen some one use Integer. I could be wrong. Super thanks to anyone who can dismental these problem for me!!!

Product Version: UE 4.15
Tags:
more ▼

asked Dec 11 '17 at 06:58 AM in Using UE4

avatar image

silverfish1000
124 12 23 29

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

3 answers: sort voted first

Ok thank you. What I really needed was the <<< GET CURRENT LEVEL NAME >> > node. So I can save it to Game Instance and then get info out from it with UMG on button pressed. That's the best way to get MAP NAME!!

alt text

alt text

more ▼

answered Dec 12 '17 at 10:46 AM

avatar image

silverfish1000
124 12 23 29

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

They take Name variable. How you store and fetch the value depends on your game. There's most likely as many ways of doing this as there are people:

alt text

Or like this, storing just 2 ints (which can be in a 2d vector):

alt text

Again, it all depends on how complex your game is. You can just get an array of names and Get 0,1,2 and so on... This question has too many answers. A predefined array is most likely the most logical in most situations unless you're dealing with procedurally generated content.

capture.png (115.9 kB)
cap2.png (70.4 kB)
more ▼

answered Dec 11 '17 at 08:32 AM

avatar image

Everynone
15.2k 77 25 62

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

Another way is to set up a UWorld property in your blueprint of type SoftObjectPath. This allows you to select directly a level from the content browser without relying on strings, which are error-prone.

The additional benefits are that if you change your level name, it will be propagated to your property, you won't have to go in your blueprints to manually update the names.

And since it's a soft object path, the level won't be loaded so you don't have to worry about memory.

more ▼

answered Dec 11 '17 at 11:03 AM

avatar image

Zoubi
172 22 30 35

(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