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"

Add screens to HUD on input?

Hi, I am making a game with the idea of multiple viewpoints at once. We are accomplishing this by drawing textures on the HUD. We are able to create 2 at runtime using this code.

 AMyHUD::AMyHUD(const FObjectInitializer& ObjectInitializer) : Super(ObjectInitializer)
 {
 // Set the crosshair texture
 static ConstructorHelpers::FObjectFinder<UTexture> CrosshiarTexObj(TEXT("/Game/Material/T_Map1"));


 MiniTexture = CrosshiarTexObj.Object;

 static ConstructorHelpers::FObjectFinder<UTexture> CrosshiarTexObj2(TEXT("/Game/Material/T_Map3"));


 MiniTexture2 = CrosshiarTexObj2.Object;
 }

 void AMyHUD::DrawHUD()
 {
 Super::DrawHUD();
 
 float ScreenX = 0;
 float ScreenY = 0;
 float ScreenW = 0;
 float ScreenH = 0;
 
 ScreenW = 300;
 ScreenH = 300;
 drawTexture(MiniTexture, ScreenX, ScreenY, ScreenW, ScreenH);
 
 ScreenX = 600;
 drawTexture(MiniTexture2, ScreenX, ScreenY, ScreenW, ScreenH);
 
 }

And in the player controller I want to add a camera to the HUD with

 InputComponent->BindAction("EKey", IE_Released, this, /*Function to add camera here*/);

Any ideas on how to do this? We are not committed to using the HUD for our screens, it just happened to be the first thing that worked.

Product Version: Not Selected
Tags:
more ▼

asked Jan 13 '15 at 01:06 AM in C++ Programming

avatar image

Godzilla2500
1 2 3 3

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

0 answers: sort voted first
Be the first one to answer this question
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