Editor only UFUNCTIONS and UPROPERTIES

Ungalyant
Mon, 30 Jan 2017 17:52:13 +0000
Platform & Builds

Hey guys, so something I’m struggling with at the moment, in relation to my last question (which I’m in the process of trying to answer through this question):

Unreal Engine Forums – 27 Jan 17

Packaging error: Non-editor build cannot depend on non-redistributable modules

This is a question that I know has come up before. I’ve looked at some existing answers: I’ve attempted to implement the fixes they recommend, and I’m trying to package our project for windows 64-bit and still getting this error. My Build.cs...

Is there a way to have UPROPERTY() variables that exist for editor use only?

I can simply surround a variable declaration with #if WITH_EDITOR pragmas, but it seems if this variable is a UPROPERTY() the engine looks for it at runtime even in a non-editor build, I assume this is because of something in the generated class. Blueprint editable editor only variables are a nice solution for us to simply make editing information easier without bloating the actual build. Is there any way to actually implement something like this?

Cheers for any thoughts you guys have!

4 posts - 1 participant