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"

Open level and call an event in a level blueprint

Hi everyone,

So this is what I want to do,

Call an event from a triggerbox, once the player overlaps it, to open LoadingMenu.umap and then call an event named GoToNextLevel which is in the level blueprint of LoadingMenu.umap.

How do I do this?

Product Version: Not Selected
Tags:
more ▼

asked Jun 12 '15 at 11:42 PM in Blueprint Scripting

avatar image

ShrewGlue
434 97 83 108

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

1 answer: sort voted first

a bit vague in how much detail you actually need. assuming you have the event made already...

maybe just click on the box in the editor so its selected > click open level blueprint > event graph > right click and type "onactorbegin" (you should see overlap node, click it) (you can also find it manually after right clicking and choosing "add event for box > collision> on actor begin overlap"

Drag out a node from it and type "open level" > add that node > fill in the name of the LoadingMenu (without the extension)

See what happens.

In the LoadingMenu Map.. go it its level blueprint and add node EventBeginPlay drag out and run your custom event.

May want to add a 5 second delay between the custom event and begin play... at least at first to make sure its all working.. it may load your loadingmap and then the next one before you see whats going on

more ▼

answered Jun 13 '15 at 12:43 AM

avatar image

thankstipscom
654 39 38 72

avatar image ShrewGlue Jun 13 '15 at 03:04 PM

Thanks, although I had everything set up except for the execution of the event. I plan to use this loadingMenu between all levels, so an event begin play would not work. I just need to execute the custom event.

avatar image thankstipscom Jun 13 '15 at 05:44 PM

sure create a blueprint as a child of player state call it MyPlayerState or CustomPlayerState. Make sure your project is using it in the editor settings

Open the new blueprint and create a name variable called nextMap

when the player overlaps the box, before you load the lodainglevel do this

get player state > cast to MyPlayerState > (in myplayerstate) set nextMap variable

type the name of the next level to be loaded to set that variable. so if the current map is level01..then this box would set the variable to level02 and you'd do the same thing in level02 but nextmap would be level03... etc...

then in the loading map instead of just loading a specified map,

cast to MyPlayerState > GET nextMap variable > pipe it into your custom event thats loading the next map name.

thats it. can still use event begin play as the trigger or event begin play > timer and type the name of the event

avatar image ShrewGlue Jun 13 '15 at 05:53 PM

Is there another way to do this without a player state?

Like open the level, cast to the level name, and then see If i can execute an event in the blueprint level?

(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