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"

Pointer to incomplete class type

Cant find the reason why im getting this error. It says on SpotLightPicker "pointer to incomplete class type is not allowed". SpotLightPicker is a UPROPERTY SpotLightActor type. Current is a normal float variable, im trying to get the Spot light VolumetricScatteringIntensity value and set it on Current since its also a float value.

Code:

 Current = SpotLightPicker->SpotLightComponent->VolumetricScatteringIntensity;

Product Version: UE 4.18
Tags:
more ▼

asked Mar 16 '18 at 06:39 AM in C++ Programming

avatar image

Shadowjonny
46 3 6 10

avatar image j.mueller RFG Mar 16 '18 at 01:35 PM

Is it possible that ASpotLight is included but not USpotLightComponent? Then the compiler would know how to handle SpotLightPicker but not how to access VolumetricScatteringIntensitiy from SpotLightComponent in the line you provided. If so, try to also include SpotLightComponent.h

avatar image Shadowjonny Mar 16 '18 at 06:38 PM

that worked #include "Components/SpotLightComponent.h". For some reason i though that Spotlight.h already had it so i didnt include it.

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

1 answer: sort voted first

try

 #inlcude "Runtime/Engine/Classes/Components/SpotLightComponent.h"
more ▼

answered Mar 16 '18 at 03:23 PM

avatar image

Nazdorovye
54 1 5 9

(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