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"

I cannot access C++ class properties from Blueprints with a hot reload?

Is it a bug that I cannot access C++ class properties from Blueprints with a hot reload? I do have to restart the editor first.

Product Version: Not Selected
Tags:
more ▼

asked Dec 05 '14 at 04:33 AM in Bug Reports

avatar image

birdfreeyahoo
880 46 45 80

avatar image Tim C ♦♦ STAFF Dec 09 '14 at 06:19 PM

Hi birdfreeyahoo,

I did some quick testing on this issue, and was not able to see what you described. Would you be able to provide some additional information?

  • What version of the Engine are you using?

  • Are you using the binary version installed by the Launcher, or did you build the Engine from source code?

  • Are you able to reproduce this issue in a new project?

  • Can you provide the code you are using/changing in your class?

  • Do you have the Blueprint open when you are performing the Hot Reload?

  • Any additional information you can provide would be helpful.

Tim

avatar image InfectedFPS Dec 14 '14 at 02:49 AM

Hi Tim, Not OP, but I am getting the same issue as him. Whenever I hot reload some times properties will not be available in blueprints.

To answer your questions:

  • I am using version 4.6

  • I am using the binary version installed via the launcher

  • I have not tried on a new project, but I have had it happen a few times on my current one. I can try again after this weekend (Working on the Game Jam project :P )

  • Here is the code I added to my class: UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = "Pikcups") bool bDestroyed;

  • I do not recall I will take note of this next time and report back on that. My gut response at the moment would be yes I do have the BP open while doing the hot reload.

  • I cannot think of any at this time. If I encounter anything else that I think would be pertinent to looking into this I will follow up with a reply

Thanks! :D

avatar image Tim C ♦♦ STAFF Dec 23 '14 at 04:32 PM

Hi Craig,

Have you had a chance to experiment with this issue any further? I tried to reproduce it again and was still unable to do so. This is what I did:

  • Create a new project using the code first person template.

  • Build the project in Visual Studio.

  • Open the project in the Editor.

  • Add a new Actor code class to the project.

  • Close the Editor.

  • Build the project in Visual Studio.

  • Open the project in the Editor.

  • Create a Blueprint using the new Actor class.

  • Add the UPROPERTY that you provided above.

  • Built the project in Visual Studio with the Editor still open (I had the Blueprint open as well).

  • The Hot Reload completes and the Defaults tab in the Blueprint refreshed and showed the new bool property.

Do you see anything different from what you are doing when you see this issue?

avatar image InfectedFPS Dec 24 '14 at 06:25 AM

The only thing I see different is that you close the editor after adding the new class. Usually I add the class then recompile in VS2013 to trigger it in the Hot Reload.

avatar image Tim C ♦♦ STAFF Dec 30 '14 at 04:26 PM

I just ran through my test again without closing the Editor after adding a new Actor class. I received the same results as before, but I did have another question for clarification. When you say that a new property is not available in Blueprints, where are you looking for them? We are aware of an issue where adding a UPROPERTY variable to a class and performing a Hot Reload will not make the Get/Set nodes appear in a right-click search for the variable in the Event Graph. However, the variable will still appear correctly in the Defaults tab and the My Blueprint panel.

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

1 answer: sort voted first

Hi Everyone,

We have not heard back from you for a few days. Do you still need any help with this issue? I will be marking this question as resolved for tracking purposes, but please feel free to re-open this question if you need any more help.

Tim

more ▼

answered Jan 08 '15 at 09:27 PM

avatar image Footman Feb 27 '15 at 06:31 PM

I got this issue sometimes in 4.7 too. Same problem: Mark variable as BlueprintReadOnly and have to restart editor to see changes. Hotreload does not help.

This does not happen always but often.

avatar image Tim C ♦♦ STAFF Mar 03 '15 at 11:28 PM

Hi Footman,

Where are you looking for changes to appear in the Blueprint when you change the UPROPERTY to BlueprintReadOnly? I ran some tests that involved changing BlueprintReadWrite to BlueprintReadOnly and vice versa, and saw results similar to what I had mentioned before (after the hot reload, the nodes for the variable did not appear in the right-click search results). I went ahead and filed a report about this since it is a very specific case, whereas the previous report had been more general (UE-11270). They may be related.

Tim

avatar image Aizenhar Mar 30 '15 at 02:22 AM

I get errors after compiling (image). This occurs after adding new properties/functions to my Actor class, like the code below:

 UFUNCTION(BlueprintCallable, Category="Damage")
 void CalculateValues();

or

 UFUNCTION (BlueprintImplementableEvent, Category = "Damage")
 CalledFromCpp void ();

alt text

avatar image Tim C ♦♦ STAFF Apr 15 '15 at 10:24 PM

Hi Ivan,

I set up a code class with a couple BlueprintCallable functions, then created a Blueprint of that class. Then I added another BlueprintCallable function and performed a hot reload. When I clicked Compile in the Blueprint, I did not receive any errors. I was using 4.7.5 at the time. What version are you using when you see these errors?

Tim

avatar image Tim C ♦♦ STAFF Apr 30 '15 at 07:28 PM

Hi Ivan,

We have not heard back from you for a while. Is this something that is still a problem for you? I will mark this post as resolved again, but please feel free to add a comment and re-open this post if you need any more help. We have quite a few improvements to hot reloading in relation to Blueprints that are coming in the next version.

Tim

(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