Download

Changing code without closing the Editor ?

Ive started a simple project with code + side scroller
I have my VS open and unreal, but to build in VS i must close the editor, but if i click Compile in the editor, my changes aren’t picked up

currently the only change ive made is messing with this number :



CameraBoom->TargetArmLength = 500.f;


Do I have to change how my VS is setup for this to work properly? Or something in my editor?

Cheers for any info !

Yes I thinks that’s normal since when you build from VS you create a new dll but the editor is not aware of it. For simple changes you can build from the editor directly, this will generate a temporary dll that the editor will load automatically.

If you make changes to the constructor, add a new class or new functions, then you need to close the editor and build it with VS.

ok yeah, changes to contructor, new class/func that seems legit !

What quantifies as “simple changes” ?

can I edit a function on the fly ?



void DoSomething()
{
// forgot to add line to do the thing!
}


while the editor is running I can add the line I forgot ?



void DoSomething()
{
print("some string");
}


I think you can. Try it out?

Yes that works, if you click compile in the editor that should work just fine.

I think anything that doesn’t change the definition of a class is a “simple” change, that can be recompiled from the Editor while it’s running. If you add, remove or change any of the functions or variables of a class, you have to quit the editor and compile in VS. I’m not entirely sure about constructors.