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"

Teleport after pressing HUD Button

Hello everybody. I apologize but I'm still not very experienced with Blueprint Scripting. I am working on a game in which I would like to activate the teleportation function following a button pressed in the hud. My problem concerns the communication between HUD and Character blueprints. If someone has a solution to my problem or can tell me a youtube tutorial i will be very pleased.

Product Version: UE 4.18
Tags:
more ▼

asked Jan 10 '18 at 11:00 AM in Blueprint Scripting

avatar image

ftd89
1

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

1 answer: sort voted first

Hey there, on your widget do the following:

  • Create a variable called Player and set it to the type of your character

  • On event construct do Get Owning Player Pawn, cast it to the type of your character and save that to the Player variable

  • On the mouse clicked event you get the Player variable and do with him what you want (call a function, use Set Actor Location to teleport, etc)

It is similar to this image:

alt text

more ▼

answered Jan 10 '18 at 12:27 PM

avatar image

xlar8or
6k 163 129 305

avatar image ThompsonN13 Jan 10 '18 at 03:31 PM

you can add the functionality for the teleport either in the widget or just have the widget call a function that executes within the player BP

(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